[GNC] "31 tests failed out of 128" in Ubuntu 24.04

Bill Sommerfeld sommerfeld+gnucash at hamachi.org
Sun May 4 18:31:04 EDT 2025


On 5/4/25 13:41, Dong Lin via gnucash-user wrote:
> With release 5.11 under Ubuntu 24.04, all 31 failed with this error:
> Loading guile/site file from outside build tree! "/usr/share/guile/site/3.0/gnucash/options.scm"
> This used to pass in 5.9 under Ubuntu 22.04. Now even 5.9 failed with the same error in Ubuntu 24.04.
> When I disable this check, all 128 tests passed. but loading the installed version of options.scm seems wrong.
> Does this mean I must remove the installed gnucash in order to run the build binaries properly? Is there a way to run the tests strictly within the build directory?
> Thanks
I ran into this very issue last week when packaging gnucash 5.11 for 
openindiana and came up with a method to run the tests that works in 
that environment.

The underlying problem is that the gnucash build creates a directory 
tree  with all the compiled *.go files but waits until the install phase 
to construct a tree with the corresponding *.scm source files.

So the trick is to wait to run the tests until you have that tree built 
somewhere else in the filesystem.

OI's package-building system installs to a prototype/staging tree via 
setting DESTDIR; if you can set things up to run tests after the proto 
area is populated,  you can point the Guile load paths at a subtree of 
DESTDIR and tell the load-hook that loading from DESTDIR is OK.

see:
https://github.com/OpenIndiana/oi-userland/blob/oi/hipster/components/desktop/gnucash/patches/06-tests-in-DESTDIR.patch

This patch is not appropriate to upstream as-is -- it lives in a context 
where we always know that DESTDIR will be set to a temporary tree; it 
would need a little tweaking for general-purpose use.



More information about the gnucash-user mailing list