Permalink
Browse files

Update Mac build script

- Switch to OS X 10.9 SDK
- Use gettext and openssl from Homebrew
  • Loading branch information...
gelraen committed Jul 26, 2015
1 parent 4a0b0d5 commit a2a086a4f46275d85cc8ed1449c5eb0f9c0ca26b
Showing with 7 additions and 5 deletions.
  1. +7 −5 macosx/build.sh
View
@@ -10,13 +10,15 @@
set -e
OSXSDK="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk"
OPTIONS="-DCMAKE_BUILD_TYPE=Release -DUSE_MINIUPNP=ON -DLOCAL_MINIUPNP=ON -DFREE_SPACE_BAR_C=ON -DWITH_SOUNDS=ON -DUSE_ASPELL=ON -DWITH_DHT=ON"
OSXSDK="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk"
OPTIONS="-DCMAKE_BUILD_TYPE=Release -DUSE_MINIUPNP=ON -DLOCAL_MINIUPNP=ON -DFREE_SPACE_BAR_C=ON -DWITH_SOUNDS=ON -DUSE_ASPELL=ON -DWITH_DHT=ON -DUSE_QT=OFF -DUSE_QT5=ON"
COMPILER="-DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++"
COMPILER_FLAGS="-DCMAKE_SYSTEM_PREFIX_PATH='/opt/local/;${OSXSDK}/' -DCMAKE_INCLUDE_PATH='${OSXSDK}/usr/include;/opt/local/include;/usr/include' -DCMAKE_CXX_FLAGS='-I${OSXSDK}/usr/include -I/opt/local/include -stdlib=libc++' -DCMAKE_C_FLAGS='-I${OSXSDK}/usr/include -I/opt/local/include' -DCMAKE_EXE_LINKER_FLAGS=-L/opt/local/lib"
ARCH="-DCMAKE_OSX_DEPLOYMENT_TARGET=10.8 -DCMAKE_OSX_SYSROOT='${OSXSDK}'"
COMPILER_FLAGS="-DCMAKE_SYSTEM_PREFIX_PATH='/usr/local/;${OSXSDK}/' -DCMAKE_INCLUDE_PATH='${OSXSDK}/usr/include;/usr/local/include;/usr/include' -DCMAKE_CXX_FLAGS='-I${OSXSDK}/usr/include -I/usr/local/include -stdlib=libc++' -DCMAKE_C_FLAGS='-I${OSXSDK}/usr/include -I/usr/local/include' -DCMAKE_EXE_LINKER_FLAGS=-L/usr/local/lib"
ARCH="-DCMAKE_OSX_DEPLOYMENT_TARGET=10.9 -DCMAKE_OSX_SYSROOT='${OSXSDK}'"
GETTEXT="-DGETTEXT_SEARCH_PATH=/usr/local/opt/gettext/bin"
OPENSSL="-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl -DOPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include"
eval /opt/local/bin/cmake ../eiskaltdcpp -DCMAKE_OSX_ARCHITECTURES=\'x86_64\' ${ARCH} ${COMPILER_FLAGS} ${COMPILER} ${OPTIONS} "$@"
eval cmake .. -DCMAKE_OSX_ARCHITECTURES=\'x86_64\' ${ARCH} ${COMPILER_FLAGS} ${COMPILER} ${OPTIONS} ${GETTEXT} ${OPENSSL} "$@"
make -j 4

0 comments on commit a2a086a

Please sign in to comment.