3

I installed Linux Debian yesterday and then the latest Qt version. Today I installed gcc and g++. But the problem is, it doesn't build and run when I create a GUI Application.

Whenever I create a new Project, select the gui and don't even change anything it doesn't compile and I get this message :

/usr/bin/ld: cannot find -lGL collect2: error: ld returned 1 exit status make: * [untitled] Error 1 14:17:36: The process "/usr/bin/make" exited with code 2. Error while building/deploying project untitled (kit: Desktop Qt 5.1.1 GCC 64bit) When executing step 'Make'

Seems like I'm missing a library but I don't know how to install it. I don't even know which one it is.

Can anyone help me?

4

2 回答 2

2

尝试:

apt-get 安装 libgl1-mesa-glx

开发包实际上不是问题。您有链接器错误,而不是编译器错误。

根据您的显卡,您可能会使用专门的 OpenGL 实现,例如libgl1-nvidia-glxNVIDA 卡之类的东西。

于 2013-09-01T12:35:59.763 回答
1

显然,您需要安装 openGL 开发包。抱歉,不记得包名。

于 2013-09-01T12:26:26.600 回答