aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorGravatar Jeroen Massar <jeroen@massar.ch>2016-03-16 09:00:37 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-03-16 09:00:31 -0700
commit0ddfd3a99233168bc0de6e028fc6decb6a547191 (patch)
treee029d58c5d824b30600ccd87bbfe3befd5edd174 /scripts
parent4a8619349aa1f91f81986132608cb659d9f8b2d7 (diff)
downloadsubsurface-0ddfd3a99233168bc0de6e028fc6decb6a547191.tar.gz
Detect Homebrew Qt5
And preserve that path in CMAKE_PREFIX_PATH and pass it along to cmake Signed-off-by: Jeroen Massar <jeroen@massar.ch> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/build.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/build.sh b/scripts/build.sh
index a35dce979..ea8752119 100755
--- a/scripts/build.sh
+++ b/scripts/build.sh
@@ -144,6 +144,9 @@ if [ $PLATFORM = Darwin ] ; then
export CMAKE_PREFIX_PATH=~/Qt/5.5/clang_64/lib/cmake
elif [ -d "$HOME/Qt/5.6" ] ; then
export CMAKE_PREFIX_PATH=~/Qt/5.6/clang_64/lib/cmake
+ elif [ -d /usr/local/opt/qt5/lib ] ; then
+ # Homebrew location for qt5 package
+ export CMAKE_PREFIX_PATH=/usr/local/opt/qt5/lib/cmake
else
echo "cannot find Qt 5.5 or 5.6 in ~/Qt"
exit 1
@@ -218,7 +221,7 @@ for (( i=0 ; i < ${#BUILDS[@]} ; i++ )) ; do
mkdir -p $SRC/subsurface/$BUILDDIR
cd $SRC/subsurface/$BUILDDIR
- export CMAKE_PREFIX_PATH=$INSTALL_ROOT/lib/cmake
+ export CMAKE_PREFIX_PATH="$INSTALL_ROOT/lib/cmake;${CMAKE_PREFIX_PATH}"
cmake -DCMAKE_BUILD_TYPE=Debug .. \
-DSUBSURFACE_TARGET_EXECUTABLE=$SUBSURFACE_EXECUTABLE \
-DLIBGIT2_INCLUDE_DIR=$INSTALL_ROOT/include \
@@ -227,6 +230,7 @@ for (( i=0 ; i < ${#BUILDS[@]} ; i++ )) ; do
-DLIBDIVECOMPUTER_LIBRARIES=$INSTALL_ROOT/lib/libdivecomputer.a \
-DMARBLE_INCLUDE_DIR=$INSTALL_ROOT/include \
-DMARBLE_LIBRARIES=$INSTALL_ROOT/lib/libssrfmarblewidget.$SH_LIB_EXT \
+ -DCMAKE_PREFIX_PATH=$CMAKE_PREFIX_PATH \
-DNO_PRINTING=OFF
if [ $PLATFORM = Darwin ] ; then