1
0
mirror of https://github.com/fwbuilder/fwbuilder synced 2025-06-15 14:47:52 +02:00
fwbuilder/runqmake.sh
Dominique Leuenberger d4b8f9127d
Build: fix script to handle potential empty $FLAGS
In case $FLAGS is empty, the original command would have been
  qmake "" -recursive

qmake interpretes "" as the first parameter that should point to a filename, if given
2018-01-31 15:11:07 +01:00

23 lines
413 B
Bash
Executable File

#!/bin/sh
test -z "${QMAKE}" && QMAKE="qmake"
C="-recursive"
test -n "$QMAKESPEC" && C="$C -spec $QMAKESPEC "
echo "QTDIR=\"$QTDIR\""
echo "Running qmake: $QMAKE $C"
oIFS=$IFS
IFS="
"
test -z "$EXTRA_CXXFLAGS" || FLAGS="QMAKE_CXXFLAGS += $EXTRA_CXXFLAGS"
if [ -z "$FLAGS" ]; then
# in case there are no FLAGS defined, we can't pass an empty "" parameter to qmake
$QMAKE $C
else
$QMAKE "$FLAGS" $C
fi