Sophie

Sophie

distrib > Mandriva > 2008.0 > i586 > by-pkgid > 8a10625dd3b8e42e5ee544d2d6b223e7 > files > 5

ruby-1.8.6-5mdv2008.0.src.rpm

--- mkconfig.rb	2003-08-05 11:27:20.000000000 +0200
+++ mkconfig.rb	2005-03-31 09:18:17.000000000 +0200
@@ -107,7 +107,7 @@
 print v_fast, v_others
 print <<EOS
   CONFIG["ruby_version"] = "$(MAJOR).$(MINOR)"
-  CONFIG["rubylibdir"] = "$(libdir)/ruby/$(ruby_version)"
+  CONFIG["rubylibdir"] = "$(prefix)/lib/ruby/$(ruby_version)"
   CONFIG["archdir"] = "$(rubylibdir)/$(arch)"
   CONFIG["sitelibdir"] = "$(sitedir)/$(ruby_version)"
   CONFIG["sitearchdir"] = "$(sitelibdir)/$(sitearch)"
--- ext/tk/extconf.rb.lib64	2007-02-13 00:01:19.000000000 +0100
+++ ext/tk/extconf.rb	2007-04-06 15:10:54.000000000 +0200
@@ -39,6 +39,11 @@
   have_library("m", "log") 
 end
 
+$lib = "lib"
+if RUBY_PLATFORM =~ /(x86_64|powerpc64)-linux/
+  $lib = "lib64"
+end
+
 dir_config("tk")
 dir_config("tcl")
 dir_config("X11")
@@ -50,7 +55,7 @@
 use_X = with_config("X11", (! is_win32))
 
 def find_tcl(tcllib, stubs)
-  paths = ["/usr/local/lib", "/usr/pkg/lib", "/usr/lib"]
+  paths = ["/usr/local/"+$lib, "/usr/pkg/"+$lib, "/usr/"+$lib]
   if stubs
     func = "Tcl_InitStubs"
     lib = "tclstub"
@@ -73,7 +78,7 @@
 end
 
 def find_tk(tklib, stubs)
-  paths = ["/usr/local/lib", "/usr/pkg/lib", "/usr/lib"]
+  paths = ["/usr/local/"+$lib, "/usr/pkg/"+$lib, "/usr/"+$lib]
   if stubs
     func = "Tk_InitStubs"
     lib = "tkstub"
@@ -276,8 +281,8 @@
 if tcltk_framework || 
    (have_header("tcl.h") && have_header("tk.h") &&
       ( !use_X || find_library("X11", "XOpenDisplay",
-                               "/usr/X11/lib", "/usr/lib/X11", 
-                               "/usr/X11R6/lib", "/usr/openwin/lib")) &&
+                               "/usr/#{$lib}/lib", "/usr/#{$lib}/X11", 
+                               "/usr/X11R6/#{$lib}", "/usr/openwin/#{$lib}")) &&
     find_tcl(tcllib, stubs) &&
     find_tk(tklib, stubs))
   $CPPFLAGS += ' -DUSE_TCL_STUBS -DUSE_TK_STUBS' if stubs