Messages in this thread Patch in this message | | | From | Andreas Robinson <> | Subject | [RFC PATCH 4/6] kbuild: allow linking of an external object into vmlinux | Date | Sun, 15 Feb 2009 19:20:26 +0100 |
| |
--- Makefile | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile index 22d7584..921d6b4 100644 --- a/Makefile +++ b/Makefile @@ -651,7 +651,8 @@ libs-y := $(libs-y1) $(libs-y2) # Build vmlinux # --------------------------------------------------------------------------- # vmlinux is built from the objects selected by $(vmlinux-init) and -# $(vmlinux-main). Most are built-in.o files from top-level directories +# $(vmlinux-main) and an optional object $(EXTOBJ) specified when +# running make. Most are built-in.o files from top-level directories # in the kernel tree, others are specified in arch/$(ARCH)/Makefile. # Ordering when linking is important, and $(vmlinux-init) must be first. # @@ -664,6 +665,8 @@ libs-y := $(libs-y1) $(libs-y2) # +--< $(vmlinux-main) # | +--< driver/built-in.o mm/built-in.o + more # | +# +--< $(EXTOBJ) (optional) +# | # +-< kallsyms.o (see description in CONFIG_KALLSYMS section) # # vmlinux version (uname -v) cannot be updated during normal @@ -686,7 +689,7 @@ export KBUILD_VMLINUX_OBJS := $(vmlinux-all) quiet_cmd_vmlinux__ ?= LD $@ cmd_vmlinux__ ?= $(LD) $(LDFLAGS) $(LDFLAGS_vmlinux) -o $@ \ -T $(vmlinux-lds) $(vmlinux-init) \ - --start-group $(vmlinux-main) --end-group \ + --start-group $(vmlinux-main) $(EXTOBJ) --end-group \ $(filter-out $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) vmlinux.o FORCE ,$^) # Generate new vmlinux version -- 1.5.6.3
| |