[Buildroot] Which order: $(MAKE) $(TARGET_CONFIGURE_OPTS) or $(TARGET_CONFIGURE_OPTS) $(MAKE)

Thomas Petazzoni thomas.petazzoni at free-electrons.com
Wed Mar 29 19:49:59 UTC 2017


Hello,

On Wed, 29 Mar 2017 21:43:18 +0200, Thomas De Schampheleire wrote:

> But, on the other hand, if a package would do:
> 
> CFLAGS = -I../include
> 
> then we cannot use either approach because one approach will ignore
> the -I../include, and the other will ignore our own settings. In that
> case, a patch of the package is required, right?

Correct. But I guess in many cases we don't realize when the package
"ignores" our CFLAGS, because there is nothing in our CFLAGS that is
really mandatory for the thing to build.

Of course, the fact that our CFLAGS may be ignored means that the
package may not have the correct optimization level, debugging level,
stack smashing protection flags, etc. I remember at some Buildroot
meeting, we discussed the idea of injecting a fake CFLAGS, and then
checking in the toolchain wrapper that we have this fake flag. But I'm
sure this would cause lots and lots of false positives.

> Is there a recommendation for the case that the package allows either way?

I don't really have a good suggestion. We tend to fix those issues on a
case by case basis, with no well defined "best practice".

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com


More information about the buildroot mailing list