At 2015-05-11 09:53, Simon Tiong was heard to say: 

> On 8/5/2015 9:01 PM, Markus Hoenicka wrote: 
> 
> At 2015-05-08 03:33, Simon Tiong was heard to say: 
> On 8/5/2015 7:38 AM, markus.hoeni...@mhoenicka.de wrote: 
> 
> Simon Tiong writes:
>> Dear All,
>> 
>> I try to compile libdbi-drivers on centos 5.9 to work with sqlite3.Can 
>> anyone advice me ? Below is the error message that i get.
>> 
>> 
>> [root@localhost libdbi-drivers-0.9.0]# make
>> make all-recursive
>> make[1]: Entering directory `/root/libdbi-drivers-0.9.0'
>> Making all in drivers
>> make[2]: Entering directory `/root/libdbi-drivers-0.9.0/drivers'
>> Making all in mysql
>> make[3]: Entering directory `/root/libdbi-drivers-0.9.0/drivers/mysql'
>> make[3]: Nothing to be done for `all'.
>> make[3]: Leaving directory `/root/libdbi-drivers-0.9.0/drivers/mysql'
>> Making all in pgsql
>> make[3]: Entering directory `/root/libdbi-drivers-0.9.0/drivers/pgsql'
>> make[3]: Nothing to be done for `all'.
>> make[3]: Leaving directory `/root/libdbi-drivers-0.9.0/drivers/pgsql'
>> Making all in sqlite
>> make[3]: Entering directory `/root/libdbi-drivers-0.9.0/drivers/sqlite'
>> make[3]: Nothing to be done for `all'.
>> make[3]: Leaving directory `/root/libdbi-drivers-0.9.0/drivers/sqlite'
>> Making all in sqlite3
>> make[3]: Entering directory `/root/libdbi-drivers-0.9.0/drivers/sqlite3'
>> /bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. 
>> -I../.. -I../.. -I../../include 
>> -DDBDIR="/usr/local/var/lib/libdbi/sqlite3" -std=gnu99 -MT 
>> dbd_sqlite3.lo -MD -MP -MF .deps/dbd_sqlite3.Tpo -c -o dbd_sqlite3.lo 
>> dbd_sqlite3.c
>> libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../.. 
>> -I../../include -DDBDIR="/usr/local/var/lib/libdbi/sqlite3" -std=gnu99 
>> -MT dbd_sqlite3.lo -MD -MP -MF .deps/dbd_sqlite3.Tpo -c dbd_sqlite3.c 
>> -fPIC -DPIC -o .libs/dbd_sqlite3.o
>> dbd_sqlite3.c: In function '_real_dbd_connect':
>> dbd_sqlite3.c:172: error: 'DBI_ERROR_CLIENT' undeclared (first use in 
>> this function)
>> dbd_sqlite3.c:172: error: (Each undeclared identifier is reported only once
>> dbd_sqlite3.c:172: error: for each function it appears in.)
>> dbd_sqlite3.c: At top level:
>> dbd_sqlite3.c:316: error: conflicting types for 'dbd_goto_row'
>> /usr/include/dbi/dbd.h:41: error: previous declaration of 'dbd_goto_row' 
>> was here
>> dbd_sqlite3.c: In function 'dbd_list_dbs':
>> dbd_sqlite3.c:404: error: 'DBI_ERROR_CLIENT' undeclared (first use in 
>> this function)
>> dbd_sqlite3.c:409: warning: implicit declaration of function 
>> '_dirent_buf_size'
>> dbd_sqlite3.c: In function 'dbd_list_tables':
>> dbd_sqlite3.c:504: error: 'dbi_inst' undeclared (first use in this function)
>> dbd_sqlite3.c:504: error: expected ';' before 'instance'
>> dbd_sqlite3.c:513: error: 'instance' undeclared (first use in this function)
>> dbd_sqlite3.c:513: warning: implicit declaration of function 
>> 'dbi_driver_get_instance'
>> dbd_sqlite3.c:514: warning: implicit declaration of function 
>> 'dbi_conn_new_r'
>> dbd_sqlite3.c:514: warning: assignment makes pointer from integer 
>> without a cast
>> make[3]: *** [dbd_sqlite3.lo] Error 1
>> make[3]: Leaving directory `/root/libdbi-drivers-0.9.0/drivers/sqlite3'
>> make[2]: *** [all-recursive] Error 1
>> make[2]: Leaving directory `/root/libdbi-drivers-0.9.0/drivers'
>> make[1]: *** [all-recursive] Error 1
>> make[1]: Leaving directory `/root/libdbi-drivers-0.9.0'
>> make: *** [all] Error 2
>> 
>> Thank For help.
>> 
> 
> Hi Simon,
> 
> this kind of error usually happens when libdbi and libdbi-drivers are
> out of sync, or if more than one version of libdbi is installed and
> libdbi-drivers picks up the wrong headers during compilation. Please
> verify that your libdbi installation is at 0.9.0 or later as well, and
> remove any outdated headers.
> 
> regards,
> Markus
> 
> Hi Markus,
> 
> Thank you for advices. I solved it with uninstall libdbi & libdbi-drives 
> version which in rpm, and install libdbi 0.9 and libdbi-drives 0.9 .
> 
> This is my step:
> 
> Install libdbi-0.9.0:
> ./configure
> make
> Make install
> 
> Install libdbi-drivers-0.9.0
> [root@localhost libdbi-drivers-0.9.0]# ./configure --with-sqlite3 (RESULT 
> SUCCEEDED DURING MAKE)
> but ./configure --with-sqlite3 --with-mysql (not success during make)
> 
> checking dbi/dbi.h presence... yes
> checking for dbi/dbi.h... yes
> checking for MySQL support... yes
> checking for mysql_config... yes
> checking for MySQL includes... -I/usr/include/mysql
> checking for MySQL libraries...
> checking for PostgreSQL support... no
> checking for SQLite support... no
> checking for SQLite3 support... yes
> checking sqlite3.h usability... yes
> checking sqlite3.h presence... yes
> checking for sqlite3.h... yes
> 
> error during MAKE:
> Attached with ryslog.log
> 
> Please guide me. Thank You. Have a nice day.

Hi, 

this error is a bit weird. The official tarballs contain the
documentation so make should not try to build them. The SGML setup on
your box appears to be broke, all it takes is probably some tweaking of
your SGML_CATALOG_FILES environment variable or of your catalogs proper.
In any case, if you don't need the docs installed locally (they are
available on the libdbi-drivers homepage), you can use the
--disable-docs configure switch to disable building the docs. 

hope this helps 

Markus 

-- 
Markus Hoenicka
http://www.mhoenicka.de [1]
AQ score 38

 HI Markus,

 Thank you for the advice, Now i could successfully build it. but i get
some error during make check. I wonder why it failed at
.PLUGINS/LIBDBDMYSQL.SO
 Can you advice me?

 [root@localhost dbd]# cd /root/rsyslog/libdbi-drivers-0.9.0
 [root@localhost libdbi-drivers-0.9.0]# make check
 Making check in drivers
 make[1]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers'
 Making check in mysql
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/mysql'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/mysql'
 Making check in pgsql
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/pgsql'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/pgsql'
 Making check in sqlite
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/sqlite'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/sqlite'
 Making check in sqlite3
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/sqlite3'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/sqlite3'
 Making check in msql
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/msql'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/msql'
 Making check in oracle
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/oracle'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/oracle'
 Making check in firebird
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/firebird'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/firebird'
 Making check in freetds
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/freetds'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/freetds'
 Making check in ingres
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/ingres'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/ingres'
 Making check in db2
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/db2'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/db2'
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/drivers'
 make[2]: Nothing to be done for `check-am'.
 make[2]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/drivers'
 make[1]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/drivers'
 Making check in tests
 make[1]: Entering directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 Making check in cgreen
 make[2]: Entering directory
`/root/rsyslog/libdbi-drivers-0.9.0/tests/cgreen'
 make[2]: Nothing to be done for `check'.
 make[2]: Leaving directory
`/root/rsyslog/libdbi-drivers-0.9.0/tests/cgreen'
 make[2]: Entering directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make libtest_dbi_plugin.la test_dbi test_dbi_dlopen
 make[3]: Entering directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make[3]: `libtest_dbi_plugin.la' is up to date.
 make[3]: `test_dbi' is up to date.
 make[3]: `test_dbi_dlopen' is up to date.
 make[3]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make check-TESTS
 make[3]: Entering directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 Installing MySQL system tables...
 OK
 Filling help tables...
 OK

 To start mysqld at boot time you have to copy
 support-files/mysql.server to the right place for your system

 PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
 To do so, start the server, then issue the following commands:
 /usr/bin/mysqladmin -u root password 'new-password'
 /usr/bin/mysqladmin -u root -h password 'new-password'

 Alternatively you can run:
 /usr/bin/mysql_secure_installation

 which will also give you the option of removing the test
 databases and anonymous user created by default. This is
 strongly recommended for production servers.

 See the manual for more instructions.

 You can start the MySQL daemon with:
 cd /usr ; /usr/bin/mysqld_safe &

 You can test the MySQL daemon with mysql-test-run.pl
 cd mysql-test ; perl mysql-test-run.pl

 Please report any problems with the /usr/bin/mysqlbug script!

 The latest information about MySQL is available on the web at
http://www.mysql.com [2]
 Support MySQL by buying support/licenses at http://shop.mysql.com [3]
 InnoDB: The first specified data file ./ibdata1 did not exist:
 InnoDB: a new database to be created!
 150507 19:09:29 InnoDB: Setting file ./ibdata1 size to 10 MB
 InnoDB: Database physically writes the file full: wait...
 150507 19:09:29 InnoDB: Log file ./ib_logfile0 did not exist: new to be
created
 InnoDB: Setting log file ./ib_logfile0 size to 5 MB
 InnoDB: Database physically writes the file full: wait...
 150507 19:09:29 InnoDB: Log file ./ib_logfile1 did not exist: new to be
created
 InnoDB: Setting log file ./ib_logfile1 size to 5 MB
 InnoDB: Database physically writes the file full: wait...
 InnoDB: Doublewrite buffer not found: creating new
 InnoDB: Doublewrite buffer created
 InnoDB: Creating foreign key constraint system tables
 InnoDB: Foreign key constraint system tables created
 150507 19:09:29 InnoDB: Started; log sequence number 0 0
 150507 19:09:29 [Note] /usr/libexec/mysqld: ready for connections.
 Version: '5.0.95' socket:
'/root/rsyslog/libdbi-drivers-0.9.0/tests/tmpv14034/mysql.sock' port: 0
Source distribution
 pinging mysqld.mysqld is alive

 libdbi-drivers test program: $Id: test_dbi.c,v 1.72 2013/02/24 15:06:57
mhoenicka Exp $

 test instance-based (i) or legacy (l) libdbi interface? [i] log query
(y|n)? [n] libdbi driver directory? [/usr/local/lib/dbd] 1 drivers
available: mysql
 test which driver?
 database administrator name?
 database administrator password?
 database hostname? [(blank for local socket if possible)] database
name? [libdbitest] encoding? []
 Connection information:
 --------------------
 Legacy mode: 0
 Log query: 0
 Driverdir: ../drivers/mysql/.libs
 Drivername: mysql
 Dbdir:
 Initial Database: mysql
 Database: libdbitest
 Username: root
 Password:
 Hostname: localhost
 Version:
 Initial tables schema: CREATE TABLE test_datatypes ( the_char
TINYINT,the_uchar TINYINT,the_short SMALLINT,the_ushort
SMALLINT,the_long INT,the_ulong INT,the_longlong BIGINT,the_ulonglong
BIGINT,the_float FLOAT4,the_double FLOAT8,the_conn_quoted_string
VARCHAR(255),the_conn_quoted_string_copy
VARCHAR(255),the_conn_escaped_string
VARCHAR(255),the_conn_escaped_string_copy VARCHAR(255),the_numstring
VARCHAR(255),the_empty_string VARCHAR(255),the_null_string
VARCHAR(255),the_binary_quoted_string BLOB,the_binary_escaped_string
BLOB,the_datetime DATETIME,the_datetime_tz DATETIME,the_date
DATE,the_time TIME,the_time_tz TIME,id INT AUTO_INCREMENT,PRIMARY KEY
(id)) ENGINE=InnoDB
 Initial sub schema:
 0:
 1:
 2:
 3:
 4:
 Initial data schema: INSERT INTO test_datatypes
(the_char,the_uchar,the_short,the_ushort,the_long,the_ulong,the_longlong,the_ulonglong,the_float,the_double,the_conn_quoted_string,the_conn_quoted_string_copy,the_conn_escaped_string,the_conn_escaped_string_copy,the_numstring,the_empty_string,the_null_string,the_binary_quoted_string,the_binary_escaped_string,the_datetime,the_datetime_tz,the_date,the_time,the_time_tz)
VALUES
(-127,127,-32768,32767,-2147483648,2147483647,-9223372036854775807,9223372036854775807,3.402823466E+38,1.7976931348623157E+307,'Can
''we'' "quote" this properly?','Can ''we'' "quote" this properly?','Can
''we'' "escape" this properly?','Can ''we'' "escape" this
properly?','-54321','',NULL,'ABC'D','ABC'D','2001-12-31
23:59:59','2001-12-31 23:59:59
-10:00','2001-12-31','23:59:59','23:59:59-10:00')

 Begin tests:
 --------------------
 Running "libdbi framework test"...
 Completed "libdbi framework test": 413 passes, 0 failures, 0
exceptions.
 150507 19:09:33 [Note] /usr/libexec/mysqld: Normal shutdown

 150507 19:09:33 InnoDB: Starting shutdown...
 150507 19:09:35 InnoDB: Shutdown completed; log sequence number 0
788643
 150507 19:09:35 [Note] /usr/libexec/mysqld: Shutdown complete

 PASS: test_mysql.sh
 create symbolic link
`/root/rsyslog/libdbi-drivers-0.9.0/tests/.plugins/libdbdmysql.so' to
`/root/rsyslog/libdbi-drivers-0.9.0/drivers/mysql/.libs/libdbdmysql.so'
LIBDBI: FAILED TO LOAD DRIVER: .PLUGINS/LIBDBDMYSQL.SO
EITHER YOU HAVE NO DRIVERS IN .PLUGINS , OR THERE WAS A PROBLEM LOADING
THEM.
FAIL: TEST_LIBDBI.SH
 ===================
 1 of 2 tests failed
 ===================
 make[3]: *** [check-TESTS] Error 1
 make[3]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make[2]: *** [check-am] Error 2
 make[2]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make[1]: *** [check-recursive] Error 1
 make[1]: Leaving directory `/root/rsyslog/libdbi-drivers-0.9.0/tests'
 make: *** [check-recursive] Error 1

 Thank You.

Hi, 

I haven't seen this error yet. Do you have write permissions in the
directory where the symlink is to be created? The weird thing is why
this symlink is created *after* the test succeeds. 

regards, 

Markus 

-- 
Markus Hoenicka
http://www.mhoenicka.de
AQ score 38

 

Links:
------
[1] http://www.mhoenicka.de
[2] http://www.mysql.com
[3] http://shop.mysql.com
------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Libdbi-drivers-devel mailing list
Libdbi-drivers-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libdbi-drivers-devel

Reply via email to