List:MySQL++« Previous MessageNext Message »
From:Steve Povilaitis Date:February 1 2006 3:05pm
Subject:RE: Another newbie here...
View as plain text  
> -----Original Message-----
> From: Brian Henning [mailto:brian@stripped] 
> % g++ -I/usr/local/include/mysql++ -o testmysql testmysql.cpp
> results in (as you experienced folks might guess) a huge 
> vomitous mass of compiler errors.


I'm using gcc on RHEL. These are some of the things I had to do to get my
stuff compiled:

1. Make sure I had all the necessary MySQL and MySQL ++ components:
a. Server
b. Client
c. Headers and Libraries
d. Shared Libraries

2. Had to run the following command to configure my shared libraries

/sbin/ldconfig /usr/local/lib

And add the following line to /etc/

3. In my makefile include the proper libs. For example I have the following
macro substitutions in my makefile:

# Specify include path for mySQL header files
CCFLAGS += -I/usr/include/mysql

# Specify include path for mySQL++ header files
CCFLAGS += -I/usr/local/include/mysql++

# Specify include path for mySQL client library
LDFLAGS += -L/usr/lib/mysql -lmysqlclient

# Specify include path for mySQL++ library
LDFLAGS += -L/usr/local/include/mysql++ -lmysqlpp

Hope this helps,


This e-mail and any attachments are provided through AEgis 
Technologies' e-mail services and may contain company sensitive and/or 
privileged information. If you are not the intended recipient, please 
notify the sender immediately by return e-mail, delete this e-mail and 
destroy any copies. Any dissemination or use of this information by a 
person other than the intended recipient is unauthorized and may be 
Another newbie here...Brian Henning1 Feb
  • RE: Another newbie here...Steve Povilaitis1 Feb
  • Re: Another newbie here...Warren Young2 Feb