gnome-python-desktop r530 - in trunk: . evince



Author: fpeters
Date: Wed Jan 28 11:49:09 2009
New Revision: 530
URL: http://svn.gnome.org/viewvc/gnome-python-desktop?rev=530&view=rev

Log:
added support for building the evince module when using autotools.


Added:
   trunk/evince/Makefile.am
Modified:
   trunk/Makefile.am
   trunk/configure.ac

Modified: trunk/Makefile.am
==============================================================================
--- trunk/Makefile.am	(original)
+++ trunk/Makefile.am	Wed Jan 28 11:49:09 2009
@@ -57,6 +57,10 @@
   SUBDIRS += evolution
 endif
 
+if BUILD_EVINCE
+  SUBDIRS += evince
+endif
+
 SUBDIRS +=  tests
 
 pkgconfigdir = $(libdir)/pkgconfig

Modified: trunk/configure.ac
==============================================================================
--- trunk/configure.ac	(original)
+++ trunk/configure.ac	Wed Jan 28 11:49:09 2009
@@ -128,7 +128,7 @@
 AM_CONDITIONAL(BUILD_DOCS, [test "$enable_gtk_doc" = "yes"])
 
 dnl default bindings to build:
-default_bindings_on="applet gnomeprint gnomeprintui gtksourceview wnck totem_plparser gtop nautilusburn mediaprofiles rsvg gnomekeyring gnomedesktop bugbuddy metacity evolution evolution_ecal"
+default_bindings_on="applet gnomeprint gnomeprintui gtksourceview wnck totem_plparser gtop nautilusburn mediaprofiles rsvg gnomekeyring gnomedesktop bugbuddy metacity evolution evolution_ecal evince"
 default_bindings_off="metacity"
 default_bindings_all="$default_bindings_on $default_bindings_off"
 
@@ -398,6 +398,19 @@
 AM_CONDITIONAL(BUILD_EVOLUTION, $build_evolution)
 AM_CONDITIONAL(BUILD_EVOLUTION_ECAL, $build_evolution_ecal)
 
+dnl should we build the evince module
+AC_ARG_BINDING([evince],[YES])
+if $build_evince; then
+    PKG_CHECK_MODULES(EVINCE, [evince-document-2.25 evince-view-2.25],
+      build_evince=true,
+      build_evince=false)
+    if test -n "$export_dynamic"; then
+      EVINCE_LIBS=`echo $EVINCE_LIBS | sed -e "s/$export_dynamic//"`
+    fi
+fi
+AM_CONDITIONAL(BUILD_EVINCE, $build_evince)
+
+
 dnl add required cflags ...
 JH_ADD_CFLAG([-Wall])
 JH_ADD_CFLAG([-std=c9x])
@@ -418,6 +431,7 @@
   gnomekeyring/Makefile
   gnomedesktop/Makefile
   evolution/Makefile
+  evince/Makefile
   gnome-python-desktop-2.0.pc
   tests/Makefile
   docs/Makefile
@@ -446,6 +460,7 @@
 $build_bugbuddy          && echo     bugbuddy
 $build_evolution         && echo     evolution
 $build_evolution_ecal    && echo     evolution ecal support
+$build_evince            && echo     evince
 echo
 
 echo "The following modules will NOT be built:"
@@ -466,6 +481,7 @@
 $build_bugbuddy          || echo     bugbuddy
 $build_evolution         || echo     evolution
 $build_evolution_ecal    || echo     evolution ecal support
+$build_evince            || echo     evince
 
 
 echo "*****************************************************************************"

Added: trunk/evince/Makefile.am
==============================================================================
--- (empty file)
+++ trunk/evince/Makefile.am	Wed Jan 28 11:49:09 2009
@@ -0,0 +1,39 @@
+INCLUDES = $(PYTHON_INCLUDES) $(PYGTK_CFLAGS)
+
+defsdir = $(datadir)/pygtk/2.0/defs
+
+defs_DATA = evince.defs
+
+EXTRA_DIST = $(defs_DATA)
+
+common_ldflags = -module -avoid-version
+
+pkgpythondir = $(pyexecdir)/gtk-2.0
+pkgpyexecdir = $(pyexecdir)/gtk-2.0
+
+# evince binding
+
+if BUILD_EVINCE
+pkgpyexec_LTLIBRARIES = evince.la
+endif
+evince_la_CFLAGS = $(EVINCE_CFLAGS)
+evince_la_LDFLAGS = $(common_ldflags) -export-symbols-regex initevince
+evince_la_LIBADD = $(EVINCE_LIBS)
+evince_la_SOURCES = evincemodule.c
+nodist_evince_la_SOURCES = evince.c
+CLEANFILES = evince.c
+EXTRA_DIST += evince.override  
+evince.c: evince.defs evince.override
+
+.defs.c:
+	(cd $(srcdir) \
+	 && $(PYGTK_CODEGEN) \
+            --register $(PYGTK_DEFSDIR)/gtk-types.defs \
+            --register $(PYGTK_DEFSDIR)/gdk-types.defs \
+	    --py_ssize_t-clean \
+	    --override $*.override \
+	    --prefix py$* $*.defs) > gen-$*.c \
+	&& cp gen-$*.c $*.c \
+	&& rm -f gen-$*.c
+
+EXTRA_DIST += wscript



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]