Firejail: Fedora 30 Compilation Errors

Created on 23 Apr 2019  路  3Comments  路  Source: netblue30/firejail

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.

Most helpful comment

I think it's better to detect if -fcf-protection is passed in CFLAGS.

All 3 comments

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.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

francoism90 picture francoism90  路  4Comments

Fincer picture Fincer  路  4Comments

dandelionred picture dandelionred  路  3Comments

polyzen picture polyzen  路  4Comments

yourcelf picture yourcelf  路  4Comments