mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Fix guile-1.6 compatibility of r18541 (bug#582325).
We still suppport guile-1.6, hence we can use the functions introduced in guile-1.8 only by providing our own backward compatibility macro definitions in guile-mappings.h. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18545 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
d61fd27953
commit
a5217470af
@ -3,6 +3,7 @@
|
|||||||
/* Includes the header in the wrapper code */
|
/* Includes the header in the wrapper code */
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include <option-util.h>
|
#include <option-util.h>
|
||||||
|
#include <guile-mappings.h>
|
||||||
#include <gnc-euro.h>
|
#include <gnc-euro.h>
|
||||||
#include <gnc-exp-parser.h>
|
#include <gnc-exp-parser.h>
|
||||||
#include <gnc-ui-util.h>
|
#include <gnc-ui-util.h>
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
|
#include "guile-mappings.h"
|
||||||
#include "file-utils.h"
|
#include "file-utils.h"
|
||||||
#include "gnc-engine.h"
|
#include "gnc-engine.h"
|
||||||
#include "gnc-filepath-utils.h"
|
#include "gnc-filepath-utils.h"
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
%{
|
%{
|
||||||
/* Includes the header in the wrapper code */
|
/* Includes the header in the wrapper code */
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
#include <guile-mappings.h>
|
||||||
#include <gncAddress.h>
|
#include <gncAddress.h>
|
||||||
#include <gncBillTerm.h>
|
#include <gncBillTerm.h>
|
||||||
#include <gncCustomer.h>
|
#include <gncCustomer.h>
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include "gncBusGuile.h"
|
#include "gncBusGuile.h"
|
||||||
#include "engine-helpers.h"
|
#include "engine-helpers.h"
|
||||||
#include "swig-runtime.h"
|
#include "swig-runtime.h"
|
||||||
|
#include "guile-mappings.h"
|
||||||
#define FUNC_NAME G_STRFUNC
|
#define FUNC_NAME G_STRFUNC
|
||||||
|
|
||||||
static swig_type_info *
|
static swig_type_info *
|
||||||
|
@ -35,7 +35,9 @@ AM_CPPFLAGS = \
|
|||||||
${GUILE_INCS} \
|
${GUILE_INCS} \
|
||||||
${GLIB_CFLAGS} \
|
${GLIB_CFLAGS} \
|
||||||
${GCONF_CFLAGS} \
|
${GCONF_CFLAGS} \
|
||||||
${GTK_CFLAGS}
|
${GTK_CFLAGS} \
|
||||||
|
-I${top_srcdir}/src
|
||||||
|
|
||||||
|
|
||||||
gncmoddir = ${GNC_SHAREDIR}/guile-modules/gnucash
|
gncmoddir = ${GNC_SHAREDIR}/guile-modules/gnucash
|
||||||
gncmod_DATA = core-utils.scm
|
gncmod_DATA = core-utils.scm
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
%module sw_core_utils
|
%module sw_core_utils
|
||||||
%{
|
%{
|
||||||
|
#include <guile-mappings.h>
|
||||||
#include <gnc-glib-utils.h>
|
#include <gnc-glib-utils.h>
|
||||||
#include <gnc-main.h>
|
#include <gnc-main.h>
|
||||||
#include <glib.h>
|
#include <glib.h>
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
#include <glib.h>
|
#include <glib.h>
|
||||||
#include <qof.h>
|
#include <qof.h>
|
||||||
#include <Query.h>
|
#include <Query.h>
|
||||||
|
#include <guile-mappings.h>
|
||||||
#include <gnc-budget.h>
|
#include <gnc-budget.h>
|
||||||
#include <gnc-commodity.h>
|
#include <gnc-commodity.h>
|
||||||
#include <gnc-engine.h>
|
#include <gnc-engine.h>
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include <glib.h>
|
#include <glib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <libguile.h>
|
#include <libguile.h>
|
||||||
|
#include <guile-mappings.h>
|
||||||
#include "swig-runtime.h"
|
#include "swig-runtime.h"
|
||||||
#include "gnc-hooks.h"
|
#include "gnc-hooks.h"
|
||||||
#include "gnc-hooks-scm.h"
|
#include "gnc-hooks-scm.h"
|
||||||
|
@ -36,6 +36,7 @@
|
|||||||
#include "gnc-ui-common.h"
|
#include "gnc-ui-common.h"
|
||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
#include "gnc-pricedb.h"
|
#include "gnc-pricedb.h"
|
||||||
|
#include "guile-mappings.h"
|
||||||
|
|
||||||
|
|
||||||
/** Help Files ******************************************************/
|
/** Help Files ******************************************************/
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
#include <dialog-progress.h>
|
#include <dialog-progress.h>
|
||||||
|
#include "guile-mappings.h"
|
||||||
|
|
||||||
SCM scm_init_sw_gnome_module (void);
|
SCM scm_init_sw_gnome_module (void);
|
||||||
%}
|
%}
|
||||||
|
@ -17,6 +17,24 @@
|
|||||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
|
||||||
\********************************************************************/
|
\********************************************************************/
|
||||||
|
|
||||||
|
#include <libguile/version.h> /* for SCM_MAJOR_VERSION etc */
|
||||||
|
|
||||||
|
/* Backward-compatibility macros for guile-1.6 for functions which
|
||||||
|
were introduced in libguile-1.8.0 */
|
||||||
|
#if (SCM_MAJOR_VERSION == 1) && (SCM_MINOR_VERSION <= 6)
|
||||||
|
# define scm_is_bool SCM_BOOLP
|
||||||
|
# define scm_is_false SCM_FALSEP
|
||||||
|
# define scm_is_null SCM_NULLP
|
||||||
|
# define scm_is_number SCM_NUMBERP
|
||||||
|
# define scm_is_pair SCM_CONSP
|
||||||
|
# define scm_is_string SCM_STRINGP
|
||||||
|
# define scm_is_symbol SCM_SYMBOLP
|
||||||
|
# define scm_is_true SCM_NFALSEP
|
||||||
|
# define scm_is_vector SCM_VECTORP
|
||||||
|
# define scm_to_locale_string SCM_STRING_CHARS
|
||||||
|
# define scm_i_string_length SCM_STRING_LENGTH
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Convenience macros */
|
/* Convenience macros */
|
||||||
|
|
||||||
#define scm_is_equal(obj1,obj2) scm_is_true(scm_equal_p(obj1,obj2))
|
#define scm_is_equal(obj1,obj2) scm_is_true(scm_equal_p(obj1,obj2))
|
||||||
|
Loading…
Reference in New Issue
Block a user