-
Notifications
You must be signed in to change notification settings - Fork 120
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
fails to cmake config+build on Windows using cmake and vscode (hunter pain) #246
Comments
@diablodale does the build work correctly if done outside VSCode? (eg. following specified build commands in README.md) Seems like an environment issue on first glance. |
Testing... |
I isolated and fixed the cmake harness of depthai-core to enables building depthai-core from vscode or command line. Errant things included depth-ai's cmake code, a lack-of-features, related #72, and/or due to opencv's inconsistent transitive library declarations. How to useHunter is limited and has to be told about the build environment directly -- it doesn't respect or infer it from a parent environment like VSCode. This is done by specifying the Quick howto for vscode
Because of more Hunter pain, you can NOT if(NOT DEFINED HUNTER_MSVC_ARCH)
set(CMAKE_VS_MSBUILD_COMMAND "C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/MSBuild/Current/Bin/MSBuild.exe")
endif()
set(DEPTHAI_DEPENDENCY_INCLUDE "${CMAKE_SOURCE_DIR}/cmake/my-extra-include.cmake") And last, you can set the cmake var set(THIRDPARTY_OPENCV_LIBRARIES TBB::tbb) |
* enable build in vscode, custom toolchain+include - fixes luxonis#246
* self doc dependency options with set(cache) * enable build in vscode, custom toolchain+include * fixes luxonis#246
depthai-core fails to config (and therefore can't build) on a clean repo and using VSCode.
Cascading failures in hunter.
Setup
Repro
git clone https://github.com/luxonis/depthai-core
into an empty folder.git checkout c1b697afa432c8d620b097ba57e20a0ffd2ec52d
so to have less variations in the setup.depthai-core
folder. Selectyes
to trust.NOT NOW
andNOT THIS WORKSPACE
at the configure project popup.BUILD_SHARED_LIBS
is not declared anywhere, it should be a static library buildResult
If you want to continue down the path of pain...
15. create/edit the .vscode/settings.json file
git submodule update --init --recursive
if it was not already doneResult
it goes a few seconds longer then
Expected
Clean build with no errors.
The text was updated successfully, but these errors were encountered: