for guile 1.8 builds. However if we don't have guile 2.0.10 then don't
allow "make dist" to run. This also means we wont patch the guile
files unless we find swig 2.0.10.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23748 57a11ea4-9604-0410-9ed3-97b8803252fd
The current version of the patch tool in our build chain
can't handle this patch.
This is not a problem (for now) because
a. our windows build is still using guile 1.8
b. we're not creating release tarballs on windows
Hopefully swig itself is updated before we move to guile 2 on Windows
This reverts commit e48381ecf9.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23743 57a11ea4-9604-0410-9ed3-97b8803252fd
This bug is a continuation of bug 719481. The fix for that bug
wouldn't trickle down into the release tarballs because the needed
patch would only be applied if the tarball were generated against
guile 2.
This commit fixes this by applying that patch unconditionally
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23702 57a11ea4-9604-0410-9ed3-97b8803252fd
- guile 1.8 doesn't need the swig patch
- make sure all swig interface files include guile-mappings.h
for the *utf8_string to *locale_string mappings
but only load it when building guile modules
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23559 57a11ea4-9604-0410-9ed3-97b8803252fd
This is actually a bug in swig.
This commit works around it by patching the swig
generated source files until swig itself has been fixed.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23557 57a11ea4-9604-0410-9ed3-97b8803252fd
MacOSX, for example, sets RAND_MAX at 65535, which rather limits the
size of random gint64s on that platform.
Fixing this revealed some odd behavior in creating random interest rates,
so created a specific function for that with a somewhat more reasonable
approach.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23493 57a11ea4-9604-0410-9ed3-97b8803252fd
New functions to simplify creating log handlers for expected log
messages, especially fatal message handlers. Handlers are tracked in the
Fixture and automatically freed during teardown.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23138 57a11ea4-9604-0410-9ed3-97b8803252fd
scm is the modern term. vcs is rather used to refer to archaic systems
such as cvs and older. I wish I remembered this before my previous
commit. Oh well...
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22476 57a11ea4-9604-0410-9ed3-97b8803252fd
The code actually has provisions for svn, svk, git and bzr. Only svn and
git are actively used by the core developers though.
This involves changing
- filenames that contained svn while meant for multiple vcs's
- variable and macro names that are relevant for multiple vcs's
- the various locations where the vcs revision info is displayed
to the user, to mention the actual vcs used instead of standard "svn"
While at the last item, I also changed the text printed when gnucash is
called with the --version parameter, to reuse the translatable string
that is also used for the about dialog. This saves us one string to
translate.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22475 57a11ea4-9604-0410-9ed3-97b8803252fd
The actual change to configure.ac (at line 1106) to enable -Wunused -- or rather to un-disable it -- is not included in order to not break the build for folks with buggy versions of swig.
(For example, https://sourceforge.net/tracker/?func=detail&aid=3530021&group_id=1645&atid=101645)
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22203 57a11ea4-9604-0410-9ed3-97b8803252fd
Allows asserting on the number of times error messages are encountered.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22135 57a11ea4-9604-0410-9ed3-97b8803252fd
I'd originally put the functions supporting log detection, qof event handling, and mock-counting in test-stuff along with the functions that support the older "make check" integration tests. There are now more unit test support functions than there are of the older functions, so it's time for them to move out on their own.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22132 57a11ea4-9604-0410-9ed3-97b8803252fd
Works on GObjects. Asserts if the object isn't a GObject (which may be the case if it has already been finalized) or if the object's finalize method isn't called (indicating a leak).
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22114 57a11ea4-9604-0410-9ed3-97b8803252fd
Now the assert reports the location in the test program where it fails instead of inside test-stuff.c.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@22113 57a11ea4-9604-0410-9ed3-97b8803252fd
As usual, re-indentation was done using astyle-1.24 using the following options:
astyle --indent=spaces=4 --brackets=break --pad-oper --pad-header --suffix=none
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21816 57a11ea4-9604-0410-9ed3-97b8803252fd
Enables silencing expected error output. Finally found the secret code
to get libtool to build a "noinst" dynamic library: pass -rpath as an
ldflag.
BP
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21724 57a11ea4-9604-0410-9ed3-97b8803252fd
Add an GTestFatalFunc which can examine a list of error conditions and suppress those messages and prevent their exiting while passing through any unexpected errors.
Rename test_silent_logger to test_null_handler and change it to a GTestFatalFunc (it can still be used as a GLogFunc).
Rename test_handle_faults to test_checked_handler and improve its flow and message display. It no longer asserts on a bad match.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21668 57a11ea4-9604-0410-9ed3-97b8803252fd
For use from tests based on glib testing. Create a private structure to
compare to and register a handler which tests the event parameters
against the private structure and counts the number of valid hits.
Provides a test function for checking that the event handler has been
hit the requisite number of times.
Pass through, rather than testing, logs with a lower (i.e., less
important rather than lower-value) loglevel than the one the handler was
set up for. Test the log message rather than overwriting the pre-set one
with the actual message.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21523 57a11ea4-9604-0410-9ed3-97b8803252fd
As usual, re-indentation was done using astyle-1.24 using the following options:
astyle --indent=spaces=4 --brackets=break --pad-oper --pad-header --suffix=none
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@21205 57a11ea4-9604-0410-9ed3-97b8803252fd
easier to test callbacks and to intercept and
ignore or test expected error log messages.
Much lifted from Muslim's test-qofbook.c
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@20928 57a11ea4-9604-0410-9ed3-97b8803252fd
It's not used and prevents test-core from being included in core-utils tests
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18826 57a11ea4-9604-0410-9ed3-97b8803252fd
To build this:
mkdir build-cpp
cd build-cpp
cmake ..
make
./src/gnc/cutecash
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18815 57a11ea4-9604-0410-9ed3-97b8803252fd
This also strips trailing whitespaces from lines where they existed.
This re-indentation was done using astyle-1.24 using the following options:
astyle --indent=spaces=4 --brackets=break --pad-oper --pad-header --suffix=none
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18787 57a11ea4-9604-0410-9ed3-97b8803252fd
The example was based on Qt4's "application" example, but
the main window layout is done through the .ui file already.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18776 57a11ea4-9604-0410-9ed3-97b8803252fd
Also, add a test executable to check that we got all the
library dependencies.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18737 57a11ea4-9604-0410-9ed3-97b8803252fd
This also strips trailing whitespaces from lines where they existed.
This re-indentation was done using astyle-1.23 using the following options:
astyle --indent=spaces=4 --brackets=break --pad-oper
Discussed at http://lists.gnucash.org/pipermail/gnucash-devel/2009-August/026121.html
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18535 57a11ea4-9604-0410-9ed3-97b8803252fd
AM_CFLAGS is passed both to the compiler (.c -> .o) and to the linker, so it
should only have flags that are appropriate for both steps. AM_CPPFLAGS is
passed only to the compiler, so flags that are only appropriate for that step
(-I and -D flags, for example), should be in _CPPFLAGS instead of _CFLAGS.
Every gnucash-2.2.3 Makefile.am that passes -I flags gets it wrong, placing
them in _CFLAGS. It's not a functional bug (the linker ignores -I flags), but a
ton of superfluous flags makes the build output pretty verbose and hard to
debug when things do go wrong.
To make matters more confusing as a developer, the FOO_CFLAGS variable set by
PKG_CHECK_MODULES(FOO) is actually for _CPPFLAGS in the Makefile.am
('pkg-config --cflags' returns the -I flags).
A related -I bug (one that *is* functionally broken) is that sometimes a local
(build dir) -I flag is passed after a global (installed dependent library) one.
If my system happens to have a header installed from some unrelated thing,
compiler will find *that* one instead of the expected one in the source
directory. Should always pass all local -I before any global ones.
Patch by andi5 plus one manual addition in src/gnome-utils/Makefile.am
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@17655 57a11ea4-9604-0410-9ed3-97b8803252fd
Change gnc-module.c to load the unique symbols based on the module filename.
Change gnc-module-api.h to declare the functions based on a provided filename.
Change ALL the modules to use the new symbol names.
This change should allow the code to build cleanly on the MacIntel platform.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@15928 57a11ea4-9604-0410-9ed3-97b8803252fd
Rename libcore-utils to libgnc-core-utils
Rename libgncgnome to libgnc-gnome
Rename libgncmodule to libgnc-module
Rename libgncqof to libgnc-qof
Rename libgnc-backend-file to libgncmod-backend-file
Move libgnc-business-ledger to $prefix/lib
Move libgncqof-backend-qsf to $prefix/lib/gnucash
Move libgncmod-backend-file to $prefix/lib/gnucash
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@15321 57a11ea4-9604-0410-9ed3-97b8803252fd
Modules are loaded directly with the g_symbol_* API now while dropping
the dependency on libltdl.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@15317 57a11ea4-9604-0410-9ed3-97b8803252fd
Use shorter strings for commodity mnemonics.
Ensure that test splits amount and value have the same sign.
Avoid numerical overflow in rate calculation when generating test splits.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@13718 57a11ea4-9604-0410-9ed3-97b8803252fd
test-core/test-stuff: remove unused variable.
register/ledger-core/split-register-control: insert do .. while
because the code still uses "break"s to exit out.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@10253 57a11ea4-9604-0410-9ed3-97b8803252fd