2016-11-03 21:49:37 +00:00
|
|
|
DESTDIR =
|
|
|
|
PREFIX = /usr/local
|
|
|
|
BINDIR = $(PREFIX)/bin
|
|
|
|
|
|
|
|
CC = gcc
|
|
|
|
LD = $(CC)
|
|
|
|
|
|
|
|
CFLAGS = -g -O2 -Wall -Werror -pthread
|
2017-11-10 10:02:23 +00:00
|
|
|
INCS += -I../../ebtree -I./include
|
2017-11-30 09:11:36 +00:00
|
|
|
LIBS = -lpthread -levent -levent_pthreads
|
2016-11-03 21:49:37 +00:00
|
|
|
|
|
|
|
OBJS = spoa.o
|
|
|
|
|
|
|
|
|
|
|
|
spoa: $(OBJS)
|
2017-11-30 09:11:36 +00:00
|
|
|
$(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
|
2016-11-03 21:49:37 +00:00
|
|
|
|
|
|
|
install: spoa
|
|
|
|
install spoa $(DESTDIR)$(BINDIR)
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f spoa $(OBJS)
|
|
|
|
|
|
|
|
%.o: %.c
|
2016-12-21 07:58:16 +00:00
|
|
|
$(CC) $(CFLAGS) $(INCS) -c -o $@ $<
|