History

Merge tag 'kbuild-thinar-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild

Pull Kbuild thin archives updates from Masahiro Yamada: "Thin archives migration by Nicholas Piggin. THIN_ARCHIVES has been available for a while as an optional feature only for PowerPC architecture, but we do not need two different intermediate-artifact schemes. Using thin archives instead of conventional incremental linking has various advantages: - save disk space for builds - speed-up building a little - fix some link issues (for example, allyesconfig on ARM) due to more flexibility for the final linking - work better with dead code elimination we are planning As discussed before, this migration has been done unconditionally so that any problems caused by this will show up with "git bisect". With testing with 0-day and linux-next, some architectures actually showed up problems, but they were trivial and all fixed now" * tag 'kbuild-thinar-v4.13' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: tile: remove unneeded extra-y in Makefile kbuild: thin archives make default for all archs x86/um: thin archives build fix tile: thin archives fix linking ia64: thin archives fix linking sh: thin archives fix linking kbuild: handle libs-y archives separately from built-in.o archives kbuild: thin archives use P option to ar kbuild: thin archives final link close --whole-archives option ia64: remove unneeded extra-y in Makefile.gate tile: fix dependency and .*.cmd inclusion for incremental build sparc64: Use indirect calls in hamming weight stubs

Linus Torvalds committed 9 years ago

Commit 98ced882 parents 16ffc4c 42317ea12 files · +93 −72Browse files

Unified · Split

12 files
  1. Documentation/kbuild/kbuild.txt +6 −2
  2. Documentation/process/changes.rst +4 −5
  3. Makefile +4 −4
  4. arch/Kconfig +1 −1
  5. arch/ia64/kernel/Makefile.gate +8 −7
  6. arch/powerpc/Kconfig +0 −8
  7. arch/sh/kernel/vsyscall/Makefile +8 −8
  8. arch/sparc/lib/hweight.S +8 −8
  9. arch/tile/kernel/vdso/Makefile +12 −14
  10. arch/x86/um/vdso/Makefile +1 −1
  11. scripts/Makefile.build +4 −4
  12. scripts/link-vmlinux.sh +37 −10
Documentation/kbuild/kbuild.txt+6−2
@@ -236,5 +236,9 @@ Files specified with KBUILD_VMLINUX_INIT are linked first. · 235 unmodified lines
236236 KBUILD_VMLINUX_MAIN
237237 --------------------------------------------------
238238 All object files for the main part of vmlinux.
239−KBUILD_VMLINUX_INIT and KBUILD_VMLINUX_MAIN together specify
240−all the object files used to link vmlinux.
239+
240+KBUILD_VMLINUX_LIBS
241+--------------------------------------------------
242+All .a "lib" files for vmlinux.
243+KBUILD_VMLINUX_INIT, KBUILD_VMLINUX_MAIN, and KBUILD_VMLINUX_LIBS together
244+specify all the object files used to link vmlinux.
Documentation/process/changes.rst+4−5
@@ -31,7 +31,7 @@ you probably needn't concern yourself with isdn4k-utils. · 30 unmodified lines
3131 ====================== =============== ========================================
3232 GNU C 3.2 gcc --version
3333 GNU make 3.81 make --version
34−binutils 2.12 ld -v
34+binutils 2.20 ld -v
3535 util-linux 2.10o fdformat --version
3636 module-init-tools 0.9.10 depmod -V
3737 e2fsprogs 1.41.4 e2fsck -V
@@ -75,10 +75,9 @@ You will need GNU make 3.81 or later to build the kernel. · 37 unmodified lines
7575 Binutils
7676 --------
7777
78−Linux on IA-32 has recently switched from using ``as86`` to using ``gas`` for
79−assembling the 16-bit boot code, removing the need for ``as86`` to compile
80−your kernel. This change does, however, mean that you need a recent
81−release of binutils.
78+The build system has, as of 4.13, switched to using thin archives (`ar T`)
79+rather than incremental linking (`ld -r`) for built-in.o intermediate steps.
80+This requires binutils 2.20 or newer.
8281
8382 Perl
8483 ----
Makefile+4−4
@@ -944,19 +944,19 @@ core-y := $(patsubst %/, %/built-in.o, $(core-y)) · 943 unmodified lines
944944 drivers-y := $(patsubst %/, %/built-in.o, $(drivers-y))
945945 net-y := $(patsubst %/, %/built-in.o, $(net-y))
946946 libs-y1 := $(patsubst %/, %/lib.a, $(libs-y))
947−libs-y2 := $(patsubst %/, %/built-in.o, $(libs-y))
948−libs-y := $(libs-y1) $(libs-y2)
947+libs-y2 := $(filter-out %.a, $(patsubst %/, %/built-in.o, $(libs-y)))
949948 virt-y := $(patsubst %/, %/built-in.o, $(virt-y))
950949
951950 # Externally visible symbols (used by link-vmlinux.sh)
952951 export KBUILD_VMLINUX_INIT := $(head-y) $(init-y)
953−export KBUILD_VMLINUX_MAIN := $(core-y) $(libs-y) $(drivers-y) $(net-y) $(virt-y)
952+export KBUILD_VMLINUX_MAIN := $(core-y) $(libs-y2) $(drivers-y) $(net-y) $(virt-y)
953+export KBUILD_VMLINUX_LIBS := $(libs-y1)
954954 export KBUILD_LDS := arch/$(SRCARCH)/kernel/vmlinux.lds
955955 export LDFLAGS_vmlinux
956956 # used by scripts/pacmage/Makefile
957957 export KBUILD_ALLDIRS := $(sort $(filter-out arch/%,$(vmlinux-alldirs)) arch Documentation include samples scripts tools)
958958
959−vmlinux-deps := $(KBUILD_LDS) $(KBUILD_VMLINUX_INIT) $(KBUILD_VMLINUX_MAIN)
959+vmlinux-deps := $(KBUILD_LDS) $(KBUILD_VMLINUX_INIT) $(KBUILD_VMLINUX_MAIN) $(KBUILD_VMLINUX_LIBS)
960960
961961 # Include targets which we want to execute sequentially if the rest of the
962962 # kernel build went well. If CONFIG_TRIM_UNUSED_KSYMS is set, this might be
arch/Kconfig+1−1
@@ -550,7 +550,7 @@ config CC_STACKPROTECTOR_STRONG · 549 unmodified lines
550550 endchoice
551551
552552 config THIN_ARCHIVES
553− bool
553+ def_bool y
554554 help
555555 Select this if the architecture wants to use thin archives
556556 instead of ld -r to create the built-in.o files.
arch/ia64/kernel/Makefile.gate+8−7
@@ -1,8 +1,8 @@
11 # The gate DSO image is built using a special linker script.
22
3−targets += gate.so gate-syms.o
3+targets += gate.so gate.lds gate.o gate-dummy.o
44
5−extra-y += gate.so gate-syms.o gate.lds gate.o
5+obj-y += gate-syms.o
66
77 CPPFLAGS_gate.lds := -P -C -U$(ARCH)
88
@@ -14,13 +14,14 @@ GATECFLAGS_gate.so = -shared -s -Wl,-soname=linux-gate.so.1 \ · 5 unmodified lines
1414 $(obj)/gate.so: $(obj)/gate.lds $(obj)/gate.o FORCE
1515 $(call if_changed,gate)
1616
17−$(obj)/built-in.o: $(obj)/gate-syms.o
18−$(obj)/built-in.o: ld_flags += -R $(obj)/gate-syms.o
19−
20−GATECFLAGS_gate-syms.o = -r
21−$(obj)/gate-syms.o: $(obj)/gate.lds $(obj)/gate.o FORCE
17+GATECFLAGS_gate-dummy.o = -r
18+$(obj)/gate-dummy.o: $(obj)/gate.lds $(obj)/gate.o FORCE
2219 $(call if_changed,gate)
2320
21+LDFLAGS_gate-syms.o := -r -R
22+$(obj)/gate-syms.o: $(obj)/gate-dummy.o FORCE
23+ $(call if_changed,ld)
24+
2425 # gate-data.o contains the gate DSO image as data in section .data..gate.
2526 # We must build gate.so before we can assemble it.
2627 # Note: kbuild does not track this dependency due to usage of .incbin
arch/powerpc/Kconfig+0−8
@@ -463,14 +463,6 @@ config MPROFILE_KERNEL · 462 unmodified lines
463463 depends on PPC64 && CPU_LITTLE_ENDIAN
464464 def_bool !DISABLE_MPROFILE_KERNEL
465465
466−config USE_THIN_ARCHIVES
467− bool "Build the kernel using thin archives"
468− default n
469− select THIN_ARCHIVES
470− help
471− Build the kernel using thin archives.
472− If you're unsure say N.
473−
474466 config IOMMU_HELPER
475467 def_bool PPC64
476468
arch/sh/kernel/vsyscall/Makefile+8−8
@@ -1,11 +1,11 @@
1−obj-y += vsyscall.o vsyscall-syscall.o
1+obj-y += vsyscall.o vsyscall-syscall.o vsyscall-syms.o
22
33 $(obj)/vsyscall-syscall.o: \
44 $(foreach F,trapa,$(obj)/vsyscall-$F.so)
55
66 # Teach kbuild about targets
77 targets += $(foreach F,trapa,vsyscall-$F.o vsyscall-$F.so)
8−targets += vsyscall-note.o vsyscall.lds
8+targets += vsyscall-note.o vsyscall.lds vsyscall-dummy.o
99
1010 # The DSO images are built using a special linker script
1111 quiet_cmd_syscall = SYSCALL $@
@@ -26,11 +26,11 @@ $(obj)/vsyscall-%.so: $(src)/vsyscall.lds $(obj)/vsyscall-%.o FORCE · 14 unmodified lines
2626 # We also create a special relocatable object that should mirror the symbol
2727 # table and layout of the linked DSO. With ld -R we can then refer to
2828 # these symbols in the kernel code rather than hand-coded addresses.
29−extra-y += vsyscall-syms.o
30−$(obj)/built-in.o: $(obj)/vsyscall-syms.o
31−$(obj)/built-in.o: ld_flags += -R $(obj)/vsyscall-syms.o
32−
33−SYSCFLAGS_vsyscall-syms.o = -r
34−$(obj)/vsyscall-syms.o: $(src)/vsyscall.lds \
29+SYSCFLAGS_vsyscall-dummy.o = -r
30+$(obj)/vsyscall-dummy.o: $(src)/vsyscall.lds \
3531 $(obj)/vsyscall-trapa.o $(obj)/vsyscall-note.o FORCE
3632 $(call if_changed,syscall)
33+
34+LDFLAGS_vsyscall-syms.o := -r -R
35+$(obj)/vsyscall-syms.o: $(obj)/vsyscall-dummy.o FORCE
36+ $(call if_changed,ld)
arch/sparc/lib/hweight.S+8−8
@@ -4,9 +4,9 @@ · 3 unmodified lines
44 .text
55 .align 32
66 ENTRY(__arch_hweight8)
7− ba,pt %xcc, __sw_hweight8
7+ sethi %hi(__sw_hweight8), %g1
8+ jmpl %g1 + %lo(__sw_hweight8), %g0
89 nop
9− nop
1010 ENDPROC(__arch_hweight8)
1111 EXPORT_SYMBOL(__arch_hweight8)
1212 .section .popc_3insn_patch, "ax"
@@ -17,9 +17,9 @@ EXPORT_SYMBOL(__arch_hweight8) · 4 unmodified lines
1717 .previous
1818
1919 ENTRY(__arch_hweight16)
20− ba,pt %xcc, __sw_hweight16
20+ sethi %hi(__sw_hweight16), %g1
21+ jmpl %g1 + %lo(__sw_hweight16), %g0
2122 nop
22− nop
2323 ENDPROC(__arch_hweight16)
2424 EXPORT_SYMBOL(__arch_hweight16)
2525 .section .popc_3insn_patch, "ax"
@@ -30,9 +30,9 @@ EXPORT_SYMBOL(__arch_hweight16) · 4 unmodified lines
3030 .previous
3131
3232 ENTRY(__arch_hweight32)
33− ba,pt %xcc, __sw_hweight32
33+ sethi %hi(__sw_hweight32), %g1
34+ jmpl %g1 + %lo(__sw_hweight32), %g0
3435 nop
35− nop
3636 ENDPROC(__arch_hweight32)
3737 EXPORT_SYMBOL(__arch_hweight32)
3838 .section .popc_3insn_patch, "ax"
@@ -43,9 +43,9 @@ EXPORT_SYMBOL(__arch_hweight32) · 4 unmodified lines
4343 .previous
4444
4545 ENTRY(__arch_hweight64)
46− ba,pt %xcc, __sw_hweight64
46+ sethi %hi(__sw_hweight16), %g1
47+ jmpl %g1 + %lo(__sw_hweight16), %g0
4748 nop
48− nop
4949 ENDPROC(__arch_hweight64)
5050 EXPORT_SYMBOL(__arch_hweight64)
5151 .section .popc_3insn_patch, "ax"
arch/tile/kernel/vdso/Makefile+12−14
@@ -5,15 +5,14 @@ vdso-syms = rt_sigreturn gettimeofday · 4 unmodified lines
55 obj-vdso = $(patsubst %, v%.o, $(vdso-syms))
66
77 # Build rules
8−targets := $(obj-vdso) vdso.so vdso.so.dbg vdso.lds
8+targets := $(obj-vdso) vdso.so vdso.so.dbg vdso.lds vdso-dummy.o
99 obj-vdso := $(addprefix $(obj)/, $(obj-vdso))
1010
1111 # vdso32 is only for tilegx -m32 compat task.
1212 VDSO32-$(CONFIG_COMPAT) := y
1313
14−obj-y += vdso.o
14+obj-y += vdso.o vdso-syms.o
1515 obj-$(VDSO32-y) += vdso32.o
16−extra-y += vdso.lds
1716 CPPFLAGS_vdso.lds += -P -C -U$(ARCH)
1817
1918 # vDSO code runs in userspace and -pg doesn't help with profiling anyway.
@@ -42,23 +41,22 @@ $(obj)/vdso.o: $(obj)/vdso.so · 22 unmodified lines
4241
4342 # link rule for the .so file, .lds has to be first
4443 SYSCFLAGS_vdso.so.dbg = $(c_flags)
45−$(obj)/vdso.so.dbg: $(src)/vdso.lds $(obj-vdso)
44+$(obj)/vdso.so.dbg: $(src)/vdso.lds $(obj-vdso) FORCE
4645 $(call if_changed,vdsold)
4746
48−
4947 # We also create a special relocatable object that should mirror the symbol
5048 # table and layout of the linked DSO. With ld -R we can then refer to
5149 # these symbols in the kernel code rather than hand-coded addresses.
52−extra-y += vdso-syms.o
53−$(obj)/built-in.o: $(obj)/vdso-syms.o
54−$(obj)/built-in.o: ld_flags += -R $(obj)/vdso-syms.o
5550
5651 SYSCFLAGS_vdso.so.dbg = -shared -s -Wl,-soname=linux-vdso.so.1 \
5752 $(call cc-ldoption, -Wl$(comma)--hash-style=both)
58−SYSCFLAGS_vdso_syms.o = -r
59−$(obj)/vdso-syms.o: $(src)/vdso.lds $(obj)/vrt_sigreturn.o FORCE
53+SYSCFLAGS_vdso_dummy.o = -r
54+$(obj)/vdso-dummy.o: $(src)/vdso.lds $(obj)/vrt_sigreturn.o FORCE
6055 $(call if_changed,vdsold)
6156
57+LDFLAGS_vdso-syms.o := -r -R
58+$(obj)/vdso-syms.o: $(obj)/vdso-dummy.o FORCE
59+ $(call if_changed,ld)
6260
6361 # strip rule for the .so file
6462 $(obj)/%.so: OBJCOPYFLAGS := -S
@@ -96,17 +94,17 @@ KBUILD_CFLAGS_32 := $(filter-out -m64,$(KBUILD_CFLAGS)) · 31 unmodified lines
9694 KBUILD_CFLAGS_32 += -m32 -fPIC -shared
9795
9896 obj-vdso32 = $(patsubst %, v%32.o, $(vdso-syms))
99−obj-vdso32 := $(addprefix $(obj)/, $(obj-vdso32))
10097
10198 targets += $(obj-vdso32) vdso32.so vdso32.so.dbg
99+obj-vdso32 := $(addprefix $(obj)/, $(obj-vdso32))
102100
103101 $(obj-vdso32:%=%): KBUILD_AFLAGS = $(KBUILD_AFLAGS_32)
104102 $(obj-vdso32:%=%): KBUILD_CFLAGS = $(KBUILD_CFLAGS_32)
105103
106−$(obj)/vgettimeofday32.o: $(obj)/vgettimeofday.c
104+$(obj)/vgettimeofday32.o: $(obj)/vgettimeofday.c FORCE
107105 $(call if_changed_rule,cc_o_c)
108106
109−$(obj)/vrt_sigreturn32.o: $(obj)/vrt_sigreturn.S
107+$(obj)/vrt_sigreturn32.o: $(obj)/vrt_sigreturn.S FORCE
110108 $(call if_changed,as_o_S)
111109
112110 # Force dependency
@@ -114,5 +112,5 @@ $(obj)/vdso32.o: $(obj)/vdso32.so · 1 unmodified line
114112
115113 SYSCFLAGS_vdso32.so.dbg = -m32 -shared -s -Wl,-soname=linux-vdso32.so.1 \
116114 $(call cc-ldoption, -Wl$(comma)--hash-style=both)
117−$(obj)/vdso32.so.dbg: $(src)/vdso.lds $(obj-vdso32)
115+$(obj)/vdso32.so.dbg: $(src)/vdso.lds $(obj-vdso32) FORCE
118116 $(call if_changed,vdsold)
arch/x86/um/vdso/Makefile+1−1
@@ -53,7 +53,7 @@ CFLAGS_REMOVE_vdso-note.o = -pg -fprofile-arcs -ftest-coverage · 52 unmodified lines
5353 CFLAGS_REMOVE_um_vdso.o = -pg -fprofile-arcs -ftest-coverage
5454
5555 targets += vdso-syms.lds
56−obj-$(VDSO64-y) += vdso-syms.lds
56+extra-$(VDSO64-y) += vdso-syms.lds
5757
5858 #
5959 # Match symbols in the DSO that look like VDSO*; produce a file of constants.
scripts/Makefile.build+4−4
@@ -437,8 +437,8 @@ $(sort $(subdir-obj-y)): $(subdir-ym) ; · 436 unmodified lines
437437 ifdef builtin-target
438438
439439 ifdef CONFIG_THIN_ARCHIVES
440− cmd_make_builtin = rm -f $@; $(AR) rcST$(KBUILD_ARFLAGS)
441− cmd_make_empty_builtin = rm -f $@; $(AR) rcST$(KBUILD_ARFLAGS)
440+ cmd_make_builtin = rm -f $@; $(AR) rcSTP$(KBUILD_ARFLAGS)
441+ cmd_make_empty_builtin = rm -f $@; $(AR) rcSTP$(KBUILD_ARFLAGS)
442442 quiet_cmd_link_o_target = AR $@
443443 else
444444 cmd_make_builtin = $(LD) $(ld_flags) -r -o
@@ -478,7 +478,7 @@ ifdef lib-target · 33 unmodified lines
478478 quiet_cmd_link_l_target = AR $@
479479
480480 ifdef CONFIG_THIN_ARCHIVES
481− cmd_link_l_target = rm -f $@; $(AR) rcsT$(KBUILD_ARFLAGS) $@ $(lib-y)
481+ cmd_link_l_target = rm -f $@; $(AR) rcsTP$(KBUILD_ARFLAGS) $@ $(lib-y)
482482 else
483483 cmd_link_l_target = rm -f $@; $(AR) rcs$(KBUILD_ARFLAGS) $@ $(lib-y)
484484 endif
@@ -531,7 +531,7 @@ cmd_link_multi-link = $(LD) $(ld_flags) -r -o $@ $(link_multi_deps) $(cmd_secana · 46 unmodified lines
531531
532532 ifdef CONFIG_THIN_ARCHIVES
533533 quiet_cmd_link_multi-y = AR $@
534− cmd_link_multi-y = rm -f $@; $(AR) rcST$(KBUILD_ARFLAGS) $@ $(link_multi_deps)
534+ cmd_link_multi-y = rm -f $@; $(AR) rcSTP$(KBUILD_ARFLAGS) $@ $(link_multi_deps)
535535 else
536536 quiet_cmd_link_multi-y = LD $@
537537 cmd_link_multi-y = $(cmd_link_multi-link)
scripts/link-vmlinux.sh+37−10
@@ -3,9 +3,12 @@ · 2 unmodified lines
33 # link vmlinux
44 #
55 # vmlinux is linked from the objects selected by $(KBUILD_VMLINUX_INIT) and
6−# $(KBUILD_VMLINUX_MAIN). Most are built-in.o files from top-level directories
7−# in the kernel tree, others are specified in arch/$(ARCH)/Makefile.
8−# Ordering when linking is important, and $(KBUILD_VMLINUX_INIT) must be first.
6+# $(KBUILD_VMLINUX_MAIN) and $(KBUILD_VMLINUX_LIBS). Most are built-in.o files
7+# from top-level directories in the kernel tree, others are specified in
8+# arch/$(ARCH)/Makefile. Ordering when linking is important, and
9+# $(KBUILD_VMLINUX_INIT) must be first. $(KBUILD_VMLINUX_LIBS) are archives
10+# which are linked conditionally (not within --whole-archive), and do not
11+# require symbol indexes added.
912 #
1013 # vmlinux
1114 # ^
@@ -16,6 +19,9 @@ · 4 unmodified lines
1619 # +--< $(KBUILD_VMLINUX_MAIN)
1720 # | +--< drivers/built-in.o mm/built-in.o + more
1821 # |
22+# +--< $(KBUILD_VMLINUX_LIBS)
23+# | +--< lib/lib.a + more
24+# |
1925 # +-< ${kallsymso} (see description in KALLSYMS section)
2026 #
2127 # vmlinux version (uname -v) cannot be updated during normal
@@ -37,9 +43,10 @@ info() · 15 unmodified lines
3743 fi
3844 }
3945
40−# Thin archive build here makes a final archive with
41−# symbol table and indexes from vmlinux objects, which can be
42−# used as input to linker.
46+# Thin archive build here makes a final archive with symbol table and indexes
47+# from vmlinux objects INIT and MAIN, which can be used as input to linker.
48+# KBUILD_VMLINUX_LIBS archives should already have symbol table and indexes
49+# added.
4350 #
4451 # Traditional incremental style of link does not require this step
4552 #
@@ -50,7 +57,7 @@ archive_builtin() · 4 unmodified lines
5057 if [ -n "${CONFIG_THIN_ARCHIVES}" ]; then
5158 info AR built-in.o
5259 rm -f built-in.o;
53− ${AR} rcsT${KBUILD_ARFLAGS} built-in.o \
60+ ${AR} rcsTP${KBUILD_ARFLAGS} built-in.o \
5461 ${KBUILD_VMLINUX_INIT} \
5562 ${KBUILD_VMLINUX_MAIN}
5663 fi
@@ -63,11 +70,17 @@ modpost_link() · 6 unmodified lines
6370 local objects
6471
6572 if [ -n "${CONFIG_THIN_ARCHIVES}" ]; then
66− objects="--whole-archive built-in.o"
73+ objects="--whole-archive \
74+ built-in.o \
75+ --no-whole-archive \
76+ --start-group \
77+ ${KBUILD_VMLINUX_LIBS} \
78+ --end-group"
6779 else
6880 objects="${KBUILD_VMLINUX_INIT} \
6981 --start-group \
7082 ${KBUILD_VMLINUX_MAIN} \
83+ ${KBUILD_VMLINUX_LIBS} \
7184 --end-group"
7285 fi
7386 ${LD} ${LDFLAGS} -r -o ${1} ${objects}
@@ -83,11 +96,18 @@ vmlinux_link() · 9 unmodified lines
8396
8497 if [ "${SRCARCH}" != "um" ]; then
8598 if [ -n "${CONFIG_THIN_ARCHIVES}" ]; then
86− objects="--whole-archive built-in.o ${1}"
99+ objects="--whole-archive \
100+ built-in.o \
101+ --no-whole-archive \
102+ --start-group \
103+ ${KBUILD_VMLINUX_LIBS} \
104+ --end-group \
105+ ${1}"
87106 else
88107 objects="${KBUILD_VMLINUX_INIT} \
89108 --start-group \
90109 ${KBUILD_VMLINUX_MAIN} \
110+ ${KBUILD_VMLINUX_LIBS} \
91111 --end-group \
92112 ${1}"
93113 fi
@@ -96,11 +116,18 @@ vmlinux_link() · 2 unmodified lines
96116 -T ${lds} ${objects}
97117 else
98118 if [ -n "${CONFIG_THIN_ARCHIVES}" ]; then
99− objects="-Wl,--whole-archive built-in.o ${1}"
119+ objects="-Wl,--whole-archive \
120+ built-in.o \
121+ -Wl,--no-whole-archive \
122+ -Wl,--start-group \
123+ ${KBUILD_VMLINUX_LIBS} \
124+ -Wl,--end-group \
125+ ${1}"
100126 else
101127 objects="${KBUILD_VMLINUX_INIT} \
102128 -Wl,--start-group \
103129 ${KBUILD_VMLINUX_MAIN} \
130+ ${KBUILD_VMLINUX_LIBS} \
104131 -Wl,--end-group \
105132 ${1}"
106133 fi

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t