Make pkgConfigExecutable() work when a pkg-config is defined in the spec
Commit 6e6f27b6 made it possible to set the PKG_CONFIG variable using
CROSS_COMPILE as a prefix. The problem with that solution is that it makes
pkgConfigExecutable() skip the environment setup for pkg-config as well,
as it expects the pre-set command to be self-contained - which it isn't.
To avoid this problem we need to store the pkg-config define in the
device spec in a separate variable.
Change-Id: Id8ae7fb03d9253be55840e23fe73b30815ee86c3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
bb10
parent
1185c28f2f
commit
205987750d
|
|
@ -25,4 +25,4 @@ QMAKE_NM = $${CROSS_COMPILE}nm -P
|
|||
QMAKE_STRIP = $${CROSS_COMPILE}strip
|
||||
|
||||
contains(DISTRO_OPTS, deb-multi-arch): \
|
||||
PKG_CONFIG = $${CROSS_COMPILE}pkg-config
|
||||
QMAKE_PKG_CONFIG = $${CROSS_COMPILE}pkg-config
|
||||
|
|
|
|||
|
|
@ -215,7 +215,10 @@ defineTest(qtAddTargetEnv) {
|
|||
|
||||
defineReplace(pkgConfigExecutable) {
|
||||
isEmpty(PKG_CONFIG) {
|
||||
PKG_CONFIG = pkg-config
|
||||
!isEmpty(QMAKE_PKG_CONFIG): \
|
||||
PKG_CONFIG = $$QMAKE_PKG_CONFIG
|
||||
else: \
|
||||
PKG_CONFIG = pkg-config
|
||||
|
||||
sysroot.name = PKG_CONFIG_SYSROOT_DIR
|
||||
sysroot.value = $$PKG_CONFIG_SYSROOT_DIR
|
||||
|
|
|
|||
Loading…
Reference in New Issue