LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 03-11-2008, 04:23 PM   #1
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 540

Rep: Reputation: 30
Ubuntu can't build, I get "cannot find -lGL" error


Hello. I'm trying to build mythtv. I am getting the following error during the "make" process:

/usr/bin/ld: cannot find -lGL

I've installed all kinds of dependencies and packages and now just don't know what to do.

Ubuntu 7.04 desktop is the os.

Does anyone have any ideas what this means? I googled it and found next to nothing except for a couple of guys saying install so and so package which i did.

-Thanks
-Steve
 
Old 03-11-2008, 04:46 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,384

Rep: Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963Reputation: 1963
well it's after the OpenGL library, and to compile against it you need to headers for it. for just mesaGL, install libgl-dev and you should be ok, but are you not aware that mythtv is in apt under ubuntu? no need to compile anything yourself... "sudo apt-get install mythtv"
 
Old 03-11-2008, 05:19 PM   #3
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 540

Original Poster
Rep: Reputation: 30
OK, I tried apt-get install libgl-dev, but it says:

Code:
Package libgl-dev is a virtual package provided by:
  libgl1-mesa-swx11-dev 6.5.2-3ubuntu8
  libgl1-mesa-dev 6.5.2-3ubuntu8
You should explicitly select one to install.
E: Package libgl-dev has no installation candidate

i tried an apt-get install libgl1-mesa-dev, but it is already installed.

Upon trying atp-get install libgl1-mesa-swx11-dev, i got this:

Code:
The following extra packages will be installed:
  libgl1-mesa-swx11
The following packages will be REMOVED:
  libgl1-mesa-dev libgl1-mesa-dri libgl1-mesa-glx libgl1-mesa-glx-dbg
  nvidia-glx ubuntu-desktop xorg
The following NEW packages will be installed:
  libgl1-mesa-swx11 libgl1-mesa-swx11-dev
0 upgraded, 2 newly installed, 7 to remove and 99 not upgraded.
Need to get 1961kB of archives.
After unpacking 49.2MB disk space will be freed.
Do you want to continue [Y/n]?

That doesn't look good to me. i don't want to remove that stuff.

Any ideas?

The main reason i'm trying to build it myself is to learn how to do linux builds, also, i want to run the svn version of mythtv.
-Thanks
 
Old 03-12-2008, 08:42 AM   #4
berbae
Member
 
Registered: Jul 2005
Location: France
Distribution: Arch Linux
Posts: 540

Rep: Reputation: Disabled
Quote:
/usr/bin/ld: cannot find -lGL
This message means that ld needs the libGL.la library.
It is provided by the nvidia-glx-dev package.
As I see you already have the nvidia-glx package installed, you only need to add the nvidia-glx-dev package to get the needed file.
I hope that it will be enough to build mythtv.
 
Old 03-12-2008, 10:18 AM   #5
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 540

Original Poster
Rep: Reputation: 30
Very Odd...

I tried a "sudo apt-get install nvidia-glx-dev"

And got this message:

(trimmed)
Code:
Unpacking nvidia-glx-dev (from .../nvidia-glx-dev_1%3a1.0.9631+2.6.20.6-16.30_i386.deb) ...
dpkg-divert: `diversion of /usr/lib/libGL.so to /usr/lib/nvidia/libGL.so.xlibmesa by nvidia-glx-dev' clashes with `diversion of /usr/lib/libGL.so to /usr/lib/nvidia/libGL.so.xlibmesa by nvidia-glx'
dpkg: error processing /var/cache/apt/archives/nvidia-glx-dev_1%3a1.0.9631+2.6.20.6-16.30_i386.deb (--unpack):
 subprocess pre-installation script returned error exit status 2
Errors were encountered while processing:
 /var/cache/apt/archives/nvidia-glx-dev_1%3a1.0.9631+2.6.20.6-16.30_i386.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)


I've never seen anything like this. What can i do?
-Thanks
 
Old 03-13-2008, 11:18 AM   #6
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 540

Original Poster
Rep: Reputation: 30
OK, so i figured it out. Your nvidia problem pointed me in the right direction. Here's what i did:

apt-get install nvidia-glx-new

Then

delete /usr/lib/libGL.so
then run
cd /usr/lib/
sudo ln -s libGL.so.1.0.9755 libGL.so



Now i can compile just fine.

-Thanks again for the help
 
Old 05-18-2008, 03:26 PM   #7
re_bound86
LQ Newbie
 
Registered: May 2008
Posts: 1

Rep: Reputation: 0
Or instead of changing files yourself, you could after you've installed

apt-get install nvidia-glx-new

install

apt-get install nvidia-glx-new-dev


And everything should work.



//R
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
initial build of gcc: "cannot find -lc" xlq Linux From Scratch 5 06-03-2007 08:40 AM
Why do I get a "can't find trashcan_full image" every time I start ubuntu? jlpf Linux - General 2 11-02-2006 04:55 AM
perl install error: Can't locate object method "new" via package "Module::Build::Vers powah Linux - Software 0 10-24-2006 01:57 PM
Ntfs-Fuse copy error Debian "Sid" / Ubuntu "6.06" animefriik Linux - General 0 10-06-2006 09:28 AM
Can't install "glibmm" library. "configure" script can't find "sigc++-2.0&q kornerr Linux - General 4 05-10-2005 02:32 PM


All times are GMT -5. The time now is 05:28 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration