Skip to content
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/dev_gpu_linux_level_zero.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,13 @@ jobs:
build-additional-python-packages: true
build-variant: 'levelzero'
store_artifacts: false
build-samples: true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That can be a bit confusing. If we set build-samples: true, why do we need to set it explicitly in the CMake options as well?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe it would be better to use one of them only? build-samples: true for example, and set cmake option in the build job

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the cmake option, now solely controlled by build-samples.

target-branch: ${{ inputs.target-branch }}
cmake-options: >-
-G 'Ninja Multi-Config'
-DENABLE_NCC_STYLE=OFF
-DENABLE_TESTS=ON
-DENABLE_SAMPLES=ON
-DENABLE_STRICT_DEPENDENCIES=OFF
-DENABLE_SYSTEM_OPENCL=ON
-DCMAKE_VERBOSE_MAKEFILE=ON
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/job_build_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ on:
type: boolean
required: false
default: true
build-samples:
description: 'Whether to build OpenVINO C++/C samples and include them in the OpenVINO package'
type: boolean
required: false
default: false

permissions: read-all

Expand Down Expand Up @@ -249,6 +254,11 @@ jobs:
cmake --install ${BUILD_DIR} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${INSTALL_TEST_DIR} --component tests
cmake --install ${BUILD_DIR} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${DEVELOPER_PACKAGE_DIR} --component developer_package

# Samples are built by the main build (ENABLE_SAMPLES=ON); install their binaries into the package
- name: Install OpenVINO samples
if: ${{ inputs.build-samples }}
Comment thread
akashchi marked this conversation as resolved.
run: cmake --install ${BUILD_DIR} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${INSTALL_DIR} --component samples_bin

- name: Install Python wheels for the main Python
if: ${{ ! inputs.build-additional-python-packages }}
run: cmake --install ${BUILD_DIR} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${INSTALL_WHEELS_DIR} --component python_wheels
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/job_build_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ on:
type: string
required: false
default: 'vs2022'
build-samples:
description: 'Whether to build OpenVINO C++/C samples and include them in the OpenVINO package'
type: boolean
required: false
default: false

permissions: read-all

Expand Down Expand Up @@ -197,6 +202,11 @@ jobs:
cmake --install ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_PDB_DIR }} --component pdb
cmake --install ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_DEV_PACKAGE }} --component developer_package

# Samples are built by the main build (ENABLE_SAMPLES=ON); install their binaries into the package
- name: Install OpenVINO samples
if: ${{ inputs.build-samples }}
run: cmake --install ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_DIR }} --component samples_bin

# Setup additional Python versions for wheels building
- name: Setup Python 3.10
if: ${{ inputs.build-additional-python-wheels }}
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/job_gpu_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,7 @@ jobs:
# Samples
#

- name: Build cpp samples
if: ${{ inputs.test_type == 'unit' }}
run: $INSTALL_DIR/samples/cpp/build_samples.sh -i $INSTALL_DIR -b $BUILD_DIR/cpp_samples

# Samples are built in the Build job and reused from openvino_package
# git uses the system CA bundle, so add the proxy root CA (mounted at
# /usr/local/share/ca-certificates) to it before cloning over HTTPS,
# otherwise git fails with "server certificate verification failed".
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/job_samples_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,19 +99,15 @@ jobs:
with:
toolset: 14.42 # v2022

- name: Build cpp samples
run: $INSTALL_DIR/samples/cpp/build_samples.sh -i $INSTALL_DIR -b $BUILD_DIR/cpp_samples

# C++/C samples are built in the Build job and reused from openvino_package.
# This step only validates that the C++ samples still compile with Clang
- name: Build cpp samples - Clang
if: runner.os == 'Linux'
run: $INSTALL_DIR/samples/cpp/build_samples.sh -i $INSTALL_DIR -b $BUILD_DIR/cpp_samples_clang
run: $INSTALL_DIR/samples/cpp/build_samples.sh -b $BUILD_DIR/cpp_samples_clang
env:
CC: clang
CXX: clang++

- name: Build c samples
run: $INSTALL_DIR/samples/c/build_samples.sh -i $INSTALL_DIR -b $BUILD_DIR/c_samples

#
# Tests
#
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/linux_arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,13 @@ jobs:
build-debian-packages: false
build-rpm-packages: false
build-additional-python-packages: true
build-samples: true
target-branch: ${{ inputs.target-branch }}
cmake-options: >-
-G 'Ninja Multi-Config'
-DENABLE_NCC_STYLE=OFF
-DENABLE_TESTS=ON
-DENABLE_SAMPLES=ON
-DENABLE_OV_GGUF_FRONTEND=ON
-DENABLE_STRICT_DEPENDENCIES=OFF
-DENABLE_SYSTEM_OPENCL=ON
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/mac_arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ jobs:
-G "${{ env.CMAKE_GENERATOR }}" \
-DENABLE_NCC_STYLE=OFF \
-DENABLE_TESTS=ON \
-DENABLE_SAMPLES=ON \
-DENABLE_OV_GGUF_FRONTEND=ON \
-DENABLE_WHEEL=OFF \
-DCMAKE_COMPILE_WARNING_AS_ERROR=OFF \
Expand Down Expand Up @@ -218,6 +219,10 @@ jobs:
run: tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/developer_package.tar.gz
working-directory: ${{ env.DEVELOPER_PACKAGE_DIR }}/developer_package

# Samples are built by the main build (ENABLE_SAMPLES=ON); install their binaries into the package
- name: Install OpenVINO samples
run: cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCOMPONENT=samples_bin -P ${{ env.BUILD_DIR }}/cmake_install.cmake

- name: Pack Artifacts
run: |
pushd ${{ env.INSTALL_DIR }}
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/ubuntu_22.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,13 @@ jobs:
build-debian-packages: true
build-rpm-packages: false
build-additional-python-packages: true
build-samples: true
target-branch: ${{ inputs.target-branch }}
cmake-options: >-
-G 'Ninja Multi-Config'
-DENABLE_NCC_STYLE=OFF
-DENABLE_TESTS=ON
-DENABLE_SAMPLES=ON
-DENABLE_STRICT_DEPENDENCIES=OFF
-DENABLE_SYSTEM_OPENCL=ON
-DENABLE_OV_GGUF_FRONTEND=ON
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/ubuntu_24.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,13 @@ jobs:
build-debian-packages: true
build-contrib: true
build-additional-python-packages: true
build-samples: true
target-branch: ${{ inputs.target-branch }}
cmake-options: >-
-G 'Ninja Multi-Config'
-DENABLE_NCC_STYLE=OFF
-DENABLE_TESTS=ON
-DENABLE_SAMPLES=ON
-DENABLE_OV_GGUF_FRONTEND=ON
-DENABLE_STRICT_DEPENDENCIES=OFF
-DENABLE_SYSTEM_OPENCL=ON
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/windows_vs2022_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,13 @@ jobs:
build-type: 'Release'
target-branch: ${{ needs.smart_ci.outputs.target_branch }}
build-additional-python-wheels: true
build-samples: true
cmake-options: >-
-G 'Ninja Multi-Config'
-DENABLE_PYTHON=ON
-DENABLE_WHEEL=OFF
-DENABLE_TESTS=ON
-DENABLE_SAMPLES=ON
-DENABLE_OV_GGUF_FRONTEND=ON
-DCMAKE_COMPILE_WARNING_AS_ERROR=ON
-DENABLE_STRICT_DEPENDENCIES=OFF
Expand Down Expand Up @@ -143,16 +145,6 @@ jobs:
self-hosted-runner: 'true'
use-pip-proxy: 'true'

# Test with the short names of the arguments
- name: Build cpp samples
run: |
& ${{ env.SAMPLES_INSTALL_DIR }}/cpp/build_samples.ps1 -i ${{ env.INSTALL_DIR }} -b ${{ env.BUILD_DIR }}/cpp_samples

# Test with the full names of the arguments
- name: Build c samples
run: |
& ${{ env.SAMPLES_INSTALL_DIR }}/c/build_samples.ps1 -InstallDirectory ${{ env.INSTALL_DIR }} -BuildDirectory ${{ env.BUILD_DIR }}/c_samples

# Install Python benchmark_app by installing openvino-*.whl
- name: Install OpenVINO Python wheels
uses: ./openvino/.github/actions/install_ov_wheels
Expand Down
Loading