Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Decouple linking for C-exts from clang/gcc.
  • Loading branch information
brixen committed Feb 23, 2016
1 parent a8b3449 commit ce4e526
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions core/rbconfig.rb
Expand Up @@ -209,9 +209,13 @@ module RbConfig
CONFIG["PACKAGE_VERSION"] = ""
CONFIG["PACKAGE_STRING"] = ""
CONFIG["PACKAGE_BUGREPORT"] = ""
CONFIG["LDSHARED"] = Rubinius::LDSHARED.dup
CONFIG["LIBRUBY_LDSHARED"] = Rubinius::LDSHARED.dup
CONFIG["LDSHAREDXX"] = Rubinius::LDSHAREDXX.dup

ldshared = (ENV["LDSHARED"] || Rubinius::LDSHARED.sub(/^(gcc|clang)/, "cc")).dup
ldsharedxx = (ENV["LDSHAREDXX"] || Rubinius::LDSHAREDXX.sub(/^(g|clang)\+\+/, "c++")).dup

CONFIG["LDSHARED"] = ldshared
CONFIG["LIBRUBY_LDSHARED"] = ldshared
CONFIG["LDSHAREDXX"] = ldsharedxx

# absolute path to ruby executable (pulled directly from MRI's mkconfig.rb)
def RbConfig.ruby
Expand Down

0 comments on commit ce4e526

Please sign in to comment.