]> danny-edel.de - dspdfviewer.git/commitdiff
osx: Use shellglob to find qt5
authorDanny Edel <mail@danny-edel.de>
Wed, 18 May 2016 10:48:18 +0000 (12:48 +0200)
committerDanny Edel <mail@danny-edel.de>
Wed, 18 May 2016 10:48:18 +0000 (12:48 +0200)
_travis/configure

index c5e5d54c1683a7e9d347eccb936ee8f35fd7c6ea..8e1d9172077d87151676d75c539c52c676598602 100755 (executable)
@@ -30,6 +30,14 @@ if [ "$QT_VERSION" -eq 4 ] ; then
        CMAKE_PARAMETERS+=" -DUseQtFive=OFF"
 elif [ "$QT_VERSION" -eq 5 ] ; then
        CMAKE_PARAMETERS+=" -DUseQtFive=ON"
+       if [ "$TRAVIS_OS_NAME" = "osx" ] ; then
+               # on OSX/Homebrew, qt5 is not in default search path yet.
+               #
+               # Use shell-glob to find the qt5 directory
+               # and pass it to cmake
+               QT5PATH=$(ls -d /usr/local/Cellar/qt5/5.*/ | head -n1 )
+               CMAKE_PARAMETERS+=" -DCMAKE_PREFIX_PATH=$QT5PATH"
+       fi
 else
        echo "Unknown qt version $QT_VERSION" >&2
        false