[GNC-dev] Master: Cannot open or save to SQLite3 database
John Ralls
jralls at ceridwen.us
Mon May 4 14:28:20 EDT 2020
> On May 3, 2020, at 10:40 PM, Chris Good <goodchris96 at gmail.com> wrote:
>
> Hi,
>
>
>
> GnuCash master (as at 29 Apr 2020 fbf7171ab Fix libgnc-app-utils.dylib
> install_name_dir.) on Ubuntu 18.04
>
>
>
> I'm trying to open SQLite3 file del-account-cross-currencies-issue.gnucash
> attached to bug 797220.
>
>
>
> But when I try to open SQLite3 file. It says "no suitable backend was found"
> and if I try to save an xml file, only xml format is available.
>
>
>
> I have built with no options for turning off SQL ie
>
>
>
> Src/CMakeLists.txt: WITH_SQL=ON
>
>
>
> I have the following installed
>
> libdbi-dev 0.9.0-5
>
> libdbi1 0.9.0-5
>
> libdbi1-dbg 0.9.0-5
>
> libdbd-sqlite3 0.9.0-5ubuntu2
>
>
>
> When I try to debug, it seems to me:
>
>
>
> In gnucash/libgnucash/backend/dbi/gnc-backend-dbi.cpp
> gnc_module_init_backend_dbi()
>
> I can see HAVE_LIBDBI_R is set
>
>
>
> num_drivers = dbi_initialize_r (driver_dir, &dbi_instance);
>
>
>
> returns num_drivers=0 but dbi_instance is no longer null so
> the code exits before any drivers are registered.
>
>
>
> Any suggestions please?
>
I just built from current master on my Ubuntu-18.04 VM and SQLite3 is an option in Save As...
If dpi_initialize_r returns 0 then that function (a libdbi one) didn't find any drivers to initialize. Make sure that GNC_DBD_DIR isn't set and in gdb at that dpi_initialize_r call check that driver_dir is 0.
Check that /usr/lib/x86_64-linux-gnu/dbd/lidbdsqlite3.so and /usr/lib/x86_64-linux-gnu/libsqlite3.so.0 is present.
Regards,
John Ralls
More information about the gnucash-devel
mailing list