Skip to content
This repository
Browse code

Merge pull request #280 from edlebert/master

Issue #279: Can't install in cygwin
  • Loading branch information...
commit 69151c3ebb3e4ecf2bb9b6e2fab2022dc34f8541 2 parents 86784d2 + 8c0e5ae
Aman Gupta authored November 20, 2011
9  ext/extconf.rb
@@ -139,6 +139,15 @@ def manual_ssl_config
139 139
 when /aix/
140 140
   CONFIG['LDSHARED'] = "$(CXX) -shared -Wl,-G -Wl,-brtl"
141 141
 
  142
+when /cygwin/
  143
+  # For rubies built with Cygwin, CXX may be set to CC, which is just
  144
+  # a wrapper for gcc.
  145
+  # This will compile, but it will not link to the C++ std library.
  146
+  # Explicitly set CXX to use g++.
  147
+  CONFIG['CXX'] = "g++"
  148
+  # on Unix we need a g++ link, not gcc.
  149
+  CONFIG['LDSHARED'] = "$(CXX) -shared"
  150
+
142 151
 else
143 152
   # on Unix we need a g++ link, not gcc.
144 153
   CONFIG['LDSHARED'] = "$(CXX) -shared"
9  ext/fastfilereader/extconf.rb
@@ -77,6 +77,15 @@ def add_define(name)
77 77
   # on Unix we need a g++ link, not gcc.
78 78
   CONFIG['LDSHARED'] = "$(CXX) -shared -Wl,-G"
79 79
 
  80
+when /cygwin/
  81
+  # For rubies built with Cygwin, CXX may be set to CC, which is just
  82
+  # a wrapper for gcc.
  83
+  # This will compile, but it will not link to the C++ std library.
  84
+  # Explicitly set CXX to use g++.
  85
+  CONFIG['CXX'] = "g++"
  86
+  # on Unix we need a g++ link, not gcc.
  87
+  CONFIG['LDSHARED'] = "$(CXX) -shared"
  88
+
80 89
 else
81 90
   # on Unix we need a g++ link, not gcc.
82 91
   CONFIG['LDSHARED'] = "$(CXX) -shared"

0 notes on commit 69151c3

Please sign in to comment.
Something went wrong with that request. Please try again.