1name: Build Binaries and Deploy 2 3# Controls when the action will run. Triggers the workflow on push or pull request 4# events but only for the master branch 5on: 6 push: 7 branches: [ master ] 8 pull_request: 9 branches: [ master ] 10 11jobs: 12 macos-build: 13 runs-on: macos-latest 14 15 steps: 16 - uses: actions/checkout@v2 17 with: 18 submodules: recursive 19 - run: brew install boost ilmbase openexr tbb@2020 glm libomp 20 21 - name: Run tests 22 run: make test 23 - name: Release build 24 run: make 25 26 - uses: actions/upload-artifact@v2 27 with: 28 name: curv-mac-${{ github.sha }} 29 path: | 30 release/curv 31 lib 32 33 windows-build: 34 runs-on: windows-latest 35 36 steps: 37 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it 38 - uses: actions/checkout@v2 39 with: 40 submodules: recursive 41 42 - uses: msys2/setup-msys2@v2 43 with: 44 msystem: MINGW64 45 update: true 46 install: "git diffutils mingw-w64-x86_64-clang make mingw-w64-x86_64-cmake mingw-w64-x86_64-boost mingw-w64-x86_64-mesa mingw-w64-x86_64-openexr mingw-w64-x86_64-intel-tbb mingw-w64-x86_64-glm mingw-w64-x86_64-glew mingw-w64-x86_64-dbus patch mingw-w64-x86_64-openvdb mingw-w64-x86_64-ccache" 47 48 - name: ccache cache files 49 uses: actions/cache@v2 50 with: 51 path: .ccache 52 key: ${{matrix.config.name}}-ccache-${{ github.sha }} 53 restore-keys: | 54 ${{matrix.config.name}}-ccache- 55 56 - name: Build Curv 57 shell: msys2 {0} 58 run: make 59 - name: Test built executable 60 shell: msys2 {0} 61 run: ./release/curv --version 62 63 - name: Copy runtime dependencies to build dir 64 shell: msys2 {0} 65 run: | 66 cp /mingw64/bin/libHalf*.dll ./release 67 cp /mingw64/bin/tbb.dll ./release 68 cp /mingw64/bin/libopenvdb.dll ./release 69 cp /mingw64/bin/libboost_filesystem-mt.dll ./release 70 - uses: actions/upload-artifact@v2 71 with: 72 name: curv-win-${{ github.sha }} 73 path: | 74 release/*.exe 75 release/*.dll 76 lib 77 78 linux-build: 79 runs-on: ubuntu-latest 80 81 steps: 82 - uses: actions/checkout@v2 83 with: 84 submodules: recursive 85 86 - name: Set up dependencies 87 run: | 88 sudo apt install clang cmake git-core libboost-all-dev libopenexr-dev libtbb-dev libglm-dev dbus-x11 89 sudo apt install libxcursor-dev libxinerama-dev libxrandr-dev libgl-dev libxi-dev 90 91 - name: Build AppImage 92 run: | 93 sudo chmod +x build-appimage.sh 94 bash build-appimage.sh 95 96 - name: Test built executable(s) 97 run: | 98 sudo chmod +x release/Curv-*.AppImage 99 find ./release -maxdepth 1 -iname "Curv-*.AppImage" -exec {} --version \; 100 101 - uses: actions/upload-artifact@v2 102 with: 103 name: curv-appimage-${{ github.sha }} 104 path: | 105 release/Curv-*.AppImage 106 release/Curv-*.AppImage.zsync