name: macOS CI on: [pull_request] jobs: build: name: ${{ matrix.name }} ${{ matrix.build_type }} runs-on: ${{ matrix.os }} env: CTEST_OUTPUT_ON_FAILURE: ON CTEST_PARALLEL_LEVEL: 2 CMAKE_BUILD_TYPE: ${{ matrix.build_type }} GTSAM_BUILD_UNSTABLE: ${{ matrix.build_unstable }} strategy: fail-fast: false matrix: # Github Actions requires a single row to be added to the build matrix. # See https://help.github.com/en/articles/workflow-syntax-for-github-actions. name: [ macOS-10.15-xcode-11.3.1, ] build_type: [Debug, Release] build_unstable: [ON] include: - name: macOS-10.15-xcode-11.3.1 os: macOS-10.15 compiler: xcode version: "11.3.1" steps: - name: Checkout uses: actions/checkout@master - name: Install (macOS) if: runner.os == 'macOS' run: | brew tap ProfFan/robotics brew install cmake ninja brew install ProfFan/robotics/boost if [ "${{ matrix.compiler }}" = "gcc" ]; then brew install gcc@${{ matrix.version }} echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV else sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.app echo "CC=clang" >> $GITHUB_ENV echo "CXX=clang++" >> $GITHUB_ENV fi - name: Build and Test (macOS) if: runner.os == 'macOS' run: | bash .github/scripts/unix.sh -t - name: Upload build directory uses: actions/upload-artifact@v2 with: name: gtsam-${{ matrix.name }} path: $GITHUB_WORKSPACE/build/