From d127146846f4d6561e15000d1469b715dafdb627 Mon Sep 17 00:00:00 2001 From: Kimplul Date: Sat, 2 Nov 2024 15:28:23 +0200 Subject: initial exec support --- tests/scripts/gen-prog | 32 -------------------------------- 1 file changed, 32 deletions(-) delete mode 100755 tests/scripts/gen-prog (limited to 'tests/scripts/gen-prog') diff --git a/tests/scripts/gen-prog b/tests/scripts/gen-prog deleted file mode 100755 index 6e99f37..0000000 --- a/tests/scripts/gen-prog +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -NAME= -PROG= -while getopts "n:p:" opt; do - case "$opt" in - n) NAME="$OPTARG";; - p) PROG="$OPTARG";; - *) echo "unrecognised options -$OPTARG" >&2; exit 1; - esac -done - -shift $((OPTIND - 1)) - -# create all subdirectories -mkdir -p $(echo "${@}" | tr ' ' '\n' | sed "s|[^/]*$||;s|^|build/$NAME|" | uniq) - -for s in ${@} -do - obj="build/${NAME}/${s%.*}.o" - dep="${obj}.d" - - echo "${NAME}_OBJS += ${obj}" >> tests.mk - echo "${dep}:" >> tests.mk - echo "-include ${dep}" >> tests.mk - echo "${obj}: $NAME/${s} \$(COMMON)" >> tests.mk - echo " \$(COMPILE_TEST) -c $NAME/${s} -o ${obj}" >> tests.mk -done - -echo "build/${NAME}/$PROG: \$(${NAME}_OBJS) \$(COMMON)" >> tests.mk -echo " \$(COMPILE_TEST) \$(${NAME}_OBJS) \$(COMMON) \ - -o build/${NAME}/$PROG" >> tests.mk -- cgit v1.3