summaryrefslogtreecommitdiff
path: root/mkconfig.rb
diff options
context:
space:
mode:
Diffstat (limited to 'mkconfig.rb')
-rw-r--r--mkconfig.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/mkconfig.rb b/mkconfig.rb
index 721cd3f67d..14e5829f53 100644
--- a/mkconfig.rb
+++ b/mkconfig.rb
@@ -48,7 +48,7 @@ File.foreach "config.status" do |line|
v_others << v
end
has_version = true if name == "MAJOR"
- elsif /^ac_given_srcdir=(.*)/ =~ line
+ elsif /^(?:ac_given_)srcdir=(.*)/ =~ line
v_fast << " CONFIG[\"srcdir\"] = \"" + File.expand_path($1) + "\"\n"
has_srcdir = true
elsif /^ac_given_INSTALL=(.*)/ =~ line
@@ -58,7 +58,7 @@ File.foreach "config.status" do |line|
end
if not has_srcdir
- v_fast << " CONFIG[\"srcdir\"] = \"" + File.expand_path(srcdir) + "\"\n"
+ v_fast << " CONFIG[\"srcdir\"] = \"" + File.expand_path(srcdir || '.') + "\"\n"
end
if not has_version