PDA

View Full Version : Eclipse can't find mysql.h


zjunkie
September 17th, 2009, 12:17 AM
I'm having a bit of trouble building some source code that uses mysql. Eclipse is saying that it has an "unresolved inclusion: <mysql.h>"

I have installed libmysqlclient-dev and the .h file is under /usr/include/mysql/mysq.h

Is there an environment variable that I am missing?

dinxter
September 27th, 2009, 09:30 AM
one of the default paths included is /usr/include so the line would be
#include <mysql/mysql.h>
or you can add the directory /usr/include/mysql to eclipse in project->properties->c/c++ build->settings
to the various compilers/linkers in which case your previous line would work