blob: 8328469380738e3ae5637d6988ce7bfd47a6d0a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
ifeq ($(PREFIX),)
PREFIX := /usr/local
endif
ifeq ($(BINDIR),)
BINDIR := /bin
endif
CMD=qidx
CC=gcc
DEBUG := -fsanitize=address -O2
CFLAGS := -Wall -pedantic -g
LDFLAGS := -lhts -lm
SRC_EXT:=%.c
_STD_BUILD=$(CC) $(CFLAGS) $(filter $(SRC_EXT) %.o, $^) -o $@
STD_BUILD=$(_STD_BUILD) $(LDFLAGS)
STD_COMPILE=$(_STD_BUILD) -c
OBJS = ./util/hash.o
OBJS += ./util/prime_search.o
OBJS += ./util/prime_search.o
OBJS += ./util/sds/sds.o
OBJS += ./util/err.o
OBJS += ./qidx.o
make: $(CMD)
$(CMD): ./main.c $(OBJS)
$(STD_BUILD)
clean:
$(RM) $(CMD) $(OBJS)
%.o: %.c
$(STD_COMPILE)
|