Insta360Develop / CameraSDK-Cpp

CameraSDK-Cpp is a C++ library to control Insta360 cameras.
https://www.insta360.com
115 stars 16 forks source link

ld: library not found for -lCameraSDK, How to run the sample in macos #14

Open allenzerg001 opened 1 year ago

allenzerg001 commented 1 year ago

I got the error below when I download the full sdk from offical website I execute this command step by step

cmake .
make

full error below:

CMake Warning (dev) at CMakeLists.txt:25:
  Syntax Warning in cmake code at column 30

  Argument not separated from preceding token by whitespace.
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at CMakeLists.txt:26:
  Syntax Warning in cmake code at column 44

  Argument not separated from preceding token by whitespace.
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at CMakeLists.txt:27:
  Syntax Warning in cmake code at column 39

  Argument not separated from preceding token by whitespace.
This warning is for project developers.  Use -Wno-dev to suppress it.

-- iokit dir: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/IOKit.framework
-- core foundation lib dir: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/CoreFoundation.framework
-- camera sdk lib dir: CameraSDK_LIB-NOTFOUND
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/allen/Works/workspace/insta360sdk/WindowsSDK20220917/CameraSDKWindows/build
Consolidate compiler generated dependencies of target CameraSDKTest
[ 33%] Building CXX object CMakeFiles/CameraSDKTest.dir/cmake-build-debug/CMakeFiles/3.23.2/CompilerIdCXX/CMakeCXXCompilerId.cpp.o
[ 66%] Building CXX object CMakeFiles/CameraSDKTest.dir/main.cc.o
[100%] Linking CXX executable /Users/allen/Works/workspace/insta360sdk/WindowsSDK20220917/CameraSDKWindows/bin/CameraSDKTest
ld: library not found for -lCameraSDK
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [/Users/allen/Works/workspace/insta360sdk/WindowsSDK20220917/CameraSDKWindows/bin/CameraSDKTest] Error 1
make[1]: *** [CMakeFiles/CameraSDKTest.dir/all] Error 2
make: *** [all] Error 2
Tianweihaihaihai commented 1 year ago

need to write include path and library path of camera sdk on cmakelists.txt