Skip to content

Commit 4c73104

Browse files
committed
configure: use cc and c++ as defaults on os x
Commit 8b2363d ("configure: use gcc and g++ as CC and CXX defaults") switches the CC and CXX defaults but it turns out that GYP uses cc and c++ as defaults on OS X. It also made the configure script complain about old compilers because the xcode gcc identifies as v4.2.1, whereas cc is less ambiguous about it being a clang hybrid. PR-URL: #1210 Reviewed-By: Jeremiah Senkpiel <[email protected]> Reviewed-By: Johan Bergström <[email protected]>
1 parent 2034137 commit 4c73104

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

configure

+4-3
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ import sys
99
import shutil
1010
import string
1111

12-
# gcc and g++ as defaults matches what GYP's Makefile generator does.
13-
CC = os.environ.get('CC', 'gcc')
14-
CXX = os.environ.get('CXX', 'g++')
12+
# gcc and g++ as defaults matches what GYP's Makefile generator does,
13+
# except on OS X.
14+
CC = os.environ.get('CC', 'cc' if sys.platform == 'darwin' else 'gcc')
15+
CXX = os.environ.get('CXX', 'c++' if sys.platform == 'darwin' else 'g++')
1516

1617
root_dir = os.path.dirname(__file__)
1718
sys.path.insert(0, os.path.join(root_dir, 'tools', 'gyp', 'pylib'))

0 commit comments

Comments
 (0)