On Sun, Dec 08, 2013 at 08:41:23AM -0500, Stuart Cassoff wrote:
> On 12/07/13 16:42, Marc Espie wrote:
> > On Sat, Dec 07, 2013 at 03:39:28PM -0500, Stuart Cassoff wrote:
> >> On 12/05/13 05:36, Marc Espie wrote:
> >>> On Thu, Dec 05, 2013 at 01:26:47AM -0500, Stuart Cassoff wrote:
> >>>> I'd like tcllib and tklib to make use of 'tcl modules'.
> >>>> Every package that can be installed as a tcl module saves one file and 
> >>>> one dir
> >>>> and there are enough eligible packages that I think it's worth doing.
> >>>> This makes use of a newer tcl packaging system that's a bit better 
> >>>> and/or faster.
> >>>>
> >>>> These should always be installend in the dir for lowest tcl version 
> >>>> possible, which is 8.5.
> >>>> I'm concerned that ${MODTK_VERSION} in the PLIST isn't right.
> >>>>
> >>>> Here's the result for one package:
> >>>
> >>> So, make sure to look at the result of update-plist, it's not always
> >>> right.
> >>>
> >>
> >> How's this? Snippet from the port Makefile diff.
> >>
> >> +# We want the lowest Tcl version possible.
> >> +MODTK_VERSION =        8.5
> >> +
> >> +# Manual target to adjust PLIST after update-plist.
> >> +adj-plist:
> >> +       perl -pi -e 's/\$${MODTK_VERSION}/8.5/' ${PKGDIR}/PLIST
> >> +
> > YUCK. A big *NO*.
> > 
> > Did you try the approach I outlined ?  Namely provide longer module 
> > variables
> > that would be FIRST in the substituted list.
> > 

> It confused and frightened me.
> 
> Eventually I manned-up and so with your approach I get this in the PLIST:
> 
> lib/tcl/${MODTK_MODPATH}/autoscroll-1.1.tm
> 
> Which I don't understand much more.
> 
> Either way I get the same package file so maybe I don't actually have a 
> problem here?

Maybe you don't understand it much more, but it's cleaner, in as much
as there's no extra step to fix the plist after update-plist.

... and it will fix the same problem in (potentially) other ports, without
you needing to special-case each and every port.

Reply via email to