Fedora 30 has changed the default compile flags for programs. One new addition is -fcf-protection which is marked incompatible with -mindirect-branch.
Example:
/usr/include/bits/stdio.h: In function 'getchar':
/usr/include/bits/stdio.h:48:1: error: '-mindirect-branch' and '-fcf-protection' are not compatible
48 | {
| ^
https://github.com/netblue30/firejail/blob/master/configure#L3113
will need to be changed.
So how do we do this such that it doesn't affect other distros which haven't (yet?) done this?
Maybe something like
[ -e /etc/fedora-release ] && [ "$(cat /etc/fedora-release)" = "Fedora release 30 (Thirty)" ]
I think it's better to detect if -fcf-protection is passed in CFLAGS.
Most helpful comment
I think it's better to detect if
-fcf-protectionis passed inCFLAGS.