[libgdamm] Build examples non-recursively



commit 3b8b834cb8916b2702dae3f64df4d4a488b255e6
Author: Daniel Elstner <danielk openismus com>
Date:   Thu Aug 20 16:42:57 2009 +0200

    Build examples non-recursively
    
    * examples/Makefile.am: Rewrite based on non-recursive make, and
    have all example programs built from here.
    * examples/Makefile.am_fragment: Remove obsolete build file.
    * examples/*/Makefile.am: ditto.
    * configure.ac (AC_CONFIG_FILES): Remove examples/*/Makefile from
    the list of output files.

 ChangeLog                     |   11 +++++++++++
 configure.ac                  |    6 ++----
 examples/Makefile.am          |   30 +++++++++++++++++++++++++++---
 examples/Makefile.am_fragment |   11 -----------
 examples/config/Makefile.am   |    8 --------
 examples/simple/Makefile.am   |    8 --------
 6 files changed, 40 insertions(+), 34 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index bd32010..2be85f2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,16 @@
 2009-08-20  Daniel Elstner  <danielk openismus com>
 
+	Build examples non-recursively
+
+	* examples/Makefile.am: Rewrite based on non-recursive make, and
+	have all example programs built from here.
+	* examples/Makefile.am_fragment: Remove obsolete build file.
+	* examples/*/Makefile.am: ditto.
+	* configure.ac (AC_CONFIG_FILES): Remove examples/*/Makefile from
+	the list of output files.
+
+2009-08-20  Daniel Elstner  <danielk openismus com>
+
 	Overhaul pkg-config metadata files
 
 	* libgda/libgdamm.pc.in: Rename file from libgda/libgdamm-4.0.pc.in.
diff --git a/configure.ac b/configure.ac
index 31874b3..ead58b1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,9 +65,7 @@ AC_CONFIG_FILES([Makefile
                  libgda/${LIBGDAMM_MODULE_NAME}-uninstalled.pc:libgda/libgdamm-uninstalled.pc.in
                  libgda/src/Makefile
                  libgda/libgdamm/Makefile
-                 docs/Makefile
-                 docs/reference/Doxyfile
                  examples/Makefile
-                 examples/simple/Makefile
-                 examples/config/Makefile])
+                 docs/Makefile
+                 docs/reference/Doxyfile])
 AC_OUTPUT
diff --git a/examples/Makefile.am b/examples/Makefile.am
index 6f4ef10..e4ff4c6 100644
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -1,6 +1,30 @@
-SUBDIRS =  simple \
-	config
+## Copyright (c) 2009  Openismus GmbH  <http://www.openismus.com/>
+##
+## This file is part of libgdamm.
+##
+## libgdamm is free software: you can redistribute it and/or modify it
+## under the terms of the GNU Lesser General Public License as published
+## by the Free Software Foundation, either version 2.1 of the License,
+## or (at your option) any later version.
+##
+## libgdamm is distributed in the hope that it will be useful, but
+## WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+## See the GNU Lesser General Public License for more details.
+##
+## You should have received a copy of the GNU Lesser General Public License
+## along with this library.  If not, see <http://www.gnu.org/licenses/>.
 
-EXTRA_DIST	=  Makefile.am_fragment README.txt
+AUTOMAKE_OPTIONS = subdir-objects
 
+check_PROGRAMS = config/example simple/example
 
+libgdamm_includes = -I$(top_builddir)/libgda $(if $(srcdir:.=),-I$(top_srcdir)/libgda)
+
+AM_CPPFLAGS = -I$(top_builddir) $(libgdamm_includes) $(LIBGDAMM_CFLAGS)
+AM_CXXFLAGS = $(LIBGDAMM_WXXFLAGS)
+
+LDADD = $(LIBGDAMM_LIBS) $(top_builddir)/libgda/libgdamm/libgdamm-$(LIBGDAMM_API_VERSION).la
+
+config_example_SOURCES = config/main.cc
+simple_example_SOURCES = simple/main.cc



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