[gnome-games] libgames-support: [build] Only build those parts of libg-s that are used



commit 8c2b98c43d9cd6c0d4a265ba1e61414b6008375c
Author: Christian Persch <chpe gnome org>
Date:   Sat Jul 4 21:10:37 2009 +0200

    libgames-support: [build] Only build those parts of libg-s that are used
    
    If we only build aisleriot, half of libgames-support is unused (and it
    has problems compiling on the old glib/gtk that aisleriot supports), so
    disable that part.

 configure.in                 |    7 +++++++
 libgames-support/Makefile.am |   21 +++++++++++++--------
 2 files changed, 20 insertions(+), 8 deletions(-)
---
diff --git a/configure.in b/configure.in
index 8d271cd..b28b338 100644
--- a/configure.in
+++ b/configure.in
@@ -119,6 +119,7 @@ allow_gnuchess=no
 allow_smclient=no
 disallow_hildon=no
 require_gtk_2_16=no
+libgames_support_full=no
 
 for game in $gamelist; do
   case $game in
@@ -169,8 +170,14 @@ for game in $gamelist; do
     aisleriot) ;;
     *) require_gtk_2_16=yes ;;
   esac
+  case $game in
+    aisleriot) ;;
+    *) libgames_support_full=yes ;;
+  esac
 done
 
+AM_CONDITIONAL([LIBGAMES_SUPPORT_FULL],[test "$libgames_support_full" = "yes"])
+
 # Locate various programs
 
 PKG_PROG_PKG_CONFIG([0.15])
diff --git a/libgames-support/Makefile.am b/libgames-support/Makefile.am
index ca66742..cf79753 100644
--- a/libgames-support/Makefile.am
+++ b/libgames-support/Makefile.am
@@ -67,19 +67,26 @@ libgames_support_la_SOURCES +=		\
 	games-atk-utils.h		\
 	games-clock.c			\
 	games-clock.h			\
+	games-help.c			\
+	games-help.h			\
+	games-preimage.c                \
+	games-preimage.h                \
+	games-preimage-private.h	\
+	games-show.c			\
+	games-show.h			\
+	$(NULL)
+endif # !HAVE_HILDON
+
+if LIBGAMES_SUPPORT_FULL
+libgames_support_la_SOURCES +=		\
 	games-frame.c			\
 	games-frame.h			\
 	games-find-file.c		\
 	games-find-file.h		\
 	games-gridframe.c		\
 	games-gridframe.h		\
-	games-help.c			\
-	games-help.h			\
 	games-card-selector.c		\
 	games-card-selector.h		\
-	games-preimage.c                \
-	games-preimage.h                \
-	games-preimage-private.h	\
 	games-score.h			\
 	games-score.c			\
 	games-scores.c			\
@@ -93,10 +100,8 @@ libgames_support_la_SOURCES +=		\
 	games-setgid-io.h		\
 	games-scores-backend.c		\
 	games-scores-backend.h		\
-	games-show.c			\
-	games-show.h			\
 	$(NULL)
-endif
+endif # LIBGAMES_SUPPORT_FULL
 
 if HAVE_GNOME
 if GGZ_CLIENT



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