diff options
author | Nick Desaulniers <ndesaulniers@google.com> | 2019-04-23 17:27:41 -0400 |
---|---|---|
committer | Masahiro Yamada <yamada.masahiro@socionext.com> | 2019-05-20 11:02:59 -0400 |
commit | 055efab3120bae7ab1ed841317774f3c953f6e1b (patch) | |
tree | d464025628dc65e9e36430ee53e35749639431be /Documentation/kbuild | |
parent | cb6f8739fbf98203d0fb0bc2c2dbbec0ddfe978a (diff) |
kbuild: drop support for cc-ldoption
If you want to see if your linker supports a certain flag, then ask the
linker directly with ld-option (not the compiler with cc-ldoption).
Checking for linker flag support is an antipattern that complicates the
usage of various linkers other than bfd via -fuse-ld={bfd|gold|lld}.
Cc: clang-built-linux@googlegroups.com
Suggested-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'Documentation/kbuild')
-rw-r--r-- | Documentation/kbuild/makefiles.txt | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/Documentation/kbuild/makefiles.txt b/Documentation/kbuild/makefiles.txt index 03c065855eaf..d65ad5746f94 100644 --- a/Documentation/kbuild/makefiles.txt +++ b/Documentation/kbuild/makefiles.txt | |||
@@ -437,20 +437,6 @@ more details, with real examples. | |||
437 | The second argument is optional, and if supplied will be used | 437 | The second argument is optional, and if supplied will be used |
438 | if first argument is not supported. | 438 | if first argument is not supported. |
439 | 439 | ||
440 | cc-ldoption | ||
441 | cc-ldoption is used to check if $(CC) when used to link object files | ||
442 | supports the given option. An optional second option may be | ||
443 | specified if first option are not supported. | ||
444 | |||
445 | Example: | ||
446 | #arch/x86/kernel/Makefile | ||
447 | vsyscall-flags += $(call cc-ldoption, -Wl$(comma)--hash-style=sysv) | ||
448 | |||
449 | In the above example, vsyscall-flags will be assigned the option | ||
450 | -Wl$(comma)--hash-style=sysv if it is supported by $(CC). | ||
451 | The second argument is optional, and if supplied will be used | ||
452 | if first argument is not supported. | ||
453 | |||
454 | as-instr | 440 | as-instr |
455 | as-instr checks if the assembler reports a specific instruction | 441 | as-instr checks if the assembler reports a specific instruction |
456 | and then outputs either option1 or option2 | 442 | and then outputs either option1 or option2 |