aboutsummaryrefslogtreecommitdiff
path: root/build.sh
diff options
context:
space:
mode:
Diffstat (limited to 'build.sh')
-rwxr-xr-xbuild.sh10
1 files changed, 4 insertions, 6 deletions
diff --git a/build.sh b/build.sh
index 8fd07b8..8470eb6 100755
--- a/build.sh
+++ b/build.sh
@@ -10,8 +10,8 @@ if [ -z "$CC" ]; then
CC=cc
fi
-CFLAGS=""
-LIBS=""
+CFLAGS="-Wall -Wextra -Werror -Wno-format-security -Wnull-dereference -Wjump-misses-init -std=c89 -D_GNU_SOURCE "
+LIBS="-pthread "
if [ ! -z "$SANITIZE_ADDRESS" ]; then
CFLAGS+="-fsanitize=address "
@@ -24,8 +24,7 @@ if [ ! -z "$PEDANTIC" ]; then
fi
build_test() {
- CFLAGS+="-Wall -Wextra -Werror -Wno-format-security -g -O0 -DDEBUG -std=c89 -D_GNU_SOURCE"
- LIBS+="-pthread"
+ CFLAGS+="-g -O0 -DDEBUG"
BUILD_ARGS="$source_files $CFLAGS $LIBS -shared -fpic -o "$this_script_dir/libamalgam.so""
set -x
@@ -62,8 +61,7 @@ build_test() {
}
build_release() {
- CFLAGS+="-Wall -Wextra -Werror -Wno-format-security -O2 -DNDEBUG -std=c89 -D_GNU_SOURCE -s"
- LIBS+="-pthread"
+ CFLAGS+="-O2 -DNDEBUG -s"
BUILD_ARGS="$source_files $CFLAGS $LIBS -shared -fpic -o "$this_script_dir/libamalgam.so""
set -x