copy contents of toolchain.mk instead of including them - fixes #287

Sun, 03 Sep 2023 12:36:53 +0200

author
Mike Becker <universe@uap-core.de>
date
Sun, 03 Sep 2023 12:36:53 +0200
changeset 36
9e386a530bdf
parent 35
57ea620a54ac
child 37
ef09f80e911e

copy contents of toolchain.mk instead of including them - fixes #287

test/make/toolchain.sh file | annotate | diff | comparison | revisions
--- a/test/make/toolchain.sh	Sun Sep 03 12:24:39 2023 +0200
+++ b/test/make/toolchain.sh	Sun Sep 03 12:36:53 2023 +0200
@@ -191,9 +191,8 @@
 	echo "LD = ${TOOLCHAIN_LD}" >> "$TEMP_DIR/config.mk"
 	echo >> "$TEMP_DIR/config.mk"
 	
-	cat "make/${TOOLCHAIN_NAME}.mk" > /dev/null 2>&1
-	if [ $? -eq 0 ]; then 
-		echo "include \$(BUILD_ROOT)/make/${TOOLCHAIN_NAME}.mk" >> "$TEMP_DIR/config.mk"
+	if [ -f "make/${TOOLCHAIN_NAME}.mk" ]; then
+		cat "make/${TOOLCHAIN_NAME}.mk" >> "$TEMP_DIR/config.mk"
 	else
 		echo "SHLIB_CFLAGS = -fPIC" >> "$TEMP_DIR/config.mk"
 		echo "SHLIB_LDFLAGS = -shared" >> "$TEMP_DIR/config.mk"

mercurial