我正在尝试使用cmake ..构建Mapbox GL Native,所以我从GitHub克隆了存储库:
$ git clone https://github.com/mapbox/mapbox-gl-native.git
$ cd mapbox-gl-native
$ mkdir build && cd build
$ cmake ./
然后它返回错误:
CMake Error at node_modules/@mapbox/cmake-node-module/module.cmake:126 (add_library):
Target "mbgl-node.abi-64" links to target "OpenGL::OpenGL" but the target
was not found. Perhaps a find_package() call is missing for an IMPORTED
target, or an ALIAS target is missing?
Call Stack (most recent call first):
platform/node/CMakeLists.txt:9 (add_node_module)
CMake Error at node_modules/@mapbox/cmake-node-module/module.cmake:126 (add_library):
Target "mbgl-node.abi-64" links to target "OpenGL::OpenGL" but the target
was not found. Perhaps a find_package() call is missing for an IMPORTED
target, or an ALIAS target is missing?
Call Stack (most recent call first):
platform/node/CMakeLists.txt:9 (add_node_module)
CMake Error at node_modules/@mapbox/cmake-node-module/module.cmake:126 (add_library):
Target "mbgl-node.abi-57" links to target "OpenGL::OpenGL" but the target
was not found. Perhaps a find_package() call is missing for an IMPORTED
target, or an ALIAS target is missing?
Call Stack (most recent call first):
platform/node/CMakeLists.txt:9 (add_node_module)
我需要heeeelp,我一直在这里尝试解决此问题,但我不知道可能是什么问题。
多谢你们!
如果在ENV路径中定义了OpenGL库路径安装,则需要将其设置CMAKE_PREFIX_PATH
为OpenGL安装路径(可以在顶级CMakeList.txt中进行设置)。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句