On Fri, 16 Nov 2007 17:15:57 +0100, Stefan Kristensen wrote:
> Hello my experienced friends.
>
> As previously stated, I'm refreshing my C++ on a FreeBSD box and the
> basics are pretty much in place now. So time to move on: Accessing MySQL
> databases from C++.
> As I see it, there is a wrapper class that makes it somewhat easier than
> using the C API. But already at the #include "mysql.h" line, I get an
> error: No such file or directory. I have installed MySQL and MySQL++1
> (MySQL++ reported something as broken) and can see mysql.h in
> /usr/local/include/mysql
>
> So: How do I tell g++ where to look for include files?
Most likely /usr/local/include will be on the include path for your g++
by default, so:
#include "mysql/mysql.h"
should work.
Otherwise, you can tell g++ to search a directory for included headers
via the -I flag. See:
http://gcc.gnu.org/onlinedocs/gcc-4.2.2/gcc/Directory-Options.html
for details.
Cheers,
--
Lionel B
_______________________________________________
help-gplusplus mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gplusplus