Loading .gitlab-ci.yml +74 −32 Original line number Diff line number Diff line #.gcc_83_before: &gcc_83_before # - if [[ -f "/data/test_gcc/gcc-8.3.0/load_dev_env.sh" ]]; then BASE_DIR="/data/gitlab-runner"; . /data/test_gcc/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/data/test_gcc/gcc-8.3.0; else BASE_DIR="/localhome/gitlab-runner"; . /projects/vera/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/projects/vera/gcc-8.3.0; fi # - which gcc # - SRC_DIR=`pwd` # - BLD_DIR="$SRC_DIR/build" # .gcc_83_before: &gcc_83_before - if [[ -f "/data/test_gcc/gcc-8.3.0/load_dev_env.sh" ]]; then BASE_DIR="/data/gitlab-runner"; . /data/test_gcc/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/data/test_gcc/gcc-8.3.0; else BASE_DIR="/localhome/gitlab-runner"; . /projects/vera/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/projects/vera/gcc-8.3.0; fi .nix_before: &nix_before - SRC_DIR=`pwd` - BLD_DIR="$SRC_DIR/build/$CI_COMMIT_SHORT_SHA" - source $HOME/miniconda3/bin/activate - conda init zsh - conda activate saline .windows_before: &windows_before #Temporary but need conda - C:\Users\oxh\Miniconda3\\shell\\condabin\\conda-hook.ps1 Loading @@ -12,7 +16,39 @@ - $SRC_DIR=$pwd.Path - $BLD_DIR="$SRC_DIR/build/$CI_COMMIT_SHORT_SHA" build_macos: when: - manual tags: - macOS script: - *nix_before - echo $CI_BUILDS_DIR - echo $SRC_DIR - echo $BLD_DIR - cmake -S $SRC_DIR -B $BLD_DIR -Dsaline_ENABLE_Fortran=OFF -Dsaline_ENABLE_Python=ON - cmake --build $BLD_DIR artifacts: expire_in: 1 day paths: - $BLD_DIR test_macos: when: - manual tags: - macOS script: - *nix_before - echo $SRC_DIR - echo $BLD_DIR - ctest --test-dir $BLD_DIR needs: - job: build_macos build_windows: when: - manual tags: - windows script: Loading @@ -23,40 +59,46 @@ build_windows: - cmake -S $SRC_DIR -B $BLD_DIR -Dsaline_ENABLE_Fortran=OFF -Dsaline_ENABLE_Python=ON -DCMAKE_WINDOWS_EXPORT_ALL_SYMBOLS=TRUE - cmake --build $BLD_DIR --target ALL_BUILD --config RELEASE artifacts: expire_in: 3 day expire_in: 1 day paths: - "build/$CI_COMMIT_SHORT_SHA" - $BLD_DIR test windows: test_windows: when: - manual tags: - windows script: - *windows_before - echo $SRC_DIR - echo $BLD_DIR - ls build - ctest --build-config RELEASE --test-dir /build/$CI_COMMIT_SHORT_SHA needs: - job: build_windows #build_linux_gcc83: # tags: # - linux # - gcc # script: # - *gcc_83_before # - cmake -S $SRC_DIR -B $BLD_DIR -DCMAKE_BUILD_TYPE=RELEASE -Dsaline_ENABLE_Fortran=ON -DCMAKE_Fortran_FLAGS:STRING="-ffree-line-length-none" -Dsaline_ENABLE_Python=OFF # - cmake --build $BLD_DIR # artifacts: # paths: # - "build/" # #test linux_gcc83: # tags: # - linux # - gcc # script: # - ctest --test-dir build/ # needs: # - job: build_linux_gcc83 # build_linux_gcc83: tags: - linux - gcc script: #This first script is actually 100% machine dependent - *gcc_83_before - *nix_before - cmake -S $SRC_DIR -B $BLD_DIR -DCMAKE_BUILD_TYPE=RELEASE -Dsaline_ENABLE_Fortran=ON -DCMAKE_Fortran_FLAGS:STRING="-ffree-line-length-none" -Dsaline_ENABLE_Python=OFF - cmake --build $BLD_DIR artifacts: expire_in: 1 day paths: - $BLD_DIR test linux_gcc83: tags: - linux - gcc script: - *gcc_83_before - *nix_before - ctest --test-dir build/ needs: - job: build_linux_gcc83 tests/CMakeLists.txt +1 −1 Original line number Diff line number Diff line Loading @@ -10,7 +10,7 @@ message("Configuring Saline libary tests") include(FetchContent) FetchContent_Declare( googletest GIT_REPOSITORY https://github.com/google/googletest.git GIT_REPOSITORY https://code.ornl.gov/scale/code/external/googletest.git GIT_TAG release-1.12.1 ) # For Windows: Prevent overriding the parent project's compiler/linker settings Loading Loading
.gitlab-ci.yml +74 −32 Original line number Diff line number Diff line #.gcc_83_before: &gcc_83_before # - if [[ -f "/data/test_gcc/gcc-8.3.0/load_dev_env.sh" ]]; then BASE_DIR="/data/gitlab-runner"; . /data/test_gcc/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/data/test_gcc/gcc-8.3.0; else BASE_DIR="/localhome/gitlab-runner"; . /projects/vera/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/projects/vera/gcc-8.3.0; fi # - which gcc # - SRC_DIR=`pwd` # - BLD_DIR="$SRC_DIR/build" # .gcc_83_before: &gcc_83_before - if [[ -f "/data/test_gcc/gcc-8.3.0/load_dev_env.sh" ]]; then BASE_DIR="/data/gitlab-runner"; . /data/test_gcc/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/data/test_gcc/gcc-8.3.0; else BASE_DIR="/localhome/gitlab-runner"; . /projects/vera/gcc-8.3.0/load_dev_env.sh; ENV_BASE=/projects/vera/gcc-8.3.0; fi .nix_before: &nix_before - SRC_DIR=`pwd` - BLD_DIR="$SRC_DIR/build/$CI_COMMIT_SHORT_SHA" - source $HOME/miniconda3/bin/activate - conda init zsh - conda activate saline .windows_before: &windows_before #Temporary but need conda - C:\Users\oxh\Miniconda3\\shell\\condabin\\conda-hook.ps1 Loading @@ -12,7 +16,39 @@ - $SRC_DIR=$pwd.Path - $BLD_DIR="$SRC_DIR/build/$CI_COMMIT_SHORT_SHA" build_macos: when: - manual tags: - macOS script: - *nix_before - echo $CI_BUILDS_DIR - echo $SRC_DIR - echo $BLD_DIR - cmake -S $SRC_DIR -B $BLD_DIR -Dsaline_ENABLE_Fortran=OFF -Dsaline_ENABLE_Python=ON - cmake --build $BLD_DIR artifacts: expire_in: 1 day paths: - $BLD_DIR test_macos: when: - manual tags: - macOS script: - *nix_before - echo $SRC_DIR - echo $BLD_DIR - ctest --test-dir $BLD_DIR needs: - job: build_macos build_windows: when: - manual tags: - windows script: Loading @@ -23,40 +59,46 @@ build_windows: - cmake -S $SRC_DIR -B $BLD_DIR -Dsaline_ENABLE_Fortran=OFF -Dsaline_ENABLE_Python=ON -DCMAKE_WINDOWS_EXPORT_ALL_SYMBOLS=TRUE - cmake --build $BLD_DIR --target ALL_BUILD --config RELEASE artifacts: expire_in: 3 day expire_in: 1 day paths: - "build/$CI_COMMIT_SHORT_SHA" - $BLD_DIR test windows: test_windows: when: - manual tags: - windows script: - *windows_before - echo $SRC_DIR - echo $BLD_DIR - ls build - ctest --build-config RELEASE --test-dir /build/$CI_COMMIT_SHORT_SHA needs: - job: build_windows #build_linux_gcc83: # tags: # - linux # - gcc # script: # - *gcc_83_before # - cmake -S $SRC_DIR -B $BLD_DIR -DCMAKE_BUILD_TYPE=RELEASE -Dsaline_ENABLE_Fortran=ON -DCMAKE_Fortran_FLAGS:STRING="-ffree-line-length-none" -Dsaline_ENABLE_Python=OFF # - cmake --build $BLD_DIR # artifacts: # paths: # - "build/" # #test linux_gcc83: # tags: # - linux # - gcc # script: # - ctest --test-dir build/ # needs: # - job: build_linux_gcc83 # build_linux_gcc83: tags: - linux - gcc script: #This first script is actually 100% machine dependent - *gcc_83_before - *nix_before - cmake -S $SRC_DIR -B $BLD_DIR -DCMAKE_BUILD_TYPE=RELEASE -Dsaline_ENABLE_Fortran=ON -DCMAKE_Fortran_FLAGS:STRING="-ffree-line-length-none" -Dsaline_ENABLE_Python=OFF - cmake --build $BLD_DIR artifacts: expire_in: 1 day paths: - $BLD_DIR test linux_gcc83: tags: - linux - gcc script: - *gcc_83_before - *nix_before - ctest --test-dir build/ needs: - job: build_linux_gcc83
tests/CMakeLists.txt +1 −1 Original line number Diff line number Diff line Loading @@ -10,7 +10,7 @@ message("Configuring Saline libary tests") include(FetchContent) FetchContent_Declare( googletest GIT_REPOSITORY https://github.com/google/googletest.git GIT_REPOSITORY https://code.ornl.gov/scale/code/external/googletest.git GIT_TAG release-1.12.1 ) # For Windows: Prevent overriding the parent project's compiler/linker settings Loading