diff options
| author | iamcheeseman <[email protected]> | 2026-04-06 17:04:05 -0400 |
|---|---|---|
| committer | iamcheeseman <[email protected]> | 2026-04-06 17:06:53 -0400 |
| commit | 957c64c7b8b5e98d8a03dd84c7e27e7991fb9dbc (patch) | |
| tree | f5fc230703791cee8d8e7851fb87eaef07ae63a2 /build.sh | |
Initial commit
Diffstat (limited to 'build.sh')
| -rwxr-xr-x | build.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..8b7908e --- /dev/null +++ b/build.sh @@ -0,0 +1,20 @@ +#! /bin/bash + +source build.env + +[[ "$1" == "debug" ]] && cflags+=" ${debug_cflags[@]}" +[[ "$1" == "relsym" ]] && cflags+=" -g" + +src=$(find . -name '*.c') + +echo "cc: $cc" +echo "cflags: ${cflags[@]}" +echo "ldflags: ${ldflags[@]}" +echo "out: $out" + +set -x + +# If the compilation time gets so long that incremental compilation is a +# necessity, the project is undeserving of the name "microengine". Hence why +# this project does not use Make or CMake. +$cc -o $out ${src[@]} ${cflags[@]} ${ldflags[@]} |
