[Buildroot] [PATCH] package/jitterentropy-library: fix build failure due to missing -fPIC
arnout at mind.be
Fri Oct 25 18:52:53 UTC 2019
On 25/10/2019 18:19, Peter Korsgaard wrote:
>>>>>> "Arnout" == Arnout Vandecappelle <arnout at mind.be> writes:
> >> +
> >> define JITTERENTROPY_LIBRARY_BUILD_CMDS
> >> - $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(TARGET_CONFIGURE_OPTS)
> >> + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(TARGET_CONFIGURE_OPTS) CFLAGS="$(JITTERENTROPY_LIBRARY_CFLAGS)"
> > And here we see the actual issue: TARGET_CONFIGURE_OPTS should be passed in the
> > environment instead of as arguments, so the Makefile can add its stuff to it.
> > Hm, but maybe there are indeed good reasons to override the CFLAGS, because the
> > fstack-protector-all requires support from the toolchain. On the other hand, we
> > probably *do* want to keep the -O0 and -fwrapv flags...
> The fstack-protector-* options should be handled by BR2_SSP_* and
> hardcoded in the package.
If with "hardcoded in the package" you mean "set by the package's .mk file",
then I disagree, since it is passed by the toolchain wrapper.
> Why would we want to use -O0?
The package description is "Hardware RNG based on CPU timing jitter." I expect
that compiler optimisations mess with CPU timing jitter.
More information about the buildroot