git: 830ec3717024 - main - Mk/Scripts/do-depends.sh: Avoid make -D flag
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 06 Mar 2024 20:25:15 UTC
The branch main has been updated by tijl:
URL: https://cgit.FreeBSD.org/ports/commit/?id=830ec3717024e0060b2b48db4319a4eb060f8023
commit 830ec3717024e0060b2b48db4319a4eb060f8023
Author: Tijl Coosemans <tijl@FreeBSD.org>
AuthorDate: 2024-03-06 19:13:39 +0000
Commit: Tijl Coosemans <tijl@FreeBSD.org>
CommitDate: 2024-03-06 20:22:21 +0000
Mk/Scripts/do-depends.sh: Avoid make -D flag
Both FreeBSD make and GNU make pass command line flags to sub-makes
through the MAKEFLAGS environment variable, but the flags aren't
compatible and GNU make 4.4 exits with an error when it encounters
flags it doesn't understand, e.g. -D.
Avoid using the flag for now until ports run gmake with SETENVI.
This fixes the case where a port is built using make directly and it
recurses to build a dependency that uses gmake. Poudriere does not
use this feature of the ports tree to build dependencies so it's not
affected.
PR: 272216, 277492
---
Mk/Scripts/do-depends.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Mk/Scripts/do-depends.sh b/Mk/Scripts/do-depends.sh
index 238a8f221b18..c01bd8c16965 100644
--- a/Mk/Scripts/do-depends.sh
+++ b/Mk/Scripts/do-depends.sh
@@ -24,7 +24,7 @@ install_depends()
subpkg=$3
depends_args=$4
if [ -z "${dp_USE_PACKAGE_DEPENDS}" -a -z "${dp_USE_PACKAGE_DEPENDS_ONLY}" ]; then
- MAKEFLAGS="${dp_MAKEFLAGS}" ${dp_MAKE} -C ${origin} -DINSTALLS_DEPENDS ${target} ${depends_args}
+ INSTALLS_DEPENDS=1 MAKEFLAGS="${dp_MAKEFLAGS}" ${dp_MAKE} -C ${origin} ${target} ${depends_args}
return 0
fi
@@ -53,7 +53,7 @@ install_depends()
echo "===> USE_PACKAGE_DEPENDS_ONLY set - not building missing dependency from source" >&2
exit 1
else
- MAKEFLAGS="${dp_MAKEFLAGS}" ${dp_MAKE} -C ${origin} -DINSTALLS_DEPENDS ${target} ${depends_args}
+ INSTALLS_DEPENDS=1 MAKEFLAGS="${dp_MAKEFLAGS}" ${dp_MAKE} -C ${origin} ${target} ${depends_args}
fi
}