swt2c / rpms / openbabel

Forked from rpms/openbabel 5 years ago
Clone
TASAKA Mamoru 00ba8a9
--- openbabel-2.3.1/scripts/ruby/extconf.rb.gcc47	2011-01-11 23:53:32.000000000 +0900
TASAKA Mamoru 00ba8a9
+++ openbabel-2.3.1/scripts/ruby/extconf.rb	2012-04-05 14:15:14.286842274 +0900
TASAKA Mamoru 00ba8a9
@@ -3,11 +3,13 @@
TASAKA Mamoru 00ba8a9
 # Compensate for the fact that Ruby will try to build universal
TASAKA Mamoru 00ba8a9
 # binaries on OS X by default
TASAKA Mamoru 00ba8a9
 require 'rbconfig'
TASAKA Mamoru 00ba8a9
+darwin_ldflags = ""
TASAKA Mamoru 00ba8a9
 if Config::CONFIG["arch"] =~ /universal-darwin/
TASAKA Mamoru 00ba8a9
   ENV['ARCHFLAGS'] = case `uname -smr`.chomp
TASAKA Mamoru 00ba8a9
     when "i386" then '-arch i386'
TASAKA Mamoru 00ba8a9
     when "ppc"  then '-arch ppc'
TASAKA Mamoru 00ba8a9
   end
TASAKA Mamoru 00ba8a9
+  darwin_ldflags = "-flat_namespace"
TASAKA Mamoru 00ba8a9
 end
TASAKA Mamoru 00ba8a9
 
TASAKA Mamoru 00ba8a9
 require 'mkmf'
TASAKA Mamoru 00ba8a9
@@ -36,7 +38,7 @@
TASAKA Mamoru 00ba8a9
 end
TASAKA Mamoru 00ba8a9
 
TASAKA Mamoru 00ba8a9
 if have_library('openbabel')
TASAKA Mamoru 00ba8a9
-  with_ldflags("#$LDFLAGS -dynamic -flat_namespace") do #Enables cc to handle linking better.
TASAKA Mamoru 00ba8a9
+  with_ldflags("#$LDFLAGS -dynamic #$darwin_ldflags") do #Enables cc to handle linking better.
TASAKA Mamoru 00ba8a9
   create_makefile('openbabel')
TASAKA Mamoru 00ba8a9
 end
TASAKA Mamoru 00ba8a9
 else