scripts/Makefile.vmlinux_a
Source file repositories/reference/linux-study-clean/scripts/Makefile.vmlinux_a
File Facts
- System
- Linux kernel
- Corpus path
scripts/Makefile.vmlinux_a- Extension
.vmlinux_a- Size
- 2337 bytes
- Lines
- 83
- Domain
- Support Tooling And Documentation
- Bucket
- scripts
- Inferred role
- Support Tooling And Documentation: build/configuration rule
- Status
- atlas-only
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
Dependency Surface
- No C-style include directives detected by the generator.
Detected Declarations
- No top-level syscall, struct, function, initcall, or export declaration detected by the generator.
Annotated Snippet
# SPDX-License-Identifier: GPL-2.0-only
PHONY := __default
__default: vmlinux.a
include include/config/auto.conf
include $(srctree)/scripts/Kbuild.include
include $(srctree)/scripts/Makefile.lib
# Link of built-in-fixup.a
# ---------------------------------------------------------------------------
quiet_cmd_ar_builtin_fixup = AR $@
cmd_ar_builtin_fixup = \
rm -f $@; \
$(AR) cDPrST $@ $(KBUILD_VMLINUX_OBJS); \
$(AR) mPi $$($(AR) t $@ | sed -n 1p) $@ $$($(AR) t $@ | grep -F -f $(srctree)/scripts/head-object-list.txt)
targets += built-in-fixup.a
built-in-fixup.a: $(KBUILD_VMLINUX_OBJS) scripts/head-object-list.txt FORCE
$(call if_changed,ar_builtin_fixup)
ifdef CONFIG_LTO_CLANG_THIN_DIST
quiet_cmd_builtin.order = GEN $@
cmd_builtin.order = $(AR) t $< > $@
targets += builtin.order
builtin.order: built-in-fixup.a FORCE
$(call if_changed,builtin.order)
quiet_cmd_ld_thinlto_index = LD $@
cmd_ld_thinlto_index = \
$(LD) $(KBUILD_LDFLAGS) -r --thinlto-index-only=$@ @$<
targets += vmlinux.thinlto-index
vmlinux.thinlto-index: builtin.order FORCE
$(call if_changed,ld_thinlto_index)
quiet_cmd_ar_vmlinux.a = GEN $@
cmd_ar_vmlinux.a = \
rm -f $@; \
while read -r obj; do \
if grep -Fqx $${obj} $(word 2, $^); then \
echo $${obj%.o}.thinlto-native.o; \
else \
echo $${obj}; \
fi; \
done < $< | xargs $(AR) cDPrS --thin $@
targets += vmlinux.a
vmlinux.a: builtin.order vmlinux.thinlto-index FORCE
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.thinlto
$(call if_changed,ar_vmlinux.a)
else
# vmlinux.a
# ---------------------------------------------------------------------------
targets += vmlinux.a
vmlinux.a: built-in-fixup.a FORCE
$(call if_changed,copy)
endif
# Add FORCE to the prerequisites of a target to force it to be always rebuilt.
# ---------------------------------------------------------------------------
PHONY += FORCE
Annotation
- Atlas domain: Support Tooling And Documentation / scripts.
- Implementation status: atlas-only.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.