1
0
forked from mirrors/0ad

Sets default compiler for OS X build to clang, using hack that should be replaced if we upgrade premake.

Fixes linking error in ICU build from build-osx-libs.sh (it was setting
the C++ compiler to clang, which is the C compiler, so it wouldn't
automatically link to the c++ lib). Now build-osx-libs.sh and the game
should use clang and whichever c++ lib is the default

This was SVN commit r15725.
This commit is contained in:
historic_bruno
2014-09-09 23:56:39 +00:00
parent 7ada7dd2a8
commit e4d7586cdd
2 changed files with 8 additions and 1 deletions
+7
View File
@@ -66,6 +66,13 @@ else
end
end
-- Hack to force clang as default compiler on OS X
-- TODO: proper clang support
if os.is("macosx") then
premake.gcc.cc = "clang"
premake.gcc.cxx = "clang++"
end
-- Set up the Solution
solution "pyrogenesis"
targetdir(rootdir.."/binaries/system")
+1 -1
View File
@@ -582,7 +582,7 @@ then
mkdir -p source/build
pushd source/build
(CXX="clang" CFLAGS="$CFLAGS" CXXFLAGS="$CXXFLAGS -stdlib=libstdc++" LDFLAGS="$LDFLAGS -lstdc++" ../runConfigureICU MacOSX --prefix=$INSTALL_DIR --disable-shared --enable-static --disable-samples --enable-extras --enable-icuio --enable-layout --enable-tools && make ${JOBS} && make install) || die "ICU build failed"
(CFLAGS="$CFLAGS" CXXFLAGS="$CXXFLAGS" LDFLAGS="$LDFLAGS" ../runConfigureICU MacOSX --prefix=$INSTALL_DIR --disable-shared --enable-static --disable-samples --enable-extras --enable-icuio --enable-layout --enable-tools && make ${JOBS} && make install) || die "ICU build failed"
popd
popd
touch .already-built