suggestion/feature request for Portfile: assert PortSystem comes first
Roger Pack
rogerdpack2 at gmail.com
Thu Apr 11 22:16:26 PDT 2013
Hello. As a matter of "warning newbies like myself", the following occurred.
I added a line to a portfile. The line was
supported_archs i386
I then ran portindex, and got this:
Failed to parse file multimedia/mplayer-edl-i386/Portfile: invalid
command name "supported_archs"
(you can guess my failure here--I put it *before* the PortSystem line).
Suggestion/feature request: it would be nice to spit out a warning or
error message that supplemented this particular error message, for
instance
"warning: Portfile started without a PortSystem declaration for its first line"
then I would have known more concisely where I had went wrong.
Also as a further note, on this page:
http://guide.macports.org/
section 5.1
Perhaps it should say
PortSystem:
The top (non comment) line of every Portfile;
instead of the current:
PortSystem
The top line of every Portfile;
(the current wording confused me, since I have these lines at the top
of my Portfile:
# $Id: Portfile 86914 2011-11-07 02:04:09Z ecronin at macports.org $
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil;
c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
which are obviously "not" PortSystem.
Cheers and thanks.
-roger-
More information about the macports-users
mailing list