From b43fdf40f1f90c4c313dda5b74955cc725a88b40 Mon Sep 17 00:00:00 2001 From: Yann Diorcet Date: Fri, 16 Nov 2012 15:25:57 +0100 Subject: scripts: add BUILD/HOST extra cflags/ldflags On some hosts, and for certain toolchains (eg. toolchain targetting the upcoming Darwin), it may be necessary to pass arbitrary CFLAGS and/or LDFLAGS when building the components. And necessary infrastructure: - EXTRA_{CFLAGS,LDFLAGS}_FOR_{BUILD,HOST} as config options - pass those extra flags to components Fix-up a slight typo in elf2flt at the same time (misnamed cflags). Signed-off-by: Yann Diorcet Message-Id: Patchwork-Id: 199645 --- config/global/build-behave.in | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) (limited to 'config/global') diff --git a/config/global/build-behave.in b/config/global/build-behave.in index bb11e913..c98e0fa6 100644 --- a/config/global/build-behave.in +++ b/config/global/build-behave.in @@ -41,7 +41,27 @@ config USE_PIPES Use gcc's option -pipe to use pipes rather than temp files when building the toolchain. -config EXTRA_FLAGS_FOR_HOST +config EXTRA_CFLAGS_FOR_BUILD + string + prompt "Extra build compiler flags" + default "" + help + Extra flags to pass to the build C and C++ compiler. + + May be used to change the default features of the build + compiler such as turning off the stack protector or fortify. + +config EXTRA_LDFLAGS_FOR_BUILD + string + prompt "Extra build linker flags" + default "" + help + Extra flags to pass to the build linker. + + May be used to change the default features of the build + linker. + +config EXTRA_CFLAGS_FOR_HOST string prompt "Extra host compiler flags" default "" @@ -50,6 +70,16 @@ config EXTRA_FLAGS_FOR_HOST May be used to change the default features of the host compiler such as turning off the stack protector or fortify. + +config EXTRA_LDFLAGS_FOR_HOST + string + prompt "Extra host linker flags" + default "" + help + Extra flags to pass to the host linker. + + May be used to change the default features of the host + linker. choice bool -- cgit v1.2.3