bin/autoproj_bootstrap in autoproj-1.8.2.b15 vs bin/autoproj_bootstrap in autoproj-1.8.2.b16
- old
+ new
@@ -293,23 +293,31 @@
"yum install '%s'",
"yum install -y '%s'")
end
def filter_uptodate_packages(packages)
- result = `LANG=C rpm -q '#{packages.join("' '")}'`
- if $?.exitstatus != 0
- Autoproj.warn "cannot run rpm -q #{packages.join(", ")}. I am assuming that no packages are already installed"
- return packages
- else
- result = []
- result.split("\n").each_with_index do |line, index|
- if line =~ /is not installed/
- result << packages[index]
- end
+ result = `LANG=C rpm -q --queryformat "%{NAME}\n" '#{packages.join("' '")}'`
+
+ installed_packages = []
+ new_packages = []
+ result.split("\n").each_with_index do |line, index|
+ line = line.strip
+ if line =~ /package (.*) is not installed/
+ package_name = $1
+ if !packages.include?(package_name) # something is wrong, fallback to installing everything
+ return packages
+ end
+ new_packages << package_name
+ else
+ package_name = line.strip
+ if !packages.include?(package_name) # something is wrong, fallback to installing everything
+ return packages
+ end
+ installed_packages << package_name
end
- result
end
+ new_packages
end
end
# Package manager interface for systems that use APT and dpkg for
# package management
@@ -1790,10 +1798,15 @@
- libopenssl-ruby1.8
- rake
gentoo:
- dev-lang/ruby:1.8
- rake
+ fedora:
+ '15,16':
+ - ruby
+ - rubygems
+ default: nonexistent
ruby19:
debian:
- ruby1.9.1
- ruby1.9.1-dev
- rubygems1.9.1
@@ -1810,56 +1823,71 @@
- dev-lang/ruby:1.9
- rake
arch:
- ruby
- rake
+ fedora:
+ '17':
+ - ruby
+ - rubygems
+ default: nonexistent
build-essential:
debian,ubuntu: build-essential
gentoo: ignore
arch: ignore
-zlib:
- debian,ubuntu: zlib1g-dev
+ fedora: ignore
autobuild: gem
autoproj: gem
git:
debian:
lenny: git
default: git-core
ubuntu: git-core
gentoo: dev-vcs/git
arch: git
+ fedora: git
svn:
debian,ubuntu: subversion
gentoo: dev-util/subversion
arch: subversion
+ fedora: subversion
cmake:
debian,ubuntu: cmake
gentoo: dev-util/cmake
arch: cmake
+ fedora: cmake
autotools:
debian,ubuntu:
- automake1.9
- autoconf
gentoo:
- sys-devel/automake:1.9
- sys-devel/autoconf
arch: automake autoconf
+ fedora:
+ - automake
+ - autoconf
lsb_release:
debian,ubuntu: lsb-release
gentoo: sys-apps/lsb-release
arch: ignore
+ fedora: redhat-lsb
archive:
debian,ubuntu:
- tar
- unzip
gentoo:
- app-arch/tar
- app-arch/unzip
arch:
- tar
- unzip
+ fedora:
+ - tar
+ - unzip
cvs:
debian,ubuntu: cvs
+ fedora: cvs
EODEFS
Autoproj::OSDependencies.define_osdeps_mode_option
osdeps_mode = Autoproj::OSDependencies.osdeps_mode