Make build on win
This commit is contained in:
@@ -793,6 +793,7 @@ WARN_LOGFILE =
|
||||
INPUT = mainpage.md \
|
||||
guides.md \
|
||||
guide_build_linux.md \
|
||||
guide_build_win.md \
|
||||
guide_samples.md \
|
||||
guide_tools.md \
|
||||
guide_log.md \
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
# 编译 on Linux {#guide_build_linux}
|
||||
|
||||
> Ubuntu 16.04, Ubuntu 14.04
|
||||
|
||||
## 获取代码
|
||||
|
||||
```bash
|
||||
|
||||
103
doc/zh-Hans/guide_build_win.md
Normal file
103
doc/zh-Hans/guide_build_win.md
Normal file
@@ -0,0 +1,103 @@
|
||||
# 编译 on Windows {#guide_build_win}
|
||||
|
||||
> Windows 10
|
||||
|
||||
## 前提条件
|
||||
|
||||
* [Git](https://git-scm.com/downloads),用于获取代码。
|
||||
* [CMake](https://cmake.org/download/),用于构建编译。
|
||||
* [Doxygen](http://www.stack.nl/~dimitri/doxygen/download.html),用于生成文档。
|
||||
|
||||
最终,命令提示符(Command Prompt, cmd)里可找到如下命令:
|
||||
|
||||
```cmd
|
||||
>cmake --version
|
||||
cmake version 3.10.1
|
||||
|
||||
>git --version
|
||||
git version 2.11.1.windows.1
|
||||
|
||||
>doxygen --version
|
||||
1.8.13
|
||||
```
|
||||
|
||||
* [Visual Studio](https://www.visualstudio.com/)
|
||||
* [Visual Studio 2015](https://my.visualstudio.com/Downloads?q=Visual Studio 2015)
|
||||
* [Visual Studio 2017](https://my.visualstudio.com/Downloads?q=Visual Studio 2017)
|
||||
* [Windows 10 SDK](https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk)
|
||||
|
||||
以 Visual Studio 2015 举例,请在系统环境变量 `PATH` 里添加上如下路径:
|
||||
|
||||
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin
|
||||
C:\Program Files (x86)\MSBuild\14.0\Bin
|
||||
|
||||
最终,命令提示符(Command Prompt, cmd)里可找到如下命令:
|
||||
|
||||
```cmd
|
||||
>cl
|
||||
Microsoft (R) C/C++ Optimizing Compiler Version 19.00.24215.1 for x86
|
||||
|
||||
>link
|
||||
Microsoft (R) Incremental Linker Version 14.00.24215.1
|
||||
|
||||
>lib
|
||||
Microsoft (R) Library Manager Version 14.00.24215.1
|
||||
|
||||
>msbuild
|
||||
Microsoft (R) 生成引擎版本 14.0.25420.1
|
||||
```
|
||||
|
||||
* [MSYS2](http://www.msys2.org/)
|
||||
* [国内镜像](https://lug.ustc.edu.cn/wiki/mirrors/help/msys2)
|
||||
* [pacman](https://wiki.archlinux.org/index.php/pacman)
|
||||
|
||||
打开 MSYS2 MSYS ,然后执行:
|
||||
|
||||
```msys
|
||||
$ pacman -Syu
|
||||
$ pacman -S make
|
||||
```
|
||||
|
||||
并在系统环境变量 `PATH` 里添加上如下路径:
|
||||
|
||||
C:\msys64\usr\bin
|
||||
|
||||
最终,命令提示符(Command Prompt, cmd)里可找到如下命令:
|
||||
|
||||
```cmd
|
||||
>make --version
|
||||
GNU Make 4.2.1
|
||||
```
|
||||
|
||||
## 获取代码
|
||||
|
||||
```cmd
|
||||
>git clone https://github.com/slightech/MYNT-EYE-SDK-2.git
|
||||
```
|
||||
|
||||
## 准备依赖
|
||||
|
||||
```cmd
|
||||
>cd mynt-eye-sdk-2
|
||||
>make init
|
||||
Make init
|
||||
Init deps
|
||||
Install cmd: pacman -S
|
||||
Install deps: git clang-format
|
||||
pacman -S clang-format (not exists)
|
||||
error: target not found: clang-format
|
||||
pip install --upgrade autopep8 cpplint pylint requests
|
||||
...
|
||||
Init git hooks
|
||||
ERROR: clang-format-diff is not installed!
|
||||
Expect cmake version >= 3.0
|
||||
cmake version 3.10.1
|
||||
How to upgrade cmake in Ubuntu
|
||||
https://askubuntu.com/questions/829310/how-to-upgrade-cmake-in-ubuntu
|
||||
```
|
||||
|
||||
## 编译代码
|
||||
|
||||
```cmd
|
||||
>make install
|
||||
```
|
||||
@@ -12,6 +12,12 @@
|
||||
|
||||
* [OpenCV](https://opencv.org/),用于显示图像。
|
||||
|
||||
<!--
|
||||
```cmd
|
||||
>set OpenCV_DIR=C:\opencv
|
||||
```
|
||||
-->
|
||||
|
||||
## 编译
|
||||
|
||||
```bash
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
# SDK 指导 {#guides}
|
||||
|
||||
* @subpage guide_build_linux
|
||||
* @subpage guide_build_win
|
||||
* @subpage guide_samples
|
||||
* @subpage guide_tools
|
||||
* @subpage guide_log
|
||||
|
||||
Reference in New Issue
Block a user