无法在 CMAKE_CXX_LIBRARY_ARCHITECTURE“”的“”中找到 "glu32"

Failed to find "glu32" in "" with CMAKE_CXX_LIBRARY_ARCHITECTURE ""

我正在尝试编译 cryptonotecoinwallet repo using CMake with VS2010 compiler (according to the comments I got for this question)

我尝试将以下行添加到 CMake 文件和缓存文件中,但没有成功。

set (CMAKE_PREFIX_PATH "C:\Program Files\Microsoft SDKs\Windows\v7.1\Lib\x64")

我尝试使用命令行编译它,但得到了同样的错误。

D:\My Documents\Fiverr\C++ and Qt\FitsoCoin\cryptonotewallet>cmake.exe -DBOOST_ROOT=C:\boost_1_66_0 -DBOOST_LIBRARYDIR=C:\boost_1_66_0\lib32-msvc-1
0.0:C:\boost_1_66_0\libs  -G "Visual Studio 10 2010" .
CMake Error at C:/Qt/Qt5.2.0/5.2.0/msvc2010_opengl/lib/cmake/Qt5Gui/Qt5GuiConfigExtras.cmake:16 (message):
  Failed to find "glu32" in "" with CMAKE_CXX_LIBRARY_ARCHITECTURE "".
Call Stack (most recent call first):
  C:/Qt/Qt5.2.0/5.2.0/msvc2010_opengl/lib/cmake/Qt5Gui/Qt5GuiConfigExtras.cmake:52 (_qt5gui_find_extra_libs)
  C:/Qt/Qt5.2.0/5.2.0/msvc2010_opengl/lib/cmake/Qt5Gui/Qt5GuiConfig.cmake:152 (include)
  CMakeLists.txt:19 (find_package)

有什么解决办法吗?

谢谢。

如果您想将 CMake(和 Find* 脚本)指向包含库的目录,请设置 CMAKE_LIBRARY_PATH 变量:

set(CMAKE_LIBRARY_PATH "C:/Program Files/Microsoft SDKs/Windows/v7.1/Lib/x64")

您尝试设置的

变量 CMAKE_PREFIX_PATH 应指向 安装前缀 。搜索库时使用此前缀,但仅在其后附加 lib/ 等子目录。