-
Notifications
You must be signed in to change notification settings - Fork 9
/
Makefile
24 lines (17 loc) · 826 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
LIBEVENT_HOME=/prod/pkgs/libevent-2.0.17
# Remove NDEBUG define to trigger asserts
CPPFLAGS+=-O2 -I. -DNDEBUG -Wall -Wno-sign-compare -Wno-unused -g -I${LIBEVENT_HOME}/include -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
LDFLAGS+=-levent -lstdc++
all: swift-dynamic
swift: swift.o sha1.o compat.o sendrecv.o send_control.o hashtree.o bin.o binmap.o channel.o transfer.o httpgw.o statsgw.o cmdgw.o avgspeed.o avail.o storage.o zerostate.o zerohashtree.o
#nat_test.o
swift-static: swift
g++ ${CPPFLAGS} -o swift *.o ${LDFLAGS} -static -lrt
strip swift
touch swift-static
swift-dynamic: swift
g++ ${CPPFLAGS} -o swift *.o ${LDFLAGS} -L${LIBEVENT_HOME}/lib -Wl,-rpath,${LIBEVENT_HOME}/lib
touch swift-dynamic
clean:
rm *.o swift swift-static swift-dynamic2>/dev/null
.PHONY: all clean swift swift-static swift-dynamic