-----Original Message-----
From: John Ralls <jra...@ceridwen.us> 
Sent: Friday, 8 May 2020 6:53 AM
To: Chris Good <goodchri...@gmail.com>
Cc: gnucash-devel <gnucash-devel@gnucash.org>
Subject: Re: [GNC-dev] Master: Cannot open or save to SQLite3 database



> On May 6, 2020, at 8:42 PM, Chris Good <goodchri...@gmail.com> wrote:
> 
> Hi John,
> 
> cd /home/cgood/gnucash-master/build
> cmake -DCMAKE_BUILD_TYPE=debug -G"Eclipse CDT4 - Ninja"
> -DCMAKE_ECLIPSE_GENERATE_SOURCE_PROJECT=TRUE
> -DCMAKE_INSTALL_PREFIX=../install ../src as per 
> https://wiki.gnucash.org/wiki/Eclipse#With_CMake_.26_Ninja
> 
> repo is /home/cgood/gnucash-master/src
> 
> Regards,
> Chris Good
> 
> -----Original Message-----
> From: John Ralls <jra...@ceridwen.us>
> Sent: Thursday, 7 May 2020 3:10 AM
> To: Chris Good <goodchri...@gmail.com>
> Cc: gnucash-devel <gnucash-devel@gnucash.org>
> Subject: Re: [GNC-dev] Master: Cannot open or save to SQLite3 database
> 
> Are you setting CMAKE_PREFIX_PATH on the cmake command line? Better 
> yet, what's the whole cmake command line that you're using?


I was able to reproduce this on my Fedora 31 VM, no Eclipse required. It
turns out that the lines 
    get_filename_component(drivers_dir ${LIBDBI_DRIVERS_DIR} DIRECTORY)
    set(LIBDBI_DRIVERS_DIR ${drivers_dir} CACHE FILEPATH "Directory
containing the libdbi driver modules." FORCE) recurse so that
LIBDBI_DRIVERS_DIR ends up being '/', confusing the heck out of libdbi. I
changed the find_library result variable to LIBDBI_DRIVERS, preventing the
recursion, and libdbi is happy again.

I also fixed GNC_DBD_DIR so that it doesn't have a default. Instead it just
loads from the command line or the environment. It's in the main
CMakeLists.txt to help find_library find the drivers if they're somewhere
outside of the usual places, much like GTEST_ROOT. That's separate from
putting it in the environment file; *that* is for making it relocatable,
particularly for MacOS app bundles.

Pushed to maint and merged up to master.

Regards,
John Ralls

Hi John,

Tested and working fine.

Many thanks, Chris Good

_______________________________________________
gnucash-devel mailing list
gnucash-devel@gnucash.org
https://lists.gnucash.org/mailman/listinfo/gnucash-devel

Reply via email to