[anjuta] Revert "Allow to build without libgd"



commit a8262d8fae73c38791f34049e3f774d413b603fa
Author: James Liggett <jrliggett cox net>
Date:   Fri Jun 14 16:57:19 2013 -0700

    Revert "Allow to build without libgd"
    
    This reverts commit 730f0d6f47cd24b380d09a82e248fa169e212a27.

 Makefile.am                             |    5 +--
 autogen.sh                              |    2 +-
 configure.ac                            |   52 +++---------------------------
 plugins/sourceview/Makefile.am          |    4 +-
 plugins/sourceview/sourceview-private.h |    2 -
 plugins/sourceview/sourceview.c         |   17 ++--------
 6 files changed, 13 insertions(+), 69 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 7963c40..df7e89a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -4,12 +4,9 @@ ACLOCAL_AMFLAGS = -I m4 -I libgd ${ACLOCAL_FLAGS}
 
 @INTLTOOL_DESKTOP_RULE@
 
-if HAVE_LIBGD
-LIBGD_DIR = libgd
-endif
 SUBDIRS = \
        pixmaps scripts data \
-       doc libanjuta $(LIBGD_DIR) plugins src manuals mime launcher po
+       doc libanjuta libgd plugins src manuals mime launcher po
 
 dist_doc_DATA = \
        MAINTAINERS\
diff --git a/autogen.sh b/autogen.sh
index ec6132d..7827e2e 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -9,7 +9,7 @@ sh -c "cd $srcdir/libanjuta/interfaces && \
 perl anjuta-idl-compiler.pl libanjuta && \
 touch iface-built.stamp"
 
-(cd "$srcdir" && exec git submodule update --init --recursive)
+git submodule update --init --recursive
 
 ACLOCAL_FLAGS="-I libgd $ACLOCAL_FLAGS"
 
diff --git a/configure.ac b/configure.ac
index fc05c9d..d00b4cf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -32,8 +32,7 @@ AC_SUBST(BUGZILLA_VERSION)
 
 dnl Anjuta core
 GLIB_REQUIRED=2.32.0
-GTK_REQUIRED=3.4.0
-LIBGD_GTK_REQUIRED=3.7.10
+GTK_REQUIRED=3.7.10
 GTHREAD_REQUIRED=2.22.0
 GDK_PIXBUF_REQUIRED=2.0.0
 GDA4_REQUIRED=4.2.0
@@ -173,45 +172,13 @@ if test x$AUTOGEN_PATH = xno; then
                 but several things won't work. You can get it from http://autogen.sourceforge.net/])
 fi
 
-
 dnl Check for libgd
-dnl ---------------
-
-AC_ARG_ENABLE(libgd,
-  AS_HELP_STRING([--disable-libgd], [Do not use libgd which needs a more recent version of Gtk+]),,
-  [enable_libgd=yes])
-
-if test "x$enable_libgd" = "xyes"; then
-       AC_MSG_CHECKING(if libgd is used)
-       PKG_CHECK_EXISTS([gtk+-3.0 >= $LIBGD_GTK_REQUIRED],
-           [ libgd_enabled=yes ],
-           [ libgd_enabled=no ])
-       AC_MSG_RESULT($libgd_enabled)
-else
-       libgd_enabled=no
-fi
-
-if test "x$libgd_enabled" = "xyes"; then
-       LIBGD_INIT([
-         revealer
-         static
-       ])
-
-       LOCAL_LIBGD_CFLAGS='-I$(top_srcdir)/libgd'
-       LOCAL_LIBGD_LIBS='$(top_builddir)/libgd/libgd.la'
-       AC_SUBST(LOCAL_LIBGD_CFLAGS)
-       AC_SUBST(LOCAL_LIBGD_LIBS)
-       AC_DEFINE([HAVE_LIBGD], [1], [Define to 1 if libgd is available])
-else
-       dnl LIBGD_INIT contains AM_CONDITIONAL so it has to be run but remove
-       dnl the check of Gtk+ version because we will not use libgd.
-       pushdef([PKG_CHECK_MODULES], [])
-       LIBGD_INIT([])
-       popdef([PKG_CHECK_MODULES])
-fi
-
-AM_CONDITIONAL(HAVE_LIBGD, [test x$libgd_enabled = xyes])
+dnl ---------------------
 
+LIBGD_INIT([
+  revealer
+  static
+])
 
 dnl Check for Terminal
 dnl ---------------------
@@ -990,13 +957,6 @@ else
        echo "        Requires vte-2.90 (>= $VTE_REQUIRED)"
 fi
 
-if [ test x$libgd_enabled = xyes ]; then
-        echo "Building using libgd: ..................................YES"
-else
-        echo "Building using libgd: ..................................NO"
-        echo "        Requires gtk+ (>= $LIBGD_GTK_REQUIRED)"
-fi
-
 if [ test x$enable_vala = xyes ]; then
         echo "Building Vala support: .................................YES"
 else
diff --git a/plugins/sourceview/Makefile.am b/plugins/sourceview/Makefile.am
index f193645..69bf443 100644
--- a/plugins/sourceview/Makefile.am
+++ b/plugins/sourceview/Makefile.am
@@ -30,7 +30,7 @@ AM_CPPFLAGS = \
        $(GIO_CFLAGS) \
        $(SOURCEVIEW_CFLAGS) \
        $(LIBANJUTA_CFLAGS) \
-       $(LOCAL_LIBGD_CFLAGS) \
+       -I$(top_srcdir)/libgd \
        -DG_LOG_DOMAIN=\"sourceview\"
 
 # Where to install the plugin
@@ -81,7 +81,7 @@ libanjuta_sourceview_la_LIBADD = \
        $(GIO_LIBS) \
        $(SOURCEVIEW_LIBS) \
        $(LIBANJUTA_LIBS) \
-       $(LOCAL_LIBGD_LIBS)
+       $(top_builddir)/libgd/libgd.la
 
 gsettings_in_file = org.gnome.anjuta.plugins.sourceview.gschema.xml.in
 gsettings_SCHEMAS = $(gsettings_in_file:.xml.in=.xml)
diff --git a/plugins/sourceview/sourceview-private.h b/plugins/sourceview/sourceview-private.h
index f3816f0..ff7482d 100644
--- a/plugins/sourceview/sourceview-private.h
+++ b/plugins/sourceview/sourceview-private.h
@@ -24,9 +24,7 @@
 #include "sourceview-io.h"
 
 #include <libanjuta/anjuta-plugin.h>
-#ifdef HAVE_LIBGD
 #include <libgd/gd-revealer.h>
-#endif
 #include <glib.h>
 
 struct SourceviewPrivate {
diff --git a/plugins/sourceview/sourceview.c b/plugins/sourceview/sourceview.c
index be2cf58..c42ebec 100644
--- a/plugins/sourceview/sourceview.c
+++ b/plugins/sourceview/sourceview.c
@@ -274,21 +274,19 @@ on_destroy_message_area (Sourceview* sv, GObject *finalized_object)
 static void
 message_area_destroy (GtkWidget* message_area)
 {
-#ifdef HAVE_LIBGD
        GtkWidget* revealer;
 
        revealer = gtk_widget_get_parent (message_area);
        g_signal_connect (revealer, "notify::child-revealed",
                          G_CALLBACK(gtk_widget_destroy), NULL);
        gd_revealer_set_reveal_child (GD_REVEALER (revealer), FALSE);
-#else
-       gtk_widget_destroy (message_area);
-#endif
 }
 
 static void
 sourceview_set_message_area (Sourceview* sv, GtkWidget *message_area)
 {
+       GtkWidget* revealer;
+
        if (sv->priv->message_area != NULL)
                message_area_destroy (sv->priv->message_area);
 
@@ -299,22 +297,13 @@ sourceview_set_message_area (Sourceview* sv, GtkWidget *message_area)
 
        gtk_widget_show (message_area);
 
-#ifdef HAVE_LIBGD
-       GtkWidget* revealer;
-
        revealer = gd_revealer_new ();
        gtk_widget_show (revealer);
        gtk_container_add (GTK_CONTAINER (revealer), message_area);
        gtk_box_pack_start (GTK_BOX (sv), revealer, FALSE, FALSE, 0);
 
        gd_revealer_set_reveal_child (GD_REVEALER (revealer), TRUE);
-#else
-       gtk_box_pack_start (GTK_BOX (sv),
-                                       message_area,
-                                       FALSE,
-                                       FALSE,
-                                       0);
-#endif
+
        g_object_weak_ref (G_OBJECT (message_area),
                           (GWeakNotify)on_destroy_message_area, sv);
 


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