Reputation: 21
When I follow the instruction on https://github.com/OpenKinect/libfreenect2 to install libfreenect2 on Windows 10. I have trouble building libUSB related files.
Initially, I installed libUSB using git but I received following message (but not appeared as an error)
Build succeeded.
"D:\Tools\Kinect\libfreenect2-
master\depends\libusb_src\msvc\libusb_dll_2015.vcxproj" (Rebuild target) (1)
->
(Link target) ->
..\libusb\libusb-1.0.def : warning LNK4197: export 'libusb_set_option'
specified multiple times; using first specification
[D:\Tools\Kinect\libfreenect2-master\depends\libusb_src\msvc\libusb_dll_2015.vcxproj]
1 Warning(s)
0 Error(s)
Time Elapsed 00:00:05.43
D:\Tools\Kinect\libfreenect2master\depends\libusb_src>"D:\Tools\Compiler\MSBuild\15.0\Bin\MSBuild.exe" msvc\libusb_usbdk_dll_2015.vcxproj /p:Platform=x64 /p:Configuration=Release /target:Rebuild || exit /b
Microsoft (R) Build Engine version 15.5.180.51428 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.
MSBUILD : error MSB1009: Project file does not exist.
Switch: msvc\libusb_usbdk_dll_2015.vcxproj
Then I use CMAKE to build the whole project but with following error.
Selecting Windows SDK version to target Windows 10.0.16299.
The C compiler identification is MSVC 19.12.25835.0
The CXX compiler identification is MSVC 19.12.25835.0
Check for working C compiler:
D:/Tools/Compiler/VC/Tools/MSVC/14.12.25827/bin/Hostx86/x64/cl.exe
Check for working C compiler:
D:/Tools/Compiler/VC/Tools/MSVC/14.12.25827/bin/Hostx86/x64/cl.exe -- works
Detecting C compiler ABI info
Detecting C compiler ABI info - done
Check for working CXX compiler:
D:/Tools/Compiler/VC/Tools/MSVC/14.12.25827/bin/Hostx86/x64/cl.exe
Check for working CXX compiler:
D:/Tools/Compiler/VC/Tools/MSVC/14.12.25827/bin/Hostx86/x64/cl.exe -- works
Detecting CXX compiler ABI info
Detecting CXX compiler ABI info - done
Detecting CXX compile features
Detecting CXX compile features - done
using tinythread as threading library
Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
Performing Test LIBUSB_WITH_LIBUSBK
Performing Test LIBUSB_WITH_LIBUSBK - Failed
Performing Test LIBUSB_WITH_USBDK
Performing Test LIBUSB_WITH_USBDK - Success
CMake Error at D:/Tools/Kinect/Setups/cmake-3.10.2-win64-x64/cmake-3.10.2-
win64-x64/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137
(message):
**Could NOT find LibUSB (missing: LibUSB_LIBRARIES LibUSB_INCLUDE_DIRS)**
Call Stack (most recent call first):
D:/Tools/Kinect/Setups/cmake-3.10.2-win64-x64/cmake-3.10.2-win64-x64/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
cmake_modules/FindLibUSB.cmake:102 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:93 (FIND_PACKAGE)
Configuring incomplete, errors occurred!
See also "D:/Tools/Kinect/installed/CMakeFiles/CMakeOutput.log".
See also "D:/Tools/Kinect/installed/CMakeFiles/CMakeError.log".
I have tried using Visual Studio to build libUSB using .sln file but the result was same.
I have tried all methods I know but it still could find libUSB files I build.
Thank you for your answer in advance.
Sincerely
Upvotes: 2
Views: 663