gpt4 book ai didi

linux -/usr/bin/ld : cannot find -lGL Xubuntu 12. 10 AMD 开源

转载 作者:太空宇宙 更新时间:2023-11-04 09:04:01 24 4
gpt4 key购买 nike

我正在尝试从以下网站编译示例:http://www.opengl-tutorial.org/beginners-tutorials/tutorial-1-opening-a-window/

起初 CMake 无法找到 libGL.so,所以我将其指向 lib 所在的位置 (/usr/lib/x86_64-linux-gnu/mesa/libGL.so) txt文件。之后,我尝试了make all,这给了我以下错误:/usr/bin/ld: cannot find -lGL。根据我的发现,这意味着 ld 无法找到 libGL.so,但是如果我键入 locate libGL,我会得到以下响应:

/home/jacko/.local/share/Steam/SteamApps/common/Cave Story+/lib/libGLU.so.1
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/lib/i386-linux-gnu/libGLEW.so.1.6
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/lib/i386-linux-gnu/libGLEW.so.1.6.0
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/lib/i386-linux-gnu/libGLU.so.1
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/lib/i386-linux-gnu/libGLU.so.1.3.08004
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime/i386/usr/share/doc/nvidia-cg-toolkit/examples/Tools/trace/libGL.so.1.gz
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime.old/i386/usr/lib/i386-linux-gnu/libGLEW.so.1.6
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime.old/i386/usr/lib/i386-linux-gnu/libGLEW.so.1.6.0
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime.old/i386/usr/lib/i386-linux-gnu/libGLU.so.1
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime.old/i386/usr/lib/i386-linux-gnu/libGLU.so.1.3.08004
/home/jacko/.local/share/Steam/ubuntu12_32/steam-runtime.old/i386/usr/share/doc/nvidia-cg-toolkit/examples/Tools/trace/libGL.so.1.gz
/opt/cave-story-plus/lib64/libGLU.so.1
/usr/lib/i386-linux-gnu/libGLU.so.1
/usr/lib/i386-linux-gnu/libGLU.so.1.3.1
/usr/lib/i386-linux-gnu/mesa/libGL.so.1
/usr/lib/i386-linux-gnu/mesa/libGL.so.1.2.0
/usr/lib/x86_64-linux-gnu/libGLU.a
/usr/lib/x86_64-linux-gnu/libGLU.so
/usr/lib/x86_64-linux-gnu/libGLU.so.1
/usr/lib/x86_64-linux-gnu/libGLU.so.1.3.1
/usr/lib/x86_64-linux-gnu/mesa/libGL.so
/usr/lib/x86_64-linux-gnu/mesa/libGL.so.1
/usr/lib/x86_64-linux-gnu/mesa/libGL.so.1.2.0
/usr/lib/x86_64-linux-gnu/qtcreator/libGLSL.so
/usr/lib/x86_64-linux-gnu/qtcreator/libGLSL.so.1
/usr/lib/x86_64-linux-gnu/qtcreator/libGLSL.so.1.0
/usr/lib/x86_64-linux-gnu/qtcreator/libGLSL.so.1.0.0
/usr/lib/x86_64-linux-gnu/qtcreator/plugins/Nokia/libGLSLEditor.so
/usr/lib32/libGL.so

在我看来,libGL 完全可用。

还有:

~$ sudo apt-get install libgl1-mesa-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libgl1-mesa-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

我正在运行带有开源 AMD 驱动程序的 Xubuntu 12.10。

最佳答案

如果其他人也遇到此问题:/usr/lib/x86_64-linux-gnu/libGL.so 和/usr/lib/x86_64-linux-gnu/mesa/libGL.so 之间的符号链接(symbolic link)消失了。我做了 sudo apt-get remove --purge libgl1-mesa-devsudo apt-get install ibgl1-mesa-dev* libglu1-mesa-dev* libqt4-opengl-dev* qt -sdk* 来解决这个问题。

关于linux -/usr/bin/ld : cannot find -lGL Xubuntu 12. 10 AMD 开源,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15026334/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com