Subject: Re: pkg/28977: a couple of problems with editors/emacs
To: Julio M. Merino Vidal <jmmv84@gmail.com>
From: Greg A. Woods <woods@weird.com>
List: pkgsrc-bugs
Date: 01/16/2005 15:46:22
[ On Sunday, January 16, 2005 at 09:51:49 (+0100), Julio M. Merino Vidal wrote: ]
> Subject: Re: pkg/28977: a couple of problems with editors/emacs
>
> I think that you are missing the point that PKGNAME_NOREV _does_ include
> the version number.  It only lacks the revision:

Indeed I did not know that.  PKGNAME_NOREV must be one of the most
poorly named macros in the entire system.  Had I known about it at that
moment I would have epxected it to produce just "emacs" -- i.e. with no
revision identifier at all.

I simply tried using ${PKGVERSION} first because that's what I saw being
used in the PLIST file, and when that didn't work I went to the source
of PLIST_SUBST's initialization and borrowed the exact same expression
used there.

I was going to post a separate complaint about the hidden difference
between the meaning of PKGVERSION in Makefiles and PLISTs.  :-)

Perhaps PKGNAME_NOREV could be renamed something slightly more
meaningful, or at least slightly less misleading, such as
PKGNAME_NONBREV, and a new PKGVERSION_NONBREV could be added as well,
and then they together could be added to PLIST_SUBST and the PKGVERSION
in PLIST_SUBST could drop its magic and just be an exact match for the
Makefile value (and all existing uses of PKGVERSION in PLIST files would
have to be changed to PKGVERSION_NONBREV of course, but that could be a
mechanical change, at least initially).

It's really bad to overload already confusing words "revision" and
"version", or their various abbreviations, with special local meanings
without always keeping explicit qualifying adjectives along side to
clarify exactly what's meant.  This is especially important when
creating identifiers.

-- 
						Greg A. Woods

H:+1 416 218-0098  W:+1 416 489-5852 x122  VE3TCP  RoboHack <woods@robohack.ca>
Planix, Inc. <woods@planix.com>          Secrets of the Weird <woods@weird.com>