This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Linking problem
- From: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- To: rebelstar <kishore3385 at yahoo dot co dot in>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Mon, 27 Feb 2012 23:43:08 +0000
- Subject: Re: Linking problem
- Authentication-results: mr.google.com; spf=pass (google.com: domain of jwakely.gcc@gmail.com designates 10.152.130.102 as permitted sender) smtp.mail=jwakely.gcc@gmail.com; dkim=pass header.i=jwakely.gcc@gmail.com
- References: <33403514.post@talk.nabble.com>
On 27 February 2012 23:18, rebelstar wrote:
>
> Hi,
>
> I am trying to build a piece of code on 64 bit linux machine gcc ( ++
> compiler ) on eclipse IDE
>
> In the linking stage,it throws an error
>
> Invoking: GCC C++ Linker
> g++ -L/home/a0133140/bcpmodel/bcptest/ -o"test" ?./main.o ./wrapper.o
> -lmylib64
> /usr/bin/ld: cannot find -lmylib64
> collect2: ld returned 1 exit status
>
> I have included the library in the workfolder and tried giving full path
> name,absolute path etc..no success..
> ( The name of the library is mylib64.a)
-lmylib64 makes the linker look for libmylib64.so or libmylib64.a, so
your library has the wrong name.