-
Notifications
You must be signed in to change notification settings - Fork 22
Unified windows build ver2 #263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
avdivan
wants to merge
34
commits into
opencv:main
Choose a base branch
from
avdivan:main-wb
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+194
−21
Open
Changes from all commits
Commits
Show all changes
34 commits
Select commit
Hold shift + click to select a range
0cfaa15
Unified windows build
mshabunin a1a3990
fixup! Unified windows build
mshabunin 623b131
fixup! Unified windows build
mshabunin 3c63481
fixup! Unified windows build
mshabunin 6948293
fixup! Unified windows build
mshabunin c29374c
fixup! Unified windows build
mshabunin 5dd6636
fixup! Unified windows build
mshabunin 2438dd5
fixup! Unified windows build
mshabunin 1760a00
fixup! Unified windows build
mshabunin 63a9816
fixup! Unified windows build
mshabunin 40a9570
fixup! Unified windows build
mshabunin 3d1528d
fixup! Unified windows build
mshabunin 4105efc
fixup! Unified windows build
mshabunin d1a0955
fixup! Unified windows build
mshabunin cddf556
fixup! Unified windows build
mshabunin ca57e3c
fixup! Unified windows build
mshabunin 2ca66ad
fixup! Unified windows build
mshabunin 5a270c8
fixup! Unified windows build
mshabunin ad5b62e
fixup! Unified windows build
mshabunin f67a11f
fixup! Unified windows build
mshabunin 071e98e
fixup! Unified windows build
mshabunin 58f6589
fixup! Unified windows build
mshabunin 3fff657
fixup! Unified windows build
mshabunin 2656cd5
fixup! Unified windows build
mshabunin 7759b80
fixup! Unified windows build
mshabunin 1b8a6df
fixup! Unified windows build
mshabunin e2830ee
fixup! Unified windows build
mshabunin b82ede5
Merge branch 'opencv-pr-241' into merge-opencv-pr241
44f2f5b
Update OCV-PR-Windows.yaml
avdivan 7e34400
Test add ARM to OCV-PR-Windows.yaml
avdivan 54c1520
Update OCV-PR-Windows.yaml
avdivan 2b4f13e
Update OCV-PR-Windows.yaml
avdivan e86fca6
Update OCV-PR-Windows.yaml
avdivan a43246b
Update OCV-PR-Windows.yaml
avdivan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,179 @@ | ||
name: OCV PR Windows | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/workflows/OCV-PR-Windows.yaml' | ||
# TODO: are following paths necessary? | ||
- 'checkout-and-merge/*' | ||
- 'configure-and-build/*' | ||
- 'run-tests/*' | ||
- 'scripts/runner.py' | ||
- 'scripts/test-plan.json' | ||
workflow_call: | ||
inputs: | ||
workflow_branch: | ||
description: "Branch for ci-gha-workflow repository" | ||
default: "main" | ||
required: false | ||
type: string | ||
|
||
concurrency: | ||
group: OCV-PR-Windows-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
|
||
branch_eval: | ||
runs-on: ubuntu-24.04 | ||
outputs: | ||
branches: ${{ steps.determine-branches.outputs.branches }} | ||
steps: | ||
- id: determine-branches | ||
shell: bash | ||
run: | | ||
if [ "${{ github.event.repository.name == 'ci-gha-workflow' }}" = "true" ] ; then | ||
echo "branches=[ '4.x', '5.x' ]" >> "$GITHUB_OUTPUT" | ||
else | ||
echo "branches=[ '${{ github.base_ref }}' ]" >> "$GITHUB_OUTPUT" | ||
fi | ||
|
||
Windows: | ||
runs-on: ${{ matrix.runner }} | ||
needs: | ||
- branch_eval | ||
strategy: | ||
# NOTE: Debugging | ||
fail-fast: true | ||
# fail-fast: false | ||
max-parallel: 3 | ||
matrix: | ||
arch: [ x64, arm64 ] | ||
config: [ base, vulkan, uwp ] | ||
include: | ||
- arch: x64 | ||
config: vulkan | ||
runner: opencv-cn-win | ||
vs: 'Visual Studio 16 2019' | ||
cmake_arch: x64 | ||
vulkan: true | ||
- arch: x64 | ||
config: uwp | ||
runner: opencv-cn-win | ||
vs: 'Visual Studio 16 2019' | ||
cmake_arch: x64 | ||
uwp: true | ||
uwp_proc: x86_64 | ||
- arch: x64 | ||
config: base | ||
runner: opencv-cn-win | ||
vs: 'Visual Studio 16 2019' | ||
cmake_arch: x64 | ||
uwp_proc: x86_64 | ||
- arch: arm64 | ||
config: base | ||
runner: windows-11-arm | ||
vs: 'Visual Studio 17 2022' | ||
cmake_arch: ARM64 | ||
uwp_proc: ARM64 | ||
no_opencl: true | ||
- arch: arm64 | ||
config: uwp | ||
runner: windows-11-arm | ||
vs: 'Visual Studio 17 2022' | ||
cmake_arch: ARM64 | ||
uwp: true | ||
uwp_proc: ARM64 | ||
no_opencl: true | ||
Comment on lines
+82
to
+89
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would sau, it's redundant and can be removed. |
||
|
||
branch: ${{ fromJSON(needs.branch_eval.outputs.branches )}} | ||
exclude: | ||
- branch: '5.x' | ||
config: 'vulkan' | ||
- arch: arm64 | ||
config: vulkan | ||
defaults: | ||
run: | ||
shell: bash | ||
env: | ||
CMAKE_OPT: >- | ||
-DCL_Z_OPTION=/Z7 | ||
-DBUILD_EXAMPLES=ON | ||
-DOPENCV_ENABLE_NONFREE=ON | ||
${{ matrix.no_opencl && '-DWITH_OPENCL=OFF' || '' }} | ||
${{ matrix.uwp && format('-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0 -DCMAKE_SYSTEM_PROCESSOR={0} -DBUILD_opencv_gapi=OFF -DWITH_MSMF=OFF -DBUILD_TESTS=OFF -DBUILD_PERF_TESTS=OFF -DBUILD_EXAMPLES=OFF -DBUILD_opencv_apps=OFF', matrix.uwp_proc) || '' }} | ||
${{ matrix.config == 'vulkan' && '-DWITH_OPENCL=OFF -DWITH_VULKAN=ON' || '' }} | ||
${{ matrix.arch == 'arm64' && '-DWITH_VULKAN=OFF -DBUILD_opencv_vulkan=OFF -DOPENCV_DNN_VULKAN=OFF -DCMAKE_DISABLE_FIND_PACKAGE_Vulkan=ON -DBUILD_LIST=core,imgproc,highgui,videoio' || '' }} | ||
MAIN_BUILD_DIR: "${{ (github.event.repository.name != 'opencv_contrib') && 'build' || 'build-contrib' }}" | ||
OPENCV_FOR_THREADS_NUM: 8 | ||
CMAKE_BUILD_PARALLEL_LEVEL: 8 | ||
|
||
# ========== | ||
|
||
steps: | ||
|
||
- name: Propagate environment | ||
run: | | ||
echo "GIT_CACHE=$(cygpath -u "$GIT_CACHE")" >> "$GITHUB_ENV" | ||
echo "DNN_MODELS=$(cygpath -u "$DNN_MODELS")" >> "$GITHUB_ENV" | ||
echo "BINARIES_CACHE=$(cygpath -u "$BINARIES_CACHE")" >> "$GITHUB_ENV" | ||
echo "OPENCV_DOWNLOAD_PATH=$(cygpath -u "$BINARIES_CACHE")" >> "$GITHUB_ENV" | ||
|
||
|
||
- name: Checkout workflow repository | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: opencv/ci-gha-workflow | ||
ref: "${{ github.repository == 'opencv/ci-gha-workflow' && github.ref || inputs.workflow_branch }}" | ||
|
||
- working-directory: '${{ github.workspace }}' | ||
shell: bash | ||
run: | | ||
ls -l | ||
export | ||
whoami | ||
id | ||
which bash | ||
echo "GIT_CACHE=$GIT_CACHE" | ||
echo "DNN_MODELS=$DNN_MODELS" | ||
echo "BINARIES_CACHE=$BINARIES_CACHE" | ||
echo "OPENCV_DOWNLOAD_PATH=$BINARIES_CACHE" | ||
|
||
|
||
- name: Checkout and merge OpenCV | ||
uses: ./checkout-and-merge | ||
with: | ||
target_branch: '${{ matrix.branch }}' | ||
author: '${{ github.event.pull_request.user.login }}' | ||
source_branch: "${{ github.event.repository.name == 'ci-gha-workflow' && '' || github.head_ref }}" | ||
gitcache: '${{ env.GIT_CACHE }}' | ||
workdir: '${{ github.workspace }}' | ||
|
||
- name: Update extra dnn models | ||
if: ${{ matrix.arch != 'arm64' }} | ||
timeout-minutes: 60 | ||
working-directory: '${{ github.workspace }}' | ||
run: | | ||
python opencv_extra/testdata/dnn/download_models.py \ | ||
--cleanup \ | ||
--dst '${{ env.DNN_MODELS }}/dnn' | ||
echo "OPENCV_DNN_TEST_DATA_PATH=${{ env.DNN_MODELS }}" >> $GITHUB_ENV | ||
|
||
- if: ${{ github.event.repository.name != 'opencv_contrib' }} | ||
name: Configure and build OpenCV | ||
uses: ./configure-and-build | ||
with: | ||
workdir: '${{ github.workspace }}' | ||
builddir: 'build' | ||
generator: '${{ matrix.vs }}' | ||
options: '-A ${{ matrix.cmake_arch }} ${{ env.CMAKE_OPT }}' | ||
|
||
- name: Configure and build OpenCV with contrib | ||
uses: ./configure-and-build | ||
with: | ||
workdir: '${{ github.workspace }}' | ||
builddir: 'build-contrib' | ||
generator: '${{ matrix.vs }}' | ||
options: '-A ${{ matrix.cmake_arch }} -DOPENCV_EXTRA_MODULES_PATH=opencv_contrib/modules ${{ env.CMAKE_OPT }}' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's add x86 32 bit configuration too. No vulkan, no uwp, just build and test.