macos installation of PETSc does not work
This commit is contained in:
parent
2662bec55f
commit
461bf53320
|
@ -2,7 +2,7 @@ name: Grid and Mesh Solver
|
|||
on: [push]
|
||||
|
||||
env:
|
||||
PETSC_VERSION: '3.18.1'
|
||||
PETSC_VERSION: '3.18.2'
|
||||
HOMEBREW_NO_ANALYTICS: 'ON' # Make Homebrew installation a little quicker
|
||||
HOMEBREW_NO_AUTO_UPDATE: 'ON'
|
||||
HOMEBREW_NO_BOTTLE_SOURCE_FALLBACK: 'ON'
|
||||
|
@ -11,14 +11,14 @@ env:
|
|||
|
||||
jobs:
|
||||
|
||||
gcc:
|
||||
gcc_ubuntu:
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
runs-on: ubuntu-22.04
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, macos-latest]
|
||||
gcc_v: [9, 10, 11] # Version of GCC compilers
|
||||
gcc_v: [9, 10, 11, 12]
|
||||
fail-fast: false
|
||||
|
||||
env:
|
||||
GCC_V: ${{ matrix.gcc_v }}
|
||||
|
@ -27,8 +27,7 @@ jobs:
|
|||
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: GCC - Install (Linux)
|
||||
if: contains( matrix.os, 'ubuntu')
|
||||
- name: GCC - Install
|
||||
run: |
|
||||
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
|
||||
sudo apt-get update
|
||||
|
@ -38,12 +37,6 @@ jobs:
|
|||
--slave /usr/bin/g++ g++ /usr/bin/g++-${GCC_V} \
|
||||
--slave /usr/bin/gcov gcov /usr/bin/gcov-${GCC_V}
|
||||
|
||||
- name: GCC - Install (macOS)
|
||||
if: contains( matrix.os, 'macos')
|
||||
run: |
|
||||
brew install gcc@${GCC_V} || brew upgrade gcc@${GCC_V} || true
|
||||
brew link gcc@${GCC_V}
|
||||
|
||||
- name: PETSc - Cache download
|
||||
id: petsc-download
|
||||
uses: actions/cache@v3
|
||||
|
@ -63,28 +56,19 @@ jobs:
|
|||
export PETSC_ARCH=gcc${GCC_V}
|
||||
printenv >> $GITHUB_ENV
|
||||
|
||||
- name: PETSc - Cache installation
|
||||
- name: PETSc - Cache Installation
|
||||
id: petsc-install
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: petsc-${{ env.PETSC_VERSION }}
|
||||
key: petsc-${{ env.PETSC_VERSION }}-${{ matrix.os }}-gcc${{ matrix.gcc_v }}-${{ hashFiles('**/petscversion.h') }}
|
||||
key: petsc-${{ env.PETSC_VERSION }}-gcc${{ matrix.gcc_v }}-${{ hashFiles('**/petscversion.h') }}
|
||||
|
||||
- name: PETSc - Install (Linux)
|
||||
if: contains( matrix.os, 'ubuntu')
|
||||
- name: PETSc - Installation
|
||||
run: |
|
||||
cd petsc-${PETSC_VERSION}
|
||||
./configure --with-fc=gfortran --with-cc=gcc --with-cxx=g++ \
|
||||
--download-mpich --download-fftw --download-hdf5 --download-hdf5-fortran-bindings=1 --download-zlib \
|
||||
--with-mpi-f90module-visibility=0
|
||||
make all
|
||||
|
||||
- name: PETSc - Install (macOS)
|
||||
if: contains( matrix.os, 'macos')
|
||||
run: |
|
||||
cd petsc-${PETSC_VERSION}
|
||||
./configure --with-fc=gfortran-${GCC_V} --with-cc=gcc-${GCC_V} --with-cxx=g++-${GCC_V} \
|
||||
--download-openmpi --download-fftw --download-hdf5 --download-hdf5-fortran-bindings=1 --download-zlib
|
||||
--download-openmpi --download-fftw --download-hdf5 --download-hdf5-fortran-bindings=1 --download-zlib \
|
||||
--with-mpi-f90module-visibility=1
|
||||
make all
|
||||
|
||||
- name: DAMASK - Compile
|
||||
|
@ -100,6 +84,7 @@ jobs:
|
|||
run: |
|
||||
./bin/DAMASK_grid -l tensionX.yaml -g 20grains16x16x16.vti -w examples/grid
|
||||
|
||||
|
||||
intel:
|
||||
|
||||
runs-on: [ubuntu-22.04]
|
||||
|
@ -107,6 +92,7 @@ jobs:
|
|||
strategy:
|
||||
matrix:
|
||||
intel_v: [classic, llvm] # Variant of Intel compilers
|
||||
fail-fast: false
|
||||
|
||||
env:
|
||||
INTEL_V: ${{ matrix.intel_v }}
|
||||
|
@ -143,7 +129,7 @@ jobs:
|
|||
- name: PETSc - Prepare
|
||||
run: |
|
||||
tar -xf download/petsc-${PETSC_VERSION}.tar.gz -C .
|
||||
sed -i "1715s/if not os.path.isfile(os.path.join(self.packageDir,'configure')):/if True:/g" \
|
||||
sed -i "1718s/if not os.path.isfile(os.path.join(self.packageDir,'configure')):/if True:/g" \
|
||||
./petsc-${PETSC_VERSION}/config/BuildSystem/config/package.py
|
||||
export PETSC_DIR=${PWD}/petsc-${PETSC_VERSION}
|
||||
export PETSC_ARCH=intel-${INTEL_V}
|
||||
|
|
Loading…
Reference in New Issue