From d24ef0a2a226b241e2718244f67208b71272d2b6 Mon Sep 17 00:00:00 2001 From: Florent Pruvost <florent.pruvost@inria.fr> Date: Tue, 22 Aug 2017 12:53:04 +0200 Subject: [PATCH] Load the environment from a shell script to facilitate CI machines setup. --- .gitlab-ci-env.sh | 22 ++++++++++++++++++++++ .gitlab-ci.yml | 22 ++++++++++------------ 2 files changed, 32 insertions(+), 12 deletions(-) create mode 100755 .gitlab-ci-env.sh diff --git a/.gitlab-ci-env.sh b/.gitlab-ci-env.sh new file mode 100755 index 000000000..480da8a09 --- /dev/null +++ b/.gitlab-ci-env.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +# custom environment used during CI tests with gitlab ci + +# these paths may depend on the runner used, please be careful and add +# the necessary if blocks depending on the machine + +export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64 +export PATH=/builds/sonar/lcov-to-cobertura-xml-1.6/lcov_cobertura:$PATH +export PATH=/builds/sonar/sonar-scanner-2.9.0.670/bin:$PATH + +export QUARK_DIR=/builds/install/quark +export PARSEC_DIR=/builds/install/parsec +export STARPU_DIR=/builds/install/starpu + +if [ "$1" == "simu" ]; then + export STARPU_DIR=/builds/install/starpu-simgrid + export SIMGRID_DIR=/builds/install/simgrid +fi + +export PKG_CONFIG_PATH=$PARSEC_DIR/lib/pkgconfig:$PKG_CONFIG_PATH +export PKG_CONFIG_PATH=$STARPU_DIR/lib/pkgconfig:$PKG_CONFIG_PATH diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6cd75ba0e..039ed6a61 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,8 +1,8 @@ starpu: script: - - git submodule init - - git submodule update - - mkdir build + - source .gitlab-ci-env.sh + - git submodule update --init --recursive + - mkdir -p build - cd build - cmake .. - make -j2 @@ -13,22 +13,20 @@ starpu: starpu-simgrid: script: - - git submodule init - - git submodule update - - mkdir build + - source .gitlab-ci-env.sh simu + - git submodule update --init --recursive + - mkdir -p build - cd build - - . $HOME/spack/share/spack/setup-env.sh - - spack load hwloc && spack load fxt && spack load simgrid && spack load starpu - cmake .. -DCHAMELEON_SIMULATION=ON -DCHAMELEON_USE_CUDA=ON -DCHAMELEON_USE_MPI=OFF - make -j2 - ctest -V quark: script: - - git submodule init - - git submodule update - - mkdir build + - source .gitlab-ci-env.sh + - git submodule update --init --recursive + - mkdir -p build - cd build - cmake .. -DCHAMELEON_SCHED_QUARK=ON - make -j2 - - ctest -V -R test_shm_s \ No newline at end of file + - ctest -V -R test_shm_s -- GitLab