summaryrefslogtreecommitdiffhomepage
path: root/compile
diff options
context:
space:
mode:
authorMichael Smith <mikesmiffy128@gmail.com>2022-06-02 01:26:45 +0100
committerMichael Smith <mikesmiffy128@gmail.com>2022-06-02 01:30:26 +0100
commit3ebe43eb75806990a402aafd5858de615d5c1cca (patch)
tree16edcb4b560520ad5225673e1a8ad45facc20c40 /compile
parent74563bfb8c506150172b9bbf73d828372add3394 (diff)
Solve the error logging situation
Diffstat (limited to 'compile')
-rwxr-xr-xcompile8
1 files changed, 6 insertions, 2 deletions
diff --git a/compile b/compile
index d921b78..6948527 100755
--- a/compile
+++ b/compile
@@ -28,9 +28,12 @@ fi
objs=
cc() {
objs="$objs .build/${1%%.c}.o"
+ _mn=" -DMODULE_NAME=${1%%.c}"
+ # ugly annoying special case
+ if [ "$_mn" = " -DMODULE_NAME=con_" ]; then _mn=" -DMODULE_NAME=con"
+ elif [ "$_mn" = "-DMODULE_NAME=sst" ]; then _mn=; fi
$CC -m32 -c -flto -fpic $cflags $warnings -I.build/include \
- -D_FILE_OFFSET_BITS=64 -DFILE_BASENAME="${1%%.c}" \
- -o ".build/${1%%.c}.o" "src/$1"
+ -D_FILE_OFFSET_BITS=64$_mn -o ".build/${1%%.c}.o" "src/$1"
}
ld() {
@@ -44,6 +47,7 @@ src="\
demorec.c
engineapi.c
ent.c
+ errmsg.c
extmalloc.c
fixes.c
fov.c