<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[129851] trunk/base/doc/portstyle.7</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="https://trac.macports.org/changeset/129851">129851</a></dd>
<dt>Author</dt> <dd>raimue@macports.org</dd>
<dt>Date</dt> <dd>2014-12-21 08:00:24 -0800 (Sun, 21 Dec 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>base: regenerate portstyle.7 man page</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkbasedocportstyle7">trunk/base/doc/portstyle.7</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkbasedocportstyle7"></a>
<div class="modfile"><h4>Modified: trunk/base/doc/portstyle.7 (129850 => 129851)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/base/doc/portstyle.7        2014-12-21 15:59:44 UTC (rev 129850)
+++ trunk/base/doc/portstyle.7        2014-12-21 16:00:24 UTC (rev 129851)
</span><span class="lines">@@ -1,130 +1,52 @@
</span><del>-.\&quot; Copyright (c) 2002 Eric Melville &lt;eric@opendarwin.org&gt;
-.\&quot; All rights reserved.
-.\&quot;
-.\&quot; Redistribution and use in source and binary forms, with or without
-.\&quot; modification, are permitted provided that the following conditions
-.\&quot; are met:
-.\&quot; 1. Redistributions of source code must retain the above copyright
-.\&quot;    notice, this list of conditions and the following disclaimer.
-.\&quot; 2. Redistributions in binary form must reproduce the above copyright
-.\&quot;    notice, this list of conditions and the following disclaimer in the
-.\&quot;    documentation and/or other materials provided with the distribution.
-.\&quot;
-.\&quot; THIS SOFTWARE IS PROVIDED BY Eric Melville AND CONTRIBUTORS ``AS IS'' AND
-.\&quot; ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\&quot; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\&quot; ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
-.\&quot; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-.\&quot; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-.\&quot; OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-.\&quot; HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-.\&quot; LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-.\&quot; OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-.\&quot; SUCH DAMAGE.
-.\&quot;
-.Dd August 31, 2005
-.Dt PORTSTYLE 7
-.Os
-.Sh NAME
-.Nm portstyle
-.Nd style guide for ports
-.Sh DESCRIPTION
-A port consists of a directory and its contents, within a category subdirectory
-of the root of the ports tree.
-This document serves as a reference for the directory structure of a single
-port and the layout of the files within.
-.Pp
-The only required file in a port is
-.Va Portfile .
-The port file should be thought of as a set of declarations rather than a
-piece of code.
-It is best to format the port file is if it were a table consisting of keys
-and values.
-In fact, the simplest of ports will only contain a small block of values.
-Therefore, whitespace should not be strown about haphazardly.
-Nicely formatted compact tables will result in more values being visible at the
-same time.
-.Pp
-At the top of the port file is the requirement statement.
-There is a single space between the
-.Dq Li PortSystem
-statement and the version number.
-.Pp
-Use tabs to align items into columns.
-The left side should consist of single words, and will be separated from the
-more complex right side by a number of tabs that will result in all items
-begining on the same column.
-Variable assignments such as
-.Dq Li set libver
-can be considered a single word on the left side, with a single space between
-.Dq set
-and the variable name, followed by tabs to line up with the right side.
-.Pp
-The first category listed for a port is the port's primary category and should
-coincide with the subdirectory that the port resides in.
-Additional categories can be listed, but should be descriptive and accurate.
-.Pp
-Obviously a simple table of values won't do for all ports.
-More complicated ports will need to have things like multiple distribution
-files, custom targets, and variants.
-When items require multiple lines, they can be separated from the previous
-and next items with a blank line.
-Indent the additional lines to the same column that the right side begins on
-in the first line.
-Should the items require
-.Dq Li {}
-braces, the braces may appear on the first and last lines rather than on their
-own lines.
-This is done because the right side of the port file is already indented, and
-to make port file read like a table.
-Use a single space after the brace.
-Indent additional lines to this same column.
-If a single statement needs to span multiple lines, use a 2 space indentation
-from the first line for all additional lines.
-.Pp
-Variants are like any other part of the port file.
-Space, indent, and format them the same way other sections are formatted.
-The actual variant statement,
-.Dq Li variant
-followed by the name of the variant, can be treated as a single statement and
-thus placed together on the left side and separated by a single space.
-.Pp
-Sometimes it is useful to have a block of raw code for a port file.
-In these cases, either place the code at the bottom of the port file or pull it
-in from an external file, and simply format it in a well-structured manner
-with sensible indentation like any other code should be.
-.Pp
-Patch files reside in the files/ directory in the port's base directory.
-There should be one patch file for every file that needs to be patched.
-It is perfectly reasonable to use provided patches that affect multiple files,
-but do not create new patches that do so.
-Their names should begin with
-.Dq Li patch- .
-The rest of the name should come from the name of the file that they apply to.
-In many cases just the base name of the file being patched is enough.
-For files such as
-.Dq Li Makefile
-this may not be the case.
-In this case, use enough components of the file's path to uniquely distinguish
-the file.
-Separate the components with
-.Sq Li -
-characters.
-The patch should apply with
-.Dq Li patch -p0
-from the working source directory of the port.
-.Pp
-Try to adhere to these guidelines, but remember that this is only a guide.
-No set of rules can adequately cover all cases, and in some cases the best
-solution is to break the rules.
-.Sh SEE ALSO
-.Xr port 1 ,
-.Xr macports.conf 5 ,
-.Xr portfile 7 ,
-.Xr portgroup 7 ,
-.Xr porthier 7
-.Sh HISTORY
-This guide was initially written as a late addition to first release of
-MacPorts.
-.Sh AUTHORS
-.An Eric Melville Aq eric@opendarwin.org
</del><ins>+'\&quot; t
+.TH &quot;PORTSTYLE&quot; &quot;7&quot; &quot;2014\-12\-21&quot; &quot;MacPorts 2\&amp;.3\&amp;.99&quot; &quot;MacPorts Manual&quot;
+.\&quot; -----------------------------------------------------------------
+.\&quot; * Define some portability stuff
+.\&quot; -----------------------------------------------------------------
+.\&quot; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.\&quot; http://bugs.debian.org/507673
+.\&quot; http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
+.\&quot; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+.ie \n(.g .ds Aq \(aq
+.el       .ds Aq '
+.\&quot; -----------------------------------------------------------------
+.\&quot; * set default formatting
+.\&quot; -----------------------------------------------------------------
+.\&quot; disable hyphenation
+.nh
+.\&quot; disable justification (adjust text to left margin only)
+.ad l
+.\&quot; -----------------------------------------------------------------
+.\&quot; * MAIN CONTENT STARTS HERE *
+.\&quot; -----------------------------------------------------------------
+.SH &quot;NAME&quot;
+portstyle \- style guide for Portfiles
+.SH &quot;DESCRIPTION&quot;
+.sp
+This man page previously documented the style of Portfiles\&amp;. The canonical source for the formatting of Portfiles is now the \m[blue]\fBThe MacPorts Guide\fR\m[]\&amp;\s-2\u[1]\d\s+2, which also contains a section on \m[blue]\fBPort Style\fR\m[]\&amp;\s-2\u[2]\d\s+2\&amp;.
+.SH &quot;SEE ALSO&quot;
+.sp
+\fBportfile\fR(1)
+.SH &quot;AUTHORS&quot;
+.sp
+.if n \{\
+.RS 4
+.\}
+.nf
+(C) 2014 The MacPorts Project
+Rainer Mueller &lt;raimue@macports\&amp;.org&gt;
+.fi
+.if n \{\
+.RE
+.\}
+.SH &quot;EXTERNAL REFERENCES&quot;
+.IP &quot; 1.&quot; 4
+The MacPorts Guide
+.RS 4
+\%http://guide.macports.org/#
+.RE
+.IP &quot; 2.&quot; 4
+Port Style
+.RS 4
+\%http://guide.macports.org/#development.practices.portstyle
+.RE
</ins></span></pre>
</div>
</div>

</body>
</html>