From 08959bee21d0cab2602a244da8c5a28d327fe9c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20=C4=8Cern=C3=BD?= Date: Fri, 11 Oct 2024 15:02:44 +0200 Subject: [PATCH] Unify location of the SCE option SCE should be built in Ubuntu 20.04 and 22.04 products. However, this is specified only in the CI workflow description. In previous commit we have started to build SCE in RHEL 9 and 10. If we would like to start testing it in CI, we could do it either by changing the CI workflow description or the build_product script. It would be less complex if we could unify it in a single place which is the build_product script. --- .github/workflows/gate.yaml | 4 ++-- build_product | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/gate.yaml b/.github/workflows/gate.yaml index a874e9d8284..f72a6a3732f 100644 --- a/.github/workflows/gate.yaml +++ b/.github/workflows/gate.yaml @@ -95,7 +95,7 @@ jobs: run: pip3 install -r requirements.txt -r test-requirements.txt - name: Build env: - ADDITIONAL_CMAKE_OPTIONS: "-DSSG_SCE_ENABLED:BOOL=ON -DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" + ADDITIONAL_CMAKE_OPTIONS: "-DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" run: |- ./build_product ubuntu1604 ubuntu1804 ubuntu2004 - name: Test @@ -114,7 +114,7 @@ jobs: run: pip3 install -r requirements.txt -r test-requirements.txt - name: Build env: - ADDITIONAL_CMAKE_OPTIONS: "-DSSG_SCE_ENABLED:BOOL=ON -DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" + ADDITIONAL_CMAKE_OPTIONS: "-DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" run: |- ./build_product ubuntu2204 - name: Test diff --git a/build_product b/build_product index c19689f1f44..8685fffc627 100755 --- a/build_product +++ b/build_product @@ -339,7 +339,8 @@ set_no_derivatives_options() { set_sce_options() { grep -q "SSG_SCE_ENABLED" <<< "$ADDITIONAL_CMAKE_OPTIONS" && return - if grep -q 'rhel9\|rhel10' <<< "${_arg_product[*]}"; then + # These products will build SCE by default + if grep -q -E 'rhel9|rhel10|ubuntu2004|ubuntu2204' <<< "${_arg_product[*]}"; then CMAKE_OPTIONS+=("-DSSG_SCE_ENABLED:BOOL=ON") fi }