|
1 |
| -name: xercesc |
| 1 | +name: Build Xerces-C |
2 | 2 |
|
3 | 3 | on:
|
4 | 4 | workflow_dispatch:
|
5 | 5 | inputs:
|
6 | 6 | xercesc_ver:
|
7 |
| - description: "XercesC version" |
| 7 | + description: "Xerces-C version" |
8 | 8 | required: true
|
9 | 9 | type: string
|
10 | 10 | default: "3.2.4"
|
|
14 | 14 | required: true
|
15 | 15 | type: choice
|
16 | 16 | options:
|
17 |
| - - "ubuntu:22.04" |
18 |
| - - "ubuntu:24.04" |
19 |
| - default: "ubuntu:24.04" |
| 17 | + - "ubuntu-22.04" |
| 18 | + - "ubuntu-24.04" |
| 19 | + default: "ubuntu-22.04" |
| 20 | + |
| 21 | +defaults: |
| 22 | + run: |
| 23 | + shell: bash --login -e -o pipefail {0} # login for environment modules |
| 24 | + working-directory: ./scripts/custom |
20 | 25 |
|
21 | 26 | jobs:
|
22 | 27 | setup:
|
23 |
| - name: build and cache xercesc |
| 28 | + name: Build Xerces-C ${{ github.event.inputs.xercesc_ver }} |
24 | 29 |
|
25 |
| - runs-on: ubuntu-latest |
26 |
| - container: |
27 |
| - image: ${{ github.event.inputs.os }} |
| 30 | + runs-on: ${{ github.event.inputs.os }} |
28 | 31 |
|
29 | 32 | steps:
|
30 |
| - - name: checkout |
| 33 | + - name: Checkout |
31 | 34 | uses: actions/checkout@v4
|
32 | 35 |
|
33 |
| - - name: setup os |
34 |
| - uses: ./.github/actions/setup-defaults |
| 36 | + - name: Set env |
| 37 | + run: | |
| 38 | + source /etc/os-release |
| 39 | + OS_ID="$(echo ${ID}${VERSION_ID} | sed 's/\.//')" |
| 40 | + echo "OS_ID=${OS_ID}" >> $GITHUB_ENV |
| 41 | + echo "MODULES_DIR=$HOME/modules" >> $GITHUB_ENV |
| 42 | + echo "XERCESC_VER=${{ github.event.inputs.xercesc_ver }}" >> $GITHUB_ENV |
| 43 | +
|
| 44 | + - name: Setup OS |
| 45 | + run: | |
| 46 | + sudo ./setup_${{ env.OS_ID }}.sh |
| 47 | +
|
| 48 | + - name: List environment modules |
| 49 | + run: | |
| 50 | + module avail |
| 51 | +
|
| 52 | + - name: Run build script |
| 53 | + run: | |
| 54 | + ./install_xercesc.sh \ |
| 55 | + --version=${{ env.XERCESC_VER }} \ |
| 56 | + --modules-dir=${{ env.MODULES_DIR }} |
35 | 57 |
|
36 |
| - - name: build and cache |
37 |
| - uses: ./.github/actions/setup-xercesc |
38 |
| - with: |
39 |
| - xercesc_ver: ${{ github.event.inputs.xercesc_ver }} |
| 58 | + - name: Test |
| 59 | + run: | |
| 60 | + module use ${MODULES_DIR}/modulefiles |
| 61 | + module avail |
| 62 | + module load xercesc/${{ env.XERCESC_VER }} |
| 63 | + module test xercesc/${{ env.XERCESC_VER }} |
0 commit comments