]>
Commit | Line | Data |
---|---|---|
70df8302 MT |
1 | ############################################################################### |
2 | # # | |
3 | # IPFire.org - A linux based firewall # | |
4 | # Copyright (C) 2007 Michael Tremer & Christian Schmidt # | |
5 | # # | |
6 | # This program is free software: you can redistribute it and/or modify # | |
7 | # it under the terms of the GNU General Public License as published by # | |
8 | # the Free Software Foundation, either version 3 of the License, or # | |
9 | # (at your option) any later version. # | |
10 | # # | |
11 | # This program is distributed in the hope that it will be useful, # | |
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of # | |
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # | |
14 | # GNU General Public License for more details. # | |
15 | # # | |
16 | # You should have received a copy of the GNU General Public License # | |
17 | # along with this program. If not, see <http://www.gnu.org/licenses/>. # | |
18 | # # | |
19 | ############################################################################### | |
20 | ||
cd1a2927 MT |
21 | CC=gcc |
22 | CFLAGS=-O2 -Wall | |
23 | ||
24 | COMPILE=$(CC) $(CFLAGS) | |
25 | ||
26 | PROGS = iowrap | |
903310c4 | 27 | SUID_PROGS = setdmzholes setportfw setxtaccess \ |
900832fa | 28 | squidctrl sshctrl ipfirereboot \ |
3ef6c343 | 29 | ipsecctrl timectrl dhcpctrl snortctrl \ |
98bdae8a | 30 | applejuicectrl rebuildhosts backupctrl \ |
61e3d218 | 31 | logwatch openvpnctrl outgoingfwctrl \ |
cacc8360 | 32 | wirelessctrl getipstat qosctrl launch-ether-wake \ |
900832fa | 33 | redctrl syslogdctrl extrahdctrl sambactrl upnpctrl tripwirectrl \ |
69fe68ee | 34 | smartctrl clamavctrl addonctrl pakfire mpfirectrl wlanapctrl \ |
75bc929e | 35 | setaliases urlfilterctrl updxlratorctrl fireinfoctrl rebuildroutes \ |
27cb7805 | 36 | getconntracktable wirelessclient dnsmasqctrl torctrl |
61027579 | 37 | SUID_UPDX = updxsetperms |
cd1a2927 MT |
38 | |
39 | install : all | |
40 | install -m 755 $(PROGS) /usr/local/bin | |
41 | install -m 4750 -g nobody $(SUID_PROGS) /usr/local/bin | |
42 | ||
a19f3396 | 43 | all : $(PROGS) $(SUID_PROGS) |
cd1a2927 MT |
44 | |
45 | clean : | |
a19f3396 | 46 | -rm -f $(PROGS) $(SUID_PROGS) *.o core |
cd1a2927 MT |
47 | |
48 | ###### | |
49 | ||
50 | % : %.c | |
51 | $(COMPILE) $< setuid.o -o $@ | |
52 | ||
53 | setuid.o: setuid.c setuid.h | |
54 | $(COMPILE) $< -c -o $@ | |
55 | ||
56 | $(SUID_PROGS): setuid.o | |
57 | ||
58 | $(PROGS): setuid.o | |
59 | ||
60 | logwatch: logwatch.c setuid.o ../install+setup/libsmooth/varval.o | |
61 | $(COMPILE) -I../install+setup/libsmooth/ logwatch.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
62 | ||
6e13d0a5 MT |
63 | openvpnctrl: openvpnctrl.c setuid.o ../install+setup/libsmooth/varval.o |
64 | $(COMPILE) -I../install+setup/libsmooth/ openvpnctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
65 | ||
b684b13b MT |
66 | qosctrl: qosctrl.c setuid.o ../install+setup/libsmooth/varval.o |
67 | $(COMPILE) -I../install+setup/libsmooth/ qosctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
d95bfe98 MT |
68 | |
69 | redctrl: redctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
70 | $(COMPILE) -I../install+setup/libsmooth/ redctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
aa2870e6 MT |
71 | |
72 | extrahdctrl: extrahdctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
73 | $(COMPILE) -I../install+setup/libsmooth/ extrahdctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
5fd30232 MT |
74 | |
75 | upnpctrl: upnpctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
76 | $(COMPILE) -I../install+setup/libsmooth/ upnpctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
14cc7eac MT |
77 | |
78 | sambactrl: sambactrl.c setuid.o ../install+setup/libsmooth/varval.o | |
79 | $(COMPILE) -I../install+setup/libsmooth/ sambactrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
b684b13b | 80 | |
1cdddb12 MT |
81 | tripwirectrl: tripwirectrl.c setuid.o ../install+setup/libsmooth/varval.o |
82 | $(COMPILE) -I../install+setup/libsmooth/ tripwirectrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
40b0879d MT |
83 | |
84 | smartctrl: smartctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
85 | $(COMPILE) -I../install+setup/libsmooth/ smartctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
d81292e0 | 86 | |
f7ff12a3 MT |
87 | clamavctrl: clamavctrl.c setuid.o ../install+setup/libsmooth/varval.o |
88 | $(COMPILE) -I../install+setup/libsmooth/ clamavctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
53562849 | 89 | |
b4f8d26c MT |
90 | outgoingfwctrl: outgoingfwctrl.c setuid.o ../install+setup/libsmooth/varval.o |
91 | $(COMPILE) -I../install+setup/libsmooth/ outgoingfwctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
92 | ||
53562849 MT |
93 | timectrl: timectrl.c setuid.o ../install+setup/libsmooth/varval.o |
94 | $(COMPILE) -I../install+setup/libsmooth/ timectrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
f7ff12a3 | 95 | |
4e565351 MT |
96 | launch-ether-wake: launch-ether-wake.c setuid.o ../install+setup/libsmooth/varval.o |
97 | $(COMPILE) -I../install+setup/libsmooth/ launch-ether-wake.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
98 | ||
cd1a2927 MT |
99 | setdmzholes: setdmzholes.c setuid.o ../install+setup/libsmooth/varval.o |
100 | $(COMPILE) -I../install+setup/libsmooth/ setdmzholes.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
101 | ||
102 | setportfw: setportfw.c setuid.o ../install+setup/libsmooth/varval.o | |
103 | $(COMPILE) -I../install+setup/libsmooth/ setportfw.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
104 | ||
cd1a2927 MT |
105 | rebuildhosts: rebuildhosts.c setuid.o ../install+setup/libsmooth/varval.o |
106 | $(COMPILE) -I../install+setup/libsmooth/ rebuildhosts.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
107 | ||
99e6df8e MT |
108 | applejuicectrl: applejuicectrl.c setuid.o ../install+setup/libsmooth/varval.o |
109 | $(COMPILE) -I../install+setup/libsmooth/ applejuicectrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
a79906a4 | 110 | |
6bdd769d MT |
111 | dhcpctrl: dhcpctrl.c setuid.o ../install+setup/libsmooth/varval.o |
112 | $(COMPILE) -I../install+setup/libsmooth/ dhcpctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
cd1a2927 | 113 | |
900832fa CS |
114 | sshctrl: sshctrl.c setuid.o ../install+setup/libsmooth/varval.o |
115 | $(COMPILE) -I../install+setup/libsmooth/ sshctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
cd1a2927 | 116 | |
d56fc335 MT |
117 | squidctrl: squidctrl.c setuid.o ../install+setup/libsmooth/varval.o |
118 | $(COMPILE) -I../install+setup/libsmooth/ squidctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
cd1a2927 | 119 | |
3ef6c343 MT |
120 | snortctrl: snortctrl.c setuid.o ../install+setup/libsmooth/varval.o |
121 | $(COMPILE) -I../install+setup/libsmooth/ snortctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
cd1a2927 | 122 | |
900832fa CS |
123 | wirelessctrl: wirelessctrl.c setuid.o ../install+setup/libsmooth/varval.o |
124 | $(COMPILE) -I../install+setup/libsmooth/ wirelessctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
cd1a2927 MT |
125 | |
126 | ipsecctrl: ipsecctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
127 | $(COMPILE) -I../install+setup/libsmooth/ ipsecctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
128 | ||
a68fedca MT |
129 | getipstat: getipstat.c setuid.o ../install+setup/libsmooth/varval.o |
130 | $(COMPILE) -I../install+setup/libsmooth/ getipstat.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
3b1471da MT |
131 | |
132 | pakfire: pakfire.c setuid.o ../install+setup/libsmooth/varval.o | |
133 | $(COMPILE) -I../install+setup/libsmooth/ pakfire.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
51f3b7f5 MT |
134 | |
135 | mpfirectrl: mpfirectrl.c setuid.o ../install+setup/libsmooth/varval.o | |
136 | $(COMPILE) -I../install+setup/libsmooth/ mpfirectrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
8e8bbd9d CS |
137 | |
138 | backupctrl: backupctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
139 | $(COMPILE) -I../install+setup/libsmooth/ backupctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
5b3962de | 140 | |
33cb80ed AF |
141 | addonctrl: addonctrl.c setuid.o ../install+setup/libsmooth/varval.o |
142 | $(COMPILE) -I../install+setup/libsmooth/ addonctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
143 | ||
900832fa CS |
144 | syslogdctrl: syslogdctrl.c setuid.o ../install+setup/libsmooth/varval.o |
145 | $(COMPILE) -I../install+setup/libsmooth/ syslogdctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
819aa2b5 | 146 | |
8215834f | 147 | wlanapctrl: wlanapctrl.c setuid.o ../install+setup/libsmooth/varval.o |
819aa2b5 | 148 | $(COMPILE) -I../install+setup/libsmooth/ wlanapctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ |
69fe68ee PP |
149 | |
150 | setaliases: setaliases.c setuid.o ../install+setup/libsmooth/varval.o | |
151 | $(COMPILE) -I../install+setup/libsmooth/ setaliases.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
152 | ||
aebf1b54 MT |
153 | fireinfoctrl: fireinfoctrl.c setuid.o ../install+setup/libsmooth/varval.o |
154 | $(COMPILE) -I../install+setup/libsmooth/ fireinfoctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
155 | ||
daf96690 MT |
156 | rebuildroutes: rebuildroutes.c setuid.o ../install+setup/libsmooth/varval.o |
157 | $(COMPILE) -I../install+setup/libsmooth/ rebuildroutes.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
75bc929e MT |
158 | |
159 | getconntracktable: getconntracktable.c setuid.o ../install+setup/libsmooth/varval.o | |
160 | $(COMPILE) -I../install+setup/libsmooth/ getconntracktable.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
61027579 MT |
161 | |
162 | wirelessclient: wirelessclient.c setuid.o ../install+setup/libsmooth/varval.o | |
163 | $(COMPILE) -I../install+setup/libsmooth/ wirelessclient.c setuid.o ../install+setup/libsmooth/varval.o -o $@ | |
e4ba53ed SS |
164 | |
165 | dnsmasqctrl: dnsmasqctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
8245f77e | 166 | $(COMPILE) -I../install+setup/libsmooth/ dnsmasqctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ |
27cb7805 MT |
167 | |
168 | torctrl: toctrl.c setuid.o ../install+setup/libsmooth/varval.o | |
169 | $(COMPILE) -I../install+setup/libsmooth/ torctrl.c setuid.o ../install+setup/libsmooth/varval.o -o $@ |