mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Fix qof/test compilation errors, provide guard for glib_testing.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@20107 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
dc4ec4a8ea
commit
886cf5b4e5
12
configure.ac
12
configure.ac
@ -200,6 +200,17 @@ else
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING([for GLib testing (glib >= 2.16.0)])
|
||||
if $PKG_CONFIG 'glib-2.0 >= 2.16.0'
|
||||
then
|
||||
AC_MSG_RESULT(yes)
|
||||
_have_glib_testing=yes
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
_have_glib_testing=no
|
||||
fi
|
||||
AM_CONDITIONAL(HAVE_GLIB_TESTING, test "x$_have_glib_testing" = "xyes")
|
||||
|
||||
AC_CHECK_HEADERS(dirent.h dlfcn.h dl.h utmp.h locale.h mcheck.h unistd.h wctype.h)
|
||||
|
||||
# Gnucash replaced dlopen/dlsym by the g_module functions; dlsym
|
||||
@ -1446,6 +1457,7 @@ AC_CONFIG_FILES(
|
||||
src/import-export/aqbanking/schemas/Makefile
|
||||
src/libqof/Makefile
|
||||
src/libqof/qof/Makefile
|
||||
src/libqof/qof/test/Makefile
|
||||
src/optional/Makefile
|
||||
src/optional/python-bindings/Makefile
|
||||
src/optional/python-bindings/tests/Makefile
|
||||
|
@ -1,4 +1,8 @@
|
||||
#SUBDIRS = test
|
||||
if HAVE_GLIB_TESTING
|
||||
SUBDIRS = . test
|
||||
else
|
||||
SUBDIRS = .
|
||||
endif
|
||||
|
||||
lib_LTLIBRARIES = libgnc-qof.la
|
||||
|
||||
|
@ -25,6 +25,7 @@
|
||||
#include <qof.h>
|
||||
|
||||
static const gchar *suitename = "/qof/qofbook";
|
||||
void test_suite_qofbook ( void );
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
@ -24,6 +24,7 @@
|
||||
#include <qof.h>
|
||||
|
||||
static const gchar *suitename = "/qof/qofinstance";
|
||||
void test_suite_qofinstance ( void );
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
@ -27,6 +27,7 @@
|
||||
#include <qofsession-p.h>
|
||||
|
||||
static const gchar *suitename = "/qof/qofsession";
|
||||
void test_suite_qofsession ( void );
|
||||
|
||||
typedef struct
|
||||
{
|
||||
@ -69,7 +70,7 @@ test_session_safe_save( Fixture *fixture, gconstpointer pData )
|
||||
g_assert( NULL == qof_session_get_url( fixture->session ));
|
||||
}
|
||||
|
||||
GTestSuite*
|
||||
void
|
||||
test_suite_qofsession ( void )
|
||||
{
|
||||
g_test_add( suitename, Fixture, NULL, setup, test_session_safe_save, teardown );
|
||||
|
Loading…
Reference in New Issue
Block a user