Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Dec 1998 00:17:10 -0500 (EST)
From:      John Baldwin <jobaldwi@vt.edu>
To:        Steve Price <sprice@hiwaay.net>
Cc:        freebsd-ports@FreeBSD.ORG
Subject:   Re: make index breaks at top level
Message-ID:  <XFMail.981215001710.jobaldwi@vt.edu>
In-Reply-To: <Pine.OSF.4.02.9812142120340.4529-100000@fly.HiWAAY.net>

next in thread | previous in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----


On 15-Dec-98 Steve Price wrote:
># Another fix might be to have ports/makefile use
># perl5 to run the script instead of perl, but then you are requiring
># users prior to 3.x to install a port so they can use the ports.
># Thanks for responding though.
> 
> Actually this (index) is not intended as a target for general
> consumption.  It is there so that we can easily create a new INDEX.
> You can use it if you like, but if you do I'd suggest you install
> the lasted version of perl from the ports tree.

I do have perl5 installed, and I did patch the Makefile to expressly use perl5,
which worked for me.  I don't know if it would break elegance, but here is the
simple patch that will let 2.2.x machines with perl5 installed make the index. 
It does assume that perl5 is in the path, and I'm not sure that 3.x has a
/usr/bin/perl5.  Oh, well.  It's not that big of a deal.

- -----------

- --- Makefile    Mon Dec 14 23:56:08 1998
+++ Makefile.orig       Mon Dec 14 23:56:00 1998
@@ -54,7 +54,7 @@
 ${.CURDIR}/INDEX:
        @echo -n "Generating INDEX - please wait.."
        @make describe ECHO_MSG="echo > /dev/null" | \
- -               perl5 ${.CURDIR}/templates/make_index > ${.CURDIR}/INDEX
+               perl ${.CURDIR}/templates/make_index > ${.CURDIR}/INDEX
        @echo " Done."
 
 print-index:   ${.CURDIR}/INDEX

- -----------

># BTW, can somebody please tell me what the "my $<varname>" does
># anyway? (i.e. will it break if it is taken out or is it simply
># an optimization).
> 
> You can usually safely replace 'my' with 'local'.  And yes it is
> an optimization of sorts.  Without going into great detail, 'my'
> variables are lexically scoped and 'local' are dynamically scoped.
> For example, if I have two routines foo and bar like this:
> 
> sub foo {
>     my $foo1;    # only defined within foo
>     local $foo2; # defined within foo and any routines it calls
>     bar();
> }
> sub bar {
>     # $foo1 is not visible here
>     # but $foo2 is
> }
> 
> So it is a little faster and a little safer to use 'my'.

Ahh..  so 'my' variables have scope similar to local (volatile?) variables in
C, while 'local' variables don't have a comparable variable class in C?  Cool. 
I really should sit down and learn Perl.

> -steve

- ---

John Baldwin <jobaldwi@vt.edu> -- http://members.freedomnet.com/~jbaldwin/
PGP Key: http://members.freedomnet.com/~jbaldwin/pgpkey.asc

Eat properly, get plenty of excercise ...and die anyway!


-----BEGIN PGP SIGNATURE-----
Version: 2.6.2

iQB1AwUBNnXvj4jYza302vYpAQENLQL+IdboLWAOx8oZH66FeE5Sn85g5X2/L1D3
C/2Rrpd9se/DkNn3VfyJzUEdeDYCkK9anYbQ7SbcXNgvr/+tmFAeZgHu+OvyFZMf
qERmKfghKsK2OAz7jOEHofVB8ncC+kGH
=gogz
-----END PGP SIGNATURE-----

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.981215001710.jobaldwi>