switch default use of -fPIC
|Reported by:||dmisev||Owned by:||dmisev|
|Keywords:||Cc:||mdumitru, pbaumann, atoader|
To generate PIC (position independent code) currently --with-pic must be specified to the configure script, which adds -fPIC to the compiler options.
It might make sense for -fPIC to be used by default, and turned off on demand with --disable-pic for example.
It would be good to investigate what are the implications of this, perhaps it's a suitable task for a student to do a small report on. A couple of things I can think of:
- compiler support for -fPIC (does clang support it?)
- performance effects with and without -fPIC, a couple of tests should suffice
- compilation time, executable/library size differences
Change History (4)
comment:1 Changed 12 months ago by pbaumann
- Priority changed from major to minor
- Type changed from defect to enhancement