autoproj 1.9.3.rc9 → 1.9.3
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.
- data/Manifest.txt +0 -1
- data/bin/autoproj +12 -0
- data/bin/autoproj-show +74 -8
- data/bin/autoproj_bootstrap +2 -2
- data/bin/autoproj_bootstrap.in +1 -1
- data/lib/autoproj/autobuild.rb +36 -0
- data/lib/autoproj/cmdline.rb +61 -46
- data/lib/autoproj/manifest.rb +34 -0
- data/lib/autoproj/system.rb +1 -1
- data/lib/autoproj/version.rb +1 -1
- metadata +43 -20
- data/bin/autoproj-inspect +0 -104
data/Manifest.txt
CHANGED
data/bin/autoproj
CHANGED
|
@@ -146,6 +146,18 @@ EOTEXT
|
|
|
146
146
|
Autoproj.manifest.explicit_selection = resolved_selected_packages
|
|
147
147
|
selected_packages = resolved_selected_packages
|
|
148
148
|
|
|
149
|
+
if other_root = Autoproj::CmdLine.update_from
|
|
150
|
+
Autobuild::Package.each do |_, pkg|
|
|
151
|
+
if pkg.importer.respond_to?(:pick_from_autoproj_root)
|
|
152
|
+
if !pkg.importer.pick_from_autoproj_root(pkg, other_root)
|
|
153
|
+
pkg.update = false
|
|
154
|
+
end
|
|
155
|
+
else
|
|
156
|
+
pkg.update = false
|
|
157
|
+
end
|
|
158
|
+
end
|
|
159
|
+
end
|
|
160
|
+
|
|
149
161
|
# If in verbose mode, or if we only update sources, list the sources
|
|
150
162
|
if Autoproj.verbose || Autoproj::CmdLine.display_configuration?
|
|
151
163
|
Autoproj::CmdLine.display_configuration(manifest, selected_packages.packages)
|
data/bin/autoproj-show
CHANGED
|
@@ -25,14 +25,48 @@ def find_selection_path(from, to)
|
|
|
25
25
|
return path
|
|
26
26
|
end
|
|
27
27
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
Autoproj.manifest.resolve_package_set(from).each do |pkg_name|
|
|
29
|
+
Autobuild::Package[pkg_name].dependencies.each do |dep_pkg_name|
|
|
30
|
+
if result = find_selection_path(dep_pkg_name, to)
|
|
31
|
+
return path + result
|
|
32
|
+
end
|
|
31
33
|
end
|
|
32
34
|
end
|
|
33
35
|
nil
|
|
34
36
|
end
|
|
35
37
|
|
|
38
|
+
if packages.empty?
|
|
39
|
+
puts "no packages or OS packages match #{user_selection.join(" ")}"
|
|
40
|
+
exit 1
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
def vcs_to_array(vcs)
|
|
44
|
+
if vcs.kind_of?(Hash)
|
|
45
|
+
options = vcs.dup
|
|
46
|
+
type = options.delete('type')
|
|
47
|
+
url = options.delete('url')
|
|
48
|
+
else
|
|
49
|
+
options = vcs.options
|
|
50
|
+
type = vcs.type
|
|
51
|
+
url = vcs.url
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
value = []
|
|
55
|
+
if type
|
|
56
|
+
value << ['type', type]
|
|
57
|
+
end
|
|
58
|
+
if url
|
|
59
|
+
value << ['url', url]
|
|
60
|
+
end
|
|
61
|
+
value = value.concat(options.to_a.sort_by { |k, _| k.to_s })
|
|
62
|
+
value.map do |key, value|
|
|
63
|
+
if value.respond_to?(:to_str) && File.file?(value) && value =~ /^\//
|
|
64
|
+
value = Pathname.new(value).relative_path_from(Pathname.new(Autoproj.root_dir))
|
|
65
|
+
end
|
|
66
|
+
[key, value]
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
|
|
36
70
|
packages.each do |name|
|
|
37
71
|
result = Autoproj.manifest.resolve_package_name(name, :filter => false)
|
|
38
72
|
packages, osdeps = result.partition { |type, name| type == :package }
|
|
@@ -40,7 +74,36 @@ packages.each do |name|
|
|
|
40
74
|
osdeps = osdeps.map(&:last)
|
|
41
75
|
|
|
42
76
|
packages.each do |pkg_name|
|
|
43
|
-
puts "source package #{pkg_name}"
|
|
77
|
+
puts Autoproj.color("source package #{pkg_name}", :bold)
|
|
78
|
+
puts " imported from"
|
|
79
|
+
vcs = Autoproj.manifest.importer_definition_for(pkg_name)
|
|
80
|
+
|
|
81
|
+
fragments = []
|
|
82
|
+
if vcs.raw
|
|
83
|
+
first = true
|
|
84
|
+
fragments << [nil, vcs_to_array(vcs)]
|
|
85
|
+
vcs.raw.each do |pkg_set, vcs_info|
|
|
86
|
+
title = if first
|
|
87
|
+
"first match: in #{pkg_set}"
|
|
88
|
+
else "overriden in #{pkg_set}"
|
|
89
|
+
end
|
|
90
|
+
first = false
|
|
91
|
+
fragments << [title, vcs_to_array(vcs_info)]
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
fragments.each do |title, elements|
|
|
95
|
+
if title
|
|
96
|
+
puts " #{title}"
|
|
97
|
+
elements.each do |key, value|
|
|
98
|
+
puts " #{key}: #{value}"
|
|
99
|
+
end
|
|
100
|
+
else
|
|
101
|
+
elements.each do |key, value|
|
|
102
|
+
puts " #{key}: #{value}"
|
|
103
|
+
end
|
|
104
|
+
end
|
|
105
|
+
end
|
|
106
|
+
|
|
44
107
|
if default_packages.include?(pkg_name)
|
|
45
108
|
selection = default_packages.selection[pkg_name]
|
|
46
109
|
if selection.include?(pkg_name) && selection.size == 1
|
|
@@ -51,15 +114,18 @@ packages.each do |name|
|
|
|
51
114
|
puts " is directly selected by the manifest via #{selection.to_a.join(", ")}"
|
|
52
115
|
end
|
|
53
116
|
else
|
|
54
|
-
puts "
|
|
117
|
+
puts " is not directly selected by the manifest"
|
|
55
118
|
end
|
|
56
119
|
if Autoproj.manifest.ignored?(pkg_name)
|
|
57
|
-
puts "
|
|
120
|
+
puts " is ignored"
|
|
58
121
|
end
|
|
59
122
|
if Autoproj.manifest.excluded?(pkg_name)
|
|
60
|
-
puts "
|
|
123
|
+
puts " is excluded: #{Autoproj.manifest.exclusion_reason(pkg_name)}"
|
|
61
124
|
end
|
|
62
125
|
|
|
126
|
+
if !File.directory?(Autobuild::Package[pkg_name].srcdir)
|
|
127
|
+
puts Autobuild.color(" this package is not checked out yet, the dependency information will probably be incomplete", :magenta)
|
|
128
|
+
end
|
|
63
129
|
all_reverse_dependencies = Set.new
|
|
64
130
|
pkg_revdeps = revdeps[pkg_name].dup.to_a
|
|
65
131
|
while !pkg_revdeps.empty?
|
|
@@ -93,7 +159,7 @@ packages.each do |name|
|
|
|
93
159
|
end
|
|
94
160
|
|
|
95
161
|
osdeps.each do |pkg_name|
|
|
96
|
-
puts "the osdep '#{pkg_name}'"
|
|
162
|
+
puts Autoproj.color("the osdep '#{pkg_name}'", :bold)
|
|
97
163
|
Autoproj.osdeps.resolve_os_dependencies(pkg_name).each do |manager, packages|
|
|
98
164
|
puts " #{manager.names.first}: #{packages.map { |*subnames| subnames.join(" ") }.join(", ")}"
|
|
99
165
|
end
|
data/bin/autoproj_bootstrap
CHANGED
|
@@ -54,7 +54,7 @@ if $LOADED_FEATURES.find { |str| str =~ /bygems/ }
|
|
|
54
54
|
RUBY = RbConfig::CONFIG['RUBY_INSTALL_NAME']
|
|
55
55
|
|
|
56
56
|
ENV['GEM_HOME'] = needed_gem_home
|
|
57
|
-
ENV
|
|
57
|
+
ENV['GEM_PATH'] = nil
|
|
58
58
|
exec RUBY, __FILE__, *ARGV
|
|
59
59
|
end
|
|
60
60
|
end
|
|
@@ -1696,7 +1696,7 @@ module Autoproj
|
|
|
1696
1696
|
|
|
1697
1697
|
# OS-independent creation of symbolic links. Note that on windows, it only
|
|
1698
1698
|
# works for directories
|
|
1699
|
-
def create_symlink(from, to)
|
|
1699
|
+
def self.create_symlink(from, to)
|
|
1700
1700
|
if Autobuild.windows?
|
|
1701
1701
|
Dir.create_junction(to, from)
|
|
1702
1702
|
else
|
data/bin/autoproj_bootstrap.in
CHANGED
data/lib/autoproj/autobuild.rb
CHANGED
|
@@ -174,6 +174,42 @@ module Autobuild
|
|
|
174
174
|
@os_packages ||= Set.new
|
|
175
175
|
end
|
|
176
176
|
end
|
|
177
|
+
|
|
178
|
+
class Git
|
|
179
|
+
# Reconfigures this importer to use an already existing checkout located
|
|
180
|
+
# in the given autoproj root
|
|
181
|
+
#
|
|
182
|
+
# @param [Autobuild::Package] the package we are dealing with
|
|
183
|
+
# @param [Autoproj::InstallationManifest] the other root's installation
|
|
184
|
+
# manifest
|
|
185
|
+
def pick_from_autoproj_root(package, installation_manifest)
|
|
186
|
+
other_pkg = installation_manifest[package.name]
|
|
187
|
+
return if !other_pkg
|
|
188
|
+
self.relocate(other_pkg.srcdir)
|
|
189
|
+
true
|
|
190
|
+
end
|
|
191
|
+
end
|
|
192
|
+
|
|
193
|
+
class ArchiveImporter
|
|
194
|
+
# Reconfigures this importer to use an already existing checkout located
|
|
195
|
+
# in the given autoproj root
|
|
196
|
+
#
|
|
197
|
+
# @param [Autobuild::Package] the package we are dealing with
|
|
198
|
+
# @param [Autoproj::InstallationManifest] the other root's installation
|
|
199
|
+
# manifest
|
|
200
|
+
def pick_from_autoproj_root(package, installation_manifest)
|
|
201
|
+
# Get the cachefile w.r.t. the autoproj root
|
|
202
|
+
cachefile = Pathname.new(self.cachefile).
|
|
203
|
+
relative_path_from(Pathname.new(Autoproj.root_dir)).to_s
|
|
204
|
+
|
|
205
|
+
# The cachefile in the other autoproj installation
|
|
206
|
+
other_cachefile = File.join(installation_manifest.path, cachefile)
|
|
207
|
+
if File.file?(other_cachefile)
|
|
208
|
+
self.relocate("file://" + other_cachefile)
|
|
209
|
+
true
|
|
210
|
+
end
|
|
211
|
+
end
|
|
212
|
+
end
|
|
177
213
|
end
|
|
178
214
|
|
|
179
215
|
module Autoproj
|
data/lib/autoproj/cmdline.rb
CHANGED
|
@@ -80,7 +80,7 @@ module Autoproj
|
|
|
80
80
|
if File.file?(prg_path = File.join(ruby_bindir, prg_name))
|
|
81
81
|
File.open(File.join(bindir, name), 'w') do |io|
|
|
82
82
|
io.puts "#! #{File.join(ruby_bindir, ruby)}"
|
|
83
|
-
io.puts "
|
|
83
|
+
io.puts "exec \"#{prg_path}\", *ARGV"
|
|
84
84
|
end
|
|
85
85
|
FileUtils.chmod 0755, File.join(bindir, name)
|
|
86
86
|
end
|
|
@@ -881,6 +881,9 @@ module Autoproj
|
|
|
881
881
|
|
|
882
882
|
def self.color?; @color end
|
|
883
883
|
|
|
884
|
+
class << self
|
|
885
|
+
attr_accessor :update_from
|
|
886
|
+
end
|
|
884
887
|
def self.osdeps?; @mode == "osdeps" end
|
|
885
888
|
def self.show_osdeps?; @mode == "osdeps" && @show_osdeps end
|
|
886
889
|
def self.revshow_osdeps?; @mode == "osdeps" && @revshow_osdeps end
|
|
@@ -988,6 +991,9 @@ where 'mode' is one of:
|
|
|
988
991
|
opts.on("--reconfigure", "re-ask all configuration options (build modes only)") do
|
|
989
992
|
Autoproj.reconfigure = true
|
|
990
993
|
end
|
|
994
|
+
opts.on('--from PATH', 'in update mode, use this existing autoproj installation to check out the packages (for importers that support this)') do |path|
|
|
995
|
+
self.update_from = Autoproj::InstallationManifest.from_root(File.expand_path(path))
|
|
996
|
+
end
|
|
991
997
|
opts.on("--[no-]color", "enable or disable color in status messages (enabled by default)") do |flag|
|
|
992
998
|
@color = flag
|
|
993
999
|
Autobuild.color = flag
|
|
@@ -1298,53 +1304,62 @@ where 'mode' is one of:
|
|
|
1298
1304
|
elsif !File.directory?(pkg.srcdir)
|
|
1299
1305
|
lines << Autoproj.color(" is not imported yet", :magenta)
|
|
1300
1306
|
else
|
|
1301
|
-
status = pkg.importer.status(pkg,@only_local)
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1307
|
+
status = begin pkg.importer.status(pkg,@only_local)
|
|
1308
|
+
rescue Interrupt
|
|
1309
|
+
raise
|
|
1310
|
+
rescue Exception => e
|
|
1311
|
+
lines << Autoproj.color(" failed to fetch status information", :red)
|
|
1312
|
+
nil
|
|
1313
|
+
end
|
|
1314
|
+
|
|
1315
|
+
if status
|
|
1316
|
+
if status.uncommitted_code
|
|
1317
|
+
lines << Autoproj.color(" contains uncommitted modifications", :red)
|
|
1318
|
+
result.uncommitted = true
|
|
1319
|
+
end
|
|
1306
1320
|
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1321
|
+
case status.status
|
|
1322
|
+
when Autobuild::Importer::Status::UP_TO_DATE
|
|
1323
|
+
if !status.uncommitted_code
|
|
1324
|
+
if sync_packages.size > 80
|
|
1325
|
+
Autoproj.message "#{sync_packages},"
|
|
1326
|
+
sync_packages = ""
|
|
1327
|
+
end
|
|
1328
|
+
msg = if sync_packages.empty?
|
|
1329
|
+
pkg_name
|
|
1330
|
+
else
|
|
1331
|
+
", #{pkg_name}"
|
|
1332
|
+
end
|
|
1333
|
+
STDERR.print msg
|
|
1334
|
+
sync_packages = "#{sync_packages}#{msg}"
|
|
1335
|
+
next
|
|
1336
|
+
else
|
|
1337
|
+
lines << Autoproj.color(" local and remote are in sync", :green)
|
|
1338
|
+
end
|
|
1339
|
+
when Autobuild::Importer::Status::ADVANCED
|
|
1340
|
+
result.local = true
|
|
1341
|
+
lines << Autoproj.color(" local contains #{status.local_commits.size} commit that remote does not have:", :blue)
|
|
1342
|
+
status.local_commits.each do |line|
|
|
1343
|
+
lines << Autoproj.color(" #{line}", :blue)
|
|
1344
|
+
end
|
|
1345
|
+
when Autobuild::Importer::Status::SIMPLE_UPDATE
|
|
1346
|
+
result.remote = true
|
|
1347
|
+
lines << Autoproj.color(" remote contains #{status.remote_commits.size} commit that local does not have:", :magenta)
|
|
1348
|
+
status.remote_commits.each do |line|
|
|
1349
|
+
lines << Autoproj.color(" #{line}", :magenta)
|
|
1350
|
+
end
|
|
1351
|
+
when Autobuild::Importer::Status::NEEDS_MERGE
|
|
1352
|
+
result.local = true
|
|
1353
|
+
result.remote = true
|
|
1354
|
+
lines << " local and remote have diverged with respectively #{status.local_commits.size} and #{status.remote_commits.size} commits each"
|
|
1355
|
+
lines << Autoproj.color(" -- local commits --", :blue)
|
|
1356
|
+
status.local_commits.each do |line|
|
|
1357
|
+
lines << Autoproj.color(" #{line}", :blue)
|
|
1358
|
+
end
|
|
1359
|
+
lines << Autoproj.color(" -- remote commits --", :magenta)
|
|
1360
|
+
status.remote_commits.each do |line|
|
|
1361
|
+
lines << Autoproj.color(" #{line}", :magenta)
|
|
1313
1362
|
end
|
|
1314
|
-
msg = if sync_packages.empty?
|
|
1315
|
-
pkg_name
|
|
1316
|
-
else
|
|
1317
|
-
", #{pkg_name}"
|
|
1318
|
-
end
|
|
1319
|
-
STDERR.print msg
|
|
1320
|
-
sync_packages = "#{sync_packages}#{msg}"
|
|
1321
|
-
next
|
|
1322
|
-
else
|
|
1323
|
-
lines << Autoproj.color(" local and remote are in sync", :green)
|
|
1324
|
-
end
|
|
1325
|
-
when Autobuild::Importer::Status::ADVANCED
|
|
1326
|
-
result.local = true
|
|
1327
|
-
lines << Autoproj.color(" local contains #{status.local_commits.size} commit that remote does not have:", :blue)
|
|
1328
|
-
status.local_commits.each do |line|
|
|
1329
|
-
lines << Autoproj.color(" #{line}", :blue)
|
|
1330
|
-
end
|
|
1331
|
-
when Autobuild::Importer::Status::SIMPLE_UPDATE
|
|
1332
|
-
result.remote = true
|
|
1333
|
-
lines << Autoproj.color(" remote contains #{status.remote_commits.size} commit that local does not have:", :magenta)
|
|
1334
|
-
status.remote_commits.each do |line|
|
|
1335
|
-
lines << Autoproj.color(" #{line}", :magenta)
|
|
1336
|
-
end
|
|
1337
|
-
when Autobuild::Importer::Status::NEEDS_MERGE
|
|
1338
|
-
result.local = true
|
|
1339
|
-
result.remote = true
|
|
1340
|
-
lines << " local and remote have diverged with respectively #{status.local_commits.size} and #{status.remote_commits.size} commits each"
|
|
1341
|
-
lines << Autoproj.color(" -- local commits --", :blue)
|
|
1342
|
-
status.local_commits.each do |line|
|
|
1343
|
-
lines << Autoproj.color(" #{line}", :blue)
|
|
1344
|
-
end
|
|
1345
|
-
lines << Autoproj.color(" -- remote commits --", :magenta)
|
|
1346
|
-
status.remote_commits.each do |line|
|
|
1347
|
-
lines << Autoproj.color(" #{line}", :magenta)
|
|
1348
1363
|
end
|
|
1349
1364
|
end
|
|
1350
1365
|
end
|
data/lib/autoproj/manifest.rb
CHANGED
|
@@ -1450,6 +1450,26 @@ module Autoproj
|
|
|
1450
1450
|
# See create_autobuild_package for informations about the arguments.
|
|
1451
1451
|
def self.update_package_set(vcs, text_name, into)
|
|
1452
1452
|
fake_package = create_autobuild_package(vcs, text_name, into)
|
|
1453
|
+
if other_root = CmdLine.update_from
|
|
1454
|
+
# Define a package in the installation manifest that points to
|
|
1455
|
+
# the desired folder in other_root
|
|
1456
|
+
relative_path = Pathname.new(into).
|
|
1457
|
+
relative_path_from(Pathname.new(Autoproj.root_dir)).to_s
|
|
1458
|
+
other_dir = File.join(other_root.path, relative_path)
|
|
1459
|
+
if File.directory?(other_dir)
|
|
1460
|
+
other_root.packages.unshift(
|
|
1461
|
+
InstallationManifest::Package.new(fake_package.name, other_dir, File.join(other_dir, 'install')))
|
|
1462
|
+
end
|
|
1463
|
+
|
|
1464
|
+
# Then move the importer there if possible
|
|
1465
|
+
if fake_package.importer.respond_to?(:pick_from_autoproj_root)
|
|
1466
|
+
if !fake_package.importer.pick_from_autoproj_root(fake_package, other_root)
|
|
1467
|
+
fake_package.update = false
|
|
1468
|
+
end
|
|
1469
|
+
else
|
|
1470
|
+
fake_package.update = false
|
|
1471
|
+
end
|
|
1472
|
+
end
|
|
1453
1473
|
fake_package.import
|
|
1454
1474
|
|
|
1455
1475
|
rescue Autobuild::ConfigException => e
|
|
@@ -2421,6 +2441,20 @@ module Autoproj
|
|
|
2421
2441
|
def each(&block)
|
|
2422
2442
|
packages.each(&block)
|
|
2423
2443
|
end
|
|
2444
|
+
|
|
2445
|
+
def [](name)
|
|
2446
|
+
packages.find { |pkg| pkg.name == name }
|
|
2447
|
+
end
|
|
2448
|
+
|
|
2449
|
+
def self.from_root(root_dir)
|
|
2450
|
+
manifest = InstallationManifest.new(root_dir)
|
|
2451
|
+
manifest_file = File.join(root_dir, ".autoproj-installation-manifest")
|
|
2452
|
+
if !File.file?(manifest_file)
|
|
2453
|
+
raise ConfigError.new, "no .autoproj-installation-manifest file exists in #{root_dir}. You should probably rerun autoproj envsh in that folder first"
|
|
2454
|
+
end
|
|
2455
|
+
manifest.load(manifest_file)
|
|
2456
|
+
manifest
|
|
2457
|
+
end
|
|
2424
2458
|
end
|
|
2425
2459
|
|
|
2426
2460
|
# Access to the information contained in a package's manifest.xml file
|
data/lib/autoproj/system.rb
CHANGED
data/lib/autoproj/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: autoproj
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.9.3
|
|
5
|
-
prerelease:
|
|
4
|
+
version: 1.9.3
|
|
5
|
+
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
8
8
|
- Rock Core Developers
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2013-
|
|
12
|
+
date: 2013-07-01 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: autobuild
|
|
16
|
-
requirement:
|
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
|
17
17
|
none: false
|
|
18
18
|
requirements:
|
|
19
19
|
- - ! '>='
|
|
@@ -21,10 +21,15 @@ dependencies:
|
|
|
21
21
|
version: 1.7.0
|
|
22
22
|
type: :runtime
|
|
23
23
|
prerelease: false
|
|
24
|
-
version_requirements:
|
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
25
|
+
none: false
|
|
26
|
+
requirements:
|
|
27
|
+
- - ! '>='
|
|
28
|
+
- !ruby/object:Gem::Version
|
|
29
|
+
version: 1.7.0
|
|
25
30
|
- !ruby/object:Gem::Dependency
|
|
26
31
|
name: utilrb
|
|
27
|
-
requirement:
|
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
|
28
33
|
none: false
|
|
29
34
|
requirements:
|
|
30
35
|
- - ! '>='
|
|
@@ -32,10 +37,15 @@ dependencies:
|
|
|
32
37
|
version: 1.6.0
|
|
33
38
|
type: :runtime
|
|
34
39
|
prerelease: false
|
|
35
|
-
version_requirements:
|
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
41
|
+
none: false
|
|
42
|
+
requirements:
|
|
43
|
+
- - ! '>='
|
|
44
|
+
- !ruby/object:Gem::Version
|
|
45
|
+
version: 1.6.0
|
|
36
46
|
- !ruby/object:Gem::Dependency
|
|
37
47
|
name: highline
|
|
38
|
-
requirement:
|
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
|
39
49
|
none: false
|
|
40
50
|
requirements:
|
|
41
51
|
- - ! '>='
|
|
@@ -43,10 +53,15 @@ dependencies:
|
|
|
43
53
|
version: 1.5.0
|
|
44
54
|
type: :runtime
|
|
45
55
|
prerelease: false
|
|
46
|
-
version_requirements:
|
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
57
|
+
none: false
|
|
58
|
+
requirements:
|
|
59
|
+
- - ! '>='
|
|
60
|
+
- !ruby/object:Gem::Version
|
|
61
|
+
version: 1.5.0
|
|
47
62
|
- !ruby/object:Gem::Dependency
|
|
48
63
|
name: rdoc
|
|
49
|
-
requirement:
|
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
|
50
65
|
none: false
|
|
51
66
|
requirements:
|
|
52
67
|
- - ~>
|
|
@@ -54,10 +69,15 @@ dependencies:
|
|
|
54
69
|
version: '4.0'
|
|
55
70
|
type: :development
|
|
56
71
|
prerelease: false
|
|
57
|
-
version_requirements:
|
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
73
|
+
none: false
|
|
74
|
+
requirements:
|
|
75
|
+
- - ~>
|
|
76
|
+
- !ruby/object:Gem::Version
|
|
77
|
+
version: '4.0'
|
|
58
78
|
- !ruby/object:Gem::Dependency
|
|
59
79
|
name: hoe
|
|
60
|
-
requirement:
|
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
|
61
81
|
none: false
|
|
62
82
|
requirements:
|
|
63
83
|
- - ~>
|
|
@@ -65,7 +85,12 @@ dependencies:
|
|
|
65
85
|
version: '3.6'
|
|
66
86
|
type: :development
|
|
67
87
|
prerelease: false
|
|
68
|
-
version_requirements:
|
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
89
|
+
none: false
|
|
90
|
+
requirements:
|
|
91
|
+
- - ~>
|
|
92
|
+
- !ruby/object:Gem::Version
|
|
93
|
+
version: '3.6'
|
|
69
94
|
description: autoproj is a manager for sets of software packages. It allows the user
|
|
70
95
|
to import and build packages from source, still using the underlying distribution's
|
|
71
96
|
native package manager for software that is available on it.
|
|
@@ -80,7 +105,6 @@ executables:
|
|
|
80
105
|
- autoproj-clean
|
|
81
106
|
- autoproj-create-set
|
|
82
107
|
- autoproj-envsh
|
|
83
|
-
- autoproj-inspect
|
|
84
108
|
- autoproj-list
|
|
85
109
|
- autoproj-locate
|
|
86
110
|
- autoproj-query
|
|
@@ -108,7 +132,6 @@ files:
|
|
|
108
132
|
- bin/autoproj-clean
|
|
109
133
|
- bin/autoproj-create-set
|
|
110
134
|
- bin/autoproj-envsh
|
|
111
|
-
- bin/autoproj-inspect
|
|
112
135
|
- bin/autoproj-list
|
|
113
136
|
- bin/autoproj-locate
|
|
114
137
|
- bin/autoproj-query
|
|
@@ -171,19 +194,19 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
171
194
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
172
195
|
none: false
|
|
173
196
|
requirements:
|
|
174
|
-
- - ! '
|
|
197
|
+
- - ! '>='
|
|
175
198
|
- !ruby/object:Gem::Version
|
|
176
|
-
version:
|
|
199
|
+
version: '0'
|
|
177
200
|
requirements: []
|
|
178
201
|
rubyforge_project: autobuild
|
|
179
|
-
rubygems_version: 1.8.
|
|
202
|
+
rubygems_version: 1.8.23
|
|
180
203
|
signing_key:
|
|
181
204
|
specification_version: 3
|
|
182
205
|
summary: Easy installation and management of sets of software packages
|
|
183
206
|
test_files:
|
|
184
|
-
- test/test_manifest.rb
|
|
185
|
-
- test/test_package_manifest.rb
|
|
186
207
|
- test/test_os_dependencies.rb
|
|
187
208
|
- test/test_debian.rb
|
|
209
|
+
- test/test_manifest.rb
|
|
188
210
|
- test/package_managers/test_apt_dpkg_manager.rb
|
|
189
211
|
- test/package_managers/test_gem.rb
|
|
212
|
+
- test/test_package_manifest.rb
|
data/bin/autoproj-inspect
DELETED
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
#! /usr/bin/env ruby
|
|
2
|
-
|
|
3
|
-
require 'autoproj'
|
|
4
|
-
require 'autoproj/cmdline'
|
|
5
|
-
Autoproj.silent = true
|
|
6
|
-
Autoproj::CmdLine.initialize_root_directory
|
|
7
|
-
Autoproj::CmdLine.initialize_and_load(ARGV)
|
|
8
|
-
|
|
9
|
-
require 'pp'
|
|
10
|
-
default_packages = Autoproj.manifest.default_packages
|
|
11
|
-
revdeps = Autoproj.manifest.compute_revdeps
|
|
12
|
-
|
|
13
|
-
user_selection = ARGV.map do |arg|
|
|
14
|
-
if File.directory?(arg)
|
|
15
|
-
File.expand_path(arg)
|
|
16
|
-
else arg
|
|
17
|
-
end
|
|
18
|
-
end
|
|
19
|
-
resolved_selection = Autoproj::CmdLine.resolve_user_selection(user_selection, :filter => false)
|
|
20
|
-
packages = resolved_selection.selection.keys
|
|
21
|
-
|
|
22
|
-
def find_selection_path(from, to)
|
|
23
|
-
path = [from]
|
|
24
|
-
if from == to
|
|
25
|
-
return path
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
Autoproj.manifest.resolve_package_set(from).each do |pkg_name|
|
|
29
|
-
Autobuild::Package[pkg_name].dependencies.each do |dep_pkg_name|
|
|
30
|
-
if result = find_selection_path(dep_pkg_name, to)
|
|
31
|
-
return path + result
|
|
32
|
-
end
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
nil
|
|
36
|
-
end
|
|
37
|
-
|
|
38
|
-
packages.each do |name|
|
|
39
|
-
result = Autoproj.manifest.resolve_package_name(name, :filter => false)
|
|
40
|
-
packages, osdeps = result.partition { |type, name| type == :package }
|
|
41
|
-
packages = packages.map(&:last)
|
|
42
|
-
osdeps = osdeps.map(&:last)
|
|
43
|
-
|
|
44
|
-
packages.each do |pkg_name|
|
|
45
|
-
puts "source package #{pkg_name}"
|
|
46
|
-
if default_packages.include?(pkg_name)
|
|
47
|
-
selection = default_packages.selection[pkg_name]
|
|
48
|
-
if selection.include?(pkg_name) && selection.size == 1
|
|
49
|
-
puts " is directly selected by the manifest"
|
|
50
|
-
else
|
|
51
|
-
selection = selection.dup
|
|
52
|
-
selection.delete(pkg_name)
|
|
53
|
-
puts " is directly selected by the manifest via #{selection.to_a.join(", ")}"
|
|
54
|
-
end
|
|
55
|
-
else
|
|
56
|
-
puts " is not directly selected by the manifest"
|
|
57
|
-
end
|
|
58
|
-
if Autoproj.manifest.ignored?(pkg_name)
|
|
59
|
-
puts " is ignored"
|
|
60
|
-
end
|
|
61
|
-
if Autoproj.manifest.excluded?(pkg_name)
|
|
62
|
-
puts " is excluded: #{Autoproj.manifest.exclusion_reason(pkg_name)}"
|
|
63
|
-
end
|
|
64
|
-
|
|
65
|
-
all_reverse_dependencies = Set.new
|
|
66
|
-
pkg_revdeps = revdeps[pkg_name].dup.to_a
|
|
67
|
-
while !pkg_revdeps.empty?
|
|
68
|
-
parent_name = pkg_revdeps.shift
|
|
69
|
-
next if all_reverse_dependencies.include?(parent_name)
|
|
70
|
-
all_reverse_dependencies << parent_name
|
|
71
|
-
pkg_revdeps.concat(revdeps[parent_name].to_a)
|
|
72
|
-
end
|
|
73
|
-
if all_reverse_dependencies.empty?
|
|
74
|
-
puts " no reverse dependencies"
|
|
75
|
-
else
|
|
76
|
-
puts " reverse dependencies: #{all_reverse_dependencies.sort.join(", ")}"
|
|
77
|
-
end
|
|
78
|
-
|
|
79
|
-
selections = Set.new
|
|
80
|
-
all_reverse_dependencies = all_reverse_dependencies.to_a.sort
|
|
81
|
-
all_reverse_dependencies.each do |parent_name|
|
|
82
|
-
if default_packages.include?(parent_name)
|
|
83
|
-
selections |= default_packages.selection[parent_name]
|
|
84
|
-
end
|
|
85
|
-
end
|
|
86
|
-
|
|
87
|
-
if !selections.empty?
|
|
88
|
-
puts " selected by way of"
|
|
89
|
-
selections.each do |root_pkg|
|
|
90
|
-
path = find_selection_path(root_pkg, pkg_name)
|
|
91
|
-
puts " #{path.join(">")}"
|
|
92
|
-
end
|
|
93
|
-
end
|
|
94
|
-
puts " directly depends on: #{Autobuild::Package[pkg_name].dependencies.sort.join(", ")}"
|
|
95
|
-
end
|
|
96
|
-
|
|
97
|
-
osdeps.each do |pkg_name|
|
|
98
|
-
puts "the osdep '#{pkg_name}'"
|
|
99
|
-
Autoproj.osdeps.resolve_os_dependencies(pkg_name).each do |manager, packages|
|
|
100
|
-
puts " #{manager.names.first}: #{packages.map { |*subnames| subnames.join(" ") }.join(", ")}"
|
|
101
|
-
end
|
|
102
|
-
end
|
|
103
|
-
end
|
|
104
|
-
|