From ec223373c61e3c936f55dcdefcf04c30074aa234 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89rico=20Rolim?= Date: Fri, 18 Dec 2020 16:22:32 -0300 Subject: [PATCH] xbps-src: source cross profiles in show-var when using -a switch. This allows the user to query for variables such as XBPS_CROSS_TRIPLET, which are only available in a cross-build context. --- xbps-src | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/xbps-src b/xbps-src index 54016874010..83729a9c2c0 100755 --- a/xbps-src +++ b/xbps-src @@ -902,7 +902,11 @@ case "$XBPS_TARGET" in for f in ${XBPS_COMMONDIR}/environment/setup/*.sh; do source $f done - source ${XBPS_COMMONDIR}/build-profiles/${XBPS_MACHINE}.sh + if [ "$XBPS_CROSS_BUILD" ]; then + source ${XBPS_COMMONDIR}/cross-profiles/${XBPS_CROSS_BUILD}.sh + else + source ${XBPS_COMMONDIR}/build-profiles/${XBPS_MACHINE}.sh + fi eval value="\${$XBPS_TARGET_PKG}" echo $value ;;