collect2: ld returned 1 exit status
I have latest qt to a ubuntu system.I am taking this error collect2: ld returned 1 exit status
in build issues and this in compile output
/usr/bin/ld: cannot find -lfreetype
collect2: ld returned 1 exit status
make: *** [test] Error 1
make: Leaving directory `/home/joe/QtProjects/test'
Exited with code 2.
Error while building project test
When executing build step 'Make'
any help to fix that problem i can't run qt in linux....please help me
Re: collect2: ld returned 1 exit status
What library paths did you specify?
Re: collect2: ld returned 1 exit status
... and is freetype (or freetype-dev) installed at all?
Re: collect2: ld returned 1 exit status
I have download this:
Code:
http://www.qtsoftware.com/downloads/sdk-linux-x11-32bit-cpp
and i installed it in ubuntu 9.04.I did just a simple install.At first i had a problem with g++ so i did
Code:
sudo apt-get install g++
Now i have this problem
Code:
collect2: ld returned 1 exit status
In an other box i have installed the windows version which compiling correct
What should i fix??
Re: collect2: ld returned 1 exit status
I fixed the problem:D
I had more errors like:
Code:
/usr/bin/ld: cannot find -lfreetype ---> libfreetype from synaptic package manager
Code:
/usr/bin/ld: cannot find -lSM ---> libsm
Code:
/usr/bin/ld: cannot find -lXext ----> libxext
The solution for the other newbies like me who have the same problems is to install from synaptic package manager the correct libs.
Re: collect2: ld returned 1 exit status
sudo apt-get install build-essential
is always a good start...
Re: collect2: ld returned 1 exit status
What if the error is cannot find -lssl and ssl package is installed? and on /usr/lib there is a libssl.a ; libssl.so ; libssl.so.0.9.8 and libssl3.so
The .so files only libssl3.so doesn't have the shortcut arrow on the icon.
same thing happened to -ljpeg... and I have libjpeg installed too.
What could be wrong?
Re: collect2: ld returned 1 exit status
Development libraries / packages are often marked as libwhatever-dev, so maybe try to install libjpeg-dev, or something like that.
Re: collect2: ld returned 1 exit status
Quote:
Originally Posted by
stampede
Development libraries / packages are often marked as libwhatever-dev, so maybe try to install libjpeg-dev, or something like that.
It is already installed... every libjpeg or libssl related package is installed... except for libjpeg62-dev as libjpeg8-dev is installed... but I also tried with 62 and still same error...
Re: collect2: ld returned 1 exit status
Can you post the compilation command ? Make sure that you specify correct path for the linker with -L"path to lib" switch