null+****@clear*****
null+****@clear*****
2012年 6月 21日 (木) 18:10:31 JST
Kouhei Sutou 2012-06-21 18:10:31 +0900 (Thu, 21 Jun 2012) New Revision: 47e72085f489826164e77871e16c2075f5165731 https://github.com/groonga/gcs/commit/47e72085f489826164e77871e16c2075f5165731 Log: package: improve auto-detect of shared object extension Modified files: packages/all-in-one/Rakefile Modified: packages/all-in-one/Rakefile (+12 -2) =================================================================== --- packages/all-in-one/Rakefile 2012-06-21 18:05:21 +0900 (07fcfc6) +++ packages/all-in-one/Rakefile 2012-06-21 18:10:31 +0900 (91dac79) @@ -9,8 +9,6 @@ require "json" build_debug_p = ENV["BUILD_DEBUG"] == "yes" debug_flags = ["CFLAGS=-ggdb3 -O0", "CXXFLAGS=-ggdb3 -O0"] -shared_object_extension = RbConfig::CONFIG["LIBRUBY_SO"].split(/\./).last - base_dir = Pathname.new(__FILE__).dirname.expand_path top_dir = base_dir.parent.parent tmp_dir = base_dir + "tmp" @@ -30,7 +28,19 @@ def detect_make end end +def detect_shared_object_extension + case RUBY_PLATFORM + when /linux/, /bsd/ + "so" + when /darwin/ + "dylib" + else + RbConfig::CONFIG["LIBRUBY_SO"].split(/\./).last + end +end + make = ENV["MAKE"] || detect_make +shared_object_extension = detect_shared_object_extension def download(url) url = URI.parse(url) unless url.is_a?(URI::Generic) -------------- next part -------------- HTML$B$NE:IU%U%!%$%k$rJ]4I$7$^$7$?(B... Download