Skip to content

Commit

Permalink
add a runner
Browse files Browse the repository at this point in the history
  • Loading branch information
fangjian authored and fangjian committed Apr 24, 2024
1 parent e8504e6 commit 37fa960
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/Build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# This is a basic workflow to help you get started with Actions

name: Build

# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4

- name: Build openmpi
run: |
wget https://download.open-mpi.org/release/open-mpi/v4.1/openmpi-4.1.4.tar.gz
tar -xf openmpi-4.1.4.tar.gz
cd openmpi-4.1.4/ && mkdir installed
./configure --prefix=$(pwd)/installed
make all install
- name: Build HDF5
run: |
wget https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.12/hdf5-1.12.0/src/hdf5-1.12.0.tar.bz2
tar -xf hdf5-1.12.0.tar.bz2
cd hdf5-1.12.0/ && mkdir installed
./configure --prefix==$(pwd)/installed --enable-fortran --disable-shared --enable-parallel CC=mpicc FC=mpif90
make all install
- name: Build ASTR
run: |
export PATH=$(pwd)/hdf5-1.12.0/installed/bin/:$PATH
export FC=h5pfc
cmake -S . -B build
cmake --build build -j 2
cmake --install build
ctest --test-dir build -L nondim

0 comments on commit 37fa960

Please sign in to comment.