aboutsummaryrefslogtreecommitdiffstats
path: root/test/compile/compile.sh
diff options
context:
space:
mode:
Diffstat (limited to 'test/compile/compile.sh')
-rwxr-xr-xtest/compile/compile.sh95
1 files changed, 47 insertions, 48 deletions
diff --git a/test/compile/compile.sh b/test/compile/compile.sh
index 6b994ba70..0285c8935 100755
--- a/test/compile/compile.sh
+++ b/test/compile/compile.sh
@@ -31,7 +31,7 @@ arr[15]="TEST 15: compile private-home disabled"
31arr[16]="TEST 16: compile disable manpages" 31arr[16]="TEST 16: compile disable manpages"
32arr[17]="TEST 17: disable tmpfs as regular user" 32arr[17]="TEST 17: disable tmpfs as regular user"
33arr[18]="TEST 18: disable private home" 33arr[18]="TEST 18: disable private home"
34arr[18]="TEST 19: enable ids" 34arr[19]="TEST 19: enable ids"
35 35
36# remove previous reports and output file 36# remove previous reports and output file
37cleanup() { 37cleanup() {
@@ -47,23 +47,23 @@ print_title() {
47 echo 47 echo
48 echo 48 echo
49 echo "**************************************************" 49 echo "**************************************************"
50 echo $1 50 echo "$1"
51 echo "**************************************************" 51 echo "**************************************************"
52} 52}
53 53
54DIST="$1" 54DIST="$1"
55while [ $# -gt 0 ]; do # Until you run out of parameters . . . 55while [[ $# -gt 0 ]]; do # Until you run out of parameters . . .
56 case "$1" in 56 case "$1" in
57 --clean) 57 --clean)
58 cleanup 58 cleanup
59 exit 59 exit
60 ;; 60 ;;
61 --help) 61 --help)
62 echo "./compile.sh [--clean|--help]" 62 echo "./compile.sh [--clean|--help]"
63 exit 63 exit
64 ;; 64 ;;
65 esac 65 esac
66 shift # Check next set of parameters. 66 shift # Check next set of parameters.
67done 67done
68 68
69cleanup 69cleanup
@@ -76,8 +76,8 @@ cleanup
76#***************************************************************** 76#*****************************************************************
77print_title "${arr[1]}" 77print_title "${arr[1]}"
78echo "$DIST" 78echo "$DIST"
79tar -xJvf ../../$DIST.tar.xz 79tar -xJvf ../../"$DIST.tar.xz"
80mv $DIST firejail 80mv "$DIST" firejail
81 81
82cd firejail 82cd firejail
83./configure --prefix=/usr --enable-fatal-warnings 2>&1 | tee ../output-configure 83./configure --prefix=/usr --enable-fatal-warnings 2>&1 | tee ../output-configure
@@ -89,7 +89,6 @@ cp output-configure oc1
89cp output-make om1 89cp output-make om1
90rm output-configure output-make 90rm output-configure output-make
91 91
92
93#***************************************************************** 92#*****************************************************************
94# TEST 2 93# TEST 2
95#***************************************************************** 94#*****************************************************************
@@ -98,7 +97,7 @@ rm output-configure output-make
98print_title "${arr[2]}" 97print_title "${arr[2]}"
99cd firejail 98cd firejail
100make distclean 99make distclean
101./configure --prefix=/usr --disable-dbusproxy --enable-fatal-warnings 2>&1 | tee ../output-configure 100./configure --prefix=/usr --disable-dbusproxy --enable-fatal-warnings 2>&1 | tee ../output-configure
102make -j4 2>&1 | tee ../output-make 101make -j4 2>&1 | tee ../output-make
103cd .. 102cd ..
104grep Warning output-configure output-make > ./report-test2 103grep Warning output-configure output-make > ./report-test2
@@ -115,7 +114,7 @@ rm output-configure output-make
115print_title "${arr[3]}" 114print_title "${arr[3]}"
116cd firejail 115cd firejail
117make distclean 116make distclean
118./configure --prefix=/usr --disable-chroot --enable-fatal-warnings 2>&1 | tee ../output-configure 117./configure --prefix=/usr --disable-chroot --enable-fatal-warnings 2>&1 | tee ../output-configure
119make -j4 2>&1 | tee ../output-make 118make -j4 2>&1 | tee ../output-make
120cd .. 119cd ..
121grep Warning output-configure output-make > ./report-test3 120grep Warning output-configure output-make > ./report-test3
@@ -132,7 +131,7 @@ rm output-configure output-make
132print_title "${arr[4]}" 131print_title "${arr[4]}"
133cd firejail 132cd firejail
134make distclean 133make distclean
135./configure --prefix=/usr --disable-firetunnel --enable-fatal-warnings 2>&1 | tee ../output-configure 134./configure --prefix=/usr --disable-firetunnel --enable-fatal-warnings 2>&1 | tee ../output-configure
136make -j4 2>&1 | tee ../output-make 135make -j4 2>&1 | tee ../output-make
137cd .. 136cd ..
138grep Warning output-configure output-make > ./report-test4 137grep Warning output-configure output-make > ./report-test4
@@ -149,7 +148,7 @@ rm output-configure output-make
149print_title "${arr[5]}" 148print_title "${arr[5]}"
150cd firejail 149cd firejail
151make distclean 150make distclean
152./configure --prefix=/usr --disable-userns --enable-fatal-warnings 2>&1 | tee ../output-configure 151./configure --prefix=/usr --disable-userns --enable-fatal-warnings 2>&1 | tee ../output-configure
153make -j4 2>&1 | tee ../output-make 152make -j4 2>&1 | tee ../output-make
154cd .. 153cd ..
155grep Warning output-configure output-make > ./report-test5 154grep Warning output-configure output-make > ./report-test5
@@ -167,7 +166,7 @@ rm output-configure output-make
167print_title "${arr[6]}" 166print_title "${arr[6]}"
168cd firejail 167cd firejail
169make distclean 168make distclean
170./configure --prefix=/usr --disable-network --enable-fatal-warnings 2>&1 | tee ../output-configure 169./configure --prefix=/usr --disable-network --enable-fatal-warnings 2>&1 | tee ../output-configure
171make -j4 2>&1 | tee ../output-make 170make -j4 2>&1 | tee ../output-make
172cd .. 171cd ..
173grep Warning output-configure output-make > ./report-test6 172grep Warning output-configure output-make > ./report-test6
@@ -184,7 +183,7 @@ rm output-configure output-make
184print_title "${arr[7]}" 183print_title "${arr[7]}"
185cd firejail 184cd firejail
186make distclean 185make distclean
187./configure --prefix=/usr --disable-x11 --enable-fatal-warnings 2>&1 | tee ../output-configure 186./configure --prefix=/usr --disable-x11 --enable-fatal-warnings 2>&1 | tee ../output-configure
188make -j4 2>&1 | tee ../output-make 187make -j4 2>&1 | tee ../output-make
189cd .. 188cd ..
190grep Warning output-configure output-make > ./report-test7 189grep Warning output-configure output-make > ./report-test7
@@ -218,7 +217,7 @@ rm output-configure output-make
218print_title "${arr[9]}" 217print_title "${arr[9]}"
219cd firejail 218cd firejail
220make distclean 219make distclean
221./configure --prefix=/usr --disable-file-transfer --enable-fatal-warnings 2>&1 | tee ../output-configure 220./configure --prefix=/usr --disable-file-transfer --enable-fatal-warnings 2>&1 | tee ../output-configure
222make -j4 2>&1 | tee ../output-make 221make -j4 2>&1 | tee ../output-make
223cd .. 222cd ..
224grep Warning output-configure output-make > ./report-test9 223grep Warning output-configure output-make > ./report-test9
@@ -235,7 +234,7 @@ rm output-configure output-make
235print_title "${arr[10]}" 234print_title "${arr[10]}"
236cd firejail 235cd firejail
237make distclean 236make distclean
238./configure --prefix=/usr --disable-whitelist --enable-fatal-warnings 2>&1 | tee ../output-configure 237./configure --prefix=/usr --disable-whitelist --enable-fatal-warnings 2>&1 | tee ../output-configure
239make -j4 2>&1 | tee ../output-make 238make -j4 2>&1 | tee ../output-make
240cd .. 239cd ..
241grep Warning output-configure output-make > ./report-test10 240grep Warning output-configure output-make > ./report-test10
@@ -252,7 +251,7 @@ rm output-configure output-make
252print_title "${arr[11]}" 251print_title "${arr[11]}"
253cd firejail 252cd firejail
254make distclean 253make distclean
255./configure --prefix=/usr --disable-globalcfg --enable-fatal-warnings 2>&1 | tee ../output-configure 254./configure --prefix=/usr --disable-globalcfg --enable-fatal-warnings 2>&1 | tee ../output-configure
256make -j4 2>&1 | tee ../output-make 255make -j4 2>&1 | tee ../output-make
257cd .. 256cd ..
258grep Warning output-configure output-make > ./report-test11 257grep Warning output-configure output-make > ./report-test11
@@ -269,7 +268,7 @@ rm output-configure output-make
269print_title "${arr[12]}" 268print_title "${arr[12]}"
270cd firejail 269cd firejail
271make distclean 270make distclean
272./configure --prefix=/usr --enable-apparmor --enable-fatal-warnings 2>&1 | tee ../output-configure 271./configure --prefix=/usr --enable-apparmor --enable-fatal-warnings 2>&1 | tee ../output-configure
273make -j4 2>&1 | tee ../output-make 272make -j4 2>&1 | tee ../output-make
274cd .. 273cd ..
275grep Warning output-configure output-make > ./report-test12 274grep Warning output-configure output-make > ./report-test12
@@ -354,7 +353,7 @@ rm output-configure output-make
354print_title "${arr[17]}" 353print_title "${arr[17]}"
355cd firejail 354cd firejail
356make distclean 355make distclean
357./configure --prefix=/usr --disable-usertmpfs --enable-fatal-warnings 2>&1 | tee ../output-configure 356./configure --prefix=/usr --disable-usertmpfs --enable-fatal-warnings 2>&1 | tee ../output-configure
358make -j4 2>&1 | tee ../output-make 357make -j4 2>&1 | tee ../output-make
359cd .. 358cd ..
360grep Warning output-configure output-make > ./report-test17 359grep Warning output-configure output-make > ./report-test17
@@ -410,23 +409,23 @@ echo "**********************************************************"
410 409
411wc -l report-test* 410wc -l report-test*
412echo 411echo
413echo "Legend:" 412echo "Legend:"
414echo ${arr[1]} 413echo "${arr[1]}"
415echo ${arr[2]} 414echo "${arr[2]}"
416echo ${arr[3]} 415echo "${arr[3]}"
417echo ${arr[4]} 416echo "${arr[4]}"
418echo ${arr[5]} 417echo "${arr[5]}"
419echo ${arr[6]} 418echo "${arr[6]}"
420echo ${arr[7]} 419echo "${arr[7]}"
421echo ${arr[8]} 420echo "${arr[8]}"
422echo ${arr[9]} 421echo "${arr[9]}"
423echo ${arr[10]} 422echo "${arr[10]}"
424echo ${arr[11]} 423echo "${arr[11]}"
425echo ${arr[12]} 424echo "${arr[12]}"
426echo ${arr[13]} 425echo "${arr[13]}"
427echo ${arr[14]} 426echo "${arr[14]}"
428echo ${arr[15]} 427echo "${arr[15]}"
429echo ${arr[16]} 428echo "${arr[16]}"
430echo ${arr[17]} 429echo "${arr[17]}"
431echo ${arr[18]} 430echo "${arr[18]}"
432echo ${arr[19]} 431echo "${arr[19]}"