Alex 'AdUser' Z
10 years ago
1 changed files with 12 additions and 6 deletions
@ -1,15 +1,21 @@ |
|||||||
CFLAGS=-Wall -Wextra -O0 -g -ggdb -std=c99 -pedantic
|
CFLAGS=-Wall -Wextra -O0 -g -std=c99 -pedantic -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
|
||||||
|
CPPFLAGS=-D_FORTIFY_SOURCE=2
|
||||||
|
LDFLAGS=-shared -fPIC -Wl,-z,relro -L.
|
||||||
|
|
||||||
all: util |
all: lib util |
||||||
|
|
||||||
%.o: %.c |
%.o: %.c |
||||||
gcc $(CFLAGS) -c $<
|
gcc $(CFLAGS) $(CPPFLAGS) -c $<
|
||||||
|
|
||||||
util: util.c database.o bitmap.o |
lib: database.o bitmap.o |
||||||
gcc $(CFLAGS) -o $@ $^
|
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -Wl,-soname,libimgdup.so.1 -o libimgdup.so $^
|
||||||
gcc $(CFLAGS) -static -o $@-static $^
|
|
||||||
|
util: util.c |
||||||
|
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -limgdup -o $@ $^
|
||||||
|
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -limgdup -static -o $@-static $^
|
||||||
|
|
||||||
clean: |
clean: |
||||||
rm -f *.o
|
rm -f *.o
|
||||||
rm -f util
|
rm -f util
|
||||||
rm -f util-static
|
rm -f util-static
|
||||||
|
rm -f libimgdup*
|
||||||
|
Loading…
Reference in new issue