Skip to content

OpenVINO™ is an open source toolkit for optimizing and deploying AI inference

[CI] [GHA] Fix samples directory being empty for RPM/Debian packages build (#37537)

Andrei Kashchikhin440b3c8fdf89
diff --git a/.github/workflows/job_build_linux.yml b/.github/workflows/job_build_linux.yml
index 34367ff2c27..346121a1f02 100644
--- a/.github/workflows/job_build_linux.yml
+++ b/.github/workflows/job_build_linux.yml
@@ -327,12 +327,14 @@ jobs:
[[ "${OS}" == "ubuntu_24_04" || "${OS}" == "ubuntu_26_04" ]] && python_exec=/venv/bin/python3 || python_exec=/usr/bin/python3
$python_exec -m pip install -U pip
$python_exec -m pip install -r ${OPENVINO_REPO}/src/bindings/python/wheel/requirements-dev.txt
+ # Debian packages always ship the openvino-samples package, so enable samples regardless of build-samples
cmake -UPython* -U_Python* -UPYTHON* \
-UTBB* \
-DENABLE_SYSTEM_TBB=ON \
-DENABLE_PYTHON_PACKAGING=ON \
-DENABLE_WHEEL=OFF \
-DENABLE_TESTS=OFF \
+ -DENABLE_SAMPLES=ON \
-DPython3_EXECUTABLE=$python_exec \
-DCPACK_GENERATOR=DEB \
${BUILD_DIR}
@@ -384,12 +386,14 @@ jobs:
- name: Build RPM packages
if: ${{ inputs.build-rpm-packages }}
run: |
+ # RPM packages always ship the openvino-samples package, so enable samples regardless of build-samples
cmake -UTBB* \
-DCPACK_GENERATOR=RPM \
-DENABLE_SYSTEM_TBB=ON \
-DENABLE_PYTHON_PACKAGING=ON \
-DENABLE_WHEEL=OFF \
-DENABLE_TESTS=OFF \
+ -DENABLE_SAMPLES=ON \
${BUILD_DIR}
cmake --build ${BUILD_DIR} --parallel $(nproc) --target package -- --quiet