Page 1 of 1

Compiling ndoutils: error: expected specifier-qualifier-lis

Posted: Mon Jan 20, 2014 3:05 am
by bkfrvn
Hi all,

I experienced following error while compiling ndoutils 1.5.2
gcc -g -O2 -I/usr/include/mysql -DHAVE_CONFIG_H -c -o db.o db.c
In file included from db.c:17:
../include/ndo2db.h:58: error: expected specifier-qualifier-list before ‘MYSQL’
db.c: In function ‘ndo2db_db_init’:
db.c:128: error: ‘ndo2db_dbconninfo’ has no member named ‘instance_id’
db.c:129: error: ‘ndo2db_dbconninfo’ has no member named ‘conninfo_id’
db.c:130: error: ‘ndo2db_dbconninfo’ has no member named ‘latest_program_status_time’
Here is the use of MYSQL in ndo2db.h

Code: Select all

typedef struct ndo2db_dbconninfo_struct{
	int server_type;
	int connected;
	int error;
#ifdef USE_MYSQL
	MYSQL mysql_conn;
	MYSQL_RES *mysql_result;
	MYSQL_ROW mysql_row;
#endif
#ifdef USE_PGSQL
	PGconn *pgsql_conn;
	PGresult *pgsql_result;
#endif
	unsigned long instance_id;
	unsigned long conninfo_id;


However, I can not find the definition of MYSQL in ndoutils source code.

Could any one give me a suggestion?

Many thanks,
Giang.

Re: Compiling ndoutils: error: expected specifier-qualifier

Posted: Mon Jan 20, 2014 4:12 pm
by tmcdonald
What is the full command you are using to compile?

Re: Compiling ndoutils: error: expected specifier-qualifier

Posted: Mon Jan 20, 2014 10:18 pm
by bkfrvn
I just used:

Code: Select all

./configure
make

Re: Compiling ndoutils: error: expected specifier-qualifier

Posted: Tue Jan 21, 2014 2:19 pm
by tmcdonald
I'm going to close this thread since the other thread you made references this one and they are essentially the same issue.