GNU bug report logs - #3043
23.0.92; GtkFileSelection is deprecated

Previous Next

Package: emacs;

Reported by: Sven Joachim <svenjoac <at> gmx.de>

Date: Sat, 18 Apr 2009 07:55:03 UTC

Severity: normal

Done: Jan Djärv <jan.h.d <at> swipnet.se>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 3043 in the body.
You can then email your comments to 3043 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-submit-list <at> lists.donarmstrong.com, Sven Joachim <svenjoac <at> gmx.de>, Jan Djärv <jan.h.d <at> swipnet.se>, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sat, 18 Apr 2009 07:55:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sven Joachim <svenjoac <at> gmx.de>:
New bug report received and forwarded. Copy sent to Sven Joachim <svenjoac <at> gmx.de>, Jan Djärv <jan.h.d <at> swipnet.se>, Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sat, 18 Apr 2009 07:55:04 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Sven Joachim <svenjoac <at> gmx.de>
To: emacs-pretest-bug <at> gnu.org
Subject: 23.0.92; GtkFileSelection is deprecated
Date: Sat, 18 Apr 2009 08:48:17 +0200
Emacs uses GtkFileSelection in gtkutil.c which has been deprecated in
GTK+ 2.12.  That means that it will not build with a future GTK+ 3.0,
or with -DGTK_DISABLE_DEPRECATED in a current GTK+ 2.x.

This problem is not urgent, but it would be good if gtkutil.c could use
the GtkFileChooser interface instead.




Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sat, 18 Apr 2009 13:55:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Chong Yidong <cyd <at> stupidchicken.com>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sat, 18 Apr 2009 13:55:05 GMT) Full text and rfc822 format available.

Message #10 received at 3043 <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Chong Yidong <cyd <at> stupidchicken.com>
To: Sven Joachim <svenjoac <at> gmx.de>
Cc: 3043 <at> debbugs.gnu.org
Subject: Re: 23.0.92; GtkFileSelection is deprecated
Date: Sat, 18 Apr 2009 09:48:31 -0400
> Emacs uses GtkFileSelection in gtkutil.c which has been deprecated in
> GTK+ 2.12.  That means that it will not build with a future GTK+ 3.0,
> or with -DGTK_DISABLE_DEPRECATED in a current GTK+ 2.x.

Actually, Emacs does support the new GTK file chooser.  It's used if
HAVE_GTK_FILE_CHOOSER_DIALOG_NEW is defined, which is set by configure
upon checking the existence of the function gtk_file_chooser_dialog_new.
Is it not available on your system?




Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sat, 18 Apr 2009 14:35:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sven Joachim <svenjoac <at> gmx.de>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sat, 18 Apr 2009 14:35:03 GMT) Full text and rfc822 format available.

Message #15 received at 3043 <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Sven Joachim <svenjoac <at> gmx.de>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 3043 <at> debbugs.gnu.org
Subject: Re: 23.0.92; GtkFileSelection is deprecated
Date: Sat, 18 Apr 2009 16:29:41 +0200
On 2009-04-18 15:48 +0200, Chong Yidong wrote:

>> Emacs uses GtkFileSelection in gtkutil.c which has been deprecated in
>> GTK+ 2.12.  That means that it will not build with a future GTK+ 3.0,
>> or with -DGTK_DISABLE_DEPRECATED in a current GTK+ 2.x.
>
> Actually, Emacs does support the new GTK file chooser.  It's used if
> HAVE_GTK_FILE_CHOOSER_DIALOG_NEW is defined, which is set by configure
> upon checking the existence of the function gtk_file_chooser_dialog_new.
> Is it not available on your system?

It is, and HAVE_GTK_FILE_CHOOSER_DIALOG_NEW is defined.  However,
HAVE_GTK_FILE_BOTH and HAVE_GTK_FILE_SELECTION_NEW are also defined
which might explain the problem.

I built with 

,----
| make distclean
| CFLAGS=-DGTK_DISABLE_DEPRECATED -g -O2 ./configure
| make -k
`----

and ran into

,----
| gtkutil.c: In function 'xg_get_file_name_from_selector':
| gtkutil.c:1479: error: 'GtkFileSelection' undeclared (first use in this function)
| gtkutil.c:1479: error: (Each undeclared identifier is reported only once
| gtkutil.c:1479: error: for each function it appears in.)
| gtkutil.c:1479: error: 'filesel' undeclared (first use in this function)
| gtkutil.c: In function 'xg_get_file_with_selection':
| gtkutil.c:1503: error: 'GtkFileSelection' undeclared (first use in this function)
| gtkutil.c:1503: error: 'filesel' undeclared (first use in this function)
`----

Sven




Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sat, 18 Apr 2009 16:40:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jan Djärv <jan.h.d <at> swipnet.se>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sat, 18 Apr 2009 16:40:04 GMT) Full text and rfc822 format available.

Message #20 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Jan Djärv <jan.h.d <at> swipnet.se>
To: Sven Joachim <svenjoac <at> gmx.de>, 3043 <at> debbugs.gnu.org
Cc: emacs-pretest-bug <at> gnu.org
Subject: Re: bug#3043: 23.0.92; GtkFileSelection is deprecated
Date: Sat, 18 Apr 2009 18:30:48 +0200

Sven Joachim skrev:
> Emacs uses GtkFileSelection in gtkutil.c which has been deprecated in
> GTK+ 2.12.  That means that it will not build with a future GTK+ 3.0,
> or with -DGTK_DISABLE_DEPRECATED in a current GTK+ 2.x.
> 
> This problem is not urgent, but it would be good if gtkutil.c could use
> the GtkFileChooser interface instead.
> 

Actually Emacs has used GtkFileChooser by default for a long time now, more or 
less since it became available in a stable Gtk+ release.  But if both are 
available, GtkFileSelection can be used (I don't remember the customize 
variable for it right now).  There is a configure test for both file dialogs, 
so if one is removed in 3.0, Emacs will compile just fine.  However, as 
configure just looks at link time symbols, we might not do the right thing 
when compiled with -DGTK_DISABLE_DEPRECATED.  I'll check this.

	Jan D.




Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sat, 18 Apr 2009 16:40:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jan Djärv <jan.h.d <at> swipnet.se>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sat, 18 Apr 2009 16:40:05 GMT) Full text and rfc822 format available.

Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#3043; Package emacs. (Sun, 19 Apr 2009 11:05:06 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jan Djärv <jan.h.d <at> swipnet.se>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. (Sun, 19 Apr 2009 11:05:06 GMT) Full text and rfc822 format available.

Message #30 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Jan Djärv <jan.h.d <at> swipnet.se>
To: Sven Joachim <svenjoac <at> gmx.de>, 3043_done <at> debbugs.gnu.org
Cc: emacs-pretest-bug <at> gnu.org
Subject: Re: bug#3043: 23.0.92; GtkFileSelection is deprecated
Date: Sun, 19 Apr 2009 12:57:19 +0200
Sven Joachim skrev:
> Emacs uses GtkFileSelection in gtkutil.c which has been deprecated in
> GTK+ 2.12.  That means that it will not build with a future GTK+ 3.0,
> or with -DGTK_DISABLE_DEPRECATED in a current GTK+ 2.x.
> 
> This problem is not urgent, but it would be good if gtkutil.c could use
> the GtkFileChooser interface instead.
> 

I have checked in a better configure test and some other minor changes so
Emacs compiles with -DGTK_DISABLE_DEPRECATED.

	Jan D.




Reply sent to Jan Djärv <jan.h.d <at> swipnet.se>:
You have taken responsibility. (Sun, 19 Apr 2009 13:30:05 GMT) Full text and rfc822 format available.

Notification sent to Sven Joachim <svenjoac <at> gmx.de>:
bug acknowledged by developer. (Sun, 19 Apr 2009 13:30:05 GMT) Full text and rfc822 format available.

Message #35 received at 3043-done <at> emacsbugs.donarmstrong.com (full text, mbox):

From: Jan Djärv <jan.h.d <at> swipnet.se>
To: 3043-done <at> debbugs.gnu.org
Subject: Done
Date: Sun, 19 Apr 2009 15:23:38 +0200
Done.

	Jan D.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> emacsbugs.donarmstrong.com. (Sun, 17 May 2009 14:24:13 GMT) Full text and rfc822 format available.

This bug report was last modified 16 years and 95 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.