Changeset 27536 for trunk/doc


Ignore:
Timestamp:
Aug 7, 2007, 6:31:33 AM (12 years ago)
Author:
markd@…
Message:

Clarify and distinguish phases from global stuff in ports and Portfiles.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/doc/guide/new/xml/portfiledev.xml

    r27252 r27536  
    55  <title>Portfile Development</title>
    66
    7   <para>This chapter covers a brief introduction to port phases, how to create
    8   a local Portfile repository for development, and creating
    9   <filename>Portfile</filename>s.</para>
     7  <para>This chapter covers a brief introduction to Portfiles, how to create a
     8  local <filename>Portfile</filename> repository for development, and creating
     9  Portfiles.</para>
    1010
    1111  <section>
    1212    <title>Portfile Introduction</title>
    1313
    14     <para>A MacPorts <filename>Portfile</filename> fully defines a given port;
    15     it is also the only necessary component of a port, though ports may also
    16     include patchfiles or other textfiles as desired by a port author.</para>
    17 
    18     <para>A MacPorts port has ten distinct phases, but the main ones you to be
    19     aware of when making Portfiles are these:</para>
     14    <para>Every MacPorts port has a corresponding
     15    <filename>Portfile</filename>, but Portfiles do not completely define a
     16    port's behavior because the MacPorts base code sets the default behavior
     17    for a port's installation phases. <filename>Portfiles</filename> may
     18    contain optional section(s) of installation phase declarations, but they
     19    are only necessary if you want to augment or override the default port
     20    phase behavior defined in the MacPorts base.</para>
     21
     22    <para>If you use phase declaration(s) in a <filename>Portfile</filename>,
     23    you should know how to identify what is called the "global" section of a
     24    <filename>Portfile</filename>. Any statements not contained within a phase
     25    declaration, no matter where they are located in a
     26    <filename>Portfile</filename>, are said to be in the global section of the
     27    <filename>Portfile</filename>, therefore the global section need not be
     28    contiguous. Likewise, for any statements to be removed from the global
     29    section they would have to be moved within a phase declaration.</para>
     30
     31    <para>The main phases you need to be aware of when making a
     32    <filename>Portfile</filename> are these:</para>
    2033
    2134    <itemizedlist>
     
    4558    </itemizedlist>
    4659
    47     <para>These phases automatically perform default operations for
    48     applications that use the standard <command>configure</command>,
    49     <command>make</command>, and <command>make install</command> steps, which
    50     conform to phases configure, build, and destroot respectively. For
    51     applications that do not conform to this behavior, any installation phase
    52     may be augmented using pre- and/or post- phases or overridden entirely.
    53     See the section "Example Portfiles" below.</para>
     60    <para>The default installation phase behavior performed by the MacPorts
     61    base code is set for applications that use the standard
     62    <command>configure</command>, <command>make</command>, and <command>make
     63    install</command> steps, which conform to phases configure, build, and
     64    destroot respectively. For applications that do not conform to this
     65    standard behavior, any installation phase may be augmented using pre-
     66    and/or post- phases, or even overridden or eliminated. See the section
     67    "Example Portfiles" below.</para>
    5468
    5569    <note>
    5670      <para>For a detailed description of all port phases, see the section
    57       "Portfile Reference".</para>
     71      "Portfile Reference" below.</para>
    5872    </note>
    5973  </section>
     
    135149
    136150    <para>Here we list the individual <filename>Portfile</filename> components
    137     for a port that conforms to the default <filename>Portfile</filename>
    138     options. For non-default options, see the section Optional Portfile
    139     Keywords.</para>
     151    for an application that conforms to the the standard <command>
     152    configure</command>, <command>make</command>, and <command>make
     153    install</command> steps of most open source application installs.</para>
    140154
    141155    <orderedlist>
Note: See TracChangeset for help on using the changeset viewer.