X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Fbuild%2FMakefile;h=4a28af324a095487e8a9a5e8b88c60b870151979;hb=159356d2478ab200cda0a0aa726d8f1bfa4ffeeb;hp=c79201e3f8e08a847ebe34c86ea272d8a3572b2c;hpb=a109eb919a162bd7de58d62020801bc2e633be50;p=palacios.git diff --git a/palacios/build/Makefile b/palacios/build/Makefile index c79201e..4a28af3 100644 --- a/palacios/build/Makefile +++ b/palacios/build/Makefile @@ -1,6 +1,6 @@ # Makefile for GeekOS kernel, userspace, and tools # Copyright (c) 2004,2005 David H. Hovemeyer -# $Revision: 1.22 $ +# $Revision: 1.28 $ # This is free software. You are permitted to use, # redistribute, and modify it as specified in the file "COPYING". @@ -124,13 +124,22 @@ VMM_ASM_OBJS := $(VMM_ASM_SRCS:%.asm=palacios/%.o) VMM_C_SRCS := vm_guest.c \ svm.c svm_handler.c vmm.c vmm_util.c svm_ctrl_regs.c \ vmcb.c vmm_mem.c vmm_paging.c vmm_io.c vmm_debug.c svm_io.c \ - vmm_shadow_paging.c vm_guest_mem.c #\ + vmm_intr.c vmm_irq.c\ + vmm_shadow_paging.c vm_guest_mem.c \ + vm_dev.c vmm_dev_mgr.c \ +#\ # vmx.c vmcs_gen.c vmcs.c VMM_C_OBJS := $(VMM_C_SRCS:%.c=palacios/%.o) VMM_OBJS := $(VMM_C_OBJS) $(VMM_ASM_OBJS) +DEVICE_C_SRCS := nvram.c timer.c simple_pic.c 8259a.c + +DEVICE_C_OBJS := $(DEVICE_C_SRCS:%.c=devices/%.o) + +DEVICE_OBJS := $(DEVICE_C_OBJS) + # ---------------------------------------------------------------------- @@ -249,6 +258,12 @@ palacios/%.o : palacios/%.c palacios/%.o : palacios/%.asm $(NASM) $(NASM_VMM_OPTS) $< -o palacios/$*.o +devices/%.o : devices/%.c + $(TARGET_CC) -c $(CC_GENERAL_OPTS) $(CC_VMM_OPTS) $< -o devices/$*.o + +devices/%.o : devices/%.asm + $(NASM) $(NASM_VMM_OPTS) $< -o devices/$*.o + # ---------------------------------------------------------------------- # Targets - # Specifies files to be built @@ -309,9 +324,9 @@ geekos/kernel.bin : geekos/kernel.exe $(PAD) $@ 512 # The kernel executable and symbol map. -geekos/kernel.exe : $(KERNEL_OBJS) $(COMMON_C_OBJS) $(VMM_OBJS) +geekos/kernel.exe : $(KERNEL_OBJS) $(COMMON_C_OBJS) $(VMM_OBJS) $(DEVICE_OBJS) $(TARGET_LD) -o geekos/kernel.exe -Ttext $(KERNEL_BASE_ADDR) -e $(KERNEL_ENTRY) \ - $(KERNEL_OBJS) $(COMMON_C_OBJS) $(VMM_OBJS) + $(KERNEL_OBJS) $(COMMON_C_OBJS) $(VMM_OBJS) $(DEVICE_OBJS) $(TARGET_NM) geekos/kernel.exe > geekos/kernel.syms @@ -327,7 +342,7 @@ vm_kernel: force # Clean build directories of generated files clean : - for d in geekos common libc user tools palacios; do \ + for d in geekos common libc user tools palacios devices; do \ (cd $$d && rm -f *); \ done @@ -347,6 +362,10 @@ depend : $(GENERATED_LIBC_SRCS) $(VMM_C_SRCS:%.c=$(PROJECT_ROOT)/src/palacios/%.c) \ | $(PERL) -n -e 's,^(\S),palacios/$$1,;print' \ >> depend.mak + $(TARGET_CC) -M $(CC_GENERAL_OPTS) $(CC_KERNEL_OPTS) \ + $(DEVICE_C_SRCS:%.c=$(PROJECT_ROOT)/src/devices/%.c) \ + | $(PERL) -n -e 's,^(\S),devices/$$1,;print' \ + >> depend.mak # By default, there are no header file dependencies. depend.mak :