build: move *-user/ objects to nested Makefile.objs

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
Paolo Bonzini 2012-05-29 09:33:59 +02:00
parent e05804eebc
commit 7fc5152c6d
5 changed files with 28 additions and 23 deletions

View File

@ -113,32 +113,20 @@ user-exec.o: QEMU_CFLAGS += $(HELPER_CFLAGS)
# Note: this is a workaround. The real fix is to avoid compiling # Note: this is a workaround. The real fix is to avoid compiling
# cpu_signal_handler() in user-exec.c. # cpu_signal_handler() in user-exec.c.
signal.o: QEMU_CFLAGS += $(HELPER_CFLAGS) %/signal.o: QEMU_CFLAGS += $(HELPER_CFLAGS)
######################################################### #########################################################
# Linux user emulator target # Linux user emulator target
ifdef CONFIG_LINUX_USER ifdef CONFIG_LINUX_USER
$(call set-vpath, $(SRC_PATH)/linux-user:$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR))
QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) -I$(SRC_PATH)/linux-user QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) -I$(SRC_PATH)/linux-user
obj-y = main.o syscall.o strace.o mmap.o signal.o thunk.o \
elfload.o linuxload.o uaccess.o gdbstub.o cpu-uname.o \
user-exec.o $(oslib-obj-y)
obj-$(TARGET_HAS_BFLT) += flatload.o
obj-$(TARGET_I386) += vm86.o
obj-y += linux-user/
obj-y += gdbstub.o thunk.o user-exec.o $(oslib-obj-y)
obj-i386-y += ioport-user.o obj-i386-y += ioport-user.o
obj-$(TARGET_ARM) += arm-semi.o
nwfpe-obj-y = fpa11.o fpa11_cpdo.o fpa11_cpdt.o fpa11_cprt.o fpopcode.o obj-$(TARGET_M68K) += m68k-semi.o
nwfpe-obj-y += single_cpdo.o double_cpdo.o extended_cpdo.o
obj-arm-y += $(addprefix nwfpe/, $(nwfpe-obj-y))
obj-arm-y += arm-semi.o
obj-m68k-y += m68k-sim.o m68k-semi.o
obj-y += $(addprefix ../, $(universal-obj-y)) obj-y += $(addprefix ../, $(universal-obj-y))
obj-y += $(addprefix ../libuser/, $(user-obj-y)) obj-y += $(addprefix ../libuser/, $(user-obj-y))
@ -152,13 +140,10 @@ endif #CONFIG_LINUX_USER
ifdef CONFIG_BSD_USER ifdef CONFIG_BSD_USER
$(call set-vpath, $(SRC_PATH)/bsd-user)
QEMU_CFLAGS+=-I$(SRC_PATH)/bsd-user -I$(SRC_PATH)/bsd-user/$(TARGET_ARCH) QEMU_CFLAGS+=-I$(SRC_PATH)/bsd-user -I$(SRC_PATH)/bsd-user/$(TARGET_ARCH)
obj-y = main.o bsdload.o elfload.o mmap.o signal.o strace.o syscall.o \ obj-y += bsd-user/
gdbstub.o uaccess.o user-exec.o obj-y += gdbstub.o user-exec.o
obj-i386-y += ioport-user.o obj-i386-y += ioport-user.o
obj-y += $(addprefix ../, $(universal-obj-y)) obj-y += $(addprefix ../, $(universal-obj-y))
@ -408,6 +393,9 @@ endif # CONFIG_LINUX_USER
obj-$(CONFIG_GDBSTUB_XML) += gdbstub-xml.o obj-$(CONFIG_GDBSTUB_XML) += gdbstub-xml.o
nested-vars = obj-y
dummy := $(call unnest-vars)
ifdef QEMU_PROGW ifdef QEMU_PROGW
# The linker builds a windows executable. Make also a console executable. # The linker builds a windows executable. Make also a console executable.
$(QEMU_PROGW): $(obj-y) $(obj-$(TARGET_BASE_ARCH)-y) $(QEMU_PROGW): $(obj-y) $(obj-$(TARGET_BASE_ARCH)-y)

2
bsd-user/Makefile.objs Normal file
View File

@ -0,0 +1,2 @@
obj-y = main.o bsdload.o elfload.o mmap.o signal.o strace.o syscall.o \
uaccess.o

8
configure vendored
View File

@ -3520,8 +3520,14 @@ mkdir -p $target_dir/ide
mkdir -p $target_dir/usb mkdir -p $target_dir/usb
mkdir -p $target_dir/9pfs mkdir -p $target_dir/9pfs
mkdir -p $target_dir/kvm mkdir -p $target_dir/kvm
if test "$target_linux_user" = yes; then
mkdir -p $target_dir/linux-user
fi
if test "$target_bsd_user" = yes; then
mkdir -p $target_dir/bsd-user
fi
if test "$target" = "arm-linux-user" -o "$target" = "armeb-linux-user" -o "$target" = "arm-bsd-user" -o "$target" = "armeb-bsd-user" ; then if test "$target" = "arm-linux-user" -o "$target" = "armeb-linux-user" -o "$target" = "arm-bsd-user" -o "$target" = "armeb-bsd-user" ; then
mkdir -p $target_dir/nwfpe mkdir -p $target_dir/linux-user/arm/nwfpe
fi fi
symlink "$source_path/Makefile.target" "$target_dir/Makefile" symlink "$source_path/Makefile.target" "$target_dir/Makefile"

7
linux-user/Makefile.objs Normal file
View File

@ -0,0 +1,7 @@
obj-y = main.o syscall.o strace.o mmap.o signal.o \
elfload.o linuxload.o uaccess.o cpu-uname.o
obj-$(TARGET_HAS_BFLT) += flatload.o
obj-$(TARGET_I386) += vm86.o
obj-$(TARGET_ARM) += arm/nwfpe/
obj-$(TARGET_M68K) += m68k-sim.o

View File

@ -0,0 +1,2 @@
obj-y = fpa11.o fpa11_cpdo.o fpa11_cpdt.o fpa11_cprt.o fpopcode.o
obj-y += single_cpdo.o double_cpdo.o extended_cpdo.o