|
| 1 | +name: test build macOS native |
| 2 | + |
| 3 | +on: |
| 4 | + pull_request: |
| 5 | + branches: |
| 6 | + - main |
| 7 | + - XSCAPE-1.1.5-RC |
| 8 | + - latessa/gtl_binary_function |
| 9 | + |
| 10 | + push: |
| 11 | + branches: |
| 12 | + - main |
| 13 | + - XSCAPE-1.1.5-RC |
| 14 | + - latessa/gtl_binary_function |
| 15 | + |
| 16 | +env: |
| 17 | + REPO_NAME: ${{ github.event.repository.name }} |
| 18 | + |
| 19 | +jobs: |
| 20 | + build: |
| 21 | + name: install packages and build |
| 22 | + runs-on: ${{ matrix.os }} |
| 23 | + strategy: |
| 24 | + matrix: |
| 25 | + os: [macos-14, macos-15] |
| 26 | + |
| 27 | + steps: |
| 28 | + |
| 29 | + - name: brew install dependencies |
| 30 | + run: | |
| 31 | + export NONINTERACTIVE=1 |
| 32 | + brew update |
| 33 | + brew cleanup |
| 34 | + brew install --formula cmake |
| 35 | + brew install --formula doxygen |
| 36 | + brew install --formula root |
| 37 | + brew install --formula graph-tool |
| 38 | + brew install --formula hdf5 |
| 39 | + brew install --formula open-mpi |
| 40 | + brew install --formula gsl |
| 41 | + brew install --formula boost |
| 42 | + brew install --formula zlib |
| 43 | + . /opt/homebrew/bin/thisroot.sh |
| 44 | + - name: set environment variables |
| 45 | + run: | |
| 46 | + export ROOTSYS="/usr/local/root" |
| 47 | + export PATH="$ROOTSYS/bin:\$PATH" |
| 48 | + export LD_LIBRARY_PATH="$ROOTSYS/lib:$LD_LIBRARY_PATH" |
| 49 | + export PYTHONPATH="$ROOTSYS/lib" |
| 50 | + - name: install HepMC 3.2.6 |
| 51 | + run: | # brew tap davidchall/hep |
| 52 | + brew tap davidchall/homebrew-hep |
| 53 | + cd $(brew --repository)/Library/Taps/davidchall/homebrew-hep |
| 54 | + echo "Current directory: $(pwd)" |
| 55 | + git checkout f643d5cacc19fd0b01d0ecba0daf30452152da03 |
| 56 | + NONINTERACTIVE=1 brew install davidchall/hep/hepmc3 |
| 57 | + - name: install Pythia 8309 |
| 58 | + run: | |
| 59 | + cd $(brew --repository)/Library/Taps/davidchall/homebrew-hep |
| 60 | + echo "Current directory: $(pwd)" |
| 61 | + git checkout 141f8548d045df88d498ab44df16d2091742e4b1 |
| 62 | + NONINTERACTIVE=1 brew install davidchall/hep/pythia |
| 63 | + - name: set more variables |
| 64 | + run: | |
| 65 | + export JETSCAPE_DIR="${GITHUB_WORKSPACE}/${REPO_NAME}" |
| 66 | + - name: Checkout JETSCAPE Repository |
| 67 | + uses: actions/checkout@v4 |
| 68 | + with: |
| 69 | + path: ${{ github.event.repository.name }} |
| 70 | + |
| 71 | + - name: Download MUSIC |
| 72 | + run: | |
| 73 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages |
| 74 | + ./get_music.sh |
| 75 | + - name: Download ISS |
| 76 | + run: | |
| 77 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages |
| 78 | + ./get_iSS.sh |
| 79 | + - name: Download FREESTREAM |
| 80 | + run: | |
| 81 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages |
| 82 | + ./get_freestream-milne.sh |
| 83 | + - name: Download SMASH |
| 84 | + run: | |
| 85 | + export PYTHIA8DIR="/opt/homebrew/opt/pythia" |
| 86 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages |
| 87 | + ./get_smash.sh |
| 88 | + - name: Download 3DGlauber |
| 89 | + run: | |
| 90 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages |
| 91 | + ./get_3dglauber.sh |
| 92 | + - name: Build Application |
| 93 | + run: | |
| 94 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME} |
| 95 | + mkdir build |
| 96 | + cd build |
| 97 | + export SMASH_DIR="${GITHUB_WORKSPACE}/${REPO_NAME}/external_packages/smash/smash_code" |
| 98 | + echo "This is SMASH_DIR: " |
| 99 | + echo ${SMASH_DIR} |
| 100 | + ls ${SMASH_DIR} |
| 101 | + cmake .. -DUSE_3DGlauber=ON -DUSE_MUSIC=ON -DUSE_ISS=ON -DUSE_FREESTREAM=ON -DUSE_SMASH=ON |
| 102 | + make -j2 |
| 103 | + - name: Test Run |
| 104 | + run: | |
| 105 | + cd ${GITHUB_WORKSPACE}/${REPO_NAME}/build |
| 106 | + ./runJetscape ../config/publications_config/arXiv_1910.05481/jetscape_user_PP_1910.05481.xml |
0 commit comments