add ccache to Github CI #8
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Test PUMI Python Interface | |
| on: | |
| push: | |
| branches: [develop] | |
| pull_request: | |
| branches: [develop] | |
| jobs: | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| env: | |
| PYTHONPATH: ${{ github.workspace }}/build/python_wrappers | |
| LD_LIBRARY_PATH: ${{ github.workspace }}/libs/install/lib:${LD_LIBRARY_PATH} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y cmake mpich build-essential libbz2-dev | |
| pip3 install mpi4py | |
| - name: Build SWIG | |
| run: | | |
| git clone https://github.com/swig/swig.git | |
| cd swig | |
| ./autogen.sh | |
| ./configure --prefix=${{ github.workspace }}/libs/install | |
| make | |
| make install | |
| - name: Build GKlib | |
| run: | | |
| git clone https://github.com/KarypisLab/GKlib.git | |
| cd GKlib | |
| make config prefix=${{ github.workspace }}/libs/install | |
| make install | |
| - name: Build METIS | |
| run: | | |
| git clone https://github.com/KarypisLab/METIS.git | |
| cd METIS | |
| make config prefix=${{ github.workspace }}/libs/install | |
| make install | |
| - name: Build ParMETIS | |
| run: | | |
| git clone https://github.com/KarypisLab/ParMETIS.git | |
| cd ParMETIS | |
| make config prefix=${{ github.workspace }}/libs/install | |
| make install | |
| - name: Build Zoltan from Trilinos (minimal) | |
| run: | | |
| git clone https://github.com/trilinos/Trilinos.git | |
| mkdir build-zoltan | |
| cd build-zoltan | |
| cmake ../Trilinos \ | |
| -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/libs/install \ | |
| -DTPL_ENABLE_MPI:BOOL=ON \ | |
| -DCMAKE_C_FLAGS="-O3 -fPIC" \ | |
| -DCMAKE_CXX_FLAGS="-O3 -fPIC" \ | |
| -DTrilinos_ENABLE_ALL_PACKAGES:BOOL=OFF \ | |
| -DTrilinos_ENABLE_Zoltan:BOOL=ON \ | |
| -DZoltan_ENABLE_EXAMPLES:BOOL=OFF \ | |
| -DZoltan_ENABLE_TESTS:BOOL=OFF \ | |
| -DZoltan_ENABLE_ParMETIS:BOOL=ON \ | |
| -DParMETIS_INCLUDE_DIRS=${{ github.workspace }}/libs/install \ | |
| -DParMETIS_LIBRARY_DIRS=${{ github.workspace }}/libs/install | |
| make | |
| make install | |
| - name: Configure PUMI | |
| run: | | |
| cmake -S . -B build \ | |
| -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/build/install \ | |
| -DCMAKE_C_COMPILER=mpicc \ | |
| -DCMAKE_CXX_COMPILER=mpicxx \ | |
| -DSCOREC_CXX_OPTIMIZE=ON \ | |
| -DMDS_ID_TYPE=int \ | |
| -DPCU_COMPRESS=ON \ | |
| -DENABLE_ZOLTAN=ON \ | |
| -DZOLTAN_PREFIX=${{ github.workspace }}/libs/install \ | |
| -DPUMI_PYTHON_INTERFACE=ON \ | |
| -DBUILD_SHARED_LIBS=ON \ | |
| -DBUILD_EXES=OFF \ | |
| -DIS_TESTING=OFF \ | |
| -DENABLE_OMEGA_H=OFF \ | |
| -DPARMETIS_PREFIX=${{ github.workspace }}/libs/install \ | |
| -DENABLE_SIMMETRIX=OFF | |
| - name: Build and install | |
| run: | | |
| cmake --build build -j 4 --target install | |
| - name: Run Python test | |
| working-directory: ${{github.workspace}}/python_wrappers | |
| run: | | |
| python3 test_pyCore.py -g input/cube.dmg -m input/cube.smb |