[GNC-dev] gc 4.6 compile problem
jralls at ceridwen.us
Fri Jul 2 12:33:20 EDT 2021
> On Jul 2, 2021, at 3:58 AM, Lothar Paltins via gnucash-devel <gnucash-devel at gnucash.org> wrote:
> Am 01.07.21 um 18:18 schrieb John Ralls:
>> You're absolutely right, it should be. Unfortunately Guile doesn't agree and our efforts to convince it otherwise have been unsuccessful. It's not possible on Linux to build GnuCash on a machine that has GnuCash installed by the package manager without some gymnastics. I think the simplest work around is to set up a VM for building GnuCash, but maybe there's another way.
> Hi John,
> just to be sure. Is this only a build issue or could it be a problem at runtime?
It depends on whether you manage to get it to build and how you configure your library-loader defaults. Each executable needs to find the right set of shared libraries and loadable modules: /usr/bin/gnucash needs to find the ones in /usr/<libdir> and /opt/bin/gnucash needs to find the ones in /opt/<libdir>. Linux generally organizes loading the shared libraries with /etc/ldso.conf, but it can be tweaked with the environment variable $LD_LIBRARY_PATH. In general that config also applies to loadable modules, but Guile still uses the utterly obsolete Gnu libtool libltdl.so that has its own environment variable and redirection files ("lt libraries") that provide another layer of complexity for you to navigate.
You might be able to override the shared library half of the problem with additional CMake arguments that set up RPATHs to override the defaults and by running the self-built GnuCash from a shell script or .desktop that overrides the Guile and Gnu libtool environments to point at your /opt build. This isn't script-kiddie stuff so if you haven't been nodding along to all of that you've got some studying to do.
More information about the gnucash-devel