autoproj 1.8.2.b16 → 1.8.2.b17

Sign up to get free protection for your applications and to get access to all the features.
@@ -365,6 +365,14 @@ fi
365
365
  end
366
366
  end
367
367
 
368
+ def install(packages)
369
+ if super
370
+ # Invalidate caching of installed packages, as we just
371
+ # installed new packages !
372
+ @installed_packages = nil
373
+ end
374
+ end
375
+
368
376
  def filter_uptodate_packages(packages)
369
377
  packages.find_all do |package_name|
370
378
  !installed?(package_name)
@@ -383,12 +391,16 @@ fi
383
391
 
384
392
  def initialize
385
393
  super(['gem'])
394
+ @installed_gems = Set.new
386
395
  end
387
396
 
388
397
  # Used to override the Gem::SpecFetcher object used by this gem
389
398
  # manager. Useful mainly for testing
390
399
  attr_writer :gem_fetcher
391
400
 
401
+ # The set of gems installed during this autoproj session
402
+ attr_reader :installed_gems
403
+
392
404
  def gem_fetcher
393
405
  if !@gem_fetcher
394
406
  Autoproj.message " looking for RubyGems updates"
@@ -437,6 +449,9 @@ fi
437
449
  cmdlines.each do |c|
438
450
  Autobuild::Subprocess.run 'autoproj', 'osdeps', *c
439
451
  end
452
+ gems.each do |name, v|
453
+ installed_gems << name
454
+ end
440
455
  did_something = true
441
456
  end
442
457
  end
@@ -447,6 +462,8 @@ fi
447
462
  # Don't install gems that are already there ...
448
463
  gems = gems.dup
449
464
  gems.delete_if do |name, version|
465
+ next(true) if installed_gems.include?(name)
466
+
450
467
  version_requirements = Gem::Requirement.new(version || '>= 0')
451
468
  installed =
452
469
  if Gem::Specification.respond_to?(:find_by_name)
@@ -107,7 +107,7 @@ module Autobuild
107
107
  end
108
108
  @os_packages |= pkg_os.to_set
109
109
  rescue Autoproj::OSDependencies::MissingOSDep
110
- Autoproj.manifest.add_exclusion(name, "the #{name} osdep is not available on this operating system")
110
+ Autoproj.manifest.add_exclusion(self.name, "the #{name} osdep is not available on this operating system")
111
111
  end
112
112
 
113
113
  def depends_on_os_package(name)
@@ -370,10 +370,10 @@ def cmake_package(options, &block)
370
370
  package_common(:cmake, options) do |pkg|
371
371
  Autoproj.add_build_system_dependency 'cmake'
372
372
  yield(pkg) if block_given?
373
- unless pkg.has_doc?
373
+ unless pkg.has_doc? && pkg.doc_dir
374
374
  pkg.with_doc do
375
- doc_html = File.join('doc', 'html')
376
- if File.directory? doc_html
375
+ doc_html = File.join(pkg.builddir, 'doc', 'html')
376
+ if File.directory?(doc_html)
377
377
  pkg.doc_dir = doc_html
378
378
  end
379
379
  end
@@ -394,9 +394,9 @@ def autotools_package(options, &block)
394
394
  package_common(:autotools, options) do |pkg|
395
395
  Autoproj.add_build_system_dependency 'autotools'
396
396
  yield(pkg) if block_given?
397
- unless pkg.has_doc?
397
+ unless pkg.has_doc? && pkg.doc_dir
398
398
  pkg.with_doc do
399
- doc_html = File.join('doc', 'html')
399
+ doc_html = File.join(pkg.builddir, 'doc', 'html')
400
400
  if File.directory? doc_html
401
401
  pkg.doc_dir = doc_html
402
402
  end
@@ -266,6 +266,14 @@ fi
266
266
  end
267
267
  end
268
268
 
269
+ def install(packages)
270
+ if super
271
+ # Invalidate caching of installed packages, as we just
272
+ # installed new packages !
273
+ @installed_packages = nil
274
+ end
275
+ end
276
+
269
277
  def filter_uptodate_packages(packages)
270
278
  packages.find_all do |package_name|
271
279
  !installed?(package_name)
@@ -284,12 +292,16 @@ fi
284
292
 
285
293
  def initialize
286
294
  super(['gem'])
295
+ @installed_gems = Set.new
287
296
  end
288
297
 
289
298
  # Used to override the Gem::SpecFetcher object used by this gem
290
299
  # manager. Useful mainly for testing
291
300
  attr_writer :gem_fetcher
292
301
 
302
+ # The set of gems installed during this autoproj session
303
+ attr_reader :installed_gems
304
+
293
305
  def gem_fetcher
294
306
  if !@gem_fetcher
295
307
  Autoproj.message " looking for RubyGems updates"
@@ -338,6 +350,9 @@ fi
338
350
  cmdlines.each do |c|
339
351
  Autobuild::Subprocess.run 'autoproj', 'osdeps', *c
340
352
  end
353
+ gems.each do |name, v|
354
+ installed_gems << name
355
+ end
341
356
  did_something = true
342
357
  end
343
358
  end
@@ -348,6 +363,8 @@ fi
348
363
  # Don't install gems that are already there ...
349
364
  gems = gems.dup
350
365
  gems.delete_if do |name, version|
366
+ next(true) if installed_gems.include?(name)
367
+
351
368
  version_requirements = Gem::Requirement.new(version || '>= 0')
352
369
  installed =
353
370
  if Gem::Specification.respond_to?(:find_by_name)
@@ -1,3 +1,3 @@
1
1
  module Autoproj
2
- VERSION = "1.8.2.b16"
2
+ VERSION = "1.8.2.b17"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: autoproj
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.2.b16
4
+ version: 1.8.2.b17
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-12 00:00:00.000000000 Z
12
+ date: 2012-10-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: autobuild
16
- requirement: &17073020 !ruby/object:Gem::Requirement
16
+ requirement: &16486980 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 1.6.0.rc1
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *17073020
24
+ version_requirements: *16486980
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: utilrb
27
- requirement: &17072460 !ruby/object:Gem::Requirement
27
+ requirement: &16484260 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 1.6.0
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *17072460
35
+ version_requirements: *16484260
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: highline
38
- requirement: &17071900 !ruby/object:Gem::Requirement
38
+ requirement: &16482140 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: 1.5.0
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *17071900
46
+ version_requirements: *16482140
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: rdoc
49
- requirement: &17071040 !ruby/object:Gem::Requirement
49
+ requirement: &16480960 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ~>
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: '3.10'
55
55
  type: :development
56
56
  prerelease: false
57
- version_requirements: *17071040
57
+ version_requirements: *16480960
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: hoe
60
- requirement: &17069660 !ruby/object:Gem::Requirement
60
+ requirement: &16480180 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ~>
@@ -65,7 +65,7 @@ dependencies:
65
65
  version: '3.1'
66
66
  type: :development
67
67
  prerelease: false
68
- version_requirements: *17069660
68
+ version_requirements: *16480180
69
69
  description: autoproj is a manager for sets of software packages. It allows the user
70
70
  to import and build packages from source, still using the underlying distribution's
71
71
  native package manager for software that is available on it.