Blob


1 SRCS = \
2 diff_atomize_text.c \
3 diff_main.c \
4 diff_myers.c \
5 diff_patience.c \
6 diff_output.c \
7 diff_output_plain.c \
8 diff_output_unidiff.c \
9 $(END)
11 # Compat sources
12 VPATH= $(CURDIR)/../compat
13 SRCS+= getprogname_linux.c reallocarray.c recallocarray.c
14 CFLAGS+= -I$(CURDIR)/../compat/include
16 OBJS = $(SRCS:.c=.o)
18 libdiff.a: $(OBJS)
19 ar rcs $@ $^
21 CFLAGS += -fsanitize=address -fsanitize=undefined -g -O3
22 CFLAGS += -Wstrict-prototypes -Wunused-variable
24 %.o: %.c ./*.h ../include/diff/*.h
25 gcc $(CFLAGS) -I../include -o $@ -c $<
27 .PHONY: clean
28 clean:
29 -rm $(OBJS)
30 -rm libdiff.a