From 82734d940c843ce1085a3f4b15811689f4600187 Mon Sep 17 00:00:00 2001 From: John Date: Thu, 7 May 2020 19:43:49 +0200 Subject: [PATCH] common/xbps-src: set PKG_CONFIG{,FOR_BUILD} env vars --- common/build-style/meson.sh | 3 +-- common/build-style/qmake.sh | 2 +- common/xbps-src/shutils/common.sh | 2 ++ 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/common/build-style/meson.sh b/common/build-style/meson.sh index 38bbddd765..3302171504 100644 --- a/common/build-style/meson.sh +++ b/common/build-style/meson.sh @@ -52,7 +52,7 @@ ld = '${LD}' strip = '${STRIP}' readelf = '${READELF}' objcopy = '${OBJCOPY}' -pkgconfig = 'pkg-config' +pkgconfig = '${PKG_CONFIG}' rust = 'rustc' g-ir-scanner = '${XBPS_CROSS_BASE}/usr/bin/g-ir-scanner' g-ir-compiler = '${XBPS_CROSS_BASE}/usr/bin/g-ir-compiler' @@ -88,7 +88,6 @@ do_configure() { if [ "$CROSS_BUILD" ]; then configure_args+=" --cross-file=${meson_crossfile}" - export PKG_CONFIG_FOR_BUILD="/usr/bin/pkg-config" fi ${meson_cmd} \ diff --git a/common/build-style/qmake.sh b/common/build-style/qmake.sh index 33762e2324..14d071cd85 100644 --- a/common/build-style/qmake.sh +++ b/common/build-style/qmake.sh @@ -107,7 +107,7 @@ HostLibraries=/usr/lib Spec=${wrksrc}/.host-spec/linux-g++ TargetSpec=${wrksrc}/.target-spec/linux-g++ _EOF - qmake_args="-qtconf ${wrksrc}/qt.conf PKG_CONFIG_EXECUTABLE=${XBPS_WRAPPERDIR}/pkg-config" + qmake_args="-qtconf ${wrksrc}/qt.conf PKG_CONFIG_EXECUTABLE=${XBPS_WRAPPERDIR}/${PKG_CONFIG}" ${qmake} ${qmake_args} \ PREFIX=/usr \ QT_INSTALL_PREFIX=/usr \ diff --git a/common/xbps-src/shutils/common.sh b/common/xbps-src/shutils/common.sh index 44a92d5236..5ddf57a033 100644 --- a/common/xbps-src/shutils/common.sh +++ b/common/xbps-src/shutils/common.sh @@ -514,6 +514,7 @@ setup_pkg() { export CPP_FOR_BUILD="cpp" export FC_FOR_BUILD="gfortran" export LD_FOR_BUILD="ld" + export PKG_CONFIG_FOR_BUILD="/usr/bin/pkg-config" export CFLAGS_FOR_BUILD="$XBPS_CFLAGS" export CXXFLAGS_FOR_BUILD="$XBPS_CXXFLAGS" export CPPFLAGS_FOR_BUILD="$XBPS_CPPFLAGS" @@ -536,6 +537,7 @@ setup_pkg() { export OBJCOPY="${XBPS_CROSS_TRIPLET}-objcopy" export NM="${XBPS_CROSS_TRIPLET}-nm" export READELF="${XBPS_CROSS_TRIPLET}-readelf" + export PKG_CONFIG="${XBPS_CROSS_TRIPLET}-pkg-config" # Target tools export CC_target="$CC" export CXX_target="$CXX"