[Buildroot] [PATCH 4/4] package/Makefile.in: Use gcc spec files for PIE build flags

Matthew Weber matthew.weber at rockwellcollins.com
Tue May 1 15:13:55 UTC 2018


Stefan,

On Wed, Apr 25, 2018 at 1:45 AM, Stefan Sørensen
<stefan.sorensen at spectralink.com> wrote:
> The PIE build flags are only intended for building executables and can not be
> used in relocateable links (-r), static builds and shared library build -
> including the flags here causes build errors.
>
> So instead of parsing the PIE flags directly on the command line to gcc,
> include them in a gcc spec file where it is possible to only apply the flags
> when other incompatible flags are not set.
>
> This method and the spec files are from the Fedora build system.
>
> Signed-off-by: Stefan Sørensen <stefan.sorensen at spectralink.com>

Thank you for this approach, I had a patchset reworking packages to
deal with cases of "-r", static and shared.  This eliminates that and
makes a wrapper approach much easier as the next step.

Tested-by: Matt Weber <matthew.weber at rockwellcollins.com>


More information about the buildroot mailing list