From b5877861daf5b8b38ec009bfcab905d19560c619 Mon Sep 17 00:00:00 2001 From: Sandipan Das Date: Sat, 6 Feb 2021 19:14:29 +0530 Subject: [PATCH] tests, arch-power: Add support for building hello Commit a440108cc ("tests: Add Makefiles for hello") introduced Makefiles for building the hello test binary for ARM and x86 using dockcross. Since dockcross also provides an image with a 64-bit little endian toolchain for Power, this adds a Makefile for building the hello binary. As of this moment, 64-bit little endian (ppc64le) is the prevalent variant supported by most distributions. Hence, we are currently limited to only building the binary for this variant. Change-Id: Ic20322ca33c69634d9f17d30b29e522cc35742fb Signed-off-by: Sandipan Das Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/40949 Tested-by: kokoro Reviewed-by: Bobby R. Bruce Maintainer: Bobby R. Bruce --- tests/test-progs/hello/src/Makefile.power | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 tests/test-progs/hello/src/Makefile.power diff --git a/tests/test-progs/hello/src/Makefile.power b/tests/test-progs/hello/src/Makefile.power new file mode 100644 index 0000000000..6fb280ae48 --- /dev/null +++ b/tests/test-progs/hello/src/Makefile.power @@ -0,0 +1,11 @@ +all: hello64le-static + +hello64le-static: hello.c dockcross-ppc64le + ./dockcross-ppc64le bash -c '$$CC hello.c -o hello64le-static -static' + +dockcross-ppc64le: + docker run --rm dockcross/linux-ppc64le > ./dockcross-ppc64le + chmod +x ./dockcross-ppc64le + +clean: + rm -f dockcross* hello64le-static