I can't find working libdbi version

Christoph Holtermann c.holtermann at gmx.de
Wed Jan 26 18:59:34 EST 2011


Am 25.01.2011 17:54, schrieb John Ralls:
> On Jan 25, 2011, at 8:18 AM, Christoph Holtermann wrote:
>
>> Hello !
>>
>> The recent SVN Version got a test for libdbi versions with what gnucash doesn't
>> work. I have been using this non-stable combination for quite a while with only
>> few data loss ;-) I am now forced to change the libdbi which i have been trying
>> for quite some time yesterday but i can't make that error message disappear.
>>
>> I am using OpenSuSe 11.3 but before i used factory so my system may not be
>> clean. I tried the rpms i could find but i didn't find any that made it through
>> GnuCashs test and i was stuck with the error message.
>>
>> My database is MySql. SVN is 20166.
>>
>> Then i tried to compile libdbi and libdbi-devel myself. The current versions that
>> could be downloaded didn't go through either. But trying this i also got stuck
>> because GnuCash wasn't even able to parse the SQL. I guess that's because
>> the libraries were not found.
>>
>> Then i went to the developer versions of libdbi at cvs. Make check of libdbi-drivers
>> doesn't get through, breaks with
>>
>> make[3]: Entering directory `/usr/local/src/libdbi-drivers/tests'
>> gcc -DHAVE_CONFIG_H -I. -I.. -I.. -I../include -I../tests/cgreen/include -I/usr/include -DDBDIR=\"/usr/var/lib/libdbi\" -DDBI_DRIVER_DIR=\"/usr/lib/dbd\" -g -MT test_dbi.o -MD -MP -MF .deps/test_dbi.Tpo -c -o test_dbi.o test_dbi.c
>> test_dbi.c:46:10: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘dbi_instance’
>> ...
>> there come a lot of further errors.
>>
>> When i make and install them though at least GnuCash parses SQL correctly, so it uses the
>> libraries and i get through to this nice error message.
>> I got some confusion because i tried to compile and install different versions of libdbi. I think
>> i cleaned things up correctly though and when i use
>> strace gnucash
>> after searching different locations for libdbi like
>> ...
>> open("/usr/lib/sse2/libdbi.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
>> stat64("/usr/lib/sse2", 0xbf91a1b4) = -1 ENOENT (No such file or directory)
>> open("/usr/lib/libdbi.so.1", O_RDONLY) = 5
>> read(5, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0P:\0\0004\0\0\0"..., 512) = 512
>> ...
>> it reads the file /usr/lib/libdbi.so.1 which is a link to libdbi.so.1.1.0. And this should be the
>> correct file for the cvs version.
>>
>> It seems to me that i now use the most recent version of libdbi and libdbi-drivers and that doesn't
>> make it through the test. I tried "make debug" for both. It didn't help.
>>
>> By the way :
>>
>> make check for GnuCash stops with the following :
>> TEST: test-qof... (pid=19210)
>> /qof/qofbook: OK
>> /qof/qofinstance: **
>> ERROR:test-qofinstance.c:55:test_book_readonly: assertion failed: (!qof_begin_edit( fixture->instance ))
>> FAIL
>> GTester: last random seed: R02S89f22d5b966baeb8f7ef6e1fb67c2a4d
>> /bin/sh: Zeile 1: 19209 Beendet gtester --verbose test-qof
>> make[5]: *** [test] Fehler 143
>>
>> I don't know any further. Maybe someone can help ?
> Oops. The failing test is my fault; I took out what it tests and forgot to remove the test. I'll fix that today.
>
> In order to get libdbi to work, you have to edit configure and change the CFLAGS to not use -ffast-math or use "make debug" to build a debug library; the CFLAGS for debug don't include -ffast-math. Unfortunately, they wrote their configure to ignore CFLAGS passed in on the command line or in the environment.
make debug doesn't work for me...

I tried some versions of libdbi. Combinations which let me come through to the error message
reporting the nonworking libdbi were :

libdbi CVS & libdbi-driver CVS    (- the sqlite3 driver didn't compile here though, but i only need mysql so i don't care)
libdbi 0.8.4 & libdbi-drivers-0.8.3-1 ( compiles fine )

(Other combinations stopped even before that. GnuCash told me that the url could not be parsed.)

> Debian provides a prebuilt debug version (libdbi-debug). Perhaps Suse does too, and you could use that.
I didn't find something like that. I don't know if it would work if try to use debian binaries. I will do that tomorrow.
I hope i can use GnuCash once again ;-)


Regards,

Christoph Holtermann



More information about the gnucash-devel mailing list