File: Spack.yml

package info (click to toggle)
g2clib 2.3.0-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,600 kB
  • sloc: ansic: 28,287; python: 76; sh: 46; makefile: 26
file content (51 lines) | stat: -rw-r--r-- 1,576 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# This is a CI workflow for the NCEPLIBS-g2c project.
#
# This workflow builds g2c with Spack, including installing with the "--test
# root" option to run the CTest suite. It also has a one-off job that validates
# the recipe by ensuring that every CMake option that should be set in the
# Spack recipe is so set.
#
# Alex Richert, Sep 2023
name: Spack
on:
  push:
    branches:
    - develop
  pull_request:
    branches:
    - develop

jobs:
  # This job builds with Spack, exercising all variants, and runs the CTest suite each time
  Spack:

    strategy:
      matrix:
        os: ["ubuntu-latest"]
        variants: ["libs=shared +aec+png+jasper~openjpeg+pic+pthreads+utils+build_g2c", "libs=static ~aec~png~jasper+openjpeg~pic~pthreads~utils~build_g2c"]
    runs-on: ${{ matrix.os }}

    steps:

    - name: "Build Spack package"
      uses: NOAA-EMC/ci-test-spack-package@develop
      with:
        package-name: g2c
        package-variants: ${{ matrix.variants }}
        custom-recipe: spack/package.py
        use-repo-cache: true
        spack-compiler: gcc
        repo-cache-key-suffix: ${{ matrix.os }}-${{ matrix.variants }}-1

  # This job validates the Spack recipe by making sure each cmake build option is represented
  recipe-check:
    runs-on: ubuntu-latest

    steps:

    - name: recipe-check
      uses: NOAA-EMC/ci-check-spack-recipe@develop
      with:
        recipe-file: package/spack/package.py
        cmakelists-txt: package/CMakeLists.txt
        ignore-list: ENABLE_DOCS,FTP_TEST_FILES,FTP_LARGE_TEST_FILES,FTP_EXTRA_TEST_FILES,LOGGING