From a7784808039021ccb5c1bb3e9175d11e67618750 Mon Sep 17 00:00:00 2001 From: Ken Matsui <26405363+ken-matsui@users.noreply.github.com> Date: Wed, 15 Jun 2022 20:03:04 +0900 Subject: [PATCH] Test the case of using local packages on macOS CI (#635) * Test the case of using local packages on CI * Remove unused matrix from Linux CI * Link libarchive * Add PKG_CONFIG_PATH * Remove CPM_LOCAL_PACKAGES_ONLY --- .github/workflows/linux.yml | 2 +- .github/workflows/macos.yml | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 06e00bb64..d42d988b0 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -89,9 +89,9 @@ jobs: cmake \ -B build \ -G Ninja \ + -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ -DPOAC_BUILD_TESTING=ON \ -DPOAC_ENABLE_COVERAGE=${{ matrix.coverage }} \ - -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ -DPOAC_DEPS_DIR=${{ runner.temp }}/libs - name: Build Poac diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 3c64c15af..ff7ee1ef7 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -14,6 +14,7 @@ jobs: matrix: os: [ macos-11, macos-12 ] build_type: [ Debug, Release ] + use_local: [ on, off ] env: CACHE_KEY_PREFIX: v2-${{ github.ref }}-${{ matrix.os }}-${{ matrix.build_type }} steps: @@ -22,6 +23,10 @@ jobs: - name: Install required libraries run: brew install openssl ninja boost + - name: Install optional libraries + if: matrix.use_local == 'on' + run: brew install libarchive libgit2 fmt spdlog + - name: Restore & Cache CMake build results uses: actions/cache@v3.0.3 with: @@ -33,8 +38,9 @@ jobs: cmake \ -B build \ -G Ninja \ + -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ -DPOAC_BUILD_TESTING=ON \ - -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} + -DCPM_USE_LOCAL_PACKAGES=${{ matrix.use_local }} - name: Build Poac run: ninja