Define EVO_MARSHAL_RULE, which creates glib marshaller .c and .h files

* configure.in: Define EVO_MARSHAL_RULE, which creates glib
	marshaller .c and .h files that don't cause gcc warnings

	* marshal.mk: The Makefile fragment used by EVO_MARSHAL_RULE.
	(Can't include newlines in an AC_SUBST, so we have to use
	AC_SUBST_FILE)

	* Makefile.am (EXTRA_DIST): add marshal.mk

svn path=/trunk/; revision=21910
This commit is contained in:
Dan Winship
2003-07-23 16:38:42 +00:00
parent b167ce0861
commit fb9b835fe3
4 changed files with 28 additions and 2 deletions

View File

@ -1,3 +1,14 @@
2003-07-23 Dan Winship <danw@ximian.com>
* configure.in: Define EVO_MARSHAL_RULE, which creates glib
marshaller .c and .h files that don't cause gcc warnings
* marshal.mk: The Makefile fragment used by EVO_MARSHAL_RULE.
(Can't include newlines in an AC_SUBST, so we have to use
AC_SUBST_FILE)
* Makefile.am (EXTRA_DIST): add marshal.mk
2003-07-20 Hasbullah Bin Pit <sebol@ikhlas.com> 2003-07-20 Hasbullah Bin Pit <sebol@ikhlas.com>
*configure.in: Added 'ms' (Malay) to ALL_LINGUAS. *configure.in: Added 'ms' (Malay) to ALL_LINGUAS.

View File

@ -18,6 +18,7 @@ EXTRA_DIST = \
MAINTAINERS \ MAINTAINERS \
NEWS \ NEWS \
NEWS-1.0 \ NEWS-1.0 \
marshal.mk \
intltool-merge.in \ intltool-merge.in \
intltool-update.in \ intltool-update.in \
intltool-extract.in \ intltool-extract.in \

View File

@ -1016,6 +1016,15 @@ fi
AC_SUBST(OPENSSL_CFLAGS) AC_SUBST(OPENSSL_CFLAGS)
AC_SUBST(OPENSSL_LDFLAGS) AC_SUBST(OPENSSL_LDFLAGS)
dnl *******************
dnl GObject marshalling
dnl *******************
AM_PATH_GLIB_2_0
dnl We use AC_SUBST_FILE because AC_SUBST won't deal with newlines
EVO_MARSHAL_RULE=$srcdir/marshal.mk
AC_SUBST_FILE(EVO_MARSHAL_RULE)
dnl ************************* dnl *************************
dnl CFLAGS and LIBS and stuff dnl CFLAGS and LIBS and stuff
dnl ************************* dnl *************************
@ -1030,8 +1039,6 @@ IDL_INCLUDES="-I "`pkg-config --variable=idldir libbonobo-2.0`" -I "`pkg-config
AC_MSG_RESULT($IDL_INCLUDES) AC_MSG_RESULT($IDL_INCLUDES)
AC_SUBST(IDL_INCLUDES) AC_SUBST(IDL_INCLUDES)
AM_PATH_GLIB_2_0
dnl Utility macro to set compiler flags for a specific lib. dnl Utility macro to set compiler flags for a specific lib.
AC_DEFUN(EVO_SET_COMPILE_FLAGS, [ AC_DEFUN(EVO_SET_COMPILE_FLAGS, [
deps="$2" deps="$2"

7
marshal.mk Normal file
View File

@ -0,0 +1,7 @@
%.h: %.list
( $(GLIB_GENMARSHAL) --prefix=$(subst -,_,$*) $< --header > $@.tmp \
&& mv $@.tmp $@ ) || ( rm -f $@.tmp && exit 1 )
%.c: %.list %.h
( (echo "#include \"$*.h\""; $(GLIB_GENMARSHAL) --prefix=$(subst -,_,$*) $*.list --body) > $@.tmp \
&& mv $@.tmp $@ ) || ( rm -f $@.tmp && exit 1 )