forked from br101/horst
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
79 lines (70 loc) · 2.57 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# horst - Highly Optimized Radio Scanning Tool
#
# Copyright (C) 2005-2011 Bruno Randolf (br1@einfach.org)
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
NAME=horst
DEBUG=0
PCAP=0
OBJS=main.o capture$(if $(filter 1,$(PCAP)),-pcap).o protocol_parser.o \
network.o wext.o node.o essid.o channel.o \
util.o ieee80211_util.o listsort.o average.o \
display.o display-main.o display-filter.o display-help.o \
display-statistics.o display-essid.o display-history.o \
display-spectrum.o display-channel.o control.o
LIBS=-lncurses -lm
CFLAGS+=-Wall -DDO_DEBUG=$(DEBUG) -g
ifeq ($(PCAP),1)
CFLAGS+=-DPCAP
LIBS+=-lpcap
endif
buildstamp=.build_debug$(DEBUG)pcap$(PCAP)
all: $(buildstamp) $(NAME)
# include dependencies
average.o: average.h util.h
capture.o: capture.h util.h
capture-pcap.o: capture.h util.h
channel.o: main.h util.h ieee80211_util.h wext.h
display.o: display.h main.h ieee80211.h
display-channel.o: display.h main.h
display-essid.o: display.h main.h util.h
display-filter.o: display.h main.h util.h ieee80211.h
display-help.o: display.h main.h util.h
display-history.o: display.h main.h util.h
display-main.o: display.h main.h util.h ieee80211.h olsr_header.h listsort.h
display-spectrum.o: display.h main.h util.h
display-statistics.o: display.h main.h util.h
essid.o: main.h util.h ieee80211.h
ieee80211_util.o: ieee80211.h ieee80211_radiotap.h ieee80211_util.h main.h \
util.h
listsort.o: list.h listsort.h
main.o: protocol_parser.h display.h network.h main.h capture.h util.h \
ieee80211.h ieee80211_util.h wext.h average.h
node.o: main.h ieee80211.h util.h
network.o: main.h util.h network.h
protocol_parser.o: prism_header.h ieee80211_radiotap.h ieee80211.h \
ieee80211_util.h olsr_header.h batman_header.h protocol_parser.h \
main.h util.h
util.o: util.h ieee80211.h
wext.o: wext.h util.h
$(NAME): $(OBJS)
$(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBS)
clean:
-rm -f *.o *~
-rm -f $(NAME)
-rm -f .build_*
$(buildstamp):
make clean
touch $@