diff options
author | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2022-10-31 17:13:46 -0500 |
---|---|---|
committer | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2022-10-31 17:13:46 -0500 |
commit | 628f816a236c0c3336e6e95ae237cf4953cc897e (patch) | |
tree | 20e7354817d35a3416eeb9fdce4b0fa4954634d2 /makefile | |
parent | 71528a24e09abf1e77a7756db38490d892b4603f (diff) | |
download | qidx-628f816a236c0c3336e6e95ae237cf4953cc897e.tar.xz qidx-628f816a236c0c3336e6e95ae237cf4953cc897e.zip |
add debug opts to makefile, fix munmap error
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -15,10 +15,16 @@ so_minor := 1 CC=gcc -CFLAGS = -Wall -pedantic $(debug) +CFLAGS = -Wall -pedantic $(debug) $(opt) LDFLAGS := -lhts -lm -fPIC -# debug = -fsanitize=address -O2 -g + +ifeq ($(DEBUG),"1") + debug = -fsanitize=address -g +else + opt = -O2 +endif + SRC_EXT:=%.c _STD_BUILD=$(CC) $(CFLAGS) $(filter $(SRC_EXT) %.o, $^) -o $@ |