kbuild: test dead code/data elimination support in Kconfig
This config option should be enabled only when both the compiler and the linker support necessary flags. Add proper dependencies to Kconfig. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
This commit is contained in:
@@ -1085,6 +1085,8 @@ config LD_DEAD_CODE_DATA_ELIMINATION
|
||||
bool "Dead code and data elimination (EXPERIMENTAL)"
|
||||
depends on HAVE_LD_DEAD_CODE_DATA_ELIMINATION
|
||||
depends on EXPERT
|
||||
depends on $(cc-option,-ffunction-sections -fdata-sections)
|
||||
depends on $(ld-option,--gc-sections)
|
||||
help
|
||||
Enable this if you want to do dead code and data elimination with
|
||||
the linker by compiling with -ffunction-sections -fdata-sections,
|
||||
|
||||
Reference in New Issue
Block a user