diff --git a/bench/Makefile b/bench/Makefile index 93a9267..9d7dc66 100644 --- a/bench/Makefile +++ b/bench/Makefile @@ -2,7 +2,8 @@ SRC = $(wildcard ../*.c) ../fuzzer/datagen.c bench.c OBJ = $(SRC:.c=.o) DEP = $(OBJ:.o=.d) -CFLAGS:=-Wall -O2 -pthread +# Use -fPIC for obj compatibility with shared lib build +CFLAGS:=-Wall -O2 -pthread -fPIC CC:=gcc ASFLAGS:= diff --git a/fuzzer/Makefile b/fuzzer/Makefile index c661492..e72e635 100644 --- a/fuzzer/Makefile +++ b/fuzzer/Makefile @@ -2,7 +2,8 @@ SRC = $(wildcard ../*.c) datagen.c fuzzer.c OBJ = $(SRC:.c=.o) DEP = $(OBJ:.o=.d) -CFLAGS:=-Wall -O2 -pthread +# Use -fPIC for obj compatibility with shared lib build +CFLAGS:=-Wall -O2 -pthread -fPIC CC:=gcc ASFLAGS:=