summaryrefslogtreecommitdiff
path: root/instruby.rb
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-02-01 07:34:58 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-02-01 07:34:58 +0000
commit9b0dd20cbb3d0077c374509eb230adba84ed5488 (patch)
tree2a7936d597eff812a4e3fa896de7439b884a75f8 /instruby.rb
parent2344efc3835c3226fa06a85e6f3b1871415b8ad1 (diff)
990201
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_3@384 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'instruby.rb')
-rw-r--r--instruby.rb38
1 files changed, 18 insertions, 20 deletions
diff --git a/instruby.rb b/instruby.rb
index 3b79d40..6555b46 100644
--- a/instruby.rb
+++ b/instruby.rb
@@ -15,26 +15,25 @@ else
prefix = CONFIG["prefix"]
end
ruby_install_name = CONFIG["ruby_install_name"]
-bindir = CONFIG["bindir"]
-libdir = CONFIG["libdir"]
+bindir = destdir+CONFIG["bindir"]
+libdir = destdir+CONFIG["libdir"]
pkglibdir = libdir + "/" + ruby_install_name
archdir = pkglibdir + "/" + CONFIG["arch"]
-mandir = CONFIG["mandir"] + "/man1"
+mandir = destdir+CONFIG["mandir"] + "/man1"
wdir = Dir.getwd
-File.makedirs "#{destdir}#{bindir}", true
+File.makedirs bindir, true
File.install "ruby#{binsuffix}",
- "#{destdir}#{bindir}/#{ruby_install_name}#{binsuffix}", 0755, true
+ "#{bindir}/#{ruby_install_name}#{binsuffix}", 0755, true
for dll in Dir['*.dll']
- File.install dll, "#{destdir}#{bindir}/#{dll}", 0755, true
+ File.install dll, "#{bindir}/#{dll}", 0755, true
end
-File.makedirs "#{destdir}#{libdir}", true
+File.makedirs libdir, true
for lib in ["libruby.so.LIB", CONFIG["LIBRUBY_SO"]]
if File.exist? lib
- File.install lib, "#{destdir}#{libdir}", 0644, true
+ File.install lib, libdir, 0644, true
end
end
-pwd = Dir.pwd
Dir.chdir libdir
if File.exist? CONFIG["LIBRUBY_SO"]
for link in CONFIG["LIBRUBY_ALIASES"].split
@@ -45,25 +44,24 @@ if File.exist? CONFIG["LIBRUBY_SO"]
print "link #{CONFIG['LIBRUBY_SO']} -> #{link}\n"
end
end
-Dir.chdir pwd
-File.makedirs "#{destdir}#{pkglibdir}", true
-File.makedirs "#{destdir}#{archdir}", true
+Dir.chdir wdir
+File.makedirs pkglibdir, true
+File.makedirs archdir, true
Dir.chdir "ext"
system "../miniruby#{binsuffix} extmk.rb install #{destdir}"
Dir.chdir CONFIG["srcdir"]
for f in Dir["lib/*.rb"]
- File.install f, "#{destdir}#{pkglibdir}", 0644, true
+ File.install f, pkglibdir, 0644, true
end
-File.makedirs(archdir,true)
for f in Dir["*.h"]
- File.install f, "#{destdir}#{archdir}", 0644, true
+ File.install f, archdir, 0644, true
end
-File.install pwd+'/'+CONFIG['LIBRUBY_A'], "#{destdir}#{archdir}", 0644, true
+File.install pwd+'/'+CONFIG['LIBRUBY_A'], archdir, 0644, true
-File.makedirs "#{destdir}#{mandir}", true
-File.install "ruby.1", "#{destdir}#{mandir}", 0644, true
+File.makedirs mandir, true
+File.install "ruby.1", mandir, 0644, true
Dir.chdir wdir
-File.install "config.h", "#{destdir}#{archdir}", 0644, true
-File.install "rbconfig.rb", "#{destdir}#{archdir}", 0644, true
+File.install "config.h", archdir, 0644, true
+File.install "rbconfig.rb", archdir, 0644, true
# vi:set sw=2: