From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Adam Spiers Newsgroups: gmane.emacs.devel,gmane.emacs.pretest.bugs Subject: custom-variable-menu loses entries if defined during site-start Date: Sun, 7 Oct 2007 18:16:53 +0100 Message-ID: <20071007171653.GA11765@atlantic.linksys.moosehall> Reply-To: Adam Spiers NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1191782202 4585 80.91.229.12 (7 Oct 2007 18:36:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 7 Oct 2007 18:36:42 +0000 (UTC) To: emacs-pretest-bug@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Oct 07 20:36:40 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IeazU-0000xf-Uq for ged-emacs-devel@m.gmane.org; Sun, 07 Oct 2007 20:36:37 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IeazP-0000Bq-Pp for ged-emacs-devel@m.gmane.org; Sun, 07 Oct 2007 14:36:31 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IeZkV-0007rD-1P for emacs-devel@gnu.org; Sun, 07 Oct 2007 13:17:03 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IeZkT-0007pg-Rl for emacs-devel@gnu.org; Sun, 07 Oct 2007 13:17:02 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IeZkT-0007pU-Oi for emacs-devel@gnu.org; Sun, 07 Oct 2007 13:17:01 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IeZkT-000848-C6 for emacs-devel@gnu.org; Sun, 07 Oct 2007 13:17:01 -0400 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by fencepost.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IeZjY-0000Jf-Oy for emacs-pretest-bug@gnu.org; Sun, 07 Oct 2007 13:16:04 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1IeZkO-00082Y-8L for emacs-pretest-bug@gnu.org; Sun, 07 Oct 2007 13:17:00 -0400 Original-Received: from mail.beimborn.com ([70.84.38.100]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IeZkN-00082G-QE for emacs-pretest-bug@gnu.org; Sun, 07 Oct 2007 13:16:56 -0400 Original-Received: from mail.beimborn.com (localhost.localdomain [127.0.0.1]) by mail.beimborn.com (8.12.11.20060308/8.12.8) with ESMTP id l97HGsQi017254 for ; Sun, 7 Oct 2007 12:16:54 -0500 Original-Received: from localhost (localhost [[UNIX: localhost]]) by mail.beimborn.com (8.12.11.20060308/8.12.11/Submit) id l97HGsTU017248 for emacs-pretest-bug@gnu.org; Sun, 7 Oct 2007 18:16:54 +0100 X-Authentication-Warning: mail.beimborn.com: adam set sender to f5-sendmail@adamspiers.org using -f Content-Disposition: inline X-OS: Linux User-Agent: Mutt/1.5.14 (2007-02-12) X-Detected-Kernel: Linux 2.4-2.6 X-Detected-Kernel: Linux 2.6, seldom 2.4 (older, 4) X-Mailman-Approved-At: Sun, 07 Oct 2007 14:32:52 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:80389 gmane.emacs.pretest.bugs:20085 Archived-At: Hi there, I *think* this is probably an emacs bug, but if it's a distro bug please let me know and I'll report it to the Fedora folk. I noticed that since upgrading to emacs 22, when changing variables in a Custom buffer, individual variables no longer offered the "Save for Future Sessions" action in the State menu, even when custom-file and user-init-file are set correctly. I tracked it down to this change: http://cvs.savannah.gnu.org/viewvc/emacs/lisp/cus-edit.el?root=emacs&view=diff&r1=1.250&r2=1.251 In particular, in the defvar of custom-variable-menu: ("Save for Future Sessions" custom-variable-save is changed to ,@(when (or custom-file user-init-file) '(("Save for Future Sessions" custom-variable-save This works fine if cus-edit.el is loaded after custom-file and/or user-init-file are initialized during startup. However, on Fedora 7, the emacs-common-22.0.990-2.fc7 rpm installs the file: /usr/share/emacs/site-lisp/site-start.el which invokes a file installed by the emacs-muse-3.02.93-5.fc7 rpm: /usr/share/emacs/site-lisp/site-start.d/muse-init.el which invokes: /usr/share/emacs/site-lisp/muse/muse-project.el which contains: (require 'cus-edit) This all happens before the user's .emacs is loaded, therefore neither custom-file nor user-init-file are defined, and the menu choices end up being erroneously omitted. If emacs is invoked with --no-site-file, then the menu choices reappear. What is the correct approach for fixing this? Thanks a lot! Adam In GNU Emacs 22.0.990.1 (i386-koji-linux-gnu, GTK+ Version 2.10.11) of 2007-05-23 on xenbuilder3.fedora.phx.redhat.com configured using `configure '--build=i386-koji-linux-gnu' '--host=i386-koji-linux-gnu' '--target=i386-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--with-pop' '--with-sound' '--with-gtk' 'build_alias=i386-koji-linux-gnu' 'host_alias=i386-koji-linux-gnu' 'target_alias=i386-redhat-linux-gnu' 'CFLAGS=-DMAIL_USE_LOCKF -DSYSTEM_PURESIZE_EXTRA=16777216 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: nil locale-coding-system: nil default-enable-multibyte-characters: t Major mode: Info Minor modes in effect: eldoc-mode: t display-time-mode: t show-paren-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t