mirror of https://github.com/Chizi123/dnscomp.git

Joel Grunbaum
2022-06-01 96cf02139c7a0a344f194c95c8d3a64168e45c6b
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
CC=gcc
_OBJ=dns.o slist.o
_DEPS=dns.h servers.h slist.h
CFLAGS=-Wall -lpthread
 
ifeq ($(DEV),1)
    CFLAGS += -g
else
    #CFLAGS += -O2 -flto
endif
 
default: dnscomp
 
%.o: %c $(DEPS)
    $(CC) -c -o $@ $< $(CFLAGS)
 
dnscomp: $(_OBJ) main.o
    $(CC) -o $@ $^ $(CFLAGS)
 
test: $(_OBJ) test.o
    $(CC) -o $@ $^ $(CFLAGS)
 
.PHONY: clean
clean:
    rm -rf *.o *~