lib/autobuild/packages/genom.rb in autobuild-0.6.5 vs lib/autobuild/packages/genom.rb in autobuild-0.6.6
- old
+ new
@@ -23,10 +23,12 @@
end
# Called before running the rake tasks and
# after all imports have been made
def prepare
+ genomflags.flatten!
+
super
get_requires
end
# The file touched by genom on successful generation
@@ -57,10 +59,12 @@
end
# Alias this package to the ones defined in the EXTRA_PKGCONFIG
# flag in configure.ac.user
def get_provides
- File.open(File.join(srcdir, 'configure.ac.user')) do |f|
+ configure_ac_user = File.join(srcdir, 'configure.ac.user')
+ return unless File.readable?(configure_ac_user)
+ File.open(configure_ac_user) do |f|
f.each_line { |line|
if line =~ /^\s*EXTRA_PKGCONFIG\s*=\s*"?([\w\-]+(?:\s+[\w\-]+)*)"?/
$1.split(/\s+/).each { |pkg| provides pkg }
end
}