autoproj 2.0.3 → 2.1.0.rc1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +196 -10
  3. data/autoproj.gemspec +8 -8
  4. data/bin/alocate +12 -1
  5. data/bin/alog +8 -0
  6. data/bin/amake +12 -1
  7. data/bin/aup +12 -1
  8. data/bin/autoproj_bootstrap +15 -6
  9. data/bin/autoproj_install +15 -6
  10. data/lib/autoproj/cli/base.rb +15 -0
  11. data/lib/autoproj/cli/bootstrap.rb +3 -0
  12. data/lib/autoproj/cli/build.rb +6 -0
  13. data/lib/autoproj/cli/clean.rb +13 -5
  14. data/lib/autoproj/cli/doc.rb +8 -0
  15. data/lib/autoproj/cli/envsh.rb +3 -5
  16. data/lib/autoproj/cli/inspection_tool.rb +0 -16
  17. data/lib/autoproj/cli/main.rb +71 -52
  18. data/lib/autoproj/cli/main_test.rb +4 -0
  19. data/lib/autoproj/cli/osdeps.rb +5 -6
  20. data/lib/autoproj/cli/show.rb +1 -1
  21. data/lib/autoproj/cli/status.rb +77 -19
  22. data/lib/autoproj/cli/update.rb +16 -26
  23. data/lib/autoproj/configuration.rb +5 -0
  24. data/lib/autoproj/environment.rb +11 -1
  25. data/lib/autoproj/local_package_set.rb +2 -0
  26. data/lib/autoproj/manifest.rb +16 -0
  27. data/lib/autoproj/ops/cache.rb +3 -0
  28. data/lib/autoproj/ops/configuration.rb +3 -2
  29. data/lib/autoproj/ops/install.rb +13 -4
  30. data/lib/autoproj/ops/main_config_switcher.rb +3 -3
  31. data/lib/autoproj/ops/snapshot.rb +4 -7
  32. data/lib/autoproj/package_definition.rb +10 -0
  33. data/lib/autoproj/package_managers/bundler_manager.rb +1 -0
  34. data/lib/autoproj/package_managers/pip_manager.rb +1 -0
  35. data/lib/autoproj/package_set.rb +39 -6
  36. data/lib/autoproj/test.rb +8 -0
  37. data/lib/autoproj/version.rb +1 -1
  38. data/lib/autoproj/workspace.rb +13 -1
  39. data/samples/autoproj/README.md +60 -0
  40. data/samples/autoproj/init.rb +17 -18
  41. data/samples/autoproj/manifest +18 -34
  42. data/samples/autoproj/overrides.d/.gitattributes +1 -0
  43. data/samples/manifest.xml +2 -7
  44. metadata +64 -36
  45. data/samples/autoproj/README.txt +0 -52
  46. data/samples/autoproj/overrides.rb +0 -4
  47. data/samples/autoproj/overrides.yml +0 -18
  48. data/samples/osdeps.yml +0 -65
@@ -1,3 +1,3 @@
1
1
  module Autoproj
2
- VERSION = "2.0.3"
2
+ VERSION = "2.1.0.rc1"
3
3
  end
@@ -333,6 +333,14 @@ def rewrite_shims
333
333
  Ops::Install.rewrite_shims(binstubs, config.ruby_executable, gemfile, config.gems_gem_home)
334
334
  end
335
335
 
336
+ def update_bundler
337
+ require 'autoproj/ops/install'
338
+ gem_program = Ops::Install.guess_gem_program
339
+ install = Ops::Install.new(root_dir)
340
+ Autoproj.message " updating bundler"
341
+ install.install_bundler(gem_program, silent: true)
342
+ end
343
+
336
344
  def update_autoproj(restart_on_update: true)
337
345
  config.validate_ruby_executable
338
346
 
@@ -478,6 +486,10 @@ def load_packages(selection = manifest.default_packages(false), options = Hash.n
478
486
  ops = Ops::Import.new(self)
479
487
  ops.import_packages(selection, options)
480
488
  end
489
+
490
+ def load_all_available_package_manifests
491
+ manifest.load_all_available_package_manifests
492
+ end
481
493
 
482
494
  def setup_all_package_directories
483
495
  # Override the package directories from our reused installations
@@ -613,7 +625,7 @@ def export_installation_manifest
613
625
  end
614
626
 
615
627
  # Export the workspace's env.sh file
616
- def export_env_sh(package_names = all_present_packages, shell_helpers: true)
628
+ def export_env_sh(package_names = nil, shell_helpers: true)
617
629
  env = self.env.dup
618
630
  manifest.all_selected_source_packages.each do |pkg|
619
631
  pkg.autobuild.apply_env(env)
@@ -0,0 +1,60 @@
1
+ This is the main build configuration of an autoproj installation
2
+
3
+ See http://rock-robotics.org/stable/documentation/autoproj for detailed information about autoproj.
4
+
5
+ Assuming that this build configuration is on e.g. github at
6
+ https://github.com/myorg/buildconf, a workspace based on this build
7
+ configuration can be bootstrapped using:
8
+
9
+ ```
10
+ wget http://rock-robotics.org/autoproj_bootstrap
11
+ ruby autoproj_bootstrap git https://github.com/myorg/buildconf
12
+ ```
13
+
14
+ Once bootstrapped, the main build configuration is checked out in the
15
+ workspace's `autoproj/` folder.
16
+
17
+ ## Day-to-day workflow
18
+
19
+ `aup` updates the current package (or, if within a directory, the packages
20
+ under that directory). Use `--all` to update the whole workspace.
21
+
22
+ `amake` build the current package (or, if within a directory, the packages
23
+ under that directory). Use `--all` to build the whole workspace.
24
+
25
+ `autoproj status` will show the difference between the local workspace and
26
+ the remote repositories
27
+
28
+ `autoproj show PACKAGE` will display the configuration of said package, which
29
+ includes whether that package is selected in the current workspace ("a.k.a.
30
+ will be updated and built") and the import information (where the package
31
+ will be downloaded from)
32
+
33
+ ## Autoproj configuration structure
34
+
35
+ The main build configuration tells autoproj about:
36
+
37
+ - which extra configurations should be imported ("package sets") in the
38
+ `package_sets` section of the `manifest`. Once loaded, these package
39
+ sets are made available in the `remotes/` subfolder of this configuration.
40
+ - which packages / package sets should be built in the `layout` section of
41
+ the `manifest`
42
+ - which local overrides should be applied on package import (e.g. allowing
43
+ to change a package's import branch or URL) in `.yml` files located in
44
+ the `overrides.d` folder.
45
+
46
+ Overall, autoproj does the following with its configuration:
47
+
48
+ - load package description by (1) importing the package sets listed in
49
+ `manifest` and (2) loading the `.autobuild` files in the imported package sets.
50
+ Imported package sets are made available in the `remotes/` folder of this
51
+ directory.
52
+ - resolve the import information (which can be inspected with `autoproj show`)
53
+
54
+ ## Using extra RubyGems in an autoproj workspace
55
+
56
+ One can add new gems to a workspace, without passing through autoproj's osdeps
57
+ system, by adding new `.gemfile` files to the workspace's
58
+ `autoproj/overrides.d/` folder. These files must follow
59
+ [Bundler](http://bundler.io) gemfile format
60
+
@@ -1,23 +1,22 @@
1
- # Write in this file customization code that will get executed before all the
2
- # soures are loaded.
1
+ # Define the github handler
2
+ require 'autoproj/git_server_configuration'
3
3
 
4
- # Set the path to 'make'
5
- # Autobuild.commands['make'] = '/path/to/ccmake'
4
+ # Comment this line if you want Autoproj to import the overall shell
5
+ # environment. The default is to reset all build-related environment variables,
6
+ # forcing the build configuration to set them explicitly, to improve
7
+ # repeatability
8
+ Autoproj.isolate_environment
6
9
 
7
- # Set the parallel build level (defaults to the number of CPUs)
8
- # Autobuild.parallel_build_level = 10
10
+ # Display CMake/GCC build messages
11
+ Autobuild::CMake.show_make_messages = true
9
12
 
10
- # Uncomment to initialize the environment variables to default values. This is
11
- # useful to ensure that the build is completely self-contained, but leads to
12
- # miss external dependencies installed in non-standard locations.
13
+ # Install each package in a separate directory of install/
13
14
  #
14
- # set_initial_env
15
- #
16
- # Additionally, you can set up your own custom environment with calls to env_add
17
- # and env_set:
18
- #
19
- # env_add 'PATH', "/path/to/my/tool"
20
- # env_set 'VAR', "value"
21
- #
22
- # Variables set like this are exported in the generated env.sh scripts.
15
+ # This makes the dependencies stricter, so builds that were fine without this
16
+ # option might fail with it. However, it is also cleaner (allows to remove
17
+ # obsolete package byproducts easily) and allows to turn the
18
+ # delete_obsolete_files_in_prefix CMake option, in which autoproj's cmake
19
+ # handler will remove installed files that are not part of the package anymore.
20
+ Autoproj.config.separate_prefixes = true
21
+ Autobuild::CMake.delete_obsolete_files_in_prefix = Autoproj.config.separate_prefixes?
23
22
 
@@ -2,51 +2,35 @@
2
2
  # package set definitions.
3
3
  package_sets:
4
4
  # Examples from the Rock package set
5
- # - type: git
6
- # url: git://gitorious.com/rock/package_set.git
5
+ # - github: rock-core/package_set
7
6
 
8
- # The layout section specifies what to build, and where to build it (as a
9
- # subdirectory of the root installation directory). In the example below, all
10
- # the packages of the rubim.orocos package set will be built, in the tools/
11
- # subdirectory: source in tools/typelib, tools/orocos/rtt, ... and installed
12
- # files in build/tools/typelib, build/tools/orocos/rtt, ...
7
+ # The layout section specifies what to build. Can include both whole package sets or single packages.
13
8
  #
14
9
  # layout:
15
- # - rock:
16
- # - rock.toolchain
10
+ # - rock.core
17
11
  #
18
- # Single packages can also be selected instead of whole package sets. The
19
- # package names are interpreted as a regular expression, so it is possible to
20
- # do:
21
- #
22
- # layout:
23
- # - tools:
24
- # - typelib
25
- # - utilmm
26
- # - orocos/
27
- #
28
- # The first two match the typelib and utilmm packages, while the second one
29
- # match all packages in which "orocos/" is found.
30
- #
31
- # Again, note that if a layout section is present, only the packages listed
32
- # there will be built.
33
12
 
34
13
  # Package exclusion: packages can be completely excluded from the build. This is
35
- # an alternative way than using the layout, mainly useful if you want to enable
36
- # all packages but a few ones. As with layout, the names are actually regular
37
- # expressions.
14
+ # an alternative way than using the layout.
15
+ #
16
+ # Useful if you want to enable a whole package set except a few packages, or if
17
+ # you want to exclude some package's optional dependencies.
38
18
  #
39
19
  # exclude_packages:
40
- # - orocos/
20
+ # - gui/.*
41
21
 
42
- # Ignoring packages: same principle than package exclusion, but this time the
43
- # packages are considered to be installed and up-to-date. This is useful if you
44
- # want to use an already installed software package.
22
+ # Ignoring packages: assume that some packages are present on disk. Unlike
23
+ # exclude_packages, autoproj will not generate an error if a non-excluded
24
+ # package depends on an ignored one, but it will not include the package and its
25
+ # dependencies in the build.
26
+ #
27
+ # For instance, if one assumes that the 'rtt' package is already available on
28
+ # the machine *and* you're confident that picking it outside of the workspace
29
+ # won't create problems, then simply do:
45
30
  #
46
- # For instance, let's assume the orocos/rtt is already installed on your
47
- # machine. You would then simply do:
31
+ # Note that using this obviously hinders repeatability of the build
48
32
  #
49
33
  # ignored_packages:
50
- # - orocos/rtt
34
+ # - rtt
51
35
  #
52
36
 
@@ -0,0 +1 @@
1
+ *.gemfile diff=rb
data/samples/manifest.xml CHANGED
@@ -10,11 +10,6 @@
10
10
 
11
11
  <depend package="pkgname"/>
12
12
  <depend package="common"/>
13
- <rosdep name="python" />
14
- <versioncontrol type="svn" url="https://playerstage.svn.sourceforge.net/svnroot/playerstage/code/player/trunk"/>
15
- <export>
16
- <cpp cflags="-I${prefix}/include" lflags="-L${prefix}/lib -lros"/>
17
- <cpp os="osx" cflags="-I${prefix}/include" lflags="-L${prefix}/lib -Wl,-rpath,-L${prefix}lib -lrosthread -framework CoreServices"/>
18
- </export>
19
-
13
+ <!-- depend can handle both source and osdep packages -->
14
+ <depend package="python" />
20
15
  </package>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: autoproj
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.3
4
+ version: 2.1.0.rc1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sylvain Joyeux
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-24 00:00:00.000000000 Z
11
+ date: 2017-07-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -30,28 +30,34 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: 1.10.0.a
33
+ version: 1.11.0.a
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: 1.10.0.a
40
+ version: 1.11.0.a
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: utilrb
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: 3.0.0
45
48
  - - ">="
46
49
  - !ruby/object:Gem::Version
47
- version: '3.0'
50
+ version: 3.0.0
48
51
  type: :runtime
49
52
  prerelease: false
50
53
  version_requirements: !ruby/object:Gem::Requirement
51
54
  requirements:
55
+ - - "~>"
56
+ - !ruby/object:Gem::Version
57
+ version: 3.0.0
52
58
  - - ">="
53
59
  - !ruby/object:Gem::Version
54
- version: '3.0'
60
+ version: 3.0.0
55
61
  - !ruby/object:Gem::Dependency
56
62
  name: thor
57
63
  requirement: !ruby/object:Gem::Requirement
@@ -76,98 +82,122 @@ dependencies:
76
82
  name: concurrent-ruby
77
83
  requirement: !ruby/object:Gem::Requirement
78
84
  requirements:
85
+ - - "~>"
86
+ - !ruby/object:Gem::Version
87
+ version: 1.0.0
79
88
  - - ">="
80
89
  - !ruby/object:Gem::Version
81
- version: '0'
90
+ version: 1.0.0
82
91
  type: :runtime
83
92
  prerelease: false
84
93
  version_requirements: !ruby/object:Gem::Requirement
85
94
  requirements:
95
+ - - "~>"
96
+ - !ruby/object:Gem::Version
97
+ version: 1.0.0
86
98
  - - ">="
87
99
  - !ruby/object:Gem::Version
88
- version: '0'
100
+ version: 1.0.0
89
101
  - !ruby/object:Gem::Dependency
90
102
  name: tty-color
91
103
  requirement: !ruby/object:Gem::Requirement
92
104
  requirements:
93
105
  - - "~>"
94
106
  - !ruby/object:Gem::Version
95
- version: 0.3.0
107
+ version: 0.4.0
96
108
  - - ">="
97
109
  - !ruby/object:Gem::Version
98
- version: 0.3.0
110
+ version: 0.4.0
99
111
  type: :runtime
100
112
  prerelease: false
101
113
  version_requirements: !ruby/object:Gem::Requirement
102
114
  requirements:
103
115
  - - "~>"
104
116
  - !ruby/object:Gem::Version
105
- version: 0.3.0
117
+ version: 0.4.0
106
118
  - - ">="
107
119
  - !ruby/object:Gem::Version
108
- version: 0.3.0
120
+ version: 0.4.0
109
121
  - !ruby/object:Gem::Dependency
110
122
  name: tty-prompt
111
123
  requirement: !ruby/object:Gem::Requirement
112
124
  requirements:
125
+ - - "~>"
126
+ - !ruby/object:Gem::Version
127
+ version: 0.12.0
113
128
  - - ">="
114
129
  - !ruby/object:Gem::Version
115
- version: '0'
130
+ version: 0.12.0
116
131
  type: :runtime
117
132
  prerelease: false
118
133
  version_requirements: !ruby/object:Gem::Requirement
119
134
  requirements:
135
+ - - "~>"
136
+ - !ruby/object:Gem::Version
137
+ version: 0.12.0
120
138
  - - ">="
121
139
  - !ruby/object:Gem::Version
122
- version: '0'
140
+ version: 0.12.0
123
141
  - !ruby/object:Gem::Dependency
124
- name: flexmock
142
+ name: tty-spinner
125
143
  requirement: !ruby/object:Gem::Requirement
126
144
  requirements:
145
+ - - "~>"
146
+ - !ruby/object:Gem::Version
147
+ version: 0.4.0
127
148
  - - ">="
128
149
  - !ruby/object:Gem::Version
129
- version: 2.0.0
130
- type: :development
150
+ version: 0.4.0
151
+ type: :runtime
131
152
  prerelease: false
132
153
  version_requirements: !ruby/object:Gem::Requirement
133
154
  requirements:
155
+ - - "~>"
156
+ - !ruby/object:Gem::Version
157
+ version: 0.4.0
134
158
  - - ">="
135
159
  - !ruby/object:Gem::Version
136
- version: 2.0.0
160
+ version: 0.4.0
137
161
  - !ruby/object:Gem::Dependency
138
- name: minitest
162
+ name: flexmock
139
163
  requirement: !ruby/object:Gem::Requirement
140
164
  requirements:
141
- - - ">="
142
- - !ruby/object:Gem::Version
143
- version: '5.0'
144
165
  - - "~>"
145
166
  - !ruby/object:Gem::Version
146
- version: '5.0'
167
+ version: '2.0'
168
+ - - ">="
169
+ - !ruby/object:Gem::Version
170
+ version: 2.0.0
147
171
  type: :development
148
172
  prerelease: false
149
173
  version_requirements: !ruby/object:Gem::Requirement
150
174
  requirements:
151
- - - ">="
152
- - !ruby/object:Gem::Version
153
- version: '5.0'
154
175
  - - "~>"
155
176
  - !ruby/object:Gem::Version
156
- version: '5.0'
177
+ version: '2.0'
178
+ - - ">="
179
+ - !ruby/object:Gem::Version
180
+ version: 2.0.0
157
181
  - !ruby/object:Gem::Dependency
158
- name: fakefs
182
+ name: minitest
159
183
  requirement: !ruby/object:Gem::Requirement
160
184
  requirements:
185
+ - - "~>"
186
+ - !ruby/object:Gem::Version
187
+ version: '5.0'
161
188
  - - ">="
162
189
  - !ruby/object:Gem::Version
163
- version: '0'
190
+ version: '5.0'
164
191
  type: :development
165
192
  prerelease: false
166
193
  version_requirements: !ruby/object:Gem::Requirement
167
194
  requirements:
195
+ - - "~>"
196
+ - !ruby/object:Gem::Version
197
+ version: '5.0'
168
198
  - - ">="
169
199
  - !ruby/object:Gem::Version
170
- version: '0'
200
+ version: '5.0'
171
201
  - !ruby/object:Gem::Dependency
172
202
  name: simplecov
173
203
  requirement: !ruby/object:Gem::Requirement
@@ -302,13 +332,11 @@ files:
302
332
  - lib/autoproj/version.rb
303
333
  - lib/autoproj/workspace.rb
304
334
  - manifest.xml
305
- - samples/autoproj/README.txt
335
+ - samples/autoproj/README.md
306
336
  - samples/autoproj/init.rb
307
337
  - samples/autoproj/manifest
308
- - samples/autoproj/overrides.rb
309
- - samples/autoproj/overrides.yml
338
+ - samples/autoproj/overrides.d/.gitattributes
310
339
  - samples/manifest.xml
311
- - samples/osdeps.yml
312
340
  - shell/autoproj_bash
313
341
  - shell/autoproj_sh
314
342
  - shell/autoproj_zsh
@@ -327,9 +355,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
327
355
  version: 2.0.0
328
356
  required_rubygems_version: !ruby/object:Gem::Requirement
329
357
  requirements:
330
- - - ">="
358
+ - - ">"
331
359
  - !ruby/object:Gem::Version
332
- version: '0'
360
+ version: 1.3.1
333
361
  requirements: []
334
362
  rubyforge_project:
335
363
  rubygems_version: 2.5.1