1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

mkmf.rb: unexpand macros

* lib/mkmf.rb: unexpand macros.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37015 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2012-09-23 12:46:48 +00:00
parent 255e1b05b1
commit 9f4f154501
2 changed files with 7 additions and 4 deletions

View file

@ -1,4 +1,6 @@
Sun Sep 23 21:45:14 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
Sun Sep 23 21:46:12 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/mkmf.rb: unexpand macros.
* lib/mkmf.rb (LIBPATHFLAG): no needs to escape library path here.

View file

@ -196,10 +196,11 @@ module MakeMakefile
$extmk = path[0, topdir.size+1] == topdir+"/"
$extmk &&= %r"\A(?:ext|enc|tool|test(?:/.+)?)\z" =~ File.dirname(path[topdir.size+1..-1])
$extmk &&= true
if not $extmk and File.exist?(($hdrdir = RbConfig::CONFIG["rubyhdrdir"]) + "/ruby/ruby.h")
if not $extmk and File.exist?(RbConfig::CONFIG["rubyhdrdir"] + "/ruby/ruby.h")
$hdrdir = CONFIG["rubyhdrdir"]
$topdir = $hdrdir
$top_srcdir = $hdrdir
$arch_hdrdir = $hdrdir + "/$(arch)"
$arch_hdrdir = "$(hdrdir)/$(arch)"
elsif File.exist?(($hdrdir = ($top_srcdir ||= topdir) + "/include") + "/ruby.h")
$topdir ||= RbConfig::CONFIG["topdir"]
$arch_hdrdir = "$(extout)/include/$(arch)"
@ -1822,7 +1823,7 @@ RUBY_SO_NAME = #{CONFIG['RUBY_SO_NAME']}
arch = #{CONFIG['arch']}
sitearch = #{CONFIG['sitearch']}
ruby_version = #{RbConfig::CONFIG['ruby_version']}
ruby = #{$ruby}
ruby = #{$ruby.sub(%r[\A#{Regexp.quote(RbConfig::CONFIG['bindir'])}(?=/|\z)]) {'$(bindir)'}}
RUBY = $(ruby#{sep})
ruby_headers = #{headers.join(' ')}