Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 02 Mar 2012 09:41:10 -0800
From:      Doug Barton <dougb@FreeBSD.org>
To:        Chris Rees <utisoft@gmail.com>
Cc:        Wesley Shields <wxs@freebsd.org>, Matthew Seaman <matthew@freebsd.org>, freebsd-ports <freebsd-ports@freebsd.org>
Subject:   Re: On the usage of ${FILE}
Message-ID:  <4F510636.2020607@FreeBSD.org>
In-Reply-To: <CADLo838yGkkX%2BTj68wmTghRUEu788ZFgynzoDGB=CdvBeeHEdg@mail.gmail.com>
References:  <4F4F5C76.8040908@FreeBSD.org> <CADLo83-9TZWG9C7N0169HxxRJtPgAAvcYhA2UXQ2GpSNxGHkHw@mail.gmail.com> <20120302131903.GE55531@atarininja.org> <CADLo838yGkkX%2BTj68wmTghRUEu788ZFgynzoDGB=CdvBeeHEdg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 03/02/2012 07:22, Chris Rees wrote:
> On 2 Mar 2012 13:19, "Wesley Shields" <wxs@freebsd.org> wrote:
>>
>> On Thu, Mar 01, 2012 at 12:38:01PM +0000, Chris Rees wrote:
>>> On 1 Mar 2012 11:26, "Matthew Seaman" <matthew@freebsd.org> wrote:
>>>>
>>>>
>>>> Dear all,
>>>>
>>>> bsd.commands.mk has the following:
>>>>
>>>> FILE?=          /usr/bin/file
>>>>
>>>> which is unfortunate, given that ${FILE} is used in several thousand
>>>> ports, generally as a loop control variable for iterating through a
> list
>>>> of files. In fact, I can only find about 8 places where the file(1)
>>>> program is intended.
>>>>
>>>> This obvious conflict of meanings seems pretty undesirable to me.  Am
> I
>>>> missing something?  Is there any reason to keep the status quo rather
>>>> than changing the bsd.commands.mk variable to FILE_CMD and making the
>>>> corresponding changes in those 8 places?
>>>>
>>>>        Cheers,
>>>>
>>>>        Matthew
>>>>
>>>
>>> I think that the loop control variables should be renamed to lower case.
>>
>> Except more of them in uppercase are bound to be added in the future,
>> despite the best warnings not to do so.
> 
> Can I say portlint? ;)

Won't help, as we have a non-trivial number of developers who can't be
bothered to learn the proper way to do things, or even to use a tool as
simple as portlint.

Matthew's proposal is the right way to go.


Doug

-- 

    This .signature sanitized for your protection



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4F510636.2020607>