On 04/24/2018 12:23 PM, Alex Bennée wrote:
> As before, using Debian SID compilers. While the compiler can be
> coerced into generating big-endian code it seems the linker can't deal
> with it so we only enable the building for little endian SH4.
>
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> ---
> tests/docker/Makefile.include | 1 +
> tests/docker/dockerfiles/debian-sh4-cross.docker | 12 ++++++++++++
> tests/tcg/sh4/Makefile.include | 4 ++++
> 3 files changed, 17 insertions(+)
> create mode 100644 tests/docker/dockerfiles/debian-sh4-cross.docker
> create mode 100644 tests/tcg/sh4/Makefile.include
>
> diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
> index 15c52127c7..c08f32ca58 100644
> --- a/tests/docker/Makefile.include
> +++ b/tests/docker/Makefile.include
> @@ -65,6 +65,7 @@ docker-image-debian-win64-cross: docker-image-debian8-mxe
> docker-image-debian-alpha-cross: docker-image-debian-sid
> docker-image-debian-hppa-cross: docker-image-debian-sid
> docker-image-debian-m68k-cross: docker-image-debian-sid
> +docker-image-debian-sh4-cross: docker-image-debian-sid
> docker-image-travis: NOUSER=1
>
> # Expand all the pre-requistes for each docker image and test combination
> diff --git a/tests/docker/dockerfiles/debian-sh4-cross.docker b/tests/docker/dockerfiles/debian-sh4-cross.docker
> new file mode 100644
> index 0000000000..88a2423094
> --- /dev/null
> +++ b/tests/docker/dockerfiles/debian-sh4-cross.docker
> @@ -0,0 +1,12 @@
> +#
> +# Docker cross-compiler target
> +#
> +# This docker target builds on the debian sid base image which
> +# contains cross compilers for Debian "ports" targets.
> +#
> +FROM qemu:debian-sid
> +
> +RUN DEBIAN_FRONTEND=noninteractive eatmydata \
> + apt-get install -y --no-install-recommends \
> + gcc-sh4-linux-gnu \
> + libc6-dev-sh4-cross
> diff --git a/tests/tcg/sh4/Makefile.include b/tests/tcg/sh4/Makefile.include
> new file mode 100644
> index 0000000000..ad21594d9d
> --- /dev/null
> +++ b/tests/tcg/sh4/Makefile.include
> @@ -0,0 +1,4 @@
> +ifneq ($(TARGET_NAME), sh4eb)
> +DOCKER_IMAGE=debian-sh4-cross
> +DOCKER_CROSS_COMPILER=sh4-linux-gnu-gcc
> +endif
>
$ make -j1 run-tcg-tests-sh4-linux-user
GEN sh4-linux-user/config-target.h
BUILD debian-sid
BUILD debian-sh4-cross
CROSS-BUILD sh4 guest-tests with docker qemu:debian-sh4-cross
BUILD debian-sid
BUILD debian-sh4-cross
CROSS-BUILD sh4 guest-tests with docker qemu:debian-sh4-cross
RUN-TESTS for sh4
TEST test-mmap (default) on sh4
TEST test-mmap (8k pages) on sh4
TEST test-mmap (16k pages) on sh4
TEST test-mmap (32k pages) on sh4
TEST sha1 on sh4
BROKEN TEST linux-test SKIPPED on sh4
TEST testthread on sh4
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>