2.3 KiB
2.3 KiB
编译 on Windows
Windows 10
前提条件
最终,命令提示符(Command Prompt, cmd)里可找到如下命令:
>cmake --version
cmake version 3.10.1
>git --version
git version 2.11.1.windows.1
>doxygen --version
1.8.13
- Visual Studio
- [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
以 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)里可找到如下命令:
>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 MSYS ,然后执行:
$ pacman -Syu
$ pacman -S make
并在系统环境变量 PATH
里添加上如下路径:
C:\msys64\usr\bin
最终,命令提示符(Command Prompt, cmd)里可找到如下命令:
>make --version
GNU Make 4.2.1
获取代码
>git clone https://github.com/slightech/MYNT-EYE-SDK-2.git
准备依赖
>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
编译代码
>make install