Skip to content

Commit 9102fa3

Browse files
masahir0ysuryasaimadhu
authored andcommitted
x86/purgatory: Remove -nostdlib compiler flag
The -nostdlib option requests the compiler to not use the standard system startup files or libraries when linking. It is effective only when $(CC) is used as a linker driver. $(LD) is directly used for linking purgatory.{ro,chk} here, hence -nostdlib is unneeded. Signed-off-by: Masahiro Yamada <[email protected]> Signed-off-by: Borislav Petkov <[email protected]> Reviewed-by: Nick Desaulniers <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent a41f5b7 commit 9102fa3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/x86/purgatory/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ CFLAGS_sha256.o := -D__DISABLE_EXPORTS
1616

1717
# When linking purgatory.ro with -r unresolved symbols are not checked,
1818
# also link a purgatory.chk binary without -r to check for unresolved symbols.
19-
PURGATORY_LDFLAGS := -e purgatory_start -nostdlib -z nodefaultlib
19+
PURGATORY_LDFLAGS := -e purgatory_start -z nodefaultlib
2020
LDFLAGS_purgatory.ro := -r $(PURGATORY_LDFLAGS)
2121
LDFLAGS_purgatory.chk := $(PURGATORY_LDFLAGS)
2222
targets += purgatory.ro purgatory.chk

0 commit comments

Comments
 (0)