You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
676 B

10 years ago
CFLAGS=-Wall -Wextra -O2 -g -std=c99 -pedantic -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
CPPFLAGS=-D_FORTIFY_SOURCE=2
10 years ago
LDFLAGS=-Wl,-soname,libimgdup.so.1 -fPIC
11 years ago
10 years ago
all: lib util imdb_1to2
11 years ago
%.o: %.c
10 years ago
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -c $<
11 years ago
lib: database.o bitmap.o
10 years ago
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -shared -o libimgdup.so $^
ar rcs libimgdup.a $^
util: util.c
10 years ago
gcc $(CFLAGS) $(CPPFLAGS) -L. $^ -limgdup -o $@
gcc $(CFLAGS) $(CPPFLAGS) -L. $^ libimgdup.a -o $@-static -static
11 years ago
10 years ago
imdb_1to2: imdb_1to2.c
gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ $^
11 years ago
clean:
rm -f *.o
10 years ago
rm -f imdb_*to*
rm -f util
10 years ago
rm -f util-static
rm -f libimgdup*