[gnome-video-arcade] Bump GTK+ requirement to 2.18.
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-video-arcade] Bump GTK+ requirement to 2.18.
- Date: Sat, 6 Mar 2010 21:40:54 +0000 (UTC)
commit e00214c6687f35448d4c42ceb0b95922db8e66b8
Author: Matthew Barnes <mbarnes redhat com>
Date: Sat Mar 6 12:57:51 2010 -0500
Bump GTK+ requirement to 2.18.
Remove all traces of libgnome as well as conditional compilation
sections for GTK+ versions newer than 2.12.
README | 31 ++++---------------------------
configure.ac | 25 ++-----------------------
data/gnome-video-arcade.builder | 2 +-
docs/reference/Makefile.am | 4 ----
src/Makefile.am | 15 ++++-----------
src/gva-main.c | 12 ------------
src/gva-util.c | 27 ---------------------------
src/main.c | 33 ---------------------------------
8 files changed, 11 insertions(+), 138 deletions(-)
---
diff --git a/README b/README
index c9a9eaf..9848adf 100644
--- a/README
+++ b/README
@@ -39,7 +39,7 @@ installed prior to compiling the source code:
documentation. This should be available from your GNU/Linux
distribution as a pre-compiled package.
- - Header files for GTK+ version 2.10 (or higher).
+ - Header files for GTK+ version 2.18 (or higher).
The GTK+ header files should be available from your GNU/Linux
distribution as a "development" package. The exact package name
@@ -91,25 +91,6 @@ installed prior to compiling the source code:
clips in the Properties window. The music clips are streamed
from http://www.arcade-history.com.
- - Header files for libgnomeui version 2.14 (or higher). (optional)
-
- The libgnomeui header files should be available from your
- GNU/Linux distribution as a "development" package. The exact
- package name varies by distribution, but it should be something
- similar to libgnomeui-devel (Fedora) or libgnomeui-dev
- (Debian/Ubuntu).
-
- This library is only needed to make the Help->Contents menu item
- work. If you are already using a GNOME desktop, you should already
- have this library installed. But if you would rather not drag in
- the entire GNOME development platform, you can configure GNOME
- Video Arcade to not link against GNOME libraries. See the
- Installation section to find out how.
-
- UPDATE: As of version 2.14, GTK+ can now open help on its own. So
- you no longer need libgnomeui if you're on a sufficiently
- up-to-date system.
-
- Header files for libwnck version 2.16 (or higher). (optional)
The libwnck header files should be available from your GNU/Linux
@@ -203,18 +184,14 @@ The --enable-gtk-doc configure option tells "make" to generate
developer documentation while building GNOME Video Arcade. Once
installed, the documentation can be viewed through Devhelp.
-The --with-gnome and --without-gnome configure options tell "make"
-whether to link against high-level GNOME libraries like libgnomeui.
-Similar "with"/"without" options are available for other optional
-libraries including D-Bus, GStreamer and libwnck. See the previous
-section for details on what these libraries are used for.
+Several "with"/"without" options are available for optional libraries
+including D-Bus, GStreamer and libwnck. See the previous section for
+details on what these libraries are used for.
For a complete list of configure options, run:
$ ./configure --help
-UPDATE: --with-gnome is now ignored if GTK+ >= 2.14 is detected.
-
Usage
-----
diff --git a/configure.ac b/configure.ac
index c5e792c..e0a9aa5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2,7 +2,7 @@
AC_PREREQ([2.54])
-m4_define([gva_version], 0.6.9)
+m4_define([gva_version], 0.7.0)
AC_INIT([GNOME Video Arcade], [gva_version],
[mbarnes redhat com], gnome-video-arcade)
@@ -23,7 +23,7 @@ AC_SUBST(abs_top_builddir)
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
# Dependencies
-GLIB_MODULES="glib-2.0 >= 2.12"
+GLIB_MODULES="glib-2.0 >= 2.18"
PKG_CHECK_MODULES(GLIB, $GLIB_MODULES)
AC_SUBST(GLIB_CFLAGS)
AC_SUBST(GLIB_LIBS)
@@ -68,26 +68,6 @@ AM_CONDITIONAL(HAVE_DBUS, test $with_dbus = yes)
AC_SUBST(DBUS_CFLAGS)
AC_SUBST(DBUS_LIBS)
-# --with-gnome=[yes|no]
-GNOME_CFLAGS=
-GNOME_LIBS=
-if pkg-config --atleast-version=2.14 gtk+-2.0; then
-with_gnome="n/a"
-else
-AC_ARG_WITH([gnome],
- [AC_HELP_STRING([--with-gnome],
- [require GNOME libraries [default=yes]])],
- with_gnome="$withval", with_gnome="yes")
-if test "$with_gnome" = "yes"; then
-GNOME_MODULES="libgnomeui-2.0 >= 2.14.0"
-PKG_CHECK_MODULES(GNOME, $GNOME_MODULES)
-AC_DEFINE_UNQUOTED(HAVE_GNOME, 1,
- [Define to 1 if you are using GNOME libraries])
-fi
-fi
-AC_SUBST(GNOME_CFLAGS)
-AC_SUBST(GNOME_LIBS)
-
# --with-gstreamer=[yes|no]
AC_ARG_WITH([gstreamer],
[AC_HELP_STRING([--with-gstreamer],
@@ -254,6 +234,5 @@ echo " History File : $with_history"
echo " NPlayers File : $with_nplayers"
echo " Use D-Bus : $with_dbus"
echo " Use GStreamer : $with_gstreamer"
-echo " Use libgnomeui : $with_gnome"
echo " Use libwnck : $with_wnck"
echo
diff --git a/data/gnome-video-arcade.builder b/data/gnome-video-arcade.builder
index a56606c..6948655 100644
--- a/data/gnome-video-arcade.builder
+++ b/data/gnome-video-arcade.builder
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<interface>
- <!-- interface-requires gtk+ 2.12 -->
+ <requires lib="gtk+" version="2.16"/>
<!-- interface-requires gva 0.0 -->
<!-- interface-naming-policy toplevel-contextual -->
<object class="GtkWindow" id="main-window">
diff --git a/docs/reference/Makefile.am b/docs/reference/Makefile.am
index 58f84df..89d62c5 100644
--- a/docs/reference/Makefile.am
+++ b/docs/reference/Makefile.am
@@ -79,8 +79,6 @@ INCLUDES= \
$(GTK_CFLAGS) \
$(GIT_CFLAGS) \
$(GCONF_CFLAGS) \
- $(GLADE_CFLAGS) \
- $(GNOME_CFLAGS) \
$(GSTREAMER_CFLAGS) \
$(SQLITE_CFLAGS) \
$(WNCK_CFLAGS)
@@ -125,8 +123,6 @@ GTKDOC_LIBS= \
$(GTK_LIBS) \
$(GIT_LIBS) \
$(GCONF_LIBS) \
- $(GLADE_LIBS) \
- $(GNOME_LIBS) \
$(GSTREAMER_LIBS) \
$(SQLITE_LIBS) \
$(WNCK_LIBS)
diff --git a/src/Makefile.am b/src/Makefile.am
index fae9659..f17f72c 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -5,17 +5,11 @@ bin_PROGRAMS = gnome-video-arcade
AM_CFLAGS = \
-Wall \
@DBUS_CFLAGS@ @GLIB_CFLAGS@ @GTK_CFLAGS@ \
- @GIT_CFLAGS@ @GCONF_CFLAGS@ @GNOME_CFLAGS@ \
- @GSTREAMER_CFLAGS@ @SQLITE_CFLAGS@ @WNCK_CFLAGS@
+ @GIT_CFLAGS@ @GCONF_CFLAGS@ @GSTREAMER_CFLAGS@ \
+ @SQLITE_CFLAGS@ @WNCK_CFLAGS@
-# The DATADIR, LIBDIR, PREFIX, and SYSCONFDIR definitions
-# are only needed for libgnome. GLib handles it better.
AM_CPPFLAGS = \
-DG_LOG_DOMAIN=\"Gva\" \
- -DDATADIR=\""$(datadir)"\" \
- -DLIBDIR=\""$(libdir)"\" \
- -DPREFIX=\""$(prefix)"\" \
- -DSYSCONFDIR=\""$(sysconfdir)"\" \
-DTOPSRCDIR=\""$(abs_top_builddir)"\" \
-DLOCALEDIR=\""$(datadir)/locale/"\"
@@ -96,9 +90,8 @@ EXTRA_gnome_video_arcade_SOURCES = \
gnome_video_arcade_LDADD = \
@DBUS_LIBS@ @GLIB_LIBS@ @GTK_LIBS@ \
- @GIT_LIBS@ @GCONF_LIBS@ @GNOME_LIBS@ \
- @GSTREAMER_LIBS@ @MAME_BACKEND@ \
- @SQLITE_LIBS@ @WNCK_LIBS@
+ @GIT_LIBS@ @GCONF_LIBS@ @GSTREAMER_LIBS@ \
+ @MAME_BACKEND@ @SQLITE_LIBS@ @WNCK_LIBS@
gnome_video_arcade_DEPENDENCIES = \
@MAME_BACKEND@
diff --git a/src/gva-main.c b/src/gva-main.c
index 6aa814d..2f681ce 100644
--- a/src/gva-main.c
+++ b/src/gva-main.c
@@ -191,11 +191,6 @@ gva_main_init (void)
gtk_entry_set_text (GTK_ENTRY (GVA_WIDGET_MAIN_SEARCH_ENTRY), text);
g_free (text);
-#if !GTK_CHECK_VERSION(2,14,0) && !defined HAVE_GNOME
- /* Requires that we link against libgnome. */
- gtk_action_set_sensitive (GVA_ACTION_CONTENTS, FALSE);
-#endif
-
gtk_action_set_sensitive (GVA_ACTION_PROPERTIES, FALSE);
gtk_action_set_sensitive (GVA_ACTION_RECORD, FALSE);
gtk_action_set_sensitive (GVA_ACTION_SEARCH, FALSE);
@@ -355,9 +350,7 @@ gva_main_init_search_completion (GError **error)
sqlite3_stmt *stmt;
gint errcode;
-#if GTK_CHECK_VERSION(2,13,1)
GList *list;
-#endif
if (!gva_db_prepare (SQL_COMPLETION_LIST, &stmt, error))
return FALSE;
@@ -413,14 +406,9 @@ gva_main_init_search_completion (GError **error)
completion, "match-selected",
G_CALLBACK (main_entry_completion_match_selected_cb), NULL);
- /* XXX GtkEntryCompletion does not implement get_cells().
- * http://bugzilla.gnome.org/show_bug.cgi?id=523787
- * Fixed in GTK+ 2.13.1. */
-#if GTK_CHECK_VERSION(2,13,1)
list = gtk_cell_layout_get_cells (GTK_CELL_LAYOUT (completion));
g_object_set (list->data, "ellipsize", PANGO_ELLIPSIZE_END, NULL);
g_list_free (list);
-#endif
renderer = gtk_cell_renderer_text_new ();
g_object_set (renderer, "sensitive", FALSE, "xalign", 1.0, NULL);
diff --git a/src/gva-util.c b/src/gva-util.c
index b6afb24..44bb9fc 100644
--- a/src/gva-util.c
+++ b/src/gva-util.c
@@ -23,10 +23,6 @@
#include "gva-error.h"
#include "gva-mame.h"
-#ifdef HAVE_GNOME
-#include <gnome.h>
-#endif
-
#define DEFAULT_MONOSPACE_FONT_NAME "Monospace 10"
#define GCONF_MONOSPACE_FONT_NAME_KEY \
@@ -338,7 +334,6 @@ void
gva_help_display (GtkWindow *parent,
const gchar *link_id)
{
-#if GTK_CHECK_VERSION(2,14,0)
GString *uri;
GtkWidget *dialog;
GdkScreen *screen = NULL;
@@ -373,28 +368,6 @@ gva_help_display (GtkWindow *parent,
exit:
g_string_free (uri, TRUE);
-
-#elif defined HAVE_GNOME
- GtkWidget *dialog;
- GError *error = NULL;
-
- if (gnome_help_display ("gnome-video-arcade.xml", link_id, &error))
- return;
-
- dialog = gtk_message_dialog_new_with_markup (
- parent, GTK_DIALOG_DESTROY_WITH_PARENT,
- GTK_MESSAGE_ERROR, GTK_BUTTONS_OK,
- "<big><b>%s</b></big>",
- _(PACKAGE_NAME " could not display the help contents."));
-
- gtk_message_dialog_format_secondary_text (
- GTK_MESSAGE_DIALOG (dialog), "%s", error->message);
-
- gtk_dialog_run (GTK_DIALOG (dialog));
-
- gtk_widget_destroy (dialog);
- g_error_free (error);
-#endif
}
/**
diff --git a/src/main.c b/src/main.c
index f99a014..6fff161 100644
--- a/src/main.c
+++ b/src/main.c
@@ -24,10 +24,6 @@
#include <stdlib.h>
#include <string.h>
-#ifdef HAVE_GNOME
-#include <gnome.h>
-#endif
-
#include "gva-audit.h"
#include "gva-categories.h"
#include "gva-db.h"
@@ -109,7 +105,6 @@ warn_if_no_roms (void)
"<big><b>%s</b></big>",
_("No ROM files found"));
-#if GTK_CHECK_VERSION(2,14,0) || defined HAVE_GNOME
gtk_message_dialog_format_secondary_markup (
GTK_MESSAGE_DIALOG (dialog),
_("GNOME Video Arcade was unable to locate any ROM files. "
@@ -119,14 +114,6 @@ warn_if_no_roms (void)
gtk_dialog_add_button (
GTK_DIALOG (dialog), GTK_STOCK_HELP, GTK_RESPONSE_HELP);
-#else
- gtk_message_dialog_format_secondary_markup (
- GTK_MESSAGE_DIALOG (dialog),
- _("GNOME Video Arcade was unable to locate any ROM files. "
- "It could be that MAME is misconfigured or no ROM files "
- "are installed. Consult the user documentation for more "
- "details and troubleshooting tips."));
-#endif
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_HELP)
gva_help_display (GTK_WINDOW (dialog), "troubleshooting");
@@ -203,10 +190,6 @@ start (void)
gint
main (gint argc, gchar **argv)
{
-#ifdef HAVE_GNOME
- GnomeProgram *program;
- GOptionContext *context;
-#endif
gchar *path;
GError *error = NULL;
@@ -216,22 +199,10 @@ main (gint argc, gchar **argv)
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
-#ifdef HAVE_GNOME
- context = g_option_context_new (NULL);
- g_option_context_set_translation_domain (context, GETTEXT_PACKAGE);
- g_option_context_add_main_entries (context, entries, GETTEXT_PACKAGE);
-
- program = gnome_program_init (
- PACKAGE, VERSION, LIBGNOMEUI_MODULE, argc, argv,
- GNOME_PROGRAM_STANDARD_PROPERTIES,
- GNOME_PARAM_GOPTION_CONTEXT, context,
- GNOME_PARAM_NONE);
-#else
gtk_init_with_args (
&argc, &argv, NULL, entries, GETTEXT_PACKAGE, &error);
if (error != NULL)
g_error ("%s", error->message);
-#endif
#ifdef HAVE_GSTREAMER
if (!gst_init_check (&argc, &argv, &error))
@@ -310,9 +281,5 @@ main (gint argc, gchar **argv)
gtk_main ();
-#ifdef HAVE_GNOME
- g_object_unref (program);
-#endif
-
return EXIT_SUCCESS;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]