Skip to content

Commit

Permalink
[MERGE][GHA] WA parallel make issue (#27422) (#27675)
Browse files Browse the repository at this point in the history
### Details:
- To address the issue mentioned
[here](https://unix.stackexchange.com/questions/316644/is-make-j-with-no-argument-dangerous),
we need to set the number of parallel jobs explicitly
- #27422
- #27445
  • Loading branch information
mryzhov authored Nov 21, 2024
1 parent 736c445 commit 2bb0ab7
Show file tree
Hide file tree
Showing 13 changed files with 25 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/android_arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ jobs:
run: ${SCCACHE_PATH} --zero-stats

- name: Cmake - build
run: cmake --build ${BUILD_DIR} --parallel
run: cmake --build ${BUILD_DIR} --parallel $(nproc)

- name: Show ccache stats
run: ${SCCACHE_PATH} --show-stats
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/android_x64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ jobs:
run: ${SCCACHE_PATH} --zero-stats

- name: Cmake - build
run: cmake --build ${BUILD_DIR} --parallel
run: cmake --build ${BUILD_DIR} --parallel $(nproc)

- name: Show ccache stats
run: ${SCCACHE_PATH} --show-stats
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ jobs:
popd
- name: Cmake build - OpenVINO with Coverity
run: ${COVERITY_TOOL_DIR}/cov-analysis*/bin/cov-build --dir ${BUILD_DIR}/cov-int cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
run: ${COVERITY_TOOL_DIR}/cov-analysis*/bin/cov-build --dir ${BUILD_DIR}/cov-int cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}

- name: Pack Artefacts
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dev_cpu_linux_snippets_libxsmm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ jobs:
run: ${SCCACHE_PATH} --zero-stats

- name: Cmake build - OpenVINO
run: cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
run: cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}

- name: Show sccache stats
run: ${SCCACHE_PATH} --show-stats
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/job_build_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ jobs:
run: ${SCCACHE_PATH} --zero-stats

- name: Cmake build - OpenVINO
run: cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
run: cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}

- name: Show sccache stats
run: ${SCCACHE_PATH} --show-stats
Expand Down Expand Up @@ -210,7 +210,7 @@ jobs:
-DPython3_EXECUTABLE=$python_exec \
-DCPACK_GENERATOR=DEB \
${BUILD_DIR}
cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --target package
cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }} --target package
- name: Cmake & Build - OpenVINO Contrib
if: ${{ inputs.build-contrib }}
Expand All @@ -221,7 +221,7 @@ jobs:
-DENABLE_WHEEL=OFF \
-S ${OPENVINO_REPO} \
-B ${BUILD_DIR}
cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}
- name: CMake configure, build and install - OpenVINO JS API
if: ${{ fromJSON(inputs.affected-components).JS_API && inputs.build-js }}
Expand All @@ -230,7 +230,7 @@ jobs:
-DCPACK_GENERATOR=NPM \
-DENABLE_SYSTEM_TBB=OFF \
-DENABLE_WHEEL=OFF
cmake --build ${BUILD_DIR} --parallel
cmake --build ${BUILD_DIR} --parallel $(nproc)
cmake --install ${BUILD_DIR} --prefix ${INSTALL_DIR_JS}
- name: Build RPM packages
Expand All @@ -243,7 +243,7 @@ jobs:
-DENABLE_WHEEL=OFF \
-DENABLE_TESTS=OFF \
${BUILD_DIR}
cmake --build ${BUILD_DIR} --parallel --target package --verbose
cmake --build ${BUILD_DIR} --parallel $(nproc) --target package --verbose
#
# Upload build artifacts and logs
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/job_build_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ jobs:
run: '& ccache --zero-stats'

- name: Cmake build - OpenVINO
run: cmake --build ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --parallel --verbose
run: cmake --build ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --parallel $ENV:NUMBER_OF_PROCESSORS --verbose

- name: Show ccache stats
run: '& ccache --show-stats'
Expand Down Expand Up @@ -201,7 +201,7 @@ jobs:
-DCPACK_GENERATOR=NPM `
-DENABLE_SYSTEM_TBB=OFF `
-DENABLE_WHEEL=OFF
cmake --build ${{ env.BUILD_DIR }} --parallel
cmake --build ${{ env.BUILD_DIR }} --parallel $ENV:NUMBER_OF_PROCESSORS
cmake --install ${{ env.BUILD_DIR }} --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_DIR_JS }}
#
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/job_onnx_runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ jobs:
--config RelWithDebInfo \
--use_openvino CPU \
--build_shared_lib \
--parallel \
--parallel $(nproc) \
--skip_tests \
--compile_no_warning_as_error \
--allow_running_as_root \
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linux_conditional_compilation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ jobs:
- name: Cmake build - CC COLLECT
run: |
cmake --build ${BUILD_DIR} --parallel 8 --config ${{ env.CMAKE_BUILD_TYPE }}
cmake --build ${BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --target sea_itt_lib
cmake --build ${BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }} --target sea_itt_lib
- name: Show sccache stats
run: ${SCCACHE_PATH} --show-stats
Expand All @@ -182,7 +182,7 @@ jobs:
- name: Build C++ samples - OpenVINO build tree
run: |
cmake -G "${{ env.CMAKE_GENERATOR }}" -DOpenVINO_DIR=${BUILD_DIR} -S ${INSTALL_DIR}/samples/cpp -B ${BUILD_DIR}/cpp_samples
cmake --build ${BUILD_DIR}/cpp_samples --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --target hello_query_device
cmake --build ${BUILD_DIR}/cpp_samples --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }} --target hello_query_device
- name: Build C samples - OpenVINO install tree
run: ${INSTALL_DIR}/samples/c/build_samples.sh -i ${INSTALL_DIR} -b ${BUILD_DIR}/c_samples
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linux_riscv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -213,13 +213,13 @@ jobs:
source ${OPENVINO_BUILD_DIR}/dependencies/deactivate_conanbuild.sh
- name: Cmake - Build
run: cmake --build ${OPENVINO_BUILD_DIR} --parallel
run: cmake --build ${OPENVINO_BUILD_DIR} --parallel $(nproc)

- name: Show ccache stats
run: ccache --show-stats

- name: Cmake - Install
run: cmake --build ${OPENVINO_BUILD_DIR} --parallel --target install
run: cmake --build ${OPENVINO_BUILD_DIR} --parallel $(nproc) --target install

- name: Build OpenVINO C++ samples
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ jobs:
-B ${{ env.BUILD_DIR }}
- name: Cmake build - OpenVINO
run: cmake --build ${{ env.BUILD_DIR }} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
run: cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}

- name: Show ccache stats
run: ccache --show-stats
Expand All @@ -186,7 +186,7 @@ jobs:
-DOPENVINO_EXTRA_MODULES=${{ env.OPENVINO_CONTRIB_REPO }}/modules/custom_operations \
-S ${{ env.OPENVINO_REPO }} \
-B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}
- name: CMake configure, build and install - OpenVINO JS API
if: fromJSON(needs.smart_ci.outputs.affected_components).JS_API
Expand All @@ -196,7 +196,7 @@ jobs:
-S ${{ env.OPENVINO_REPO }} \
-B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --parallel
cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc)
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR_JS }} -P ${{ env.BUILD_DIR }}/cmake_install.cmake
#
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/mac_arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ jobs:
-B ${{ env.BUILD_DIR }}
- name: Cmake build - OpenVINO
run: cmake --build ${{ env.BUILD_DIR }} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
run: cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}

- name: Show ccache stats
run: ccache --show-stats
Expand Down Expand Up @@ -187,7 +187,7 @@ jobs:
-DOPENVINO_EXTRA_MODULES=${{ env.OPENVINO_CONTRIB_REPO }}/modules/custom_operations \
-S ${{ env.OPENVINO_REPO }} \
-B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --parallel --config ${{ env.CMAKE_BUILD_TYPE }}
cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }}
- name: CMake configure, build and install - OpenVINO JS API
if: fromJSON(needs.smart_ci.outputs.affected_components).JS_API
Expand All @@ -197,7 +197,7 @@ jobs:
-S ${{ env.OPENVINO_REPO }} \
-B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --parallel
cmake --build ${{ env.BUILD_DIR }} --parallel $(nproc)
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR_JS }} -P ${{ env.BUILD_DIR }}/cmake_install.cmake
#
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu_22.yml
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ jobs:
-DCMAKE_COMPILE_WARNING_AS_ERROR=OFF \
-S ${OPENVINO_CONTRIB_REPO}/modules/nvidia_plugin \
-B ${NVIDIA_BUILD_DIR}
cmake --build ${NVIDIA_BUILD_DIR} --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --verbose -- ov_nvidia_func_tests ov_nvidia_unit_tests
cmake --build ${NVIDIA_BUILD_DIR} --parallel $(nproc) --config ${{ env.CMAKE_BUILD_TYPE }} --verbose -- ov_nvidia_func_tests ov_nvidia_unit_tests
- name: Show ccache stats
run: ${SCCACHE_PATH} --show-stats
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/windows_conditional_compilation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ jobs:
- name: Build C++ samples - OpenVINO build tree
run: |
cmake -G "${{ env.CMAKE_GENERATOR }}" -DOpenVINO_DIR=${{ env.BUILD_DIR }} -S ${{ env.INSTALL_DIR }}/samples/cpp -B ${{ env.BUILD_DIR }}/cpp_samples
cmake --build ${{ env.BUILD_DIR }}/cpp_samples --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --target hello_query_device
cmake --build ${{ env.BUILD_DIR }}/cpp_samples --parallel $ENV:NUMBER_OF_PROCESSORS --config ${{ env.CMAKE_BUILD_TYPE }} --target hello_query_device
- name: Build C samples - OpenVINO install tree
run: |
Expand Down Expand Up @@ -331,7 +331,7 @@ jobs:
-B ${{ env.BUILD_DIR }}
- name: Cmake build - CC ON
run: cmake --build ${{ env.BUILD_DIR }} --parallel --config ${{ env.CMAKE_BUILD_TYPE }} --target benchmark_app --verbose
run: cmake --build ${{ env.BUILD_DIR }} --parallel $ENV:NUMBER_OF_PROCESSORS --config ${{ env.CMAKE_BUILD_TYPE }} --target benchmark_app --verbose

- name: List bin files
shell: cmd
Expand Down

0 comments on commit 2bb0ab7

Please sign in to comment.