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

Bug#443711: FTBFS: Uses deprecated GTK+ features



Package: d4x
Version: 2.5.7.1-4
Severity: serious
Tags: patch

d4x fails to build because it uses some deprecated GTK+ features and
defines GTK_DISABLE_DEPRECATED:

if i486-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I. -I../..   -I/usr/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/libpng12 -include ../../config.h  -O2 -Wall -MT fsched.o -MD -MP -MF ".deps/fsched.Tpo" -c -o fsched.o fsched.cc; \
	then mv -f ".deps/fsched.Tpo" ".deps/fsched.Po"; else rm -f ".deps/fsched.Tpo"; exit 1; fi
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc:45: warning: deprecated conversion from string constant to 'char*'
fsched.cc: In function 'GtkWidget* d4x_scheduler_init()':
fsched.cc:251: error: 'gtk_widget_ref' was not declared in this scope
fsched.cc: In function 'void my_gtk_aeditor_browse_ok(GtkWidget*, MyGtkAEditor*)':
fsched.cc:295: error: 'GTK_FILE_SELECTION' was not declared in this scope
fsched.cc:295: error: 'gtk_file_selection_get_filename' was not declared in this scope
fsched.cc: In function 'void my_gtk_aeditor_browse(GtkWidget*, MyGtkAEditor*)':
fsched.cc:309: error: 'gtk_file_selection_new' was not declared in this scope
fsched.cc:312: error: 'GTK_FILE_SELECTION' was not declared in this scope
fsched.cc:312: error: 'gtk_file_selection_set_filename' was not declared in this scope
fsched.cc:314: error: 'GTK_FILE_SELECTION' was not declared in this scope
fsched.cc: At global scope:
fsched.cc:113: warning: 'gint compare_nodes2(const void*, const void*)' defined but not used

The attached patch fixes this by not defining GTK_DISABLE_DEPRECATED.

-- 
Matt
diff -ru d4x-2.5.7.1~/configure.ac d4x-2.5.7.1/configure.ac
--- d4x-2.5.7.1~/configure.ac	2007-09-23 08:14:19.000000000 -0700
+++ d4x-2.5.7.1/configure.ac	2007-09-23 08:22:22.000000000 -0700
@@ -298,7 +298,6 @@
 
 # Other needed defines
 AC_DEFINE(_REENTRANT, , [Enable reenrant code of glibc])
-AC_DEFINE(GTK_DISABLE_DEPRECATED, , [Enable warnings about deprecated functions usage])
 AC_DEFINE(_FILE_OFFSET_BITS, 64, [To support files over 2GB])
 
 # Prepare all requiered flags
diff -ru d4x-2.5.7.1~/configure d4x-2.5.7.1/configure
--- d4x-2.5.7.1~/configure	2007-09-23 08:14:19.000000000 -0700
+++ d4x-2.5.7.1/configure	2007-09-23 08:22:28.000000000 -0700
@@ -18398,11 +18398,6 @@
 
 
 cat >>confdefs.h <<\_ACEOF
-#define GTK_DISABLE_DEPRECATED
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
 #define _FILE_OFFSET_BITS 64
 _ACEOF
 
diff -ru d4x-2.5.7.1~/main/face/list.cc d4x-2.5.7.1/main/face/list.cc
--- d4x-2.5.7.1~/main/face/list.cc	2007-09-23 08:14:19.000000000 -0700
+++ d4x-2.5.7.1/main/face/list.cc	2007-09-23 08:33:55.000000000 -0700
@@ -8,7 +8,6 @@
  *	but WITHOUT ANY WARRANTY; without even the implied warranty of
  *	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  */
-#define GTK_DISABLE_DEPRECATED
 
 #include <stdio.h>
 #include <gtk/gtk.h>

Reply to: