[libgda] Compilation & doc generation corrections to have "make distcheck" work



commit 9963f33c0e8338e5d01102ef28725041450810c7
Author: Vivien Malerba <malerba gnome-db org>
Date:   Sat Sep 29 22:21:13 2012 +0200

    Compilation & doc generation corrections to have "make distcheck" work

 Makefile.am                               |    2 +-
 configure.ac                              |   34 ++++++++++++++++++----------
 doc/C/Makefile.am                         |    5 ++-
 libgda-ui/data-entries/gdaui-entry-time.c |    2 +-
 libgda-ui/data-entries/gdaui-entry.h      |    6 ++--
 libgda-ui/gdaui-data-entry.c              |    2 +-
 libgda-ui/gdaui-raw-grid.c                |    2 +-
 libgda-ui/gdaui-rt-editor.c               |   10 ++++----
 libgda-ui/gdaui-server-operation.c        |    4 +-
 libgda-ui/gdaui-set.c                     |    4 +-
 libgda/Makefile.am                        |    2 +-
 libgda/data/Makefile.am                   |   17 ++++++-------
 libgda/gda-statement.h                    |    2 +-
 m4/vapigen.m4                             |    6 ++--
 tests/vala/Makefile.am                    |   20 +++++------------
 15 files changed, 60 insertions(+), 58 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 9d4d308..1e3632b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,4 +1,4 @@
-DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
+DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-gda-gi=yes --enable-introspection=yes --enable-gdaui-gi=yes --enable-gi-system-install=no --enable-vala=yes --enable-vala-extensions=yes
 
 if HAVE_LIBXSLT
 XSLT_DIR=libgda-xslt
diff --git a/configure.ac b/configure.ac
index 09012de..06869f1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -454,6 +454,7 @@ else
 	enable_gda_gi=no
     fi
 fi
+
 AM_CONDITIONAL(ENABLE_GDA_GI, [test "$enable_gda_gi" = "yes"])
 
 AC_ARG_ENABLE([gdaui-gi],
@@ -482,26 +483,35 @@ AC_ARG_ENABLE([gi-system-install],
     AS_HELP_STRING([--enable-gi-system-install], [Install GObject Introspection files along with system installed files [default=yes]]),
     [enable_gi_system_install=$enableval],[enable_gi_system_install=yes])
 AM_CONDITIONAL(ENABLE_GI_SYSTEM_INSTALL, [test x"$enable_gi_system_install" = "xyes"])
-
+found_introspection=$enable_gda_gi
 
 dnl ******************************
 dnl Check for Vala Compiler
 dnl ******************************
+enable_vala=no
+enable_vala_ext=no
 AC_ARG_ENABLE([vala-extensions],
     AS_HELP_STRING([--enable-vala-extensions], [Enable support for Vala extensions [default=no]]),
     [enable_vala_ext=$enableval],[enable_vala_ext=no])
 
-VAPIGEN_CHECK([0.17.7],[0.18])
-AS_CASE([$enable_vala],[yes],[
-  dnl Check for libgee
-  enable_vala_ext=yes
-  GEE_REQUIRED="0.8.0"
-  PKG_CHECK_MODULES(GEE, gee-0.8 >= $GEE_REQUIRED)
-  AC_SUBST(GEE_CFLAGS)
-  AC_SUBST(GEE_LIBS)
-],[no],[
-  AC_MSG_ERROR([Vala extensions for Libgda are requested but Vala/vapigen is not available or enable])
-  enable_vala_ext=no])
+if test "x$enable_gda_gi" = "xyes"
+then
+    VAPIGEN_CHECK([0.17.7],[0.18])
+    if test "x$enable_vala_ext" = "xyes"
+    then
+	if test "x$enable_vala" != "xyes"
+	then
+            AC_MSG_ERROR([Vala extensions for Libgda are requested but Vala/vapigen is not available or enabled])
+	fi
+        dnl Check for libgee
+        GEE_REQUIRED="0.8.0"
+        PKG_CHECK_MODULES(GEE, gee-0.8 >= $GEE_REQUIRED)
+        AC_SUBST(GEE_CFLAGS)
+        AC_SUBST(GEE_LIBS)
+    fi
+else
+    AM_CONDITIONAL(ENABLE_VAPIGEN, false)
+fi
 
 AM_CONDITIONAL(ENABLE_VALA_EXTENSIONS, test "x$enable_vala_ext" = "xyes")
 
diff --git a/doc/C/Makefile.am b/doc/C/Makefile.am
index dc03a46..c619ae1 100644
--- a/doc/C/Makefile.am
+++ b/doc/C/Makefile.am
@@ -78,7 +78,7 @@ FIXXREF_OPTIONS=
 include $(top_srcdir)/gtk-doc.make
 
 # Other files to distribute
-EXTRA_DIST += examples/full_example.c installation.xml limitations.xml migration.xml migration2.xml \
+EXTRA_DIST += examples/full_example.c installation.xml limitations.xml migration.xml migration2.xml migration3.xml \
 	server-operation.xml gettingstarted.xml abstraction.xml virtual.xml virtual-notice.xml store-meta-type.xml \
 	prov-writing-virtual-methods.xml prov-writing-recordsets.xml prov-writing-blobs.xml prov-writing-parser.xml prov-writing-assembly.xml \
 	packaging.xml packaging_ui.xml i_s_doc.xml howto.xml gda-sql-manual.xml data_validation.xml data_select.xml \
@@ -88,7 +88,8 @@ EXTRA_DIST += examples/full_example.c installation.xml limitations.xml migration
 	version.xml.in builddate.xml.in \
 	visual_index.xml prov-notes.xml \
 	libgda-sections.txt libgda-ui-sections.txt libgda.types libgda.types.in libgda-ui.types \
-	examples/blobtest.c
+	examples/blobtest.c \
+	data-model-writing.xml
 
 # Files not to distribute
 # for --rebuild-types in $(SCAN_OPTIONS), e.g. $(DOC_MODULE).types
diff --git a/libgda-ui/data-entries/gdaui-entry-time.c b/libgda-ui/data-entries/gdaui-entry-time.c
index 1fa54aa..b598b8d 100644
--- a/libgda-ui/data-entries/gdaui-entry-time.c
+++ b/libgda-ui/data-entries/gdaui-entry-time.c
@@ -68,7 +68,7 @@ gdaui_entry_time_init (G_GNUC_UNUSED GdauiEntryTime * gdaui_entry_time)
 }
 
 /**
- * gdaui_entry_time_new
+ * gdaui_entry_time_new:
  * @dh: the data handler to be used by the new widget
  *
  * Creates a new widget which is mainly a GtkEntry
diff --git a/libgda-ui/data-entries/gdaui-entry.h b/libgda-ui/data-entries/gdaui-entry.h
index 60d464f..2fc3630 100644
--- a/libgda-ui/data-entries/gdaui-entry.h
+++ b/libgda-ui/data-entries/gdaui-entry.h
@@ -47,7 +47,7 @@ struct _GdauiEntryClass
 
 	/* virtual methods */
 	/**
-	 * GdauiEntryClass::get_empty_text
+	 * GdauiEntryClass::get_empty_text:
 	 *
 	 * If defined, sould return a text suitable to display EMPTY value, it will be called when
 	 * entry was set to NULL and is becomming not NULL
@@ -57,7 +57,7 @@ struct _GdauiEntryClass
 	gchar                  *(*get_empty_text) (GdauiEntry *entry);
 
 	/**
-	 * GdauiEntryClass::assume_insert
+	 * GdauiEntryClass::assume_insert:
 	 * @entry: a #GdauiEntry
 	 * @text: the text to be inserted
 	 * @text_length: @text's length in bytes (not characters)
@@ -69,7 +69,7 @@ struct _GdauiEntryClass
 	void                    (*assume_insert) (GdauiEntry *entry, const gchar *text, gint text_length,
 						  gint *virt_pos, gint offset);
 	/**
-	 * GdauiEntryClass::assume_delete
+	 * GdauiEntryClass::assume_delete:
 	 * @entry: a #GdauiEntry
 	 * @virt_start_pos: the starting position.
 	 * @virt_end_pos: the end position (not included in deletion), always > @start_pos
diff --git a/libgda-ui/gdaui-data-entry.c b/libgda-ui/gdaui-data-entry.c
index 9c8fae7..3b77401 100644
--- a/libgda-ui/gdaui-data-entry.c
+++ b/libgda-ui/gdaui-data-entry.c
@@ -417,7 +417,7 @@ gdaui_data_entry_get_handler (GdauiDataEntry *de)
  *
  * Since: 4.2
  *
- * Deprecated: 5.2: use the GtkWidget "hexpand", "wexpand" or "expand" properties
+ * Deprecated: 5.2: use the GtkWidget::hexpand, GtkWidget::wexpand or GtkWidget::expand properties
  */
 gboolean
 gdaui_data_entry_can_expand (GdauiDataEntry *de, gboolean horiz)
diff --git a/libgda-ui/gdaui-raw-grid.c b/libgda-ui/gdaui-raw-grid.c
index 2792c26..919b0d2 100644
--- a/libgda-ui/gdaui-raw-grid.c
+++ b/libgda-ui/gdaui-raw-grid.c
@@ -2689,7 +2689,7 @@ gdaui_raw_grid_set_sample_start (GdauiRawGrid *grid, gint sample_start)
 }
 
 /**
- * gdaui_raw_grid_set_layout_from_file
+ * gdaui_raw_grid_set_layout_from_file:
  * @grid: a #GdauiRawGrid
  * @file_name: XML file name to use
  * @grid_name: the name of the grid to use, in @file_name
diff --git a/libgda-ui/gdaui-rt-editor.c b/libgda-ui/gdaui-rt-editor.c
index 10b8898..12f925b 100644
--- a/libgda-ui/gdaui-rt-editor.c
+++ b/libgda-ui/gdaui-rt-editor.c
@@ -1260,7 +1260,7 @@ spaces_since_start_of_line (GtkTextIter *iter)
 }
 
 /**
- * get_markup_token
+ * get_markup_token:
  * @iter: starting position
  * @out_nb_spaces_before: a place to set the value returned by spaces_since_start_of_line() if called
  * @out_end: (allow-none): place to put the last used position, or %NULL
@@ -1468,7 +1468,7 @@ get_markup_token (GtkTextIter *iter, gint *out_nb_spaces_before, GtkTextIter *ou
 }
 
 /**
- * get_char_at_iter
+ * get_char_at_iter:
  * @iter: an iter
  * @move_forward_first: %TRUE if @iter should be moved forward first
  *
@@ -1537,7 +1537,7 @@ static guint8 *serialize_as_txt2tag (GtkTextBuffer     *register_buffer,
 				     GdauiRtEditor     *editor);
 
 /**
- * gdaui_rt_editor_get_contents
+ * gdaui_rt_editor_get_contents:
  * @editor: a #GdauiRtEditor
  *
  * Get the contents of @editor, using the markup syntax
@@ -1893,7 +1893,7 @@ serialize_as_txt2tag (G_GNUC_UNUSED  GtkTextBuffer *register_buffer,
 
 
 /**
- * gdaui_rt_editor_set_contents
+ * gdaui_rt_editor_set_contents:
  * @editor: a #GdauiRtEditor
  * @markup: the text to set in @editor, using the markup syntax (must be valid UTF-8)
  * @length: length of text in bytes.
@@ -1913,7 +1913,7 @@ gdaui_rt_editor_set_contents (GdauiRtEditor *editor, const gchar *markup, gint l
 }
 
 /**
- * gdaui_rt_editor_set_editable
+ * gdaui_rt_editor_set_editable:
  * @editor: a #GdauiRtEditor
  * @editable: whether it's editable
  *
diff --git a/libgda-ui/gdaui-server-operation.c b/libgda-ui/gdaui-server-operation.c
index 94fa055..052092f 100644
--- a/libgda-ui/gdaui-server-operation.c
+++ b/libgda-ui/gdaui-server-operation.c
@@ -222,7 +222,7 @@ gdaui_server_operation_init (GdauiServerOperation * wid)
 
 
 /**
- * gdaui_server_operation_new
+ * gdaui_server_operation_new:
  * @op: a #GdaServerOperation structure
  *
  * Creates a new #GdauiServerOperation widget using all the parameters provided in @paramlist.
@@ -1059,7 +1059,7 @@ sequence_item_remove_cb (GdaServerOperation *op, const gchar *seq_path, gint ite
 
 
 /**
- * gdaui_server_operation_new_in_dialog
+ * gdaui_server_operation_new_in_dialog:
  * @op: a #GdaServerOperation object
  * @parent: (allow-none): the parent window for the new dialog, or %NULL
  * @title: (allow-none): the title of the dialog window, or %NULL
diff --git a/libgda-ui/gdaui-set.c b/libgda-ui/gdaui-set.c
index 94aa523..ad32c42 100644
--- a/libgda-ui/gdaui-set.c
+++ b/libgda-ui/gdaui-set.c
@@ -102,7 +102,7 @@ gdaui_set_class_init (GdauiSetClass *class)
 	object_class->dispose = gdaui_set_dispose;
 
 	/**
-         * GdauiSet::public-data-changed
+         * GdauiSet::public-data-changed:
          * @set: the #GdauiSet
          * 
          * Gets emitted when @set's public data (#GdauiSetGroup or #GdauiSetSource values) have changed
@@ -117,7 +117,7 @@ gdaui_set_class_init (GdauiSetClass *class)
                               NULL, NULL,
                               _gdaui_marshal_VOID__VOID, G_TYPE_NONE, 0);
 	/**
-         * GdauiSet::source-model-changed
+         * GdauiSet::source-model-changed:
          * @set: the #GdauiSet
          * 
          * Gets emitted when the data model used in @set's #GdauiSetSource has changed
diff --git a/libgda/Makefile.am b/libgda/Makefile.am
index 8fcc564..edad379 100644
--- a/libgda/Makefile.am
+++ b/libgda/Makefile.am
@@ -363,7 +363,7 @@ endif
 gir_DATA = $(INTROSPECTION_GIRS)
 typelibs_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
 
-CLEANFILES += $(typelibs_DATA)
+CLEANFILES += $(typelibs_DATA) $(gir_DATA)
 endif
 
 if ENABLE_VAPIGEN
diff --git a/libgda/data/Makefile.am b/libgda/data/Makefile.am
index 4b6cd76..1c3fb6e 100644
--- a/libgda/data/Makefile.am
+++ b/libgda/data/Makefile.am
@@ -71,7 +71,7 @@ CLEANFILES= gdadata-5.0.vapi
 libgdadata_5_0_la_LDFLAGS = 
 
 libgdadata_5_0_la_LIBADD = \
-    $(top_builddir)/libgda/libgda-5.0.la \
+        $(top_builddir)/libgda/libgda-5.0.la \
 	$(LIBGDA_LIBS) \
 	$(GEE_LIBS) \
 	$(VALA_LIBS)
@@ -93,8 +93,7 @@ typelibsdir = $(libdir)/girepository-1.0
 endif
 
 # GIR files are generated automatically by Valac then is not necessary to scan source code to generate it
-INTROSPECTION_GIRS =
-INTROSPECTION_GIRS += GdaData-5.0.gir
+INTROSPECTION_GIRS = GdaData-5.0.gir
 INTROSPECTION_COMPILER_ARGS = \
     --includedir=. \
     --includedir=$(top_srcdir)/libgda \
@@ -107,15 +106,15 @@ gir_DATA = $(INTROSPECTION_GIRS)
 typelibs_DATA = GdaData-5.0.typelib
 
 CLEANFILES += \
-    $(typelibs_DATA) \
-    gdadata-5.0.vapi \
-    libgdadata-5.0.pc \
-    $(include_headers) \
-    $(libgdadata_5_0_la_VALASOURCES:.vala=.c)
+        $(typelibs_DATA) \
+        gdadata-5.0.vapi \
+        libgdadata-5.0.pc \
+        $(include_headers) \
+        $(libgdadata_5_0_la_VALASOURCES:.vala=.c) \
+        $(srcdir)/libgdadata_5_0_la_vala.stamp
 
 EXTRA_DIST = \
 	libgdadata-5.0.pc \
-	$(libgdadata_5_0_la_VALASOURCES:.vala=.c) \
 	$(vapi_DATA) \
 	$(INTROSPECTION_GIRS) \
 	$(typelibs_DATA)
diff --git a/libgda/gda-statement.h b/libgda/gda-statement.h
index 70e724e..6979592 100644
--- a/libgda/gda-statement.h
+++ b/libgda/gda-statement.h
@@ -63,7 +63,7 @@ typedef enum
  * @GDA_STATEMENT_MODEL_CURSOR_BACKWARD: access to the data model will be done using a cursor moving backward
  * @GDA_STATEMENT_MODEL_CURSOR: access to the data model will be done using a cursor (moving both forward and backward)
  * @GDA_STATEMENT_MODEL_ALLOW_NOPARAM: specifies that the data model should be executed even if some parameters required to execute it are invalid (in this case the data model will have no row, and will automatically be re-run when the missing parameters are once again valid)
- * @GDA_STATEMENT_MODEL_OFFLINE: specifies that the data model's contents will be fully loaded into the client side (the memory of the process using &libgda;), not requiring the server any more to access the data (the default behaviour is to access the server any time data is to be read, and data is cached in memory). This flag is useful only if used in conjunction with the GDA_STATEMENT_MODEL_RANDOM_ACCESS flag (otherwise an error will be returned).
+ * @GDA_STATEMENT_MODEL_OFFLINE: specifies that the data model's contents will be fully loaded into the client side (the memory of the process using Libgda), not requiring the server any more to access the data (the default behaviour is to access the server any time data is to be read, and data is cached in memory). This flag is useful only if used in conjunction with the GDA_STATEMENT_MODEL_RANDOM_ACCESS flag (otherwise an error will be returned).
  *
  * These flags specify how the #GdaDataModel returned when executing a #GdaStatement will be used
  */
diff --git a/m4/vapigen.m4 b/m4/vapigen.m4
index 0f7183e..ff3c6b4 100644
--- a/m4/vapigen.m4
+++ b/m4/vapigen.m4
@@ -26,16 +26,16 @@ AC_DEFUN([VAPIGEN_CHECK],
   AC_REQUIRE([GOBJECT_INTROSPECTION_CHECK])
   AC_REQUIRE([PKG_PROG_PKG_CONFIG])
   AC_REQUIRE([AM_PROG_VALAC])
-  
+
   AC_ARG_ENABLE([vala],
-    [AS_HELP_STRING([--enable-vala[=@<:@no/auto/yes@:>@]],[build Vala bindings @<:@default=]ifelse($4,,auto,$4)[@:>@])],,[
+    [AS_HELP_STRING([--enable-vala[=@<:@no/auto/yes@:>@]],[build Vala bindings @<:@default=]ifelse($4,,auto,$4)[@:>@])],
+    [enable_vala=$withval],[
       AS_IF([test "x$4" = "x"], [
           enable_vala=auto
         ], [
           enable_vala=$4
         ])
     ])
-
   AS_CASE([$enable_vala], [no], [enable_vala=no],
       [yes], [
         AS_IF([test "x$3" != "xyes" -a "x$found_introspection" != "xyes"], [
diff --git a/tests/vala/Makefile.am b/tests/vala/Makefile.am
index b4fdc25..d344b2e 100644
--- a/tests/vala/Makefile.am
+++ b/tests/vala/Makefile.am
@@ -1,5 +1,3 @@
-NULL = 
-
 AM_CPPFLAGS = \
 	-I$(top_srcdir) \
 	-I$(top_srcdir)/libgda \
@@ -11,7 +9,7 @@ AM_CPPFLAGS = \
 	$(GEE_CFLAGS) \
 	-DROOT_DIR=\""$(top_srcdir)"\"
 
-TESTS_ENVIRONMENT = 
+TESTS_ENVIRONMENT = GDA_TOP_SRC_DIR="$(abs_top_srcdir)" GDA_TOP_BUILD_DIR="$(abs_top_builddir)"
 TESTS = check_dataobject check_datamodeliterator check_table
 check_PROGRAMS = check_dataobject check_datamodeliterator check_table
 
@@ -26,20 +24,16 @@ VALAFLAGS = \
     --includedir=$(top_builddir) \
     --vapidir=$(top_srcdir)/libgda \
     --vapidir=$(top_builddir)/libgda/data \
-    --vapidir=$(VAPIDIR) \
-    $(NULL)
+    --vapidir=$(VAPIDIR)
 
 check_dataobject_SOURCES = \
-	CheckDataObject.vala \
-	$(NULL)
+	CheckDataObject.vala
 
 check_datamodeliterator_SOURCES = \
-	CheckDataModelIterator.vala \
-	$(NULL)
+	CheckDataModelIterator.vala
 
 check_table_SOURCES = \
-	CheckTable.vala \
-	$(NULL)
+	CheckTable.vala
 
 check_dataobject_LDADD = \
 	$(top_builddir)/libgda/libgda-5.0.la \
@@ -62,7 +56,5 @@ check_table_LDADD = \
 CLEANFILES += \
     dataobject.db \
     datamodeliterator.db \
-    table.db \
-    $(NULL)
+    table.db
 
-EXTRA_DIST = 



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