autoproj 1.7.18 → 1.7.19.rc1
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +5 -0
- data/bin/autoproj_bootstrap +6 -5
- data/lib/autoproj/autobuild.rb +43 -15
- data/lib/autoproj/cmdline.rb +2 -2
- data/lib/autoproj/manifest.rb +7 -1
- data/lib/autoproj/osdeps.rb +6 -5
- data/lib/autoproj/version.rb +1 -1
- metadata +13 -9
data/History.txt
CHANGED
@@ -1,3 +1,8 @@
|
|
1
|
+
= Version 1.7.19
|
2
|
+
* use different colors for remote-only and local-only commits
|
3
|
+
* fix some issues with handling of osdeps vs. exclusion/ignore handling
|
4
|
+
* fix handling of optional dependencies osdeps
|
5
|
+
|
1
6
|
= Version 1.7.18
|
2
7
|
* properly detect and report circular dependencies
|
3
8
|
|
data/bin/autoproj_bootstrap
CHANGED
@@ -612,12 +612,13 @@ fi
|
|
612
612
|
def availability_of(name)
|
613
613
|
osdeps, gemdeps = partition_packages([name].to_set)
|
614
614
|
if !osdeps.empty?
|
615
|
-
|
616
|
-
|
617
|
-
|
618
|
-
|
619
|
-
|
615
|
+
osdeps.each do |dep_name|
|
616
|
+
status = resolve_package(dep_name)
|
617
|
+
if !status.respond_to?(:to_ary) && status != IGNORE
|
618
|
+
return status
|
619
|
+
end
|
620
620
|
end
|
621
|
+
AVAILABLE
|
621
622
|
elsif !gemdeps.empty?
|
622
623
|
AVAILABLE
|
623
624
|
else
|
data/lib/autoproj/autobuild.rb
CHANGED
@@ -101,14 +101,11 @@ module Autobuild
|
|
101
101
|
end
|
102
102
|
|
103
103
|
@os_packages ||= Set.new
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
elsif type == :package
|
108
|
-
__depends_on__(pkg)
|
109
|
-
else raise Autoproj::InternalError, "expected package type to be either :osdeps or :package, got #{type.inspect}"
|
110
|
-
end
|
104
|
+
pkg_autobuild, pkg_os = partition_package(name)
|
105
|
+
pkg_autobuild.each do |pkg|
|
106
|
+
__depends_on__(pkg)
|
111
107
|
end
|
108
|
+
@os_packages |= pkg_os.to_set
|
112
109
|
end
|
113
110
|
|
114
111
|
def depends_on_os_package(name)
|
@@ -123,17 +120,48 @@ module Autobuild
|
|
123
120
|
optional_dependencies << name
|
124
121
|
end
|
125
122
|
|
126
|
-
def
|
123
|
+
def partition_package(pkg_name)
|
124
|
+
pkg_autobuild, pkg_osdeps = [], []
|
125
|
+
Autoproj.manifest.resolve_package_name(pkg_name).each do |type, dep_name|
|
126
|
+
if type == :osdeps
|
127
|
+
pkg_osdeps << dep_name
|
128
|
+
elsif type == :package
|
129
|
+
pkg_autobuild << dep_name
|
130
|
+
else raise Autoproj::InternalError, "expected package type to be either :osdeps or :package, got #{type.inspect}"
|
131
|
+
end
|
132
|
+
end
|
133
|
+
return pkg_autobuild, pkg_osdeps
|
134
|
+
end
|
135
|
+
|
136
|
+
def partition_optional_dependencies
|
137
|
+
packages, osdeps, disabled = [], [], []
|
127
138
|
optional_dependencies.each do |name|
|
128
|
-
if
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
139
|
+
if !Autoproj.manifest.package_enabled?(name)
|
140
|
+
disabled << name
|
141
|
+
next
|
142
|
+
end
|
143
|
+
|
144
|
+
pkg_autobuild, pkg_osdeps = partition_package(name)
|
145
|
+
valid = pkg_autobuild.any? { |pkg| !Autoproj.manifest.package_enabled?(pkg) } ||
|
146
|
+
pkg_osdeps.any? { |pkg| !Autoproj.manifest.package_enabled?(pkg) }
|
147
|
+
|
148
|
+
if valid
|
149
|
+
packages.concat(pkg_autobuild)
|
150
|
+
osdeps.concat(pkg_osdeps)
|
151
|
+
else
|
152
|
+
disabled << name
|
135
153
|
end
|
136
154
|
end
|
155
|
+
return packages, osdeps, disabled
|
156
|
+
end
|
157
|
+
|
158
|
+
def resolve_optional_dependencies
|
159
|
+
if !Autoproj::CmdLine.ignore_dependencies?
|
160
|
+
packages, osdeps, disabled = partition_optional_dependencies
|
161
|
+
packages.each { |pkg| depends_on(packages) }
|
162
|
+
@os_packages ||= Set.new
|
163
|
+
@os_packages |= osdeps.to_set
|
164
|
+
end
|
137
165
|
end
|
138
166
|
|
139
167
|
def optional_dependencies
|
data/lib/autoproj/cmdline.rb
CHANGED
@@ -1180,9 +1180,9 @@ where 'mode' is one of:
|
|
1180
1180
|
end
|
1181
1181
|
when Autobuild::Importer::Status::ADVANCED
|
1182
1182
|
result.local = true
|
1183
|
-
lines << Autoproj.color(" local contains #{status.local_commits.size} commit that remote does not have:", :
|
1183
|
+
lines << Autoproj.color(" local contains #{status.local_commits.size} commit that remote does not have:", :blue)
|
1184
1184
|
status.local_commits.each do |line|
|
1185
|
-
lines << Autoproj.color(" #{line}", :
|
1185
|
+
lines << Autoproj.color(" #{line}", :blue)
|
1186
1186
|
end
|
1187
1187
|
when Autobuild::Importer::Status::SIMPLE_UPDATE
|
1188
1188
|
result.remote = true
|
data/lib/autoproj/manifest.rb
CHANGED
@@ -1845,7 +1845,7 @@ module Autoproj
|
|
1845
1845
|
# If it is false, the method will simply return false on non-defined
|
1846
1846
|
# packages
|
1847
1847
|
def package_enabled?(name, validate = true)
|
1848
|
-
if !Autobuild::Package[name]
|
1848
|
+
if !Autobuild::Package[name] && !Autoproj.osdeps.has?(name)
|
1849
1849
|
if validate
|
1850
1850
|
raise ArgumentError, "package #{name} does not exist"
|
1851
1851
|
end
|
@@ -2047,6 +2047,12 @@ module Autoproj
|
|
2047
2047
|
@osdeps_overrides[osdeps_name.to_s] = options
|
2048
2048
|
end
|
2049
2049
|
|
2050
|
+
# Remove any OSDeps override that has previously been added with
|
2051
|
+
# #add_osdeps_overrides
|
2052
|
+
def remove_osdeps_overrides(osdep_name)
|
2053
|
+
@osdeps_overrides.delete(osdeps_name.to_s)
|
2054
|
+
end
|
2055
|
+
|
2050
2056
|
# Package selection can be done in three ways:
|
2051
2057
|
# * as a subdirectory in the layout
|
2052
2058
|
# * as a on-disk directory
|
data/lib/autoproj/osdeps.rb
CHANGED
@@ -513,12 +513,13 @@ fi
|
|
513
513
|
def availability_of(name)
|
514
514
|
osdeps, gemdeps = partition_packages([name].to_set)
|
515
515
|
if !osdeps.empty?
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
516
|
+
osdeps.each do |dep_name|
|
517
|
+
status = resolve_package(dep_name)
|
518
|
+
if !status.respond_to?(:to_ary) && status != IGNORE
|
519
|
+
return status
|
520
|
+
end
|
521
521
|
end
|
522
|
+
AVAILABLE
|
522
523
|
elsif !gemdeps.empty?
|
523
524
|
AVAILABLE
|
524
525
|
else
|
data/lib/autoproj/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: autoproj
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
5
|
-
prerelease:
|
4
|
+
hash: 15424223
|
5
|
+
prerelease: 7
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 7
|
9
|
-
-
|
10
|
-
|
9
|
+
- 19
|
10
|
+
- rc
|
11
|
+
- 1
|
12
|
+
version: 1.7.19.rc1
|
11
13
|
platform: ruby
|
12
14
|
authors:
|
13
15
|
- Sylvain Joyeux
|
@@ -15,7 +17,7 @@ autorequire:
|
|
15
17
|
bindir: bin
|
16
18
|
cert_chain: []
|
17
19
|
|
18
|
-
date: 2012-02-
|
20
|
+
date: 2012-02-21 00:00:00 Z
|
19
21
|
dependencies:
|
20
22
|
- !ruby/object:Gem::Dependency
|
21
23
|
name: autobuild
|
@@ -186,12 +188,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
186
188
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
187
189
|
none: false
|
188
190
|
requirements:
|
189
|
-
- - "
|
191
|
+
- - ">"
|
190
192
|
- !ruby/object:Gem::Version
|
191
|
-
hash:
|
193
|
+
hash: 25
|
192
194
|
segments:
|
193
|
-
-
|
194
|
-
|
195
|
+
- 1
|
196
|
+
- 3
|
197
|
+
- 1
|
198
|
+
version: 1.3.1
|
195
199
|
requirements: []
|
196
200
|
|
197
201
|
rubyforge_project: autobuild
|