| 1 |
dpkg-buildpackage: source package test |
| 2 |
|
| 3 |
gcc -g -O2 -fstack-protector-strong -fstack-clash-protection -Wformat-security -Werror=format-security -D_FORTIFY_SOURCE=2 -c test-a.c |
| 4 |
gcc -g -O2 -fstack-clash-protection -Wformat -Wformat-security -Werror=format-security -D_FORTIFY_SOURCE=2 -c test-b.c |
| 5 |
gcc -g -O2 -fstack-protector-strong -fstack-clash-protection -Wformat -Wformat-security -D_FORTIFY_SOURCE=2 -c test-c.c |
| 6 |
gcc -Wl,-z,relro -o test test-a.o test-b.o test-c.o -ltest |
| 7 |
|
| 8 |
# Compiling and linking in one step must also check CFLAGS/CPPFLAGS. |
| 9 |
gcc -Wl,-z,relro -o test test.c -ltest |
| 10 |
gcc -shared -fPIC -Wl,-z,relro -o test.so test.c -ltest |
| 11 |
|
| 12 |
gcc -fPIC -g -O2 -fstack-protector-strong -fstack-clash-protection -Wformat-security -Werror=format-security -c -D_FORTIFY_SOURCE=2 ../../../../src/test/test.c -o test.so.o |
| 13 |
|
| 14 |
gcc test.c -o test.output |
| 15 |
|
| 16 |
(gcc -Wl,-z,relro -o test.output test.c) |
| 17 |
|
| 18 |
rm whatever ; gcc test-comma.c |
| 19 |
rm whatever && gcc test-and.c |
| 20 |
rm whatever || gcc test-or.c |