mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-02-05 15:42:32 +08:00
Update daily build action to build MPICH and OpenMPI from source (#5058)
This commit is contained in:
parent
0af437a61e
commit
8407b75a26
25
.github/workflows/build_mpich_source.yml
vendored
25
.github/workflows/build_mpich_source.yml
vendored
@ -1,13 +1,16 @@
|
||||
# Build MPICH from source using the latest commit on the
|
||||
# 'main' branch and cache the results. The result is installed
|
||||
# to (or restored to) '${{ runner.workspace }}/mpich'.
|
||||
# 'main' branch and cache the results. The result is compressed
|
||||
# into a 'mpich.tar' archive to preserve permissions and
|
||||
# then is uploaded as the artifact 'mpich' which can later
|
||||
# be downloaded with 'actions/download-artifact' and then
|
||||
# uncompressed with 'tar xvf mpich.tar -C <directory>'
|
||||
|
||||
# Triggers the workflow on a call from another workflow
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
build_mode:
|
||||
description: "production vs. debug build"
|
||||
description: "Release vs. Debug build"
|
||||
required: true
|
||||
type: string
|
||||
|
||||
@ -53,8 +56,8 @@ jobs:
|
||||
|
||||
# Enable threads=multiple for testing with Subfiling and
|
||||
# VOL connectors that require MPI_THREAD_MULTIPLE
|
||||
- name: Install MPICH (GCC) (Production)
|
||||
if: ${{ steps.cache-mpich-ubuntu-gcc.cache-hit != 'true' && (inputs.build_mode != 'debug') }}
|
||||
- name: Install MPICH (GCC) (Release)
|
||||
if: ${{ steps.cache-mpich-ubuntu-gcc.outputs.cache-hit != 'true' && (inputs.build_mode == 'Release') }}
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/mpich
|
||||
./autogen.sh
|
||||
@ -68,7 +71,7 @@ jobs:
|
||||
# Enable threads=multiple for testing with Subfiling and
|
||||
# VOL connectors that require MPI_THREAD_MULTIPLE
|
||||
- name: Install MPICH (GCC) (Debug)
|
||||
if: ${{ steps.cache-mpich-ubuntu-gcc.cache-hit != 'true' && (inputs.build_mode == 'debug') }}
|
||||
if: ${{ steps.cache-mpich-ubuntu-gcc.outputs.cache-hit != 'true' && (inputs.build_mode == 'Debug') }}
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/mpich
|
||||
./autogen.sh
|
||||
@ -80,3 +83,13 @@ jobs:
|
||||
--enable-threads=multiple
|
||||
make -j2
|
||||
make install
|
||||
|
||||
- name: Tar MPICH installation to preserve permissions for artifact
|
||||
run: tar -cvf mpich.tar ${{ runner.workspace }}/mpich
|
||||
|
||||
- name: Save MPICH installation artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: mpich
|
||||
path: mpich.tar
|
||||
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
|
||||
|
25
.github/workflows/build_openmpi_source.yml
vendored
25
.github/workflows/build_openmpi_source.yml
vendored
@ -1,13 +1,16 @@
|
||||
# Build OpenMPI from source using the latest commit on the
|
||||
# 'main' branch and cache the results. The result is installed
|
||||
# to (or restored to) '${{ runner.workspace }}/openmpi'.
|
||||
# 'main' branch and cache the results. The result is compressed
|
||||
# into a 'openmpi.tar' archive to preserve permissions and
|
||||
# then is uploaded as the artifact 'openmpi' which can later
|
||||
# be downloaded with 'actions/download-artifact' and then
|
||||
# uncompressed with 'tar xvf openmpi.tar -C <directory>'
|
||||
|
||||
# Triggers the workflow on a call from another workflow
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
build_mode:
|
||||
description: "production vs. debug build"
|
||||
description: "Release vs. Debug build"
|
||||
required: true
|
||||
type: string
|
||||
|
||||
@ -51,8 +54,8 @@ jobs:
|
||||
path: ${{ runner.workspace }}/openmpi
|
||||
key: ${{ runner.os }}-${{ runner.arch }}-gcc-openmpi-${{ steps.get-sha.outputs.sha }}-${{ inputs.build_mode }}
|
||||
|
||||
- name: Install OpenMPI (GCC) (Production)
|
||||
if: ${{ steps.cache-openmpi-ubuntu-gcc.cache-hit != 'true' && (inputs.build_mode != 'debug') }}
|
||||
- name: Install OpenMPI (GCC) (Release)
|
||||
if: ${{ steps.cache-openmpi-ubuntu-gcc.outputs.cache-hit != 'true' && (inputs.build_mode == 'Release') }}
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/ompi
|
||||
./autogen.pl
|
||||
@ -63,7 +66,7 @@ jobs:
|
||||
make install
|
||||
|
||||
- name: Install OpenMPI (GCC) (Debug)
|
||||
if: ${{ steps.cache-openmpi-ubuntu-gcc.cache-hit != 'true' && (inputs.build_mode == 'debug') }}
|
||||
if: ${{ steps.cache-openmpi-ubuntu-gcc.outputs.cache-hit != 'true' && (inputs.build_mode == 'Debug') }}
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE/ompi
|
||||
./autogen.pl
|
||||
@ -73,3 +76,13 @@ jobs:
|
||||
--enable-debug
|
||||
make -j2
|
||||
make install
|
||||
|
||||
- name: Tar OpenMPI installation to preserve permissions for artifact
|
||||
run: tar -cvf openmpi.tar ${{ runner.workspace }}/openmpi
|
||||
|
||||
- name: Save OpenMPI installation artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: openmpi
|
||||
path: openmpi.tar
|
||||
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
|
||||
|
68
.github/workflows/cmake-par-source.yml
vendored
68
.github/workflows/cmake-par-source.yml
vendored
@ -27,22 +27,47 @@ permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
Build_openmpi_source:
|
||||
name: Build OpenMPI from source
|
||||
uses: ./.github/workflows/build_openmpi_source.yml
|
||||
with:
|
||||
build_mode: ${{ inputs.build_mode }}
|
||||
|
||||
Build_mpich_source:
|
||||
name: Build MPICH from source
|
||||
uses: ./.github/workflows/build_mpich_source.yml
|
||||
with:
|
||||
build_mode: ${{ inputs.build_mode }}
|
||||
|
||||
CMake_build_parallel_src_openmpi:
|
||||
needs: Build_openmpi_source
|
||||
name: "Parallel OpenMPI GCC-${{ inputs.build_mode }}"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Install CMake Dependencies (OpenMPI)
|
||||
- name: Install Linux Dependencies (OpenMPI)
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install ninja-build graphviz curl
|
||||
sudo apt install libssl3 libssl-dev libcurl4 libcurl4-openssl-dev
|
||||
sudo apt install gcc-12 g++-12 gfortran-12
|
||||
sudo apt-get install ninja-build
|
||||
sudo apt install libaec0 libaec-dev
|
||||
sudo apt-get install libopenmpi-dev
|
||||
echo "CC=mpicc" >> $GITHUB_ENV
|
||||
echo "FC=mpif90" >> $GITHUB_ENV
|
||||
|
||||
- name: Install Dependencies
|
||||
- name: Get MPI installation (OpenMPI)
|
||||
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
|
||||
with:
|
||||
name: openmpi
|
||||
|
||||
- name: Untar MPI installation (OpenMPI)
|
||||
run: |
|
||||
tar xvf openmpi.tar -C ${{ runner.workspace }}
|
||||
|
||||
- name: Set path (OpenMPI)
|
||||
shell: bash
|
||||
run: |
|
||||
echo "${{ runner.workspace }}/openmpi/bin" >> $GITHUB_PATH
|
||||
echo "LD_LIBRARY_PATH=${{ runner.workspace }}/openmpi/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV
|
||||
echo "CC=${{ runner.workspace }}/openmpi/bin/mpicc" >> $GITHUB_ENV
|
||||
echo "FC=${{ runner.workspace }}/openmpi/bin/mpif90" >> $GITHUB_ENV
|
||||
|
||||
- name: Install Doxygen
|
||||
uses: ssciwr/doxygen-install@v1
|
||||
with:
|
||||
version: "1.9.7"
|
||||
@ -128,6 +153,7 @@ jobs:
|
||||
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
|
||||
|
||||
CMake_build_parallel_src_mpich:
|
||||
needs: Build_mpich_source
|
||||
name: "Parallel Mpich GCC-${{ inputs.build_mode }}"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
@ -136,15 +162,27 @@ jobs:
|
||||
- name: Install Linux Dependencies (MPICH)
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install ninja-build doxygen graphviz
|
||||
sudo apt install libssl3 libssl-dev libcurl4 libcurl4-openssl-dev
|
||||
sudo apt install gcc-12 g++-12 gfortran-12
|
||||
sudo apt-get install ninja-build
|
||||
sudo apt install libaec0 libaec-dev
|
||||
sudo apt-get install libmpich-dev
|
||||
echo "CC=mpicc" >> $GITHUB_ENV
|
||||
echo "FC=mpif90" >> $GITHUB_ENV
|
||||
|
||||
- name: Install Dependencies
|
||||
- name: Get MPI installation (MPICH)
|
||||
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
|
||||
with:
|
||||
name: mpich
|
||||
|
||||
- name: Untar MPI installation (MPICH)
|
||||
run: |
|
||||
tar xvf mpich.tar -C ${{ runner.workspace }}
|
||||
|
||||
- name: Set path (MPICH)
|
||||
shell: bash
|
||||
run: |
|
||||
echo "${{ runner.workspace }}/mpich/bin" >> $GITHUB_PATH
|
||||
echo "LD_LIBRARY_PATH=${{ runner.workspace }}/mpich/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV
|
||||
echo "CC=${{ runner.workspace }}/mpich/bin/mpicc" >> $GITHUB_ENV
|
||||
echo "FC=${{ runner.workspace }}/mpich/bin/mpif90" >> $GITHUB_ENV
|
||||
|
||||
- name: Install Doxygen
|
||||
uses: ssciwr/doxygen-install@v1
|
||||
with:
|
||||
version: "1.9.7"
|
||||
|
Loading…
Reference in New Issue
Block a user