Skip to content

Commit

Permalink
Pass no-pkg-config to qmake from config.test if appropriate
Browse files Browse the repository at this point in the history
On macOS, even if pkg-config is present in the path, configure will by
default correctly ignore it and set no-pkg-config. However, this was not
propagated to qmake when invoked from config.test, so tests which rely on
that did not work.

This was leading to pkg-config (installed from homebrew) to be used in
the libpng test, so it succeeded. But the later Qt build would fail to
find png.h from homebrew, as it correctly ignores pkg-config.

Task-number: QTBUG-55011
Change-Id: Ic6fb866bea0551f528da56cb545174dcd9bacf0d
Reviewed-by: Oswald Buddenhagen <[email protected]>
Reviewed-by: Liang Qi <[email protected]>
Reviewed-by: Mike Krus <[email protected]>
  • Loading branch information
mkrus authored and ossilator committed Aug 25, 2016
1 parent 1f7f73b commit 882f344
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -4293,8 +4293,12 @@ compileTest()
if [ "$CFG_SHARED" = "no" ]; then
test_config="$QMAKE_CONFIG static"
fi
TEST_CONFIG_FLAGS=
if [ -z "$PKG_CONFIG" ]; then
TEST_CONFIG_FLAGS="QT_CONFIG+=no-pkg-config"
fi
echo $ECHO_N "checking for $name... $ECHO_C"
"$unixtests/compile.test" "$XQMAKESPEC" "$test_config" $OPT_VERBOSE "$relpath" "$outpath" "$path" "$name" $I_FLAGS $D_FLAGS $L_FLAGS "$@"
"$unixtests/compile.test" "$XQMAKESPEC" "$test_config" $OPT_VERBOSE "$relpath" "$outpath" "$path" "$name" $I_FLAGS $D_FLAGS $L_FLAGS $TEST_CONFIG_FLAGS "$@"
}

compileTestWithPkgConfig()
Expand Down

0 comments on commit 882f344

Please sign in to comment.