-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
44 lines (30 loc) · 1.16 KB
/
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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
BIN=switch
CCFLAGS=-g -Wall -pedantic -lpcap -lpthread -lnet
CC=g++
all: $(BIN)
$(BIN): macaddress.o frame.o iface.o ifaces.o camtablerecord.o runswitch.o switch.o camtable.o
${CC} -o $(BIN) macaddress.o frame.o iface.o ifaces.o camtablerecord.o camtable.o switch.o runswitch.o ${CCFLAGS}
runswitch.o: RunSwitch.cpp Switch.cpp Ifaces.cpp
${CC} -c RunSwitch.cpp -o runswitch.o ${CCFLAGS}
switch.o: Switch.cpp Switch.hpp
${CC} -c Switch.cpp -o switch.o ${CCFLAGS}
camtable.o: CamTable.hpp CamTable.cpp
${CC} -c CamTable.cpp -o camtable.o ${CCFLAGS}
camtablerecord.o: CamTableRecord.cpp CamTableRecord.hpp
${CC} -c CamTableRecord.cpp -o camtablerecord.o ${CCFLAGS}
iface.o: Iface.cpp Iface.hpp
${CC} -c Iface.cpp -o iface.o ${CCFLAGS}
ifaces.o: Ifaces.cpp Ifaces.hpp
${CC} -c Ifaces.cpp -o ifaces.o ${CCFLAGS}
frame.o: Frame.cpp Frame.hpp
${CC} -c Frame.cpp -o frame.o ${CCFLAGS}
macaddress.o: MacAddress.cpp MacAddress.hpp
${CC} -c MacAddress.cpp -o macaddress.o ${CCFLAGS}
pack:
tar -czf xpalam00 *.cpp *.hpp Makefile readme.txt
unpack:
tar -xf xpalam00
load:
scp xpalam00 [email protected]:/home/milan/switch/xpalam00
clean:
rm -f *.o *~ ${BIN} *.output