[prev in list] [next in list] [prev in thread] [next in thread]
List: mysql-plusplus
Subject: Re: Header not found
From: Kaplenko Vitalij <dij () zm ! kh ! ua>
Date: 2007-04-16 16:57:14
Message-ID: 4623AAEA.3090205 () zm ! kh ! ua
[Download RAW message or body]
Hi!
For first try to compile this one:
---------------------------------
test.cpp:
#include <mysql++.h>
int main(int argc, char *argv[])
{
return 0;
}
---------------------------------
If you try like this:
>g++ -c test.cpp
You recive:
test.cpp:27:21: error: mysql++.h: No such file or directory
If you try like this:
>g++ -c -I/usr/local/include/mysql++ -I/usr/include/mysql test.cpp
It will be Ok and you'l got "test.o"-file.
Andrea Giusto wrote:
>Hi
>
>I am a total newbie to SQL! I use debian, I have installed the library,
>everything is fine except that the following code won't compile
>
>#include <mysql++.h>
>
>#include <iostream>
>#include <iomanip>
>#include <string>
>
>using namespace std;
>
>int main(int argc, char *argv[])
>{
> mysqlpp::Connection con(false);
> if(!connect_to_db(argc,argv,con)){
> return 1;
> }
> mysqlpp::Query query = con.query();
> query << "create table foo( foo int )";
>
> return 0;
>}
>
>when I try to g++ it I receive
>
>main.cpp:1:21: error: mysql++.h: No such file or directory
>main.cpp: In function ‘int main(int, char**)':
>main.cpp:11: error: ‘mysqlpp' has not been declared
>main.cpp:11: error: expected `;' before ‘con'
>etc...
>
>I checked, the header file is there, I also tried the -L option of g++. Also
>the examples won't compile issuing the same error...please help!!!
>
>
>
--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsub=mysql-plusplus@progressive-comp.com
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic