Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
bench
test-bin
xcuserdata
*.xccheckout
Expand Down
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

CC?=gcc
PROVE?=prove
CFLAGS=-Wall -fsanitize=address,undefined
TEST_CFLAGS=$(CFLAGS) -Wall -fsanitize=address,undefined
TEST_ENV="UBSAN_OPTIONS=print_stacktrace=1:halt_on_error=1"

all:
Expand All @@ -34,9 +34,11 @@ test: test-bin
env $(TEST_ENV) $(PROVE) -v ./test-bin

test-bin: picohttpparser.c picotest/picotest.c test.c
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
$(CC) $(TEST_CFLAGS) $(LDFLAGS) -o $@ $^

bench: bench.c picohttpparser.c

clean:
rm -f test-bin
rm -f bench test-bin

.PHONY: test
.PHONY: all clean test