Process LQ_TC messages. Made link quality features configurable. Set
[olsrd.git] / Makefile.win32.in
1 VERS =          0.4.8
2
3 MAINOBJS =      src/build_msg.o \
4                 src/duplicate_set.o \
5                 src/generate_msg.o \
6                 src/hashing.o \
7                 src/hna_set.o \
8                 src/hysteresis.o \
9                 src/interfaces.o \
10                 src/ipc_frontend.o \
11                 src/link_set.o \
12                 src/local_hna_set.o \
13                 src/main.o \
14                 src/mantissa.o \
15                 src/mid_set.o \
16                 src/mpr.o \
17                 src/mpr_selector_set.o \
18                 src/neighbor_table.o \
19                 src/net.o \
20                 src/olsr.o \
21                 src/packet.o \
22                 src/parser.o \
23                 src/plugin.o \
24                 src/plugin_loader.o \
25                 src/process_package.o \
26                 src/process_routes.o \
27                 src/rebuild_packet.o \
28                 src/routing_table.o \
29                 src/scheduler.o \
30                 src/socket_parser.o \
31                 src/tc_set.o \
32                 src/two_hop_neighbor_table.o \
33                 src/cfgparser/oparse.o \
34                 src/cfgparser/oscan.o \
35                 src/cfgparser/olsrd_conf.o \
36                 src/lq_packet.o \
37                 src/win32/apm.o \
38                 src/win32/compat.o \
39                 src/win32/ifnet.o \
40                 src/win32/kernel_routes.o \
41                 src/win32/log.o \
42                 src/win32/net.o \
43                 src/win32/tunnel.o
44
45 CONFDLLOBJS =   src/win32/olsrconf.def \
46                 src/cfgparser/oparse.o \
47                 src/cfgparser/oscan.o \
48                 src/cfgparser/confdll-olsrd_conf.o \
49                 src/win32/compat.o
50
51 CONFEXEOBJS =   src/cfgparser/oparse.o \
52                 src/cfgparser/oscan.o \
53                 src/cfgparser/confexe-olsrd_conf.o \
54                 src/win32/compat.o
55
56 all:            olsrd.exe olsrconf.dll olsrconf.exe
57
58 src/cfgparser/oscan.c:  src/cfgparser/oscan.lex \
59                 src/cfgparser/oparse.h src/cfgparser/olsrd_conf.h
60                 flex -osrc/cfgparser/oscan.c src/cfgparser/oscan.lex
61
62 src/cfgparser/oparse.c: src/cfgparser/oparse.y src/cfgparser/olsrd_conf.h
63                 bison -d -osrc/cfgparser/oparse.c src/cfgparser/oparse.y
64
65 %.o:            %.c
66                 gcc -mno-cygwin -O2 -Wall -c -DWIN32 \
67                 -Isrc -Isrc/win32 -o$@ $<
68
69 confdll-%.o:    %.c
70                 gcc -mno-cygwin -O2 -Wall -c -DWIN32 -DMAKELIB \
71                 -Isrc -Isrc/win32 -o$@ $<
72
73 confexe-%.o:    %.c
74                 gcc -mno-cygwin -O2 -Wall -c -DWIN32 -DMAKEBIN \
75                 -Isrc -Isrc/win32 -o$@ $<
76
77 olsrd.exe:      $(MAINOBJS)
78                 gcc -mno-cygwin -o olsrd.exe $(MAINOBJS) -lws2_32 -liphlpapi
79
80 olsrconf.dll:   $(CONFDLLOBJS)
81                 gcc -mno-cygwin -shared -o olsrconf.dll $(CONFDLLOBJS) \
82                 -lws2_32 -Wl,--out-implib,olsrconf.lib
83
84 olsrconf.exe:   $(CONFEXEOBJS)
85                 gcc -mno-cygwin -o olsrconf.exe $(CONFEXEOBJS) -lws2_32
86
87 clean:
88                 rm -f *.exe *.dll *.lib *.zip
89                 rm -f src/cfgparser/oparse.c src/cfgparser/oparse.h
90                 rm -f src/cfgparser/oscan.c
91                 find . -name \*~ -exec rm -f {} \;
92                 find src -name \*.o -exec rm -f {} \;
93
94 mclean:         clean
95                 rm -f Makefile.win32
96
97 olsr-${VERS}.zip:       gui/win32/Main/Release/Switch.exe \
98                 gui/win32/Shim/Release/Shim.exe \
99                 olsrd.exe \
100                 README-WIN32.txt \
101                 gui/win32/Inst/linux-manual.txt \
102                 files/olsrd.conf.default.win32 \
103                 lib/dot_draw/olsrd_dot_draw.dll
104                 rm -rf ${TEMP}/olsr-${VERS}
105                 rm -f ${TEMP}/olsr-${VERS}.zip
106                 rm -f olsr-${VERS}.zip
107                 mkdir ${TEMP}/olsr-${VERS}
108                 cp gui/win32/Main/Release/Switch.exe ${TEMP}/olsr-${VERS}
109                 cp gui/win32/Shim/Release/Shim.exe ${TEMP}/olsr-${VERS}
110                 cp olsrd.exe ${TEMP}/olsr-${VERS}
111                 cp README-WIN32.txt ${TEMP}/olsr-${VERS}
112                 cp gui/win32/Inst/linux-manual.txt ${TEMP}/olsr-${VERS}
113                 cp files/olsrd.conf.default.win32 ${TEMP}/olsr-${VERS}/Default.olsr
114                 cp lib/dot_draw/olsrd_dot_draw.dll ${TEMP}/olsr-${VERS}
115                 cd ${TEMP}; echo y | cacls olsr-${VERS} /T /G Everyone:F
116                 cd ${TEMP}; zip -q -r olsr-${VERS}.zip olsr-${VERS}
117                 cp ${TEMP}/olsr-${VERS}.zip .
118                 rm -rf ${TEMP}olsr-${VERS}
119                 rm -f ${TEMP}/olsr-${VERS}.zip
120
121 olsr-${VERS}-setup.exe: gui/win32/Main/Release/Switch.exe \
122                 gui/win32/Shim/Release/Shim.exe \
123                 olsrd.exe \
124                 README-WIN32.txt \
125                 gui/win32/Inst/linux-manual.txt \
126                 files/olsrd.conf.default.win32 \
127                 lib/dot_draw/olsrd_dot_draw.dll \
128                 gui/win32/Inst/installer.nsi
129                 rm -f olsr-setup.exe
130                 rm -f olsr-${VERS}-setup.exe
131                 C:/Program\ Files/NSIS/makensis gui\win32\Inst\installer.nsi
132                 mv olsr-setup.exe olsr-${VERS}-setup.exe
133