Re: /usr/bin/ld: cannot find -lmysqlcppconn

  • From: Paulo Panhoto < >
  • To:
  • Subject: Re: /usr/bin/ld: cannot find -lmysqlcppconn
  • Date: Thu, 13 Dec 2012 15:08:42 -0200

If your linux is 64bit, files must be present in /usr/lib64. If you want to compile a 32bit in a 64bit distro, you should also pass the -m32 switch to the compiler.


On Thu, Dec 13, 2012 at 4:29 AM, "> < " target="_blank"> > wrote:
[quote="Paulo Panhoto"]Also, the files that must be present in those directories, for a library xxxx are named libxxxx.so or libxxxx.a

Example:

mysqlcppconn => libmysqlcppconn.so



On Wed, Dec 12, 2012 at 2:57 PM, <address-removed (address-removed)> wrote:

>  ----- Original Message -----
>
> > Hi
> >
> > New in c++ and im trying to connect to mysql database did in java
> > works fine.when to do it in c++ project followed all the instruction
> > from http://planet.mysql.com/entry?id=18341;but (http://planet.mysql.com/entry?id=18341;but) it gives me this
> > error.
> >
> > g++ -o dist/Debug/GNU-Linux-x86/cppapplication_2
> > build/Debug/GNU-Linux-x86/main.o -L/usr/local/lib
> > -L/usr/local/include/mysql-connector-c++-1.0.5-linux-glibc2.3-x86-32bit
> > -lmysqlcppconn -lmysqlcppconn-static -lmysql -lmysqlclient
> > /usr/bin/ld: cannot find -lmysqlcppconn
> > /usr/bin/ld: cannot find -lmysqlcppconn-static
> > /usr/bin/ld: cannot find -lmysql
> > /usr/bin/ld: cannot find -lmysqlclient
> >
>
>
> Do you understand what the link editor is trying to do?
>
> Are the libraries (specified with the -l option) to be found either in library search paths (specified by -L) or the system directories (like /usr/lib)?
>
>
> > Please help my boss wants this c++ for what reason i dnt know.
> >
>
>
> He has good taste ;-)
>
> A+
> Paul
>


Yes their named mysqlcppconn => libmysqlcppconn.so







/usr/bin/ld: cannot find -lmysqlcppconn

12/12/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

paulf 12/12/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

Paulo Panhoto 12/12/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/13/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/13/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

Paulo Panhoto 12/13/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

paulf 12/14/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/14/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/14/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

Paulo Panhoto 12/14/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/14/2012

Re: /usr/bin/ld: cannot find -lmysqlcppconn

Paulo Panhoto 12/14/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/18/2012

/usr/bin/ld: cannot find -lmysqlcppconn

12/20/2012

Project Features

About this Project

CND was started in November 2009, is owned by DimaZh, and has 187 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20160708.bf2ac18). © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close