summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-05-22 20:48:34 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-05-22 20:48:34 +0000
commit80a0e2f7531dcb8260059209a6a0bab9ab3a08cc (patch)
treeb7d51903ae06d9373968445ddca12c03d088ceef /ext
parent64bffee8d630d2a18244cfa641bdbf3bc3958b7c (diff)
* ext/extmk.rb, ext/purelib.rb, lib/mkmf.rb, runruby.rb: clear default
load path to get rid of load pre-installed extensions/libraries. [ruby-core:11017] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r--ext/extmk.rb5
-rw-r--r--ext/purelib.rb6
2 files changed, 10 insertions, 1 deletions
diff --git a/ext/extmk.rb b/ext/extmk.rb
index f40bfa6..a932a14 100644
--- a/ext/extmk.rb
+++ b/ext/extmk.rb
@@ -323,8 +323,11 @@ else
$ruby = '$(topdir)/miniruby' + EXEEXT
end
$ruby << " -I'$(topdir)' -I'$(hdrdir)/lib'"
-$ruby << " -I'#{$extout}'" if $extout
+$ruby << " -I'$(extout)/$(arch)' -I'$(extout)/common'" if $extout
+$ruby << " -I'$(hdrdir)/ext' -rpurelib.rb"
$config_h = '$(topdir)/config.h'
+ENV["RUBYLIB"] = "-"
+ENV["RUBYOPT"] = "-rpurelib.rb"
MTIMES = [__FILE__, 'rbconfig.rb', srcdir+'/lib/mkmf.rb'].collect {|f| File.mtime(f)}
diff --git a/ext/purelib.rb b/ext/purelib.rb
new file mode 100644
index 0000000..f826c57
--- /dev/null
+++ b/ext/purelib.rb
@@ -0,0 +1,6 @@
+if nul = $:.index("-")
+ $:[nul..-1] = ["."]
+end
+if nul = $:.index("-")
+ $:[nul..-1] = ["."]
+end