diff --git a/scripts/build.sh b/scripts/build.sh index aa53269b1..c1be9a1cb 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -221,7 +221,8 @@ echo Building from "$SRC", installing in "$INSTALL_ROOT" # find qmake if [ -n "$CMAKE_PREFIX_PATH" ] ; then QMAKE=$CMAKE_PREFIX_PATH/../../bin/qmake -else +fi +if [[ -z $QMAKE || ! -x $QMAKE ]] ; then hash qmake > /dev/null 2> /dev/null && QMAKE=qmake [ -z $QMAKE ] && hash qmake-qt5 > /dev/null 2> /dev/null && QMAKE=qmake-qt5 [ -z $QMAKE ] && echo "cannot find qmake or qmake-qt5" && exit 1