From e579ab5faa4de2812f97174c2e17d3889a3c58ea Mon Sep 17 00:00:00 2001 From: Przemyslaw Skibinski Date: Mon, 14 Nov 2016 12:57:05 +0100 Subject: [PATCH] introduced QEMU_SYS --- Makefile | 10 +++++++--- tests/Makefile | 22 +++++++++++----------- tests/playTests.sh | 2 +- 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index 856b1a07b..7d36ab2aa 100644 --- a/Makefile +++ b/Makefile @@ -93,15 +93,19 @@ clangtest: clean armtest: clean $(MAKE) -C $(TESTDIR) datagen # use native, faster - $(MAKE) -C $(TESTDIR) test CC=arm-linux-gnueabi-gcc ZSTDRTTEST= MOREFLAGS="-Werror -static" + $(MAKE) -C $(TESTDIR) test CC=arm-linux-gnueabi-gcc QEMU_SYS=qemu-arm-static ZSTDRTTEST= MOREFLAGS="-Werror -static" + +aarch64test: + $(MAKE) -C $(TESTDIR) datagen # use native, faster + $(MAKE) -C $(TESTDIR) test CC=aarch64-linux-gnu-gcc QEMU_SYS=qemu-aarch64-static ZSTDRTTEST= MOREFLAGS="-Werror -static" ppctest: clean $(MAKE) -C $(TESTDIR) datagen # use native, faster - $(MAKE) -C $(TESTDIR) test CC=powerpc-linux-gnu-gcc ZSTDRTTEST= MOREFLAGS="-Werror -Wno-attributes -static" + $(MAKE) -C $(TESTDIR) test CC=powerpc-linux-gnu-gcc QEMU_SYS=qemu-ppc-static ZSTDRTTEST= MOREFLAGS="-Werror -Wno-attributes -static" ppc64test: clean $(MAKE) -C $(TESTDIR) datagen # use native, faster - $(MAKE) -C $(TESTDIR) test CC=powerpc-linux-gnu-gcc ZSTDRTTEST= MOREFLAGS="-m64 -static" + $(MAKE) -C $(TESTDIR) test CC=powerpc-linux-gnu-gcc QEMU_SYS=qemu-ppc64-static ZSTDRTTEST= MOREFLAGS="-m64 -static" usan: clean $(MAKE) test CC=clang MOREFLAGS="-g -fsanitize=undefined" diff --git a/tests/Makefile b/tests/Makefile index 26ae60078..63177f5ef 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -166,7 +166,7 @@ endif #------------------------------------------------------------------------ ifneq (,$(filter $(HOST_OS),MSYS POSIX)) zstd-playTests: datagen - ZSTD=$(ZSTD) ./playTests.sh $(ZSTDRTTEST) + ZSTD="$(QEMU_SYS) $(ZSTD)" ./playTests.sh $(ZSTDRTTEST) test: test-zstd test-fullbench test-fuzzer test-zbuff test-zstream @@ -184,29 +184,29 @@ test-zstd-nolegacy: ZSTD = $(PRGDIR)/zstd test-zstd-nolegacy: zstd-nolegacy zstd-playTests test-fullbench: fullbench datagen - ./fullbench -i1 - ./fullbench -i1 -P0 + $(QEMU_SYS) ./fullbench -i1 + $(QEMU_SYS) ./fullbench -i1 -P0 test-fullbench32: fullbench32 datagen - ./fullbench32 -i1 - ./fullbench32 -i1 -P0 + $(QEMU_SYS) ./fullbench32 -i1 + $(QEMU_SYS) ./fullbench32 -i1 -P0 test-fuzzer: fuzzer - ./fuzzer $(FUZZERTEST) + $(QEMU_SYS) ./fuzzer $(FUZZERTEST) test-fuzzer32: fuzzer32 - ./fuzzer32 $(FUZZERTEST) + $(QEMU_SYS) ./fuzzer32 $(FUZZERTEST) test-zbuff: zbufftest - ./zbufftest $(ZBUFFTEST) + $(QEMU_SYS) ./zbufftest $(ZBUFFTEST) test-zbuff32: zbufftest32 - ./zbufftest32 $(ZBUFFTEST) + $(QEMU_SYS) ./zbufftest32 $(ZBUFFTEST) test-zstream: zstreamtest - ./zstreamtest $(ZBUFFTEST) + $(QEMU_SYS) ./zstreamtest $(ZBUFFTEST) test-zstream32: zstreamtest32 - ./zstreamtest32 $(ZBUFFTEST) + $(QEMU_SYS) ./zstreamtest32 $(ZBUFFTEST) endif diff --git a/tests/playTests.sh b/tests/playTests.sh index ad70538a3..1bc835f0c 100755 --- a/tests/playTests.sh +++ b/tests/playTests.sh @@ -36,7 +36,7 @@ if [[ "$OSTYPE" == "darwin"* ]]; then MD5SUM="md5 -r" fi -$ECHO "\nStarting playTests.sh isWindows=$isWindows" +$ECHO "\nStarting playTests.sh isWindows=$isWindows ZSTD='$ZSTD'" [ -n "$ZSTD" ] || die "ZSTD variable must be defined!"