mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
gnc-module - remove guile traces from c-interface tests and examples
None of them still depend on guile.
This commit is contained in:
@@ -31,7 +31,6 @@
|
||||
#include <gmodule.h>
|
||||
#include <gtk/gtk.h>
|
||||
#include <glib/gi18n.h>
|
||||
#include <libguile.h>
|
||||
|
||||
#include "gnc-hooks.h"
|
||||
#include "gnc-module.h"
|
||||
@@ -66,12 +65,6 @@ libgncmod_example_gnc_module_description (void)
|
||||
int
|
||||
libgncmod_example_gnc_module_init (int refcount)
|
||||
{
|
||||
if (!gnc_module_load ("gnucash/app-utils", 0)) {
|
||||
return FALSE;
|
||||
}
|
||||
if (!gnc_module_load ("gnucash/gnome-utils", 0)) {
|
||||
return FALSE;
|
||||
}
|
||||
if (!gnc_module_load ("gnucash/engine", 0)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@@ -8,15 +8,11 @@ set(GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
${CMAKE_SOURCE_DIR}/libgnucash/gnc-module
|
||||
${CMAKE_SOURCE_DIR}/common/test-core
|
||||
${GLIB2_INCLUDE_DIRS}
|
||||
${GUILE_INCLUDE_DIRS}
|
||||
)
|
||||
|
||||
set(GNC_MODULE_TEST_LIBS
|
||||
gnc-module
|
||||
test-core
|
||||
gncmod-foo
|
||||
gncmod-bar
|
||||
gncmod-baz
|
||||
gncmod-agedver
|
||||
gncmod-futuremodsys
|
||||
gncmod-incompatdep
|
||||
@@ -24,26 +20,38 @@ set(GNC_MODULE_TEST_LIBS
|
||||
gncmod-withdep
|
||||
)
|
||||
|
||||
gnc_add_test_with_guile(test-load-c test-load-c.c GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS "GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test")
|
||||
gnc_add_test(test-load-c
|
||||
test-load-c.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
GNC_MODULE_TEST_LIBS
|
||||
"GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test")
|
||||
|
||||
gnc_add_test_with_guile(test-modsysver test-modsysver.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
|
||||
gnc_add_test(test-modsysver
|
||||
test-modsysver.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
GNC_MODULE_TEST_LIBS
|
||||
)
|
||||
gnc_add_test_with_guile(test-incompatdep test-incompatdep.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
|
||||
gnc_add_test(test-incompatdep
|
||||
test-incompatdep.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
GNC_MODULE_TEST_LIBS
|
||||
)
|
||||
gnc_add_test_with_guile(test-agedver test-agedver.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
|
||||
"GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test"
|
||||
gnc_add_test(test-agedver
|
||||
test-agedver.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
GNC_MODULE_TEST_LIBS
|
||||
"GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test"
|
||||
)
|
||||
|
||||
set(_LIBDIR ${LIBDIR_BUILD})
|
||||
if (WIN32)
|
||||
set(_LIBDIR ${CMAKE_BINARY_DIR}/bin)
|
||||
endif()
|
||||
gnc_add_test(test-dynload test-dynload.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
|
||||
LIBDIR=${_LIBDIR}
|
||||
gnc_add_test(test-dynload
|
||||
test-dynload.c
|
||||
GNC_MODULE_TEST_INCLUDE_DIRS
|
||||
GNC_MODULE_TEST_LIBS
|
||||
LIBDIR=${_LIBDIR}
|
||||
)
|
||||
|
||||
set(test_gnc_module_SOURCE_DIST
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <gmodule.h>
|
||||
#include <libguile.h>
|
||||
|
||||
#include "gnc-module-api.h"
|
||||
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <gmodule.h>
|
||||
#include <libguile.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
#include "gnc-module-api.h"
|
||||
|
||||
@@ -21,15 +21,14 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <libguile.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
#include <unittest-support.h>
|
||||
|
||||
static void
|
||||
guile_main(void *closure, int argc, char ** argv)
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
GNCModule foo;
|
||||
GNCModule testmod;
|
||||
gchar *msg = "Module '../../../libgnucash/gnc-module/test/misc-mods/.libs/libgncmod_futuremodsys.so' requires newer module system\n";
|
||||
gchar *logdomain = "gnc.module";
|
||||
guint loglevel = G_LOG_LEVEL_WARNING;
|
||||
@@ -40,9 +39,9 @@ guile_main(void *closure, int argc, char ** argv)
|
||||
|
||||
gnc_module_system_init();
|
||||
|
||||
foo = gnc_module_load("gnucash/agedver", 5);
|
||||
testmod = gnc_module_load("gnucash/agedver", 5);
|
||||
|
||||
if (foo)
|
||||
if (testmod)
|
||||
{
|
||||
printf(" ok\n");
|
||||
exit(0);
|
||||
@@ -53,10 +52,3 @@ guile_main(void *closure, int argc, char ** argv)
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
scm_boot_guile(argc, argv, guile_main, NULL);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -27,13 +27,12 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <gmodule.h>
|
||||
#include <libguile.h>
|
||||
#include <unittest-support.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
|
||||
static void
|
||||
guile_main(void *closure, int argc, char ** argv)
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
GModule *gmodule;
|
||||
gchar *msg = "Module '../../../libgnucash/gnc-module/test/misc-mods/.libs/libgncmod_futuremodsys.so' requires newer module system\n";
|
||||
@@ -102,11 +101,3 @@ guile_main(void *closure, int argc, char ** argv)
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
scm_boot_guile(argc, argv, guile_main, NULL);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -21,13 +21,12 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <libguile.h>
|
||||
#include <unittest-support.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
|
||||
static void
|
||||
guile_main(void *closure, int argc, char ** argv)
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
GNCModule foo;
|
||||
gchar *msg1 = "Module '../../../libgnucash/gnc-module/test/misc-mods/.libs/libgncmod_futuremodsys.so' requires newer module system\n";
|
||||
@@ -58,10 +57,3 @@ guile_main(void *closure, int argc, char ** argv)
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
scm_boot_guile(argc, argv, guile_main, NULL);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -21,13 +21,13 @@
|
||||
#include <config.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <libguile.h>
|
||||
#include <unittest-support.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
|
||||
static void
|
||||
guile_main(void *closure, int argc, char ** argv)
|
||||
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
GNCModule foo;
|
||||
gchar *msg1 = "Module '../../../libgnucash/gnc-module/test/misc-mods/.libs/libgncmod_futuremodsys.so' requires newer module system\n";
|
||||
@@ -59,10 +59,3 @@ guile_main(void *closure, int argc, char ** argv)
|
||||
}
|
||||
test_clear_error_list ();
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, char ** argv)
|
||||
{
|
||||
scm_boot_guile(argc, argv, guile_main, NULL);
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user