I have the following situation: - a package (valgrind) that can be compiled with PIE and uses PIE for some purpose or other if it is supported - tests (make check) that cannot be compiled with PIE
In the upstream release CFLAGS is reset to "-Wno-long-long", but I would prefer to allow customised CFLAGS. I already asked the developers why they reset the CFLAGS, but I haven't received an answer. I made a small modification to configure to enable the use of make.conf's CFLAGS, but now some problems occur. The first problem is a problem even without this modification. If compiled with the hardened gcc profile, -fno-pie has to be specified when compiling the tests or it will fail. Specifying -fno-pie always will force me to disable any PIE support through configure as well. I tried to adapt the makefiles to disable pie themselves for the tests only, but then I have another problem: What if the user specifies -fpie in make.conf? The compilation of the tests will fail because -fpie (from the environment) will end up in CFLAGS after -fno-pie (from the makefile). If I use flag-o-matic to filter out -fpie, it will add -fno-pie everywhere and disable PIE altogether. I'm looking for a solution that preferably: - uses (some of) make.conf's CFLAGS - compiles with all gcc profiles and all CFLAGS (filtering some is ok) - does not disable PIE altogether Is there such a solution? Maurice. -- Maurice van der Pot Gentoo Linux Developer [EMAIL PROTECTED] http://www.gentoo.org Creator of BiteMe! [EMAIL PROTECTED] http://www.kfk4ever.com
pgpB0CvbLCLUx.pgp
Description: PGP signature
