From 8e392570254dd7e275d0225ec0c47bebdf512e1e Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 5 Oct 2008 14:34:37 +0000 Subject: * lib/mkmf.rb ($config_h): now always defines for old libraries. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/mkmf.rb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'lib') diff --git a/lib/mkmf.rb b/lib/mkmf.rb index 87a0cdf873..76692f187f 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb @@ -13,7 +13,8 @@ if /mswin|bccwin|mingw|os2/ !~ CONFIG['build_os'] CXX_EXT.concat(%w[C]) end SRC_EXT = %w[c m] << CXX_EXT -$static = $config_h = nil +$static = nil +$config_h = '$(arch_hdrdir)/ruby/config.h' $default_static = $static unless defined? $configure_args @@ -1441,7 +1442,7 @@ def depend_rules(depend) end depend.each_line do |line| line.gsub!(/\.o\b/, ".#{$OBJEXT}") - line.gsub!(/\$\((?:hdr|top)dir\)\/config.h/, $config_h) if $config_h + line.gsub!(/\$\((?:hdr|top)dir\)\/config.h/, $config_h) line.gsub!(%r"\$\(hdrdir\)/(?!ruby(?![^:;/\s]))(?=[-\w]+\.h)", '\&ruby/') if $nmake && /\A\s*\$\(RM|COPY\)/ =~ line line.gsub!(%r"[-\w\./]{2,}"){$&.tr("/", "\\")} @@ -1742,7 +1743,7 @@ site-install-rb: install-rb if RULE_SUBST headers.each {|h| h.sub!(/.*/, &RULE_SUBST.method(:%))} end - headers << $config_h if $config_h + headers << $config_h headers << '$(RUBY_EXTCONF_H)' if $extconf_h mfile.print "$(OBJS): ", headers.join(' '), "\n" end -- cgit v1.2.3