name: gpu-build-only on: push: paths-ignore: - '**.md' - 'images/**' pull_request: paths-ignore: - '**.md' - 'images/**' jobs: build: strategy: fail-fast: false matrix: optix: [ optix-7.1.0, optix-7.2.0, optix-7.3.0, optix-7.4.0 ] cuda: [ '11.0.3', '11.1.1', '11.2.2', '11.4.3', '11.5.0' ] # 11.3.0 fails for unclear reasons os: [ ubuntu-20.04, windows-latest ] name: GPU Build Only (${{ matrix.os }}, CUDA ${{ matrix.cuda }}, ${{ matrix.optix }}) runs-on: ${{ matrix.os }} steps: - uses: mmp/cuda-toolkit@master id: cuda-toolkit with: cuda: ${{ matrix.cuda }} method: 'network' sub-packages: '[ "nvcc" ]' - name: Check NVCC run: nvcc -V - name: Checkout pbrt uses: actions/checkout@v2 with: submodules: true - name: Checkout rgb2spectrum tables uses: actions/checkout@v2 with: repository: mmp/rgb2spectrum path: build - name: Cache OptiX headers uses: actions/cache@v2 with: path: optix key: optix-7.12345 - name: Checkout OptiX headers uses: actions/checkout@v2 with: ssh-key: ${{ secrets.CHECKOUT_KEY }} repository: mmp/optix-headers path: optix - name: Get cmake uses: lukka/get-cmake@latest - name: Install OpenEXR if: ${{ matrix.os == 'ubuntu-20.04' }} run: sudo apt-get -y install libopenexr-dev - name: Install OpenGL if: ${{ matrix.os == 'ubuntu-20.04' }} run: sudo apt-get install -y --no-install-recommends libx11-dev libxcursor-dev libxrandr-dev libxinerama-dev libxi-dev libxext-dev libxfixes-dev libgl1-mesa-dev - name: Configure run: | cd build cmake .. -DPBRT_USE_PREGENERATED_RGB_TO_SPECTRUM_TABLES=True -DPBRT_OPTIX7_PATH=../optix/${{ matrix.optix }} -DPBRT_GPU_SHADER_MODEL=sm_80 - name: Build # We need to limit the number of jobs so that it doesn't OOM run: cmake --build build --parallel 3 --config Release