forked from netblue30/firejail
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.in
317 lines (287 loc) · 15.5 KB
/
Makefile.in
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
all: apps firejail.1 firemon.1 firecfg.1 firejail-profile.5 firejail-login.5 firejail-config.5
MYLIBS = src/lib
APPS = src/firejail src/firemon src/firecfg src/libtrace src/libtracelog src/ftee
prefix=@prefix@
exec_prefix=@exec_prefix@
bindir=@bindir@
libdir=@libdir@
datarootdir=@datarootdir@
mandir=@mandir@
sysconfdir=@sysconfdir@
VERSION=@PACKAGE_VERSION@
NAME=@PACKAGE_NAME@
PACKAGE_TARNAME=@PACKAGE_TARNAME@
DOCDIR=@docdir@
.PHONY: mylibs $(MYLIBS)
mylibs: $(MYLIBS)
$(MYLIBS):
$(MAKE) -C $@
.PHONY: apps $(APPS)
apps: $(APPS)
$(APPS): $(MYLIBS)
$(MAKE) -C $@
firemon.1: src/man/firemon.txt
./mkman.sh $(VERSION) src/man/firemon.txt firemon.1
firejail.1: src/man/firejail.txt
./mkman.sh $(VERSION) src/man/firejail.txt firejail.1
firecfg.1: src/man/firecfg.txt
./mkman.sh $(VERSION) src/man/firecfg.txt firecfg.1
firejail-profile.5: src/man/firejail-profile.txt
./mkman.sh $(VERSION) src/man/firejail-profile.txt firejail-profile.5
firejail-login.5: src/man/firejail-login.txt
./mkman.sh $(VERSION) src/man/firejail-login.txt firejail-login.5
firejail-config.5: src/man/firejail-config.txt
./mkman.sh $(VERSION) src/man/firejail-config.txt firejail-config.5
clean:
for dir in $(APPS); do \
$(MAKE) -C $$dir clean; \
done
for dir in $(MYLIBS); do \
$(MAKE) -C $$dir clean; \
done
rm -f firejail.1 firejail.1.gz firemon.1 firemon.1.gz firecfg.1 firecfg.gz firejail-profile.5 firejail-profile.5.gz firejail-login.5 firejail-login.5.gz firejail-config.5 firejail-config.5.gz firejail*.rpm
rm -f test/utils/index.html*
rm -f test/utils/wget-log
rm -f test/utils/lstesting
cd test/compile; ./compile.sh --clean; cd ../..
cd test/dist-compile; ./compile.sh --clean; cd ../..
distclean: clean
for dir in $(APPS); do \
$(MAKE) -C $$dir distclean; \
done
for dir in $(MYLIBS); do \
$(MAKE) -C $$dir distclean; \
done
rm -fr Makefile autom4te.cache config.log config.status config.h
realinstall:
# firejail executable
install -m 0755 -d $(DESTDIR)/$(bindir)
install -c -m 0755 src/firejail/firejail $(DESTDIR)/$(bindir)/.
chmod u+s $(DESTDIR)/$(bindir)/firejail
# firemon executable
install -c -m 0755 src/firemon/firemon $(DESTDIR)/$(bindir)/.
# firecfg executable
install -c -m 0755 src/firecfg/firecfg $(DESTDIR)/$(bindir)/.
# libraries and plugins
install -m 0755 -d $(DESTDIR)/$(libdir)/firejail
install -c -m 0644 src/libtrace/libtrace.so $(DESTDIR)/$(libdir)/firejail/.
install -c -m 0644 src/libtracelog/libtracelog.so $(DESTDIR)/$(libdir)/firejail/.
install -c -m 0755 src/ftee/ftee $(DESTDIR)/$(libdir)/firejail/.
install -c -m 0755 src/fshaper/fshaper.sh $(DESTDIR)/$(libdir)/firejail/.
install -c -m 0644 src/firecfg/firecfg.config $(DESTDIR)/$(libdir)/firejail/.
# documents
install -m 0755 -d $(DESTDIR)/$(DOCDIR)
install -c -m 0644 COPYING $(DESTDIR)/$(DOCDIR)/.
install -c -m 0644 README $(DESTDIR)/$(DOCDIR)/.
install -c -m 0644 RELNOTES $(DESTDIR)/$(DOCDIR)/.
# etc files
./mketc.sh $(sysconfdir)
install -m 0755 -d $(DESTDIR)/$(sysconfdir)/firejail
install -c -m 0644 .etc/audacious.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/clementine.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/epiphany.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/qtox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/polari.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/gnome-mplayer.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/rhythmbox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/totem.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/firefox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/icedove.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/iceweasel.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/midori.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/evince.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/chromium-browser.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/chromium.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/google-chrome.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/google-chrome-stable.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/google-chrome-beta.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/google-chrome-unstable.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/disable-common.inc $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/dropbox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/opera.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/opera-beta.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/thunderbird.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/transmission-gtk.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/transmission-qt.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/vlc.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/deluge.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/qbittorrent.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/default.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/pidgin.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/xchat.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/empathy.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/server.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/icecat.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/quassel.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/deadbeef.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/filezilla.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/fbreader.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/spotify.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/steam.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/skype.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/wine.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/disable-devel.inc $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/conkeror.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/unbound.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/dnscrypt-proxy.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/whitelist-common.inc $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/nolocal.net $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/webserver.net $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/bitlbee.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/weechat.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/weechat-curses.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/hexchat.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/rtorrent.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/parole.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/kmail.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/seamonkey.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/seamonkey-bin.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/telegram.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/mathematica.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/Mathematica.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/uget-gtk.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/mupen64plus.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/disable-programs.inc $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/disable-passwdmgr.inc $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/lxterminal.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/cherrytree.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/wesnoth.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/hedgewars.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/vivaldi.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/vivaldi-beta.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/atril.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/qutebrowser.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/flashpeak-slimjet.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/ssh.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/openbox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/dillo.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/cmus.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/dnsmasq.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/palemoon.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/icedove.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/abrowser.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/0ad.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/netsurf.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/warzone2100.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/okular.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/gwenview.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/gpredict.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/aweather.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/stellarium.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/google-play-music-desktop-player.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/quiterss.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/cyberfox.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/snap.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/xplayer.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/xreader.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/xviewer.profile $(DESTDIR)/$(sysconfdir)/firejail/.
install -c -m 0644 .etc/mcabber.profile $(DESTDIR)/$(sysconfdir)/firejail/.
sh -c "if [ ! -f $(DESTDIR)/$(sysconfdir)/firejail/login.users ]; then install -c -m 0644 etc/login.users $(DESTDIR)/$(sysconfdir)/firejail/.; fi;"
sh -c "if [ ! -f $(DESTDIR)/$(sysconfdir)/firejail/firejail.config ]; then install -c -m 0644 etc/firejail.config $(DESTDIR)/$(sysconfdir)/firejail/.; fi;"
rm -fr .etc
# man pages
rm -f firejail.1.gz
gzip -9n firejail.1
rm -f firemon.1.gz
gzip -9n firemon.1
rm -f firecfg.1.gz
gzip -9n firecfg.1
rm -f firejail-profile.5.gz
gzip -9n firejail-profile.5
rm -f firejail-login.5.gz
gzip -9n firejail-login.5
rm -f firejail-config.5.gz
gzip -9n firejail-config.5
install -m 0755 -d $(DESTDIR)/$(mandir)/man1
install -c -m 0644 firejail.1.gz $(DESTDIR)/$(mandir)/man1/.
install -c -m 0644 firemon.1.gz $(DESTDIR)/$(mandir)/man1/.
install -c -m 0644 firecfg.1.gz $(DESTDIR)/$(mandir)/man1/.
install -m 0755 -d $(DESTDIR)/$(mandir)/man5
install -c -m 0644 firejail-profile.5.gz $(DESTDIR)/$(mandir)/man5/.
install -c -m 0644 firejail-login.5.gz $(DESTDIR)/$(mandir)/man5/.
install -c -m 0644 firejail-config.5.gz $(DESTDIR)/$(mandir)/man5/.
rm -f firejail.1.gz firemon.1.gz firecfg.1.gz firejail-profile.5.gz firejail-login.5.gz firejail-config.5.gz
# bash completion
install -m 0755 -d $(DESTDIR)/$(datarootdir)/bash-completion/completions
install -c -m 0644 src/bash_completion/firejail.bash_completion $(DESTDIR)/$(datarootdir)/bash-completion/completions/firejail
install -c -m 0644 src/bash_completion/firemon.bash_completion $(DESTDIR)/$(datarootdir)/bash-completion/completions/firemon
install -c -m 0644 src/bash_completion/firecfg.bash_completion $(DESTDIR)/$(datarootdir)/bash-completion/completions/firecfg
install: all
$(MAKE) realinstall
install-strip: all
strip src/firejail/firejail
strip src/firemon/firemon
strip src/firecfg/firecfg
strip src/libtrace/libtrace.so
strip src/libtracelog/libtracelog.so
strip src/ftee/ftee
$(MAKE) realinstall
uninstall:
rm -f $(DESTDIR)/$(bindir)/firejail
rm -f $(DESTDIR)/$(bindir)/firemon
rm -f $(DESTDIR)/$(bindir)/firecfg
rm -fr $(DESTDIR)/$(libdir)/firejail
rm -fr $(DESTDIR)/$(datarootdir)/doc/firejail
rm -f $(DESTDIR)/$(mandir)/man1/firejail.1*
rm -f $(DESTDIR)/$(mandir)/man1/firemon.1*
rm -f $(DESTDIR)/$(mandir)/man1/firecfg.1*
rm -f $(DESTDIR)/$(mandir)/man5/firejail-profile.5*
rm -f $(DESTDIR)/$(mandir)/man5/firejail-login.5*
rm -f $(DESTDIR)/$(mandir)/man5/firejail-config.5*
rm -f $(DESTDIR)/$(datarootdir)/bash-completion/completions/firejail
rm -f $(DESTDIR)/$(datarootdir)/bash-completion/completions/firemon
rm -f $(DESTDIR)/$(datarootdir)/bash-completion/completions/firecfg
dist:
make distclean
rm -fr $(NAME)-$(VERSION) $(NAME)-$(VERSION).tar.bz2
mkdir $(NAME)-$(VERSION)
cd $(NAME)-$(VERSION); cp -a ../src .; cp -a ../etc .; cp -a ../platform .; rm -fr src/tools; cd ..
cd $(NAME)-$(VERSION); cp -a ../configure .; cp -a ../configure.ac .; cp -a ../Makefile.in .; cp -a ../install.sh .; cp -a ../mkman.sh .; cp -a ../mketc.sh .; cp -a ../mkdeb.sh .;cd ..
cd $(NAME)-$(VERSION); cp -a ../COPYING .; cp -a ../README .; cp -a ../RELNOTES .; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/profiles test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/apps test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/utils test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/apps-x11 test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/environment test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/compile test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/dist-compile test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/filters test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/network test/.; cd ..
cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/fs test/.; cd ..
cd $(NAME)-$(VERSION); rm -fr `find . -name .svn`; rm -fr $(NAME)-$(VERSION); cd ..
tar -cjvf $(NAME)-$(VERSION).tar.bz2 $(NAME)-$(VERSION)
rm -fr $(NAME)-$(VERSION)
deb: dist
./mkdeb.sh $(NAME) $(VERSION)
github-compile:
cd test/compile; ./compile.sh
dist-compile: dist
cd test/dist-compile; ./compile.sh $(NAME)-$(VERSION)
.PHONY: rpms
rpms:
./platform/rpm/mkrpm.sh $(NAME) $(VERSION)
extras: all
$(MAKE) -C extras/firetools
cppcheck: clean
cppcheck --force .
scan-build: clean
scan-build make
asc:; ./mkasc.sh $(VERSION)
test-profiles:
cd test/profiles; ./profiles.sh | grep TESTING
test-apps:
cd test/apps; ./apps.sh | grep TESTING
test-apps-x11:
cd test/apps-x11; ./apps-x11.sh | grep TESTING
test-utils:
cd test/utils; ./utils.sh | grep TESTING
test-environment:
cd test/environment; ./environment.sh | grep TESTING
test-filters:
cd test/filters; ./filters.sh | grep TESTING
test-network:
echo "Please read test/network/README file and run the test manually"
test-fs:
cd test/fs; ./fs.sh | grep TESTING
test: test-profiles test-fs test-utils test-environment test-apps test-apps-x11 test-filters
echo "TEST COMPLETE"