Add virt directory to the top Makefile
PATCH v2 1/1 Add virt directory to the top Makefile
We need to build files in virt/lib/, so add virt directory to the top Makefile.
Signed-off-by Feng Wu <[email protected]>
---
v2:
- Remove the explicit 'virt' entry in the KBUILD_ALLDIRS assignment
- Remove './' in virt/Makefile
Makefile | 10 ++++++---- arch/x86/kvm/Makefile | 3 --- virt/Makefile | 1 + 3 files changed, 7 insertions(+), 7 deletions(-) create mode 100644 virt/Makefile
Makefile +6 -4
@@ -550,6 +550,7 @@ drivers-y := drivers/ sound/ firmware/ net-y := net/ libs-y := lib/ core-y := usr/ +virt-y := virt/ endif # KBUILD_EXTMOD ifeq ($(dot-config),1)
@@ -890,10 +891,10 @@ core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ - $(net-y) $(net-m) $(libs-y) $(libs-m))) + $(net-y) $(net-m) $(libs-y) $(libs-m) $(virt-y))) vmlinux-alldirs := $(sort $(vmlinux-dirs) $(patsubst %/,%,$(filter %/, \ - $(init-) $(core-) $(drivers-) $(net-) $(libs-)))) + $(init-) $(core-) $(drivers-) $(net-) $(libs-) $(virt-)))) init-y := $(patsubst %/, %/built-in.o, $(init-y)) core-y := $(patsubst %/, %/built-in.o, $(core-y))
@@ -902,14 +903,15 @@ net-y := $(patsubst %/, %/built-in.o, $(net-y)) libs-y1 := $(patsubst %/, %/lib.a, $(libs-y)) libs-y2 := $(patsubst %/, %/built-in.o, $(libs-y)) libs-y := $(libs-y1) $(libs-y2) +virt-y := $(patsubst %/, %/built-in.o, $(virt-y)) # Externally visible symbols (used by link-vmlinux.sh) export KBUILD_VMLINUX_INIT := $(head-y) $(init-y) -export KBUILD_VMLINUX_MAIN := $(core-y) $(libs-y) $(drivers-y) $(net-y) +export KBUILD_VMLINUX_MAIN := $(core-y) $(libs-y) $(drivers-y) $(net-y) $(virt-y) export KBUILD_LDS := arch/$(SRCARCH)/kernel/vmlinux.lds export LDFLAGS_vmlinux # used by scripts/pacmage/Makefile -export KBUILD_ALLDIRS := $(sort $(filter-out arch/%,$(vmlinux-alldirs)) arch Documentation include samples scripts tools virt) +export KBUILD_ALLDIRS := $(sort $(filter-out arch/%,$(vmlinux-alldirs)) arch Documentation include samples scripts tools) vmlinux-deps := $(KBUILD_LDS) $(KBUILD_VMLINUX_INIT) $(KBUILD_VMLINUX_MAIN)
arch/x86/kvm/Makefile +0 -3
@@ -6,9 +6,6 @@ CFLAGS_svm.o := -I. CFLAGS_vmx.o := -I. KVM := ../../../virt/kvm -LIB := ../../../virt/lib - -obj-$(CONFIG_IRQ_BYPASS_MANAGER) += $(LIB)/ kvm-y += $(KVM)/kvm_main.o $(KVM)/coalesced_mmio.o \ $(KVM)/eventfd.o $(KVM)/irqchip.o $(KVM)/vfio.o
virt/Makefile new file +1 -0
@@ -0,0 +1 @@ +obj-y += lib/
Signature · 1 line
2.1.0
Dne 22.9.2015 v 14:23 Feng Wu napsal(a):
Quoted 8 lines
We need to build files in
virt/lib/, so add virt directory to the topMakefile.Signed-off-by Feng Wu <[email protected]>---
v2:
- Remove the explicit 'virt' entry in theKBUILD_ALLDIRSassignment
- Remove './' invirt/Makefile
Acked-by Michal Marek <[email protected]>
Michal