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 diff_output_edscript.c \
10 $(END)
12 # Compat sources
13 VPATH= $(CURDIR)/../compat
14 SRCS+= getprogname_linux.c reallocarray.c recallocarray.c
15 CFLAGS+= -I$(CURDIR)/../compat/include
17 OBJS = $(SRCS:.c=.o)
19 libdiff.a: $(OBJS)
20 ar rcs $@ $^
22 CFLAGS += -fsanitize=address -fsanitize=undefined -g -O3
23 CFLAGS += -Wstrict-prototypes -Wunused-variable
25 %.o: %.c ./*.h ../include/*.h
26 gcc $(CFLAGS) -I../include -o $@ -c $<
28 .PHONY: clean
29 clean:
30 -rm $(OBJS)
31 -rm libdiff.a