Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Build library with -fPIC or offer an option to do it #1041
In Debian we would like to build all binaries with -fPIE by default (for security purpose) but this implies that you can only link with static libraries build with -fPIC. I would thus like to suggest to build cpputest with -fPIC (in Debian this has been suggested in http://bugs.debian.org/837363).
There might be platforms where this is not desirable so I'm fine if you put this as an optional configure-time feature.
In the mean time, please find the patch I used here:
You can at least merge the parts where the flags set for the test executables are not copied from the flags used to build the library since they differ in my case.