Bug#600185: gnuplot-mode: void-function: make-local-hook

2010-10-14 Thread Julien Danjou
Package: gnuplot-mode
Version: 1:0.6.0-5
Severity: normal

With Emacs 24:

Debugger entered--Lisp error: (void-function make-local-hook)
  make-local-hook(kill-buffer-hook)
  gnuplot-make-gnuplot-buffer()

It should be removed. :)

-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=C, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages gnuplot-mode depends on:
ii  emacs [emacsen] 23.2+1-4 The GNU Emacs editor (metapackage)
ii  emacs-snapshot [emacsen]1:20101008-1 The GNU Emacs editor (development 
ii  emacs23 [emacsen]   23.2+1-4 The GNU Emacs editor (with GTK+ us
ii  gnuplot-nox 4.4.0-1.1A command-line driven interactive 
ii  gnuplot-x11 4.4.0-1.1A command-line driven interactive 

gnuplot-mode recommends no packages.

gnuplot-mode suggests no packages.

-- no debconf information

-- 
Julien Danjou
// ᐰ jul...@danjou.info   http://julien.danjou.info


pgpO4RTE9MoCg.pgp
Description: PGP signature


Bug#600185: gnuplot-mode: void-function: make-local-hook

2010-10-14 Thread Agustin Martin
tag 600185 +patch
thanks

On Thu, Oct 14, 2010 at 03:08:10PM +0200, Julien Danjou wrote:
 Package: gnuplot-mode
 Version: 1:0.6.0-5
 Severity: normal
 
 With Emacs 24:
 
 Debugger entered--Lisp error: (void-function make-local-hook)
   make-local-hook(kill-buffer-hook)
   gnuplot-make-gnuplot-buffer()
 
 It should be removed. :)

No, that will break XEmacs. Should be used conditionally as proposed
in attached patch.

-- 
Agustin
From 7444e992ebc37ead3530333c8f70d58db6259681 Mon Sep 17 00:00:00 2001
From: Agustin Martin Domingo agmar...@debian.org
Date: Thu, 14 Oct 2010 16:09:04 +0200
Subject: [PATCH] 450_gnuplot.el_make-local-hook: Call (make-local-hook) only for XEmacs.

For XEmacs we need to explicitly make a hook buffer local by means of
(make-local-hook). For FSF Emacs passing non-nil as local option will
automatically do this. For FSF Emacs 24 (make-local-hook) is no longer
provided as of 2010-10-03 (bzr r101741). Use it conditionally for
XEmacs and explicitly put 'local instead of t for clarity.
---
 debian/changelog   |8 +
 debian/patches/00list  |1 +
 .../patches/450_gnuplot.el_make-local-hook.dpatch  |   29 
 3 files changed, 38 insertions(+), 0 deletions(-)
 create mode 100755 debian/patches/450_gnuplot.el_make-local-hook.dpatch

diff --git a/debian/changelog b/debian/changelog
index 1d9b66c..75f40ee 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+gnuplot-mode (1:0.6.0-5.1) unstable; urgency=low
+
+  * patches/450_gnuplot.el_make-local-hook: Call (make-local-hook)
+only for XEmacs, (add-hook) local option will already make
+hook buffer local for FSF Emacs (Closes: #600185).
+
+ -- Agustin Martin Domingo agmar...@debian.org  Thu, 14 Oct 2010 16:08:25 +0200
+
 gnuplot-mode (1:0.6.0-5) unstable; urgency=low
 
   * patches/900_gnuplot.el_fix_indentation to fix indentation (closes:
diff --git a/debian/patches/00list b/debian/patches/00list
index 34e234d..737d2ed 100644
--- a/debian/patches/00list
+++ b/debian/patches/00list
@@ -1,3 +1,4 @@
+450_gnuplot.el_make-local-hook
 500_gnuplot.el_make-variable-buffer-local
 850_gnuplot.el_fix-obsolete-backquotes
 900_gnuplot.el_fix_indentation
\ No newline at end of file
diff --git a/debian/patches/450_gnuplot.el_make-local-hook.dpatch b/debian/patches/450_gnuplot.el_make-local-hook.dpatch
new file mode 100755
index 000..47766ff
--- /dev/null
+++ b/debian/patches/450_gnuplot.el_make-local-hook.dpatch
@@ -0,0 +1,29 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 450_gnuplot.el_make-local-hook.dpatch by Agustin Martin Domingo agmar...@debian.org
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: 'local does not automatically make hook buffer-local in XEmacs.
+
+For XEmacs we need to explicitly make a hook buffer local by means of 
+(make-local-hook). For FSF Emacs passing non-nil as local option will 
+automatically do this. For FSF Emacs 24 (make-local-hook) is no longer
+provided as of 2010-10-03 (bzr r101741). Use it conditionally for 
+XEmacs and explicitly put 'local instead of t for clarity.
+
+...@dpatch@
+diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' gnuplot-mode~/gnuplot.el gnuplot-mode/gnuplot.el
+--- gnuplot-mode~/gnuplot.el	2010-10-14 15:44:53.0 +0200
 gnuplot-mode/gnuplot.el	2010-10-14 15:45:56.0 +0200
+@@ -1863,8 +1863,10 @@
+ 	(process-kill-without-query gnuplot-process nil)
+ 	(save-excursion
+ 	  (set-buffer gnuplot-buffer)
+-	  (make-local-hook 'kill-buffer-hook)
+-	  (add-hook 'kill-buffer-hook 'gnuplot-close-down nil t)
++	  ;; 'local does not automatically make hook buffer-local in XEmacs.
++  (if (featurep 'xemacs)
++  (make-local-hook 'kill-buffer-hook))
++  (add-hook 'kill-buffer-hook 'gnuplot-close-down nil 'local)
+ 	  (gnuplot-comint-start-function)
+   (make-local-variable 'comint-output-filter-functions)
+   (setq comint-output-filter-functions
-- 
1.7.1



Bug#600185: gnuplot-mode: void-function: make-local-hook

2010-10-14 Thread Vincent Fourmond
On Thu, Oct 14, 2010 at 4:23 PM, Agustin Martin agmar...@debian.org wrote:
 tag 600185 +patch
 thanks

 On Thu, Oct 14, 2010 at 03:08:10PM +0200, Julien Danjou wrote:
 Package: gnuplot-mode
 Version: 1:0.6.0-5
 Severity: normal

 With Emacs 24:

 Debugger entered--Lisp error: (void-function make-local-hook)
   make-local-hook(kill-buffer-hook)
   gnuplot-make-gnuplot-buffer()

 It should be removed. :)

 No, that will break XEmacs. Should be used conditionally as proposed
 in attached patch.

  Wow ! I hardly had time to notice that there was a bug message in my
mail box that I already have it a patched ;-)...

  Many thanks !

  Vincent



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org