diff --git a/ChangeLog b/ChangeLog index db86af1437..5bf40cf4fa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Mar 3 09:52:05 2004 Nobuyoshi Nakada + + * lib/mkmf.rb ($topdir): use compile_dir only when not installed yet. + [ruby-talk:94098] + Wed Mar 3 01:18:52 2004 Kouhei Sutou * lib/rss/converter.rb: handled Uconv::Error. diff --git a/lib/mkmf.rb b/lib/mkmf.rb index 92fc97d726..c6180282ec 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb @@ -77,16 +77,11 @@ def map_dir(dir, map = nil) map.inject(dir) {|dir, (orig, new)| dir.gsub(orig, new)} end -if not $extmk and File.exist? Config::CONFIG["archdir"] + "/ruby.h" - $hdrdir = $archdir -elsif File.exist? $srcdir + "/ruby.h" +if not $extmk and File.exist?(Config::CONFIG["archdir"] + "/ruby.h") + $topdir = $hdrdir = $archdir +elsif File.exist?($srcdir + "/ruby.h") and + File.exist?((compile_dir = Config::CONFIG['compile_dir']) + "/config.h") $hdrdir = $srcdir -else - abort "can't find header files for ruby." -end -if File.exist?($hdrdir + "/config.h") - $topdir = $hdrdir -elsif File.exist?((compile_dir = Config::CONFIG['compile_dir']) + "/config.h") $topdir = compile_dir else abort "can't find header files for ruby."