From 7881b81014848ef050afdbc9412b302d00f1a549 Mon Sep 17 00:00:00 2001 From: Brett Dutro Date: Wed, 16 Oct 2024 12:34:40 -0500 Subject: [PATCH] Fix Github workflow LTO config --- .github/workflows/ubuntu-build.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ubuntu-build.yml b/.github/workflows/ubuntu-build.yml index a6842f9..f5f021b 100644 --- a/.github/workflows/ubuntu-build.yml +++ b/.github/workflows/ubuntu-build.yml @@ -13,12 +13,16 @@ jobs: - c: clang cxx: clang++ build_config: + - build_type: Debug + lto: false - build_type: Release - lto: 0 + lto: false - build_type: Release - lto: 1 - - build_type: Debug - lto: 0 + lto: true + + env: + LTO_CONFIG: ${{ matrix.build_config.lto && '-DFULL_LTO=1' || '' }} + runs-on: ubuntu-latest steps: @@ -34,7 +38,7 @@ jobs: - name: Configure CMAKE working-directory: ${{runner.workspace}}/build - run: CC=${{ matrix.compilers.c }} CXX=${{ matrix.compilers.cxx }} cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=${{ matrix.build_config.build_type }} -DBUILD_STF_PYTHON_LIB=ON -DFULL_LTO=${{ matrix.build_config.lto }} + run: CC=${{ matrix.compilers.c }} CXX=${{ matrix.compilers.cxx }} cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=${{ matrix.build_config.build_type }} -DBUILD_STF_PYTHON_LIB=ON $LTO_CONFIG - name: Build working-directory: ${{runner.workspace}}/build