GNU bug report logs - #5831
23.1.94; htmlfontify's `hfy-which-etags' not finding etags "standalone"

Previous Next

Package: emacs;

Reported by: MON KEY <monkey <at> sandpframing.com>

Date: Sat, 3 Apr 2010 18:42:02 UTC

Severity: normal

Fixed in version 23.3

Done: Glenn Morris <rgm <at> gnu.org>

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 5831 in the body.
You can then email your comments to 5831 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 owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#5831; Package emacs. (Sat, 03 Apr 2010 18:42:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to MON KEY <monkey <at> sandpframing.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 03 Apr 2010 18:42:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: MON KEY <monkey <at> sandpframing.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 23.1.94; htmlfontify's `hfy-which-etags' not finding etags 
	"standalone"
Date: Sat, 3 Apr 2010 14:41:40 -0400
`hfy-which-etags' fails when the etags executable in path is of type
"standalone" (not sure if this w32 specific):

(shell-command-to-string (concat hfy-etags-bin " --version"))

(executable-find hfy-etags-bin)
 ;=> "<MY-W32-PATH>/emacs-23.1.94/bin/etags.exe"

(executable-find "etags")
 ;=> "<MY-W32-PATH>/emacs-23.1.94/bin/etags.exe"

(equal (executable-find hfy-etags-bin)
       (executable-find "etags"))
 ;=> t

 (shell-command-to-string (concat  hfy-etags-bin " --version")))

 ;=> "etags (standalone 17.38.1.4)
 ; |  Copyright (C) 2010 Free Software Foundation, Inc.
 ; |  This program is distributed under the terms in ETAGS.README"

Its unlikey we wouldn't have an etags in path...

On a GNU/Linux evaluating same I get:

(shell-command-to-string (concat  hfy-etags-bin " --version"))
 ;=> "etags (GNU Emacs 23.1.90)
 ; |  Copyright (C) 2009 Free Software Foundation, Inc.
 ; |  This program is distributed under the terms in ETAGS.README"

and `hfy-which-etags' conditional _does_ match this etags exectuable.

`hfy-which-etags' conditional string-match evaluations should have a rule to
match a ``standalone'' etags.

The problem is that when `hfy-which-etags' returns false
it causes `hfy-etags-cmd' to fail:

 (cdr (assoc (hfy-which-etags) hfy-etags-cmd-alist))
  ;=> nil

if we add a new rule to `hfy-which-etags' conditional:

  ((string-match "standalone" v) "emacs etags")

then we get the appropriate shell script template:

 (cdr (assoc (hfy-which-etags) hfy-etags-cmd-alist))

 ;=> for src in `find . -type f`;
 ; |   do
 ; |     ETAGS=%s;
 ; |   { ...  lots more ellided ... }

This won't change htmlfontify's reliance on a POSIX friendly shell
(nor should it). However, the user shouldn't be restricted from using
this library _because_ she is using the executable distributed _with_
her local Emacs...

Patch follows:

;;; ==============================

*** lisp/htmlfontify.el	2010-03-10 20:20:34.000000000 -0500
--- buffer-content-3664ZIc	2010-04-03 14:28:32.493000000 -0400
***************
*** 391,397 ****
  (defun hfy-which-etags ()
    "Return a string indicating which flavour of etags we are using."
    (let ((v (shell-command-to-string (concat hfy-etags-bin " --version"))))
!     (cond ((string-match "exube" v) "exuberant ctags")
            ((string-match "GNU E" v) "emacs etags"    )) ))

  (defcustom hfy-etags-cmd
--- 391,398 ----
  (defun hfy-which-etags ()
    "Return a string indicating which flavour of etags we are using."
    (let ((v (shell-command-to-string (concat hfy-etags-bin " --version"))))
!     (cond ((string-match "standalone" v) "exuberant ctags")
!           ((string-match "exube" v) "exuberant ctags")
            ((string-match "GNU E" v) "emacs etags"    )) ))

  (defcustom hfy-etags-cmd

;;; ==============================

/s_P\





Reply sent to Glenn Morris <rgm <at> gnu.org>:
You have taken responsibility. (Thu, 31 May 2012 17:43:01 GMT) Full text and rfc822 format available.

Notification sent to MON KEY <monkey <at> sandpframing.com>:
bug acknowledged by developer. (Thu, 31 May 2012 17:43:02 GMT) Full text and rfc822 format available.

Message #10 received at 5831-done <at> debbugs.gnu.org (full text, mbox):

From: Glenn Morris <rgm <at> gnu.org>
To: 5831-done <at> debbugs.gnu.org
Subject: Re: bug#5831: 23.1.94;
	htmlfontify's `hfy-which-etags' not finding etags  "standalone"
Date: Thu, 31 May 2012 13:40:44 -0400
Version: 23.3

I guess this will have been fixed by this change:

2011-02-02  Eli Zaretskii  <eliz AT gnu.org>

   * makefile.w32-in (ETAGS_CFLAGS, CTAGS_CFLAGS): Add
   ``-DVERSION="\"$(VERSION)\"" -DEMACS_NAME="\"GNU Emacs\""''.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5831; Package emacs. (Thu, 31 May 2012 17:59:01 GMT) Full text and rfc822 format available.

Message #13 received at 5831 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Glenn Morris <rgm <at> gnu.org>
Cc: rgm <at> gnu.org, 5831 <at> debbugs.gnu.org
Subject: Re: bug#5831: 23.1.94;
	htmlfontify's `hfy-which-etags' not finding etags  "standalone"
Date: Thu, 31 May 2012 20:56:53 +0300
> From: Glenn Morris <rgm <at> gnu.org>
> Date: Thu, 31 May 2012 13:40:44 -0400
> 
> Version: 23.3
> 
> I guess this will have been fixed by this change:
> 
> 2011-02-02  Eli Zaretskii  <eliz AT gnu.org>
> 
>    * makefile.w32-in (ETAGS_CFLAGS, CTAGS_CFLAGS): Add
>    ``-DVERSION="\"$(VERSION)\"" -DEMACS_NAME="\"GNU Emacs\""''.

Yes.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 29 Jun 2012 11:24:02 GMT) Full text and rfc822 format available.

This bug report was last modified 12 years and 361 days ago.

Previous Next


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