From 1779c82ad2916f9a3c3ad2dd350dbeb2d6692f9d Mon Sep 17 00:00:00 2001 From: Martin Lund Date: Wed, 19 May 2010 17:53:04 +0200 Subject: test-suite: Added new test suite feature (experimental) This patch adds support for installing the gcc test suite. A helper Makefile is provided for building and running the gcc tests. The default configuration runs all gcc tests and requires automatic ssh/scp login access to a networked target board. See README for more details. Note: Current feature is tested with the powerpc-unknown-linux-gnu sample but it should work with others as well. Signed-off-by: Martin Lund --- scripts/build/test_suite/gcc.sh | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 scripts/build/test_suite/gcc.sh (limited to 'scripts/build/test_suite') diff --git a/scripts/build/test_suite/gcc.sh b/scripts/build/test_suite/gcc.sh new file mode 100644 index 00000000..1b652691 --- /dev/null +++ b/scripts/build/test_suite/gcc.sh @@ -0,0 +1,36 @@ +# This file adds the functions to build the GCC test suite +# Copyright 2010 DoréDevelopment +# Created by Martin Lund +# Licensed under the GPL v2. See COPYING in the root of this package + +do_test_suite_gcc_get() { :; } +do_test_suite_gcc_extract() { :; } +do_test_suite_gcc_build() { :; } + +# Overide functions depending on configuration +if [ "${CT_TEST_SUITE_GCC}" = "y" ]; then + +do_test_suite_gcc_build() { + + CT_DoStep INFO "Installing GCC test suite" + + CT_DoExecLog ALL mkdir -p "${CT_TEST_SUITE_DIR}/gcc-test-suite/gcc-${CT_CC_VERSION}/gcc" + CT_DoExecLog ALL cp "${CT_TOP_DIR}/contrib/gcc-test-suite/Makefile" \ + "${CT_TEST_SUITE_DIR}/gcc-test-suite" + CT_DoExecLog ALL cp "${CT_TOP_DIR}/contrib/gcc-test-suite/default.cfg" \ + "${CT_TEST_SUITE_DIR}/gcc-test-suite" + CT_DoExecLog ALL cp "${CT_TOP_DIR}/contrib/gcc-test-suite/README" \ + "${CT_TEST_SUITE_DIR}/gcc-test-suite" + CT_DoExecLog ALL cp -r "${CT_SRC_DIR}/gcc-${CT_CC_VERSION}/gcc/testsuite" \ + "${CT_TEST_SUITE_DIR}/gcc-test-suite/gcc-${CT_CC_VERSION}/gcc" + sed "s/DG_GCC_VERSION .*/DG_GCC_VERSION = ${CT_CC_VERSION}/g" \ + ${CT_TEST_SUITE_DIR}/gcc-test-suite/default.cfg > \ + ${CT_TEST_SUITE_DIR}/gcc-test-suite/default.cfg.tmp + sed "s/DG_TARGET .*/DG_TARGET = ${CT_TARGET}/g" \ + ${CT_TEST_SUITE_DIR}/gcc-test-suite/default.cfg.tmp > \ + ${CT_TEST_SUITE_DIR}/gcc-test-suite/default.cfg + CT_DoExecLog ALL rm -f "${CT_TEST_SUITE_DIR}/gcc-test-suite/default.cfg.tmp" + CT_EndStep +} + +fi # CT_TEST_SUITE_GCC -- cgit v1.2.3