Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
1114cbf6
Commit
1114cbf6
authored
Aug 31, 2017
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #9514 from LaurentBerger:docInsWin
parents
d0f90205
82ad0749
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
74 additions
and
0 deletions
+74
-0
windows_install.markdown
...als/introduction/windows_install/windows_install.markdown
+74
-0
No files found.
doc/tutorials/introduction/windows_install/windows_install.markdown
View file @
1114cbf6
...
...
@@ -24,6 +24,80 @@ Installation by Using the Pre-built Libraries {#tutorial_windows_install_prebuil
-# To finalize the installation go to the @ref tutorial_windows_install_path section.
Installation by Using git-bash (version>=2.14.1) and cmake (version >=3.9.1){#tutorial_windows_gitbash_build}
===============================================================
-# You must download
[
cmake (version >=3.9.1)
](
https://cmake.org
)
and install it. You must add cmake to PATH variable during installation
-# You must install
[
git-bash (version>=2.14.1)
](
https://git-for-windows.github.io/
)
. Don't add git to PATH variable during installation
-# Run git-bash. You observe a command line window.
Suppose you want to build opencv and opencv_contrib in c:/lib
-# In git command line enter following command (if folder does not exist) :
@code{.bash}
mkdir /c/lib
cd /c/lib
@endcode
-# save this script with name installOCV.sh in c:/lib
@code{.bash}
#!/bin/bash -e
myRepo=$(pwd)
CMAKE_CONFIG_GENERATOR="Visual Studio 14 2015 Win64"
if
[
! -d "$myRepo/opencv"
]
; then
echo "clonning opencv"
git clone https://github.com/opencv/opencv.git
mkdir Build
mkdir Build/opencv
mkdir Install/opencv
else
cd opencv
git pull --rebase
cd ..
fi
if
[
! -d "$myRepo/opencv_contrib"
]
; then
echo "clonning opencv_contrib"
git clone https://github.com/opencv/opencv_contrib.git
mkdir Build
mkdir Build/opencv_contrib
else
cd opencv_contrib
git pull --rebase
cd ..
fi
RepoSource=opencv
pushd Build/$RepoSource
CMAKE_OPTIONS='-DBUILD_PERF_TESTS:BOOL=OFF -DBUILD_TESTS:BOOL=OFF -DBUILD_DOCS:BOOL=OFF -DWITH_CUDA:BOOL=OFF -DBUILD_EXAMPLES:BOOL=OFF -DINSTALL_CREATE_DISTRIB=ON'
cmake -G"$CMAKE_CONFIG_GENERATOR" $CMAKE_OPTIONS -DOPENCV_EXTRA_MODULES_PATH="$myRepo"/opencv_contrib/modules -DCMAKE_INSTALL_PREFIX="$myRepo"/install/"$RepoSource" "$myRepo/$RepoSource"
echo "
************************
*
$Source_DIR -->debug"
cmake --build . --config debug
echo "
************************
*
$Source_DIR -->release"
cmake --build . --config release
cmake --build . --target install --config release
cmake --build . --target install --config debug
popd
@endcode
In this script I suppose you use VS 2015 in 64 bits
@code{.bash}
CMAKE_CONFIG_GENERATOR="Visual Studio 14 2015 Win64"
@endcode
and opencv will be installed in c:/lib/install
@code{.bash}
-DCMAKE_INSTALL_PREFIX="$myRepo"/install/"$RepoSource" "$myRepo/$RepoSource"
@endcode
with no Perf tests, no tests, no doc, no CUDA and no example
@code{.bash}
CMAKE_OPTIONS='-DBUILD_PERF_TESTS:BOOL=OFF -DBUILD_TESTS:BOOL=OFF -DBUILD_DOCS:BOOL=OFF -DWITH_CUDA:BOOL=OFF -DBUILD_EXAMPLES:BOOL=OFF'
@endcode
-# In git command line enter following command :
@code{.bash}
./installOCV.sh
@endcode
-# Drink a coffee or two... opencv is ready : That's all!
-# Next time you run this script, opencv and opencv_contrib will be updated and rebuild
Installation by Making Your Own Libraries from the Source Files {#tutorial_windows_install_build}
===============================================================
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment