diff options
| author | lijia <[email protected]> | 2018-10-24 09:36:45 +0800 |
|---|---|---|
| committer | lijia <[email protected]> | 2018-10-24 09:36:45 +0800 |
| commit | 86a43b4d325ddc850fa9dc4711670880f35b11e8 (patch) | |
| tree | 8356a056ac9bfb8cf14fcf57f113dd306b4277d1 /src/packet_io/Makefile | |
create new project.
Diffstat (limited to 'src/packet_io/Makefile')
| -rw-r--r-- | src/packet_io/Makefile | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/src/packet_io/Makefile b/src/packet_io/Makefile new file mode 100644 index 0000000..5a2d790 --- /dev/null +++ b/src/packet_io/Makefile @@ -0,0 +1,34 @@ +#CC=gcc +CC=g++ +CCC=g++ + +TARGET=flwd_io_pcap.so flwd_io_socket.so flwd_packet_io.o + +CFLAGS +=-g -Wall -fPIC -D_GNU_SOURCE=1 -D_BSD_SOURCE=1 -D__USE_MISC=1 -D__FAVOR_BSD=1 -D__USE_BSD=1 + +H_DIR=-I../../inc +H_DIR+=-I/opt/MESA/include +H_DIR+=-I/opt/MESA/include/MESA + +LIBPATH= ../../bin/ip_reuse_io_lib/ +LIB=-L/opt/MESA/lib -lpthread + + +all:$(TARGET) + +.c.o: + $(CC) -c $(CFLAGS) -I. $(H_DIR) $< + +.cpp.o: + $(CCC) -c $(CFLAGS) -I. $(H_DIR) $< + +flwd_io_pcap.so:flwd_packet_io_pcap.o + $(CCC) -o $@ -shared -g -Wall $(CFLAGS) $(H_DIR) $^ -lpcap + cp $@ $(LIBPATH) + +flwd_io_socket.so:flwd_packet_io_socket.o + $(CCC) -o $@ -shared -g -Wall $(CFLAGS) $(H_DIR) $^ + cp $@ $(LIBPATH) + +clean: + rm -f *.o |
