tests/tcg: disentangle makefiles
v2 cover tests/tcg: disentangle makefiles
The tests/tcg rely a lot on per-target informations from the QEMU makefiles, but most of the definitions in there aren't really relevant to TCG tests.
This series is just a cleanup, but it could also be a useful start in making it possible to compile tests/tcg out of QEMU's tree, and/or making it a submodule, and/or unifying the system emulation tests with kvm-unit-tests.
Paolo
v1->v2: fix configure from fresh directory, do not use $SHELL
Paolo Bonzini (3):
tests/tcg: use EXTRA_CFLAGS everywhere tests/tcg: cleanup Makefile inclusions tests/tcg: move configuration to a sub-shell script
Makefile | 1 +
Makefile.target | 3 -
configure | 155 ++-------------
tests/Makefile.include | 25 +--
tests/tcg/Makefile.include | 88 ---------
tests/tcg/Makefile.prereqs | 18 ++
tests/tcg/Makefile.probe | 31 ---
tests/tcg/Makefile.qemu | 95 +++++++++
tests/tcg/{Makefile => Makefile.target} | 15 +-
tests/tcg/aarch64/Makefile.include | 8 -
tests/tcg/aarch64/Makefile.softmmu-target | 4 +-
tests/tcg/aarch64/Makefile.target | 12 +-
tests/tcg/alpha/Makefile.include | 2 -
tests/tcg/alpha/Makefile.softmmu-target | 4 +-
tests/tcg/arm/Makefile.include | 8 -
tests/tcg/arm/Makefile.softmmu-target | 6 +-
tests/tcg/configure.sh | 228 ++++++++++++++++++++++
tests/tcg/cris/Makefile.include | 6 -
tests/tcg/hppa/Makefile.include | 2 -
tests/tcg/i386/Makefile.include | 9 -
tests/tcg/i386/Makefile.softmmu-target | 12 +-
tests/tcg/i386/Makefile.target | 13 +-
tests/tcg/m68k/Makefile.include | 2 -
tests/tcg/minilib/Makefile.target | 2 +-
tests/tcg/mips/Makefile.include | 20 --
tests/tcg/ppc/Makefile.include | 10 -
tests/tcg/riscv/Makefile.include | 10 -
tests/tcg/s390x/Makefile.include | 2 -
tests/tcg/sh4/Makefile.include | 4 -
tests/tcg/sparc64/Makefile.include | 2 -
tests/tcg/x86_64/Makefile.softmmu-target | 36 ++++
tests/tcg/x86_64/Makefile.target | 7 +-
tests/tcg/xtensa/Makefile.include | 11 --
tests/tcg/xtensa/Makefile.softmmu-target | 4 +-
34 files changed, 435 insertions(+), 420 deletions(-)
delete mode 100644 tests/tcg/Makefile.include
create mode 100644 tests/tcg/Makefile.prereqs
delete mode 100644 tests/tcg/Makefile.probe
create mode 100644 tests/tcg/Makefile.qemu
rename tests/tcg/{Makefile => Makefile.target} (90%)
delete mode 100644 tests/tcg/aarch64/Makefile.include
delete mode 100644 tests/tcg/alpha/Makefile.include
delete mode 100644 tests/tcg/arm/Makefile.include
create mode 100644 tests/tcg/configure.sh
delete mode 100644 tests/tcg/cris/Makefile.include
delete mode 100644 tests/tcg/hppa/Makefile.include
delete mode 100644 tests/tcg/i386/Makefile.include
delete mode 100644 tests/tcg/m68k/Makefile.include
delete mode 100644 tests/tcg/mips/Makefile.include
delete mode 100644 tests/tcg/ppc/Makefile.include
delete mode 100644 tests/tcg/riscv/Makefile.include
delete mode 100644 tests/tcg/s390x/Makefile.include
delete mode 100644 tests/tcg/sh4/Makefile.include
delete mode 100644 tests/tcg/sparc64/Makefile.include
create mode 100644 tests/tcg/x86_64/Makefile.softmmu-target
delete mode 100644 tests/tcg/xtensa/Makefile.includeSignature · 1 line
2.21.0
PATCH v2 1/3 tests/tcg: use EXTRA_CFLAGS everywhere
For i386 specifically, this allows using the host GCC to compile the i386 tests. But, it should really be done for all targets, unless we want to pass $(EXTRA_CFLAGS) directly as part of $(CC).
--- tests/tcg/aarch64/Makefile.softmmu-target | 4 ++-- tests/tcg/alpha/Makefile.softmmu-target | 4 ++-- tests/tcg/arm/Makefile.softmmu-target | 2 +- tests/tcg/i386/Makefile.softmmu-target | 4 ++-- tests/tcg/minilib/Makefile.target | 2 +- tests/tcg/xtensa/Makefile.softmmu-target | 4 ++-- 6 files changed, 10 insertions(+), 10 deletions(-)
tests/tcg/aarch64/Makefile.softmmu-target +2 -2
@@ -22,11 +22,11 @@ LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -x assembler-with-cpp -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -x assembler-with-cpp -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=1
tests/tcg/alpha/Makefile.softmmu-target +2 -2
@@ -22,11 +22,11 @@ LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -x assembler-with-cpp -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -x assembler-with-cpp -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=0
tests/tcg/arm/Makefile.softmmu-target +1 -1
@@ -18,7 +18,7 @@ CFLAGS+=-Wl,--build-id=none -x assembler-with-cpp LDFLAGS+=-nostdlib -N -static %: %.S %.ld - $(CC) $(CFLAGS) $(ASFLAGS) $< -o $@ $(LDFLAGS) -T $(ARM_SRC)/[email protected] + $(CC) $(CFLAGS) $(ASFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) -T $(ARM_SRC)/[email protected] # Specific Test Rules
tests/tcg/i386/Makefile.softmmu-target +2 -2
@@ -32,11 +32,11 @@ TESTS+=$(MULTIARCH_TESTS) .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=1
tests/tcg/minilib/Makefile.target +1 -1
@@ -18,4 +18,4 @@ MINILIB_INC=-isystem $(SYSTEM_MINILIB_SRC) .PRECIOUS: $(MINILIB_OBJS) %.o: $(SYSTEM_MINILIB_SRC)/%.c - $(CC) $(CFLAGS) -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c $< -o $@
tests/tcg/xtensa/Makefile.softmmu-target +2 -2
@@ -34,9 +34,9 @@ $(XTENSA_USABLE_TESTS): linker.ld macros.inc $(CRT) Makefile.softmmu-target # special rule for common blobs %.o: %.S - $(CC) $(XTENSA_INC) $($*_ASFLAGS) $(ASFLAGS) -c $< -o $@ + $(CC) $(XTENSA_INC) $($*_ASFLAGS) $(ASFLAGS) $(EXTRA_CFLAGS) -c $< -o $@ %: %.S - $(CC) $(XTENSA_INC) $(ASFLAGS) $< -o $@ $(LDFLAGS) $(NOSTDFLAGS) $(CRT) + $(CC) $(XTENSA_INC) $(ASFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) $(NOSTDFLAGS) $(CRT) endif
Signature · 1 line
2.21.0
Re: [Qemu-devel] [PATCH v2 1/3] tests/tcg: use EXTRA_CFLAGS everywhere
Quoted 6 lines · Paolo Bonzini
For i386 specifically, this allows using the host GCC to compile the i386 tests. But, it should really be done for all targets, unless we want to pass $(EXTRA_CFLAGS) directly as part of $(CC).
Signed-off-by Paolo Bonzini <[email protected]>
Quoted 92 lines
--- tests/tcg/aarch64/Makefile.softmmu-target | 4 ++-- tests/tcg/alpha/Makefile.softmmu-target | 4 ++-- tests/tcg/arm/Makefile.softmmu-target | 2 +- tests/tcg/i386/Makefile.softmmu-target | 4 ++-- tests/tcg/minilib/Makefile.target | 2 +- tests/tcg/xtensa/Makefile.softmmu-target | 4 ++-- 6 files changed, 10 insertions(+), 10 deletions(-)tests/tcg/aarch64/Makefile.softmmu-target +2
-2@@ -22,11 +22,11 @@ LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -x assembler-with-cpp -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -x assembler-with-cpp -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=1tests/tcg/alpha/Makefile.softmmu-target +2
-2@@ -22,11 +22,11 @@ LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -x assembler-with-cpp -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -x assembler-with-cpp -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=0tests/tcg/arm/Makefile.softmmu-target +1
-1@@ -18,7 +18,7 @@ CFLAGS+=-Wl,--build-id=none -x assembler-with-cpp LDFLAGS+=-nostdlib -N -static %: %.S %.ld - $(CC) $(CFLAGS) $(ASFLAGS) $< -o $@ $(LDFLAGS) -T $(ARM_SRC)/[email protected] + $(CC) $(CFLAGS) $(ASFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) -T $(ARM_SRC)/[email protected] # Specific Test Rulestests/tcg/i386/Makefile.softmmu-target +2
-2@@ -32,11 +32,11 @@ TESTS+=$(MULTIARCH_TESTS) .PRECIOUS: $(CRT_OBJS) %.o: $(CRT_PATH)/%.S - $(CC) $(CFLAGS) -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c $< -o $@ # Build and link the tests %: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) - $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) memory: CFLAGS+=-DCHECK_UNALIGNED=1tests/tcg/minilib/Makefile.target +1
-1@@ -18,4 +18,4 @@ MINILIB_INC=-isystem $(SYSTEM_MINILIB_SRC) .PRECIOUS: $(MINILIB_OBJS) %.o: $(SYSTEM_MINILIB_SRC)/%.c - $(CC) $(CFLAGS) -c $< -o $@ + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c $< -o $@tests/tcg/xtensa/Makefile.softmmu-target +0
-0@@ -34,9 +34,9 @@ $(XTENSA_USABLE_TESTS): linker.ld macros.inc $(CRT) Makefile.softmmu-target
tests/tcg/xtensa/Makefile.softmmu-target $(XTENSA_USABLE_TESTS): linker.ld macros.inc $(CRT) Makefile.softmmu-target · line 42
Quoted 10 lines
tests/tcg/xtensa/Makefile.softmmu-target +2
-2# special rule for common blobs %.o: %.S - $(CC) $(XTENSA_INC) $($*_ASFLAGS) $(ASFLAGS) -c $< -o $@ + $(CC) $(XTENSA_INC) $($*_ASFLAGS) $(ASFLAGS) $(EXTRA_CFLAGS) -c $< -o $@ %: %.S - $(CC) $(XTENSA_INC) $(ASFLAGS) $< -o $@ $(LDFLAGS) $(NOSTDFLAGS) $(CRT) + $(CC) $(XTENSA_INC) $(ASFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) $(NOSTDFLAGS) $(CRT) endif
--
Alex Bennée
PATCH v2 2/3 tests/tcg: cleanup Makefile inclusions
In reply to Paolo BonziniRename Makefile.probe to Makefile.prereqs and make it actually define rules for the tests.
Rename Makefile to Makefile.target, since it is not a toplevel makefile.
Rename Makefile.include to Makefile.qemu and disentangle it from the QEMU Makefile.target, so that it is invoked recursively by tests/Makefile.include. Tests are now placed in tests/tcg/$(TARGET).
Drop the usage of TARGET_BASE_ARCH, which is ignored by everything except x86_64 and aarch64. Fix x86 tests by using -cpu max and, while at it, standardize on QEMU_OPTS for aarch64 tests too.
---
Makefile.target | 3 --
tests/Makefile.include | 23 +++++----
.../tcg/{Makefile.probe => Makefile.prereqs} | 5 +-
tests/tcg/{Makefile.include => Makefile.qemu} | 48 +++++++++++--------
tests/tcg/{Makefile => Makefile.target} | 13 ++---
tests/tcg/aarch64/Makefile.target | 12 +++--
tests/tcg/arm/Makefile.softmmu-target | 4 --
tests/tcg/i386/Makefile.softmmu-target | 8 ----
tests/tcg/i386/Makefile.target | 13 ++---
tests/tcg/x86_64/Makefile.softmmu-target | 36 ++++++++++++++
tests/tcg/x86_64/Makefile.target | 7 +--
11 files changed, 100 insertions(+), 72 deletions(-)
rename tests/tcg/{Makefile.probe => Makefile.prereqs} (92%)
rename tests/tcg/{Makefile.include => Makefile.qemu} (52%)
rename tests/tcg/{Makefile => Makefile.target} (92%)
create mode 100644 tests/tcg/x86_64/Makefile.softmmu-targetMakefile.target +0 -3
@@ -39,9 +39,6 @@ endif PROGS=$(QEMU_PROG) $(QEMU_PROGW) STPFILES= -# Makefile Tests -include $(SRC_PATH)/tests/tcg/Makefile.include - config-target.h: config-target.h-timestamp config-target.h-timestamp: config-target.mak
tests/Makefile.include +14 -9
@@ -1061,23 +1061,28 @@ RUN_TCG_TARGET_RULES=$(patsubst %,run-tcg-tests-%, $(TARGET_DIRS)) ifeq ($(HAVE_USER_DOCKER),y) # Probe for the Docker Builds needed for each build $(foreach PROBE_TARGET,$(TARGET_DIRS), \ - $(eval -include $(SRC_PATH)/tests/tcg/Makefile.probe) \ - $(if $(DOCKER_PREREQ), \ - $(eval build-tcg-tests-$(PROBE_TARGET): $(DOCKER_PREREQ)))) + $(eval -include $(SRC_PATH)/tests/tcg/Makefile.prereqs)) endif build-tcg-tests-%: - $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)" \ - SKIP_DOCKER_BUILD=1 TARGET_DIR="$*/" guest-tests, \ + $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ + -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ + SRC_PATH=$(SRC_PATH) \ + V="$(V)" TARGET_DIR="$*/" guest-tests, \ "BUILD", "TCG tests for $*") -run-tcg-tests-%: % build-tcg-tests-% - $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)" \ - SKIP_DOCKER_BUILD=1 TARGET_DIR="$*/" run-guest-tests, \ +run-tcg-tests-%: build-tcg-tests-% %/all + $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ + -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ + SRC_PATH=$(SRC_PATH) SPEED="$(SPEED)" \ + V="$(V)" TARGET_DIR="$*/" run-guest-tests, \ "RUN", "TCG tests for $*") clean-tcg-tests-%: - $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)" TARGET_DIR="$*/" clean-guest-tests,) + $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ + -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ + SRC_PATH=$(SRC_PATH) TARGET_DIR="$*/" clean-guest-tests, \ + "RUN", "TCG tests for $*") .PHONY: build-tcg build-tcg: $(BUILD_TCG_TARGET_RULES)
tests/tcg/Makefile.prereqs renamed from tests/tcg/Makefile.probe +2 -3
@@ -8,20 +8,19 @@ # each target. # First we need the target makefile which tells us the target architecture +CROSS_CC_GUEST:= -include $(BUILD_DIR)/$(PROBE_TARGET)/config-target.mak # Then we load up the target architecture makefiles which tell us # about the compilers -CROSS_CC_GUEST:= DOCKER_IMAGE:= -DOCKER_PREREQ:= -include $(SRC_PATH)/tests/tcg/$(TARGET_BASE_ARCH)/Makefile.include -include $(SRC_PATH)/tests/tcg/$(TARGET_NAME)/Makefile.include ifndef CROSS_CC_GUEST ifneq ($(DOCKER_IMAGE),) -DOCKER_PREREQ:=docker-image-$(DOCKER_IMAGE) +build-tcg-tests-$(PROBE_TARGET): docker-image-$(DOCKER_IMAGE) endif endif
tests/tcg/Makefile.qemu renamed from tests/tcg/Makefile.include +28 -20
104 lines not on this page · raw message
tests/tcg/Makefile.target renamed from tests/tcg/Makefile +4 -9
@@ -29,8 +29,9 @@ # We also expect to be in the tests build dir for the FOO-(linux-user|softmmu). # +all: -include ../../config-host.mak --include ../config-target.mak +-include ../../../$(TARGET_DIR)/config-target.mak # for including , in command strings COMMA := ,
@@ -64,9 +65,9 @@ LDFLAGS= # The QEMU for this TARGET ifdef CONFIG_USER_ONLY -QEMU=../qemu-$(TARGET_NAME) +QEMU=../../../$(TARGET_DIR)/qemu-$(TARGET_NAME) else -QEMU=../qemu-system-$(TARGET_NAME) +QEMU=../../../$(TARGET_DIR)/qemu-system-$(TARGET_NAME) endif QEMU_OPTS=
@@ -82,10 +83,7 @@ ifdef CONFIG_USER_ONLY # The order we include is important. We include multiarch, base arch # and finally arch if it's not the same as base arch. -include $(SRC_PATH)/tests/tcg/multiarch/Makefile.target --include $(SRC_PATH)/tests/tcg/$(TARGET_BASE_ARCH)/Makefile.target -ifneq ($(TARGET_BASE_ARCH),$(TARGET_NAME)) -include $(SRC_PATH)/tests/tcg/$(TARGET_NAME)/Makefile.target -endif # Add the common build options CFLAGS+=-Wall -O0 -g -fno-strict-aliasing
@@ -101,10 +99,7 @@ else # are expected to provide their own build recipes. -include $(SRC_PATH)/tests/tcg/minilib/Makefile.target -include $(SRC_PATH)/tests/tcg/multiarch/system/Makefile.softmmu-target --include $(SRC_PATH)/tests/tcg/$(TARGET_BASE_ARCH)/Makefile.softmmu-target -ifneq ($(TARGET_BASE_ARCH),$(TARGET_NAME)) -include $(SRC_PATH)/tests/tcg/$(TARGET_NAME)/Makefile.softmmu-target -endif endif
tests/tcg/aarch64/Makefile.target +7 -5
@@ -2,12 +2,14 @@ # # AArch64 specific tweaks +ARM_SRC=$(SRC_PATH)/tests/tcg/arm +VPATH += $(ARM_SRC) + AARCH64_SRC=$(SRC_PATH)/tests/tcg/aarch64 VPATH += $(AARCH64_SRC) -# we don't build any of the ARM tests -AARCH64_TESTS=$(filter-out $(ARM_TESTS), $(TESTS)) -AARCH64_TESTS+=fcvt +# we don't build any other ARM test +AARCH64_TESTS=fcvt fcvt: LDFLAGS+=-lm
@@ -16,6 +18,6 @@ run-fcvt: fcvt $(call diff-out,$<,$(AARCH64_SRC)/fcvt.ref) AARCH64_TESTS += pauth-1 pauth-2 -run-pauth-%: QEMU += -cpu max +run-pauth-%: QEMU_OPTS += -cpu max -TESTS:=$(AARCH64_TESTS) +TESTS += $(AARCH64_TESTS)
tests/tcg/arm/Makefile.softmmu-target +0 -4
@@ -3,8 +3,6 @@ # ARM SoftMMU tests - included from tests/tcg/Makefile # -ifeq ($(TARGET_ABI_DIR),arm) - ARM_SRC=$(SRC_PATH)/tests/tcg/arm # Set search path for all sources
@@ -25,5 +23,3 @@ LDFLAGS+=-nostdlib -N -static test-armv6m-undef: EXTRA_CFLAGS+=-mcpu=cortex-m0 run-test-armv6m-undef: QEMU_OPTS+=-semihosting -M microbit -kernel - -endif
tests/tcg/i386/Makefile.softmmu-target +0 -8
@@ -12,17 +12,9 @@ X64_SYSTEM_SRC=$(SRC_PATH)/tests/tcg/x86_64/system # These objects provide the basic boot code and helper functions for all tests CRT_OBJS=boot.o -ifeq ($(TARGET_X86_64), y) -CRT_PATH=$(X64_SYSTEM_SRC) -CFLAGS=-march=x86-64 -LINK_SCRIPT=$(X64_SYSTEM_SRC)/kernel.ld -LDFLAGS=-Wl,-T$(LINK_SCRIPT) -Wl,-melf_x86_64 -else CRT_PATH=$(I386_SYSTEM_SRC) -CFLAGS+=-m32 LINK_SCRIPT=$(I386_SYSTEM_SRC)/kernel.ld LDFLAGS=-Wl,-T$(LINK_SCRIPT) -Wl,-melf_i386 -endif CFLAGS+=-nostdlib -ggdb -O0 $(MINILIB_INC) LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc
tests/tcg/i386/Makefile.target +5 -8
@@ -6,14 +6,11 @@ I386_SRC=$(SRC_PATH)/tests/tcg/i386 VPATH += $(I386_SRC) I386_SRCS=$(notdir $(wildcard $(I386_SRC)/*.c)) -I386_TESTS=$(I386_SRCS:.c=) -I386_ONLY_TESTS=$(filter-out test-i386-ssse3, $(I386_TESTS)) +ALL_X86_TESTS=$(I386_SRCS:.c=) +I386_TESTS:=$(filter-out test-i386-ssse3, $(ALL_X86_TESTS)) +X86_64_TESTS:=$(filter test-i386-ssse3, $(ALL_X86_TESTS)) # Update TESTS -TESTS+=$(I386_ONLY_TESTS) - -ifneq ($(TARGET_NAME),x86_64) -CFLAGS+=-m32 -endif +TESTS=$(MULTIARCH_TESTS) $(I386_TESTS) # # hello-i386 is a barebones app
@@ -26,7 +23,7 @@ hello-i386: LDFLAGS+=-nostdlib # test-i386: test-i386.c test-i386-code16.S test-i386-vm86.S test-i386.h test-i386-shift.h test-i386-muldiv.h - $(CC) $(CFLAGS) $(LDFLAGS) -o $@ \ + $(CC) $(CFLAGS) $(LDFLAGS) $(EXTRA_CFLAGS) -o $@ \ $(<D)/test-i386.c $(<D)/test-i386-code16.S $(<D)/test-i386-vm86.S -lm ifeq ($(SPEED), slow)
tests/tcg/x86_64/Makefile.softmmu-target new file +36 -0
@@ -0,0 +1,36 @@ +# +# x86 system tests +# +# This currently builds only for i386. The common C code is built +# with standard compiler flags however so we can support both by +# adding additional boot files for x86_64. +# + +I386_SYSTEM_SRC=$(SRC_PATH)/tests/tcg/i386/system +X64_SYSTEM_SRC=$(SRC_PATH)/tests/tcg/x86_64/system + +# These objects provide the basic boot code and helper functions for all tests +CRT_OBJS=boot.o + +CRT_PATH=$(X64_SYSTEM_SRC) +LINK_SCRIPT=$(X64_SYSTEM_SRC)/kernel.ld +LDFLAGS=-Wl,-T$(LINK_SCRIPT) -Wl,-melf_x86_64 +CFLAGS+=-nostdlib -ggdb -O0 $(MINILIB_INC) +LDFLAGS+=-static -nostdlib $(CRT_OBJS) $(MINILIB_OBJS) -lgcc + +TESTS+=$(MULTIARCH_TESTS) + +# building head blobs +.PRECIOUS: $(CRT_OBJS) + +%.o: $(CRT_PATH)/%.S + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c $< -o $@ + +# Build and link the tests +%: %.c $(LINK_SCRIPT) $(CRT_OBJS) $(MINILIB_OBJS) + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< -o $@ $(LDFLAGS) + +memory: CFLAGS+=-DCHECK_UNALIGNED=1 + +# Running +QEMU_OPTS+=-device isa-debugcon,chardev=output -device isa-debug-exit,iobase=0xf4,iosize=0x4 -kernel
tests/tcg/x86_64/Makefile.target +4 -3
@@ -6,9 +6,10 @@ # $(SRC)/tests/tcg/i386/ # -X86_64_TESTS=$(filter-out $(I386_ONLY_TESTS), $(TESTS)) -X86_64_TESTS+=test-x86_64 -TESTS:=$(X86_64_TESTS) +include $(SRC_PATH)/tests/tcg/i386/Makefile.target + +TESTS=$(MULTIARCH_TESTS) $(X86_64_TESTS) test-x86_64 +QEMU_OPTS += -cpu max test-x86_64: LDFLAGS+=-lm -lc test-x86_64: test-i386.c test-i386.h test-i386-shift.h test-i386-muldiv.h
Signature · 1 line
2.21.0
PATCH v2 3/3 tests/tcg: move configuration to a sub-shell script
In reply to Paolo BonziniAvoid the repeated inclusions of config-target.mak, which have risks of namespace pollution, and instead build minimal configuration files in a configuration script. The same configuration files can also be included in Makefile and Makefile.qemu
--- Makefile | 1 + configure | 155 ++------------------ tests/Makefile.include | 8 +- tests/tcg/Makefile.prereqs | 18 +-- tests/tcg/Makefile.qemu | 51 ++++--- tests/tcg/Makefile.target | 8 +- tests/tcg/aarch64/Makefile.include | 8 - tests/tcg/alpha/Makefile.include | 2 - tests/tcg/arm/Makefile.include | 8 - tests/tcg/configure.sh | 228 +++++++++++++++++++++++++++++ tests/tcg/cris/Makefile.include | 6 - tests/tcg/hppa/Makefile.include | 2 - tests/tcg/i386/Makefile.include | 9 -- tests/tcg/m68k/Makefile.include | 2 - tests/tcg/mips/Makefile.include | 20 --- tests/tcg/ppc/Makefile.include | 10 -- tests/tcg/riscv/Makefile.include | 10 -- tests/tcg/s390x/Makefile.include | 2 - tests/tcg/sh4/Makefile.include | 4 - tests/tcg/sparc64/Makefile.include | 2 - tests/tcg/xtensa/Makefile.include | 11 -- 21 files changed, 276 insertions(+), 289 deletions(-) delete mode 100644 tests/tcg/aarch64/Makefile.include delete mode 100644 tests/tcg/alpha/Makefile.include delete mode 100644 tests/tcg/arm/Makefile.include create mode 100644 tests/tcg/configure.sh delete mode 100644 tests/tcg/cris/Makefile.include delete mode 100644 tests/tcg/hppa/Makefile.include delete mode 100644 tests/tcg/i386/Makefile.include delete mode 100644 tests/tcg/m68k/Makefile.include delete mode 100644 tests/tcg/mips/Makefile.include delete mode 100644 tests/tcg/ppc/Makefile.include delete mode 100644 tests/tcg/riscv/Makefile.include delete mode 100644 tests/tcg/s390x/Makefile.include delete mode 100644 tests/tcg/sh4/Makefile.include delete mode 100644 tests/tcg/sparc64/Makefile.include delete mode 100644 tests/tcg/xtensa/Makefile.include
Makefile +1 -0
@@ -718,6 +718,7 @@ endef distclean: clean rm -f config-host.mak config-host.h* config-host.ld $(DOCS) qemu-options.texi qemu-img-cmds.texi qemu-monitor.texi qemu-monitor-info.texi + rm -f tests/tcg/config-*.mak rm -f config-all-devices.mak config-all-disas.mak config.status rm -f $(SUBDIR_DEVICES_MAK) rm -f po/*.mo tests/qemu-iotests/common.env
configure +15 -140
430 lines not on this page · raw message
tests/Makefile.include +3 -5
@@ -1058,30 +1058,28 @@ BUILD_TCG_TARGET_RULES=$(patsubst %,build-tcg-tests-%, $(TARGET_DIRS)) CLEAN_TCG_TARGET_RULES=$(patsubst %,clean-tcg-tests-%, $(TARGET_DIRS)) RUN_TCG_TARGET_RULES=$(patsubst %,run-tcg-tests-%, $(TARGET_DIRS)) -ifeq ($(HAVE_USER_DOCKER),y) # Probe for the Docker Builds needed for each build $(foreach PROBE_TARGET,$(TARGET_DIRS), \ $(eval -include $(SRC_PATH)/tests/tcg/Makefile.prereqs)) -endif build-tcg-tests-%: $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ SRC_PATH=$(SRC_PATH) \ - V="$(V)" TARGET_DIR="$*/" guest-tests, \ + V="$(V)" TARGET="$*" guest-tests, \ "BUILD", "TCG tests for $*") run-tcg-tests-%: build-tcg-tests-% %/all $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ SRC_PATH=$(SRC_PATH) SPEED="$(SPEED)" \ - V="$(V)" TARGET_DIR="$*/" run-guest-tests, \ + V="$(V)" TARGET="$*" run-guest-tests, \ "RUN", "TCG tests for $*") clean-tcg-tests-%: $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) \ -f $(SRC_PATH)/tests/tcg/Makefile.qemu \ - SRC_PATH=$(SRC_PATH) TARGET_DIR="$*/" clean-guest-tests, \ + SRC_PATH=$(SRC_PATH) TARGET="$*" clean-guest-tests, \ "RUN", "TCG tests for $*") .PHONY: build-tcg
tests/tcg/Makefile.prereqs +3 -15
@@ -7,24 +7,12 @@ # selection of required docker targets before we invoke a sub-make for # each target. -# First we need the target makefile which tells us the target architecture -CROSS_CC_GUEST:= --include $(BUILD_DIR)/$(PROBE_TARGET)/config-target.mak - -# Then we load up the target architecture makefiles which tell us -# about the compilers DOCKER_IMAGE:= --include $(SRC_PATH)/tests/tcg/$(TARGET_BASE_ARCH)/Makefile.include --include $(SRC_PATH)/tests/tcg/$(TARGET_NAME)/Makefile.include +-include $(BUILD_DIR)/tests/tcg/config-$(PROBE_TARGET).mak -ifndef CROSS_CC_GUEST ifneq ($(DOCKER_IMAGE),) build-tcg-tests-$(PROBE_TARGET): docker-image-$(DOCKER_IMAGE) +$(BUILD_DIR)/tests/tcg/config_$(PROBE_TARGET).mak: config-host.mak +config-host.mak: $(SRC_PATH)/tests/tcg/configure.sh endif -endif - -# Clean-up -# undefine TARGET_NAME -# undefine TARGET_BASE_ARCH -# undefine TARGET_ABI_DIR
tests/tcg/Makefile.qemu +25 -26
105 lines not on this page · raw message
tests/tcg/Makefile.target +1 -7
@@ -31,7 +31,7 @@ all: -include ../../config-host.mak --include ../../../$(TARGET_DIR)/config-target.mak +-include ../config-$(TARGET).mak # for including , in command strings COMMA := ,
@@ -63,12 +63,6 @@ CFLAGS= QEMU_CFLAGS= LDFLAGS= -# The QEMU for this TARGET -ifdef CONFIG_USER_ONLY -QEMU=../../../$(TARGET_DIR)/qemu-$(TARGET_NAME) -else -QEMU=../../../$(TARGET_DIR)/qemu-system-$(TARGET_NAME) -endif QEMU_OPTS=
tests/tcg/aarch64/Makefile.include deleted +0 -8
@@ -1,8 +0,0 @@ -# Makefile.include for AArch64 targets -# -# We don't have any bigendian build tools so we only use this for AArch64 - -ifeq ($(TARGET_NAME),aarch64) -DOCKER_IMAGE=debian-buster-arm64-cross -DOCKER_CROSS_COMPILER=aarch64-linux-gnu-gcc -endif
tests/tcg/alpha/Makefile.include deleted +0 -2
@@ -1,2 +0,0 @@ -DOCKER_IMAGE=debian-alpha-cross -DOCKER_CROSS_COMPILER=alpha-linux-gnu-gcc
tests/tcg/arm/Makefile.include deleted +0 -8
@@ -1,8 +0,0 @@ -# Makefile.include for all ARM targets -# -# We don't have any bigendian build tools so we only use this for armhf - -ifeq ($(TARGET_NAME),arm) -DOCKER_IMAGE=debian-armhf-cross -DOCKER_CROSS_COMPILER=arm-linux-gnueabihf-gcc -endif
tests/tcg/configure.sh new file +228 -0
228 lines not on this page · raw message
tests/tcg/cris/Makefile.include deleted +0 -6
@@ -1,6 +0,0 @@ -# -# Makefile.include for all CRIS targets -# - -DOCKER_IMAGE=fedora-cris-cross -DOCKER_CROSS_COMPILER=cris-linux-gnu-gcc
tests/tcg/hppa/Makefile.include deleted +0 -2
@@ -1,2 +0,0 @@ -DOCKER_IMAGE=debian-hppa-cross -DOCKER_CROSS_COMPILER=hppa-linux-gnu-gcc
tests/tcg/i386/Makefile.include deleted +0 -9
@@ -1,9 +0,0 @@ -# -# Makefile.include for all i386 -# -# There is enough brokeness in x86_64 compilers that we don't default -# to using the x86_64 system compiler for i386 binaries. -# - -DOCKER_IMAGE=fedora-i386-cross -DOCKER_CROSS_COMPILER=gcc
tests/tcg/m68k/Makefile.include deleted +0 -2
@@ -1,2 +0,0 @@ -DOCKER_IMAGE=debian-m68k-cross -DOCKER_CROSS_COMPILER=m68k-linux-gnu-gcc
tests/tcg/mips/Makefile.include deleted +0 -20
@@ -1,20 +0,0 @@ -# -# Makefile.include for all MIPs targets -# -# As Debian doesn't support mip64 in big endian mode the only way to -# build BE is to pass a working cross compiler to ./configure -# - -ifeq ($(TARGET_NAME),mips64el) -DOCKER_IMAGE=debian-mips64el-cross -DOCKER_CROSS_COMPILER=mips64el-linux-gnuabi64-gcc -else ifeq ($(TARGET_NAME),mips64) -DOCKER_IMAGE=debian-mips64-cross -DOCKER_CROSS_COMPILER=mips64-linux-gnuabi64-gcc -else ifeq ($(TARGET_NAME),mipsel) -DOCKER_IMAGE=debian-mipsel-cross -DOCKER_CROSS_COMPILER=mipsel-linux-gnu-gcc -else ifeq ($(TARGET_NAME),mips) -DOCKER_IMAGE=debian-mips-cross -DOCKER_CROSS_COMPILER=mips-linux-gnu-gcc -endif
tests/tcg/ppc/Makefile.include deleted +0 -10
@@ -1,10 +0,0 @@ -ifeq ($(TARGET_NAME),ppc) -DOCKER_IMAGE=debian-powerpc-cross -DOCKER_CROSS_COMPILER=powerpc-linux-gnu-gcc -else ifeq ($(TARGET_NAME),ppc64) -DOCKER_IMAGE=debian-ppc64-cross -DOCKER_CROSS_COMPILER=powerpc64-linux-gnu-gcc -else ifeq ($(TARGET_NAME),ppc64le) -DOCKER_IMAGE=debian-ppc64el-cross -DOCKER_CROSS_COMPILER=powerpc64le-linux-gnu-gcc -endif
tests/tcg/riscv/Makefile.include deleted +0 -10
@@ -1,10 +0,0 @@ -# -# Makefile.include for all RISCV targets -# -# Debian only really cares about 64 bit going forward -# - -ifeq ($(TARGET_NAME),riscv64) -DOCKER_IMAGE=debian-riscv64-cross -DOCKER_CROSS_COMPILER=riscv64-linux-gnu-gcc -endif
tests/tcg/s390x/Makefile.include deleted +0 -2
@@ -1,2 +0,0 @@ -DOCKER_IMAGE=debian-s390x-cross -DOCKER_CROSS_COMPILER=s390x-linux-gnu-gcc
tests/tcg/sh4/Makefile.include deleted +0 -4
@@ -1,4 +0,0 @@ -ifneq ($(TARGET_NAME), sh4eb) -DOCKER_IMAGE=debian-sh4-cross -DOCKER_CROSS_COMPILER=sh4-linux-gnu-gcc -endif
tests/tcg/sparc64/Makefile.include deleted +0 -2
@@ -1,2 +0,0 @@ -DOCKER_IMAGE=debian-sparc64-cross -DOCKER_CROSS_COMPILER=sparc64-linux-gnu-gcc
tests/tcg/xtensa/Makefile.include deleted +0 -11
@@ -1,11 +0,0 @@ -# Makefile.include for xtensa targets -# -# The compilers can only be used for building system tests - -ifeq ($(CONFIG_SOFTMMU),y) -DOCKER_IMAGE=debian-xtensa-cross - -# default to the dc232b cpu -DOCKER_CROSS_COMPILER=/opt/2018.02/xtensa-dc232b-elf/bin/xtensa-dc232b-elf-gcc -DOCKER_CROSS_LINKER=/opt/2018.02/xtensa-dc232b-elf/bin/xtensa-dc232b-elf-ld -endif
Signature · 1 line
2.21.0
Patchew URL: https://patchew.org/QEMU/[email protected]/
Patchew URL: https://patchew.org/QEMU/[email protected]/
Hi,
This series seems to have some coding style problems. See output below for more information:
Type: series
Subject: [Qemu-devel] [PATCH v2 0/3] tests/tcg: disentangle makefiles
Message-id: [email protected]
=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===
Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
* [new tag] patchew/[email protected] -> patchew/[email protected]
Submodule 'capstone' (https://git.qemu.org/git/capstone.git) registered for path 'capstone'
Submodule 'dtc' (https://git.qemu.org/git/dtc.git) registered for path 'dtc'
Submodule 'roms/QemuMacDrivers' (https://git.qemu.org/git/QemuMacDrivers.git) registered for path 'roms/QemuMacDrivers' Submodule 'roms/SLOF' (https://git.qemu.org/git/SLOF.git) registered for path 'roms/SLOF'
Submodule 'roms/edk2' (https://git.qemu.org/git/edk2.git) registered for path 'roms/edk2'
Submodule 'roms/ipxe' (https://git.qemu.org/git/ipxe.git) registered for path 'roms/ipxe'
Submodule 'roms/openbios' (https://git.qemu.org/git/openbios.git) registered for path 'roms/openbios'
Submodule 'roms/openhackware' (https://git.qemu.org/git/openhackware.git) registered for path 'roms/openhackware'
Submodule 'roms/opensbi' (https://git.qemu.org/git/opensbi.git) registered for path 'roms/opensbi'
Submodule 'roms/qemu-palcode' (https://git.qemu.org/git/qemu-palcode.git) registered for path 'roms/qemu-palcode'
Submodule 'roms/seabios' (https://git.qemu.org/git/seabios.git/) registered for path 'roms/seabios'
Submodule 'roms/seabios-hppa' (https://git.qemu.org/git/seabios-hppa.git) registered for path 'roms/seabios-hppa'
Submodule 'roms/sgabios' (https://git.qemu.org/git/sgabios.git) registered for path 'roms/sgabios'
Submodule 'roms/skiboot' (https://git.qemu.org/git/skiboot.git) registered for path 'roms/skiboot'
Submodule 'roms/u-boot' (https://git.qemu.org/git/u-boot.git) registered for path 'roms/u-boot'
Submodule 'roms/u-boot-sam460ex' (https://git.qemu.org/git/u-boot-sam460ex.git) registered for path 'roms/u-boot-sam460ex' Submodule 'slirp' (https://git.qemu.org/git/libslirp.git) registered for path 'slirp'
Submodule 'tests/fp/berkeley-softfloat-3' (https://git.qemu.org/git/berkeley-softfloat-3.git) registered for path 'tests/fp/berkeley-softfloat-3' Submodule 'tests/fp/berkeley-testfloat-3' (https://git.qemu.org/git/berkeley-testfloat-3.git) registered for path 'tests/fp/berkeley-testfloat-3' Submodule 'ui/keycodemapdb' (https://git.qemu.org/git/keycodemapdb.git) registered for path 'ui/keycodemapdb'
Cloning into 'capstone'...
Submodule path 'capstone': checked out '22ead3e0bfdb87516656453336160e0a37b066bf'
Cloning into 'dtc'...
Submodule path 'dtc': checked out '88f18909db731a627456f26d779445f84e449536'
Cloning into 'roms/QemuMacDrivers'...
Submodule path 'roms/QemuMacDrivers': checked out '90c488d5f4a407342247b9ea869df1c2d9c8e266'
Cloning into 'roms/SLOF'...
Submodule path 'roms/SLOF': checked out 'ba1ab360eebe6338bb8d7d83a9220ccf7e213af3'
Cloning into 'roms/edk2'...
Submodule path 'roms/edk2': checked out '20d2e5a125e34fc8501026613a71549b2a1a3e54'
Submodule 'SoftFloat' (https://github.com/ucb-bar/berkeley-softfloat-3.git) registered for path 'ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3' Submodule 'CryptoPkg/Library/OpensslLib/openssl' (https://github.com/openssl/openssl) registered for path 'CryptoPkg/Library/OpensslLib/openssl' Cloning into 'ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3'...
Submodule path 'roms/edk2/ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3': checked out 'b64af41c3276f97f0e181920400ee056b9c88037' Cloning into 'CryptoPkg/Library/OpensslLib/openssl'...
Submodule path 'roms/edk2/CryptoPkg/Library/OpensslLib/openssl': checked out '50eaac9f3337667259de725451f201e784599687' Submodule 'boringssl' (https://boringssl.googlesource.com/boringssl) registered for path 'boringssl'
Submodule 'krb5' (https://github.com/krb5/krb5) registered for path 'krb5'
Submodule 'pyca.cryptography' (https://github.com/pyca/cryptography.git) registered for path 'pyca-cryptography'
Cloning into 'boringssl'...
Submodule path 'roms/edk2/CryptoPkg/Library/OpensslLib/openssl/boringssl': checked out '2070f8ad9151dc8f3a73bffaa146b5e6937a583f' Cloning into 'krb5'...
Submodule path 'roms/edk2/CryptoPkg/Library/OpensslLib/openssl/krb5': checked out 'b9ad6c49505c96a088326b62a52568e3484f2168' Cloning into 'pyca-cryptography'...
Submodule path 'roms/edk2/CryptoPkg/Library/OpensslLib/openssl/pyca-cryptography': checked out '09403100de2f6f1cdd0d484dcb8e620f1c335c8f' Cloning into 'roms/ipxe'...
Submodule path 'roms/ipxe': checked out 'de4565cbe76ea9f7913a01f331be3ee901bb6e17'
Cloning into 'roms/openbios'...
Submodule path 'roms/openbios': checked out 'c79e0ecb84f4f1ee3f73f521622e264edd1bf174'
Cloning into 'roms/openhackware'...
Submodule path 'roms/openhackware': checked out 'c559da7c8eec5e45ef1f67978827af6f0b9546f5'
Cloning into 'roms/opensbi'...
Submodule path 'roms/opensbi': checked out 'ce228ee0919deb9957192d723eecc8aaae2697c6'
Cloning into 'roms/qemu-palcode'...
Submodule path 'roms/qemu-palcode': checked out 'bf0e13698872450164fa7040da36a95d2d4b326f'
Cloning into 'roms/seabios'...
Submodule path 'roms/seabios': checked out 'a5cab58e9a3fb6e168aba919c5669bea406573b4'
Cloning into 'roms/seabios-hppa'...
Submodule path 'roms/seabios-hppa': checked out '0f4fe84658165e96ce35870fd19fc634e182e77b'
Cloning into 'roms/sgabios'...
Submodule path 'roms/sgabios': checked out 'cbaee52287e5f32373181cff50a00b6c4ac9015a'
Cloning into 'roms/skiboot'...
Submodule path 'roms/skiboot': checked out '261ca8e779e5138869a45f174caa49be6a274501'
Cloning into 'roms/u-boot'...
Submodule path 'roms/u-boot': checked out 'd3689267f92c5956e09cc7d1baa4700141662bff'
Cloning into 'roms/u-boot-sam460ex'...
Submodule path 'roms/u-boot-sam460ex': checked out '60b3916f33e617a815973c5a6df77055b2e3a588'
Cloning into 'slirp'...
Submodule path 'slirp': checked out '126c04acbabd7ad32c2b018fe10dfac2a3bc1210'
Cloning into 'tests/fp/berkeley-softfloat-3'...
Submodule path 'tests/fp/berkeley-softfloat-3': checked out 'b64af41c3276f97f0e181920400ee056b9c88037'
Cloning into 'tests/fp/berkeley-testfloat-3'...
Submodule path 'tests/fp/berkeley-testfloat-3': checked out '5a59dcec19327396a011a17fd924aed4fec416b3'
Cloning into 'ui/keycodemapdb'...
Submodule path 'ui/keycodemapdb': checked out '6b3d716e2b6472eb7189d3220552280ef3d832ce'
Switched to a new branch 'test'
c097388 tests/tcg: move configuration to a sub-shell script
1659ab5 tests/tcg: cleanup Makefile inclusions
23b7902 tests/tcg: use EXTRA_CFLAGS everywhere
=== OUTPUT BEGIN ===
1/3 Checking commit 23b790280abb (tests/tcg: use EXTRA_CFLAGS everywhere) 2/3 Checking commit 1659ab5fbe5e (tests/tcg: cleanup Makefile inclusions)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating? #83:
rename from tests/tcg/Makefile.probe
total: 0 errors, 1 warnings, 341 lines checked
Patch 2/3 has style problems, please review. If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
3/3 Checking commit c097388110e2 (tests/tcg: move configuration to a sub-shell script)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating? #690:
deleted file mode 100644
WARNING: line over 80 characters
#909: FILE: tests/tcg/configure.sh:179:
+ echo "# Automatically generated by configure - do not modify" > $config_target_mak
ERROR: line over 90 characters
#936: FILE: tests/tcg/configure.sh:206:
+ if ! do_compiler "$target_compiler" $target_compiler_cflags -o $TMPE $TMPC -static ; then
WARNING: line over 80 characters
#938: FILE: tests/tcg/configure.sh:208:
+ if ! do_compiler "$target_compiler" $target_compiler_cflags -o $TMPE $TMPC ; then
WARNING: line over 80 characters
#949: FILE: tests/tcg/configure.sh:219:
+ if test $got_cross_cc = no && test "$docker" != no && test -n "$docker_image"; then
total: 1 errors, 4 warnings, 845 lines checked
Patch 3/3 has style problems, please review. If any of these errors are false positives report them to the maintainer, see CHECKPATCH in MAINTAINERS.
=== OUTPUT END ===
Test command exited with code: 1
The full log is available at
http://patchew.org/logs/[email protected]/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to [email protected]
Ping?
Paolo
Il mer 7 ago 2019, 16:35 Paolo Bonzini <[email protected]> ha scritto:
Quoted 79 lines
The tests/tcg rely a lot on per-target informations from the QEMU makefiles, but most of the definitions in there aren't really relevant to TCG tests.
This series is just a cleanup, but it could also be a useful start in making it possible to compile tests/tcg out of QEMU's tree, and/or making it a submodule, and/or unifying the system emulation tests with kvm-unit-tests.
Paolo
v1->v2: fix configure from fresh directory, do not use $SHELLPaolo Bonzini (3):
tests/tcg: useEXTRA_CFLAGSeverywhere tests/tcg: cleanupMakefileinclusions tests/tcg: move configuration to a sub-shell scriptMakefile | 1 + Makefile.target | 3 - configure | 155 ++------------- tests/Makefile.include | 25 +-- tests/tcg/Makefile.include | 88 --------- tests/tcg/Makefile.prereqs | 18 ++ tests/tcg/Makefile.probe | 31 --- tests/tcg/Makefile.qemu | 95 +++++++++ tests/tcg/{Makefile => Makefile.target} | 15 +- tests/tcg/aarch64/Makefile.include | 8 - tests/tcg/aarch64/Makefile.softmmu-target | 4 +- tests/tcg/aarch64/Makefile.target | 12 +- tests/tcg/alpha/Makefile.include | 2 - tests/tcg/alpha/Makefile.softmmu-target | 4 +- tests/tcg/arm/Makefile.include | 8 - tests/tcg/arm/Makefile.softmmu-target | 6 +- tests/tcg/configure.sh | 228 ++++++++++++++++++++++ tests/tcg/cris/Makefile.include | 6 - tests/tcg/hppa/Makefile.include | 2 - tests/tcg/i386/Makefile.include | 9 - tests/tcg/i386/Makefile.softmmu-target | 12 +- tests/tcg/i386/Makefile.target | 13 +- tests/tcg/m68k/Makefile.include | 2 - tests/tcg/minilib/Makefile.target | 2 +- tests/tcg/mips/Makefile.include | 20 -- tests/tcg/ppc/Makefile.include | 10 - tests/tcg/riscv/Makefile.include | 10 - tests/tcg/s390x/Makefile.include | 2 - tests/tcg/sh4/Makefile.include | 4 - tests/tcg/sparc64/Makefile.include | 2 - tests/tcg/x86_64/Makefile.softmmu-target | 36 ++++ tests/tcg/x86_64/Makefile.target | 7 +- tests/tcg/xtensa/Makefile.include | 11 -- tests/tcg/xtensa/Makefile.softmmu-target | 4 +- 34 files changed, 435 insertions(+), 420 deletions(-) delete mode 100644 tests/tcg/Makefile.include create mode 100644 tests/tcg/Makefile.prereqs delete mode 100644 tests/tcg/Makefile.probe create mode 100644 tests/tcg/Makefile.qemu rename tests/tcg/{Makefile => Makefile.target} (90%) delete mode 100644 tests/tcg/aarch64/Makefile.include delete mode 100644 tests/tcg/alpha/Makefile.include delete mode 100644 tests/tcg/arm/Makefile.include create mode 100644 tests/tcg/configure.sh delete mode 100644 tests/tcg/cris/Makefile.include delete mode 100644 tests/tcg/hppa/Makefile.include delete mode 100644 tests/tcg/i386/Makefile.include delete mode 100644 tests/tcg/m68k/Makefile.include delete mode 100644 tests/tcg/mips/Makefile.include delete mode 100644 tests/tcg/ppc/Makefile.include delete mode 100644 tests/tcg/riscv/Makefile.include delete mode 100644 tests/tcg/s390x/Makefile.include delete mode 100644 tests/tcg/sh4/Makefile.include delete mode 100644 tests/tcg/sparc64/Makefile.include create mode 100644 tests/tcg/x86_64/Makefile.softmmu-target delete mode 100644 tests/tcg/xtensa/Makefile.include--
2.21.0
Quoted 1 line · Paolo Bonzini
Ping?
Sorry I should have said I've queued it to testing/next. I'll post the series shortly after I've squashed the last annoying python 3.<>6 problem.
Quoted 85 lines
Paolo
Il mer 7 ago 2019, 16:35 Paolo Bonzini <[email protected]> ha scritto:
Quoted 79 lines
The tests/tcg rely a lot on per-target informations from the QEMU makefiles, but most of the definitions in there aren't really relevant to TCG tests.
This series is just a cleanup, but it could also be a useful start in making it possible to compile tests/tcg out of QEMU's tree, and/or making it a submodule, and/or unifying the system emulation tests with kvm-unit-tests.
Paolo
v1->v2: fix configure from fresh directory, do not use $SHELLPaolo Bonzini (3):
tests/tcg: useEXTRA_CFLAGSeverywhere tests/tcg: cleanupMakefileinclusions tests/tcg: move configuration to a sub-shell scriptMakefile | 1 + Makefile.target | 3 - configure | 155 ++------------- tests/Makefile.include | 25 +-- tests/tcg/Makefile.include | 88 --------- tests/tcg/Makefile.prereqs | 18 ++ tests/tcg/Makefile.probe | 31 --- tests/tcg/Makefile.qemu | 95 +++++++++ tests/tcg/{Makefile => Makefile.target} | 15 +- tests/tcg/aarch64/Makefile.include | 8 - tests/tcg/aarch64/Makefile.softmmu-target | 4 +- tests/tcg/aarch64/Makefile.target | 12 +- tests/tcg/alpha/Makefile.include | 2 - tests/tcg/alpha/Makefile.softmmu-target | 4 +- tests/tcg/arm/Makefile.include | 8 - tests/tcg/arm/Makefile.softmmu-target | 6 +- tests/tcg/configure.sh | 228 ++++++++++++++++++++++ tests/tcg/cris/Makefile.include | 6 - tests/tcg/hppa/Makefile.include | 2 - tests/tcg/i386/Makefile.include | 9 - tests/tcg/i386/Makefile.softmmu-target | 12 +- tests/tcg/i386/Makefile.target | 13 +- tests/tcg/m68k/Makefile.include | 2 - tests/tcg/minilib/Makefile.target | 2 +- tests/tcg/mips/Makefile.include | 20 -- tests/tcg/ppc/Makefile.include | 10 - tests/tcg/riscv/Makefile.include | 10 - tests/tcg/s390x/Makefile.include | 2 - tests/tcg/sh4/Makefile.include | 4 - tests/tcg/sparc64/Makefile.include | 2 - tests/tcg/x86_64/Makefile.softmmu-target | 36 ++++ tests/tcg/x86_64/Makefile.target | 7 +- tests/tcg/xtensa/Makefile.include | 11 -- tests/tcg/xtensa/Makefile.softmmu-target | 4 +- 34 files changed, 435 insertions(+), 420 deletions(-) delete mode 100644 tests/tcg/Makefile.include create mode 100644 tests/tcg/Makefile.prereqs delete mode 100644 tests/tcg/Makefile.probe create mode 100644 tests/tcg/Makefile.qemu rename tests/tcg/{Makefile => Makefile.target} (90%) delete mode 100644 tests/tcg/aarch64/Makefile.include delete mode 100644 tests/tcg/alpha/Makefile.include delete mode 100644 tests/tcg/arm/Makefile.include create mode 100644 tests/tcg/configure.sh delete mode 100644 tests/tcg/cris/Makefile.include delete mode 100644 tests/tcg/hppa/Makefile.include delete mode 100644 tests/tcg/i386/Makefile.include delete mode 100644 tests/tcg/m68k/Makefile.include delete mode 100644 tests/tcg/mips/Makefile.include delete mode 100644 tests/tcg/ppc/Makefile.include delete mode 100644 tests/tcg/riscv/Makefile.include delete mode 100644 tests/tcg/s390x/Makefile.include delete mode 100644 tests/tcg/sh4/Makefile.include delete mode 100644 tests/tcg/sparc64/Makefile.include create mode 100644 tests/tcg/x86_64/Makefile.softmmu-target delete mode 100644 tests/tcg/xtensa/Makefile.include--
2.21.0
--
Alex Bennée
Quoted 5 lines · Alex Bennée
Quoted 1 line
Ping?
Sorry I should have said I've queued it to testing/next. I'll post the series shortly after I've squashed the last annoying python 3.<>6 problem.
Great, thanks.
Paolo