Skip to content

Commit

Permalink
Merge pull request #239 from jedwards4b/github_esmf_bld_update
Browse files Browse the repository at this point in the history
update esmf bld to use official esmf action
  • Loading branch information
jedwards4b authored Aug 17, 2023
2 parents 26ab1e0 + f415e66 commit f7e657e
Showing 1 changed file with 23 additions and 50 deletions.
73 changes: 23 additions & 50 deletions .github/workflows/extbuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,8 @@ jobs:
CPPFLAGS: "-I/usr/include -I/usr/local/include "
LDFLAGS: "-L/usr/lib/x86_64-linux-gnu "
# Versions of all dependencies can be updated here - these match tag names in the github repo
ESMF_VERSION: v8.4.0
#PNETCDF_VERSION: checkpoint.1.12.3
#NETCDF_FORTRAN_VERSION: v4.6.0
ParallelIO_VERSION: pio2_5_10
ESMF_VERSION: v8.5.0
ParallelIO_VERSION: pio2_6_0
steps:
- id: checkout-CDEPS
uses: actions/checkout@v3
Expand All @@ -37,67 +35,42 @@ jobs:
sudo apt-get install netcdf-bin libnetcdf-dev libnetcdff-dev
sudo apt-get install pnetcdf-bin libpnetcdf-dev
sudo apt-get install autotools-dev autoconf
# - id: cache-pnetcdf
# uses: actions/cache@v3
# with:
# path: ~/pnetcdf
# key: ${{ runner.os }}-${{ env.PNETCDF_VERSION}}-pnetcdf1
# - name: Build PNetCDF
# if: steps.cache-pnetcdf.outputs.cache-hit != 'true'
# uses: ./.github/actions/buildpnetcdf
# with:
# pnetcdf_version: ${{ env.PNETCDF_VERSION }}
# install_prefix: $HOME/pnetcdf
# - name: Cache netcdf-fortran
# id: cache-netcdf-fortran
# uses: actions/cache@v3
# with:
# path: ~/netcdf-fortran
# key: ${{ runner.os }}-${{ env.NETCDF_FORTRAN_VERSION }}-netcdf-fortran1
# - name: Build NetCDF Fortran
# if: steps.cache-netcdf-fortran.outputs.cache-hit != 'true'
# uses: ./.github/actions/buildnetcdff
# with:
# netcdf_fortran_version: ${{ env.NETCDF_FORTRAN_VERSION }}
# install_prefix: $HOME/netcdf-fortran
# netcdf_c_path: /usr
- name: Cache PARALLELIO
id: cache-PARALLELIO
uses: actions/cache@v3
with:
path: ~/pio
path: ${GITHUB_WORKSPACE}/pio
key: ${{ runner.os }}-${{ env.ParallelIO_VERSION }}-parallelio2
- name: Build ParallelIO
if: steps.cache-PARALLELIO.outputs.cache-hit != 'true'
uses: NCAR/ParallelIO/.github/actions/parallelio_cmake@9390e30e29d4ebbfbef0fc72162cacd9e8f25e4e
with:
parallelio_version: ${{ env.ParallelIO_VERSION }}
enable_fortran: True
install_prefix: $HOME/pio
- name: Cache ESMF
id: cache-esmf
uses: actions/cache@v3
with:
path: ~/ESMF
key: ${{ runner.os }}-${{ env.ESMF_VERSION }}-ESMF2
- name: Build ESMF
if: steps.cache-esmf.outputs.cache-hit != 'true'
uses: ./.github/actions/buildesmf
install_prefix: ${GITHUB_WORKSPACE}/pio
- name: Install ESMF
uses: esmf-org/install-esmf-action@v1
env:
ESMF_COMPILER: gfortran
ESMF_BOPT: g
ESMF_COMM: openmpi
ESMF_NETCDF: nc-config
ESMF_PNETCDF: pnetcdf-config
ESMF_INSTALL_PREFIX: ${GITHUB_WORKSPACE}/ESMF
ESMF_PIO: external
ESMF_PIO_INCLUDE: ${GITHUB_WORKSPACE}/pio/include
ESMF_PIO_LIBPATH: ${GITHUB_WORKSPACE}/pio/lib
with:
esmf_version: ${{ env.ESMF_VERSION }}
esmf_bopt: g
esmf_comm: openmpi
install_prefix: $HOME/ESMF
netcdf_c_path: /usr
netcdf_fortran_path: /usr
pnetcdf_path: /usr
parallelio_path: $HOME/pio
version: ${{ env.ESMF_VERSION }}
esmpy: false
cache: true

- name: Build CDEPS
uses: ./.github/actions/buildcdeps
with:
esmfmkfile: $HOME/ESMF/lib/libg/Linux.gfortran.64.openmpi.default/esmf.mk
pio_path: $HOME/pio
src_root: $GITHUB_WORKSPACE
esmfmkfile: $ESMFMKFILE
pio_path: ${GITHUB_WORKSPACE}/pio
src_root: ${GITHUB_WORKSPACE}
cmake_flags: " -Wno-dev -DCMAKE_BUILD_TYPE=DEBUG -DWERROR=ON -DCMAKE_Fortran_FLAGS=\"-DCPRGNU -g -Wall \
-ffree-form -ffree-line-length-none -fallow-argument-mismatch \""
- name: Test CDEPS
Expand Down

0 comments on commit f7e657e

Please sign in to comment.