Reindent/rewrap chapter.
Differential Revision: https://reviews.freebsd.org/D2217 Approved by: wblock (mentor) Sponsored by: Absolight
This commit is contained in:
parent
752cf7256d
commit
16702e66ae
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=46502
1 changed files with 226 additions and 209 deletions
|
@ -58,8 +58,9 @@
|
|||
|
||||
<important>
|
||||
<para>The package name must be unique among all of the ports
|
||||
tree. Make sure that there is not already a port with the same
|
||||
<varname>PORTNAME</varname> and if there is add one of <link
|
||||
tree. Make sure that there is not already a port with the
|
||||
same <varname>PORTNAME</varname> and if there is add one of
|
||||
<link
|
||||
linkend="porting-pkgnameprefix-suffix"><varname>PKGNAMEPREFIX</varname>
|
||||
or <varname>PKGNAMESUFFIX</varname></link>.</para>
|
||||
</important>
|
||||
|
@ -106,9 +107,9 @@
|
|||
|
||||
<listitem>
|
||||
<para>Changes in the packing list or the install-time
|
||||
behavior of the package. For example, a change to a script which
|
||||
generates initial data for the package, like &man.ssh.1; host
|
||||
keys.</para>
|
||||
behavior of the package. For example, a change to a
|
||||
script which generates initial data for the package,
|
||||
like &man.ssh.1; host keys.</para>
|
||||
</listitem>
|
||||
|
||||
<listitem>
|
||||
|
@ -121,8 +122,8 @@
|
|||
|
||||
<listitem>
|
||||
<para>Silent changes to the port distfile which have
|
||||
significant functional differences. For example, changes to the
|
||||
distfile requiring a correction to
|
||||
significant functional differences. For example,
|
||||
changes to the distfile requiring a correction to
|
||||
<filename>distinfo</filename> with no corresponding
|
||||
change to <varname>PORTVERSION</varname>, where a
|
||||
<command>diff -ru</command> of the old and new versions
|
||||
|
@ -166,8 +167,9 @@
|
|||
</itemizedlist>
|
||||
|
||||
<para>A rule of thumb is to decide whether a change
|
||||
committed to a port is something which <emphasis>some</emphasis> people would
|
||||
benefit from having. Either because of an enhancement, fix,
|
||||
committed to a port is something which
|
||||
<emphasis>some</emphasis> people would benefit from having.
|
||||
Either because of an enhancement, fix,
|
||||
or by virtue that the new package will actually work at
|
||||
all. Then weigh that against that fact that it will cause
|
||||
everyone who regularly updates their ports tree to be
|
||||
|
@ -177,7 +179,7 @@
|
|||
<note>
|
||||
<para>People using binary packages will
|
||||
<emphasis>never</emphasis> see the update if
|
||||
<varname>PORTREVISION</varname> is not bumped. Without
|
||||
<varname>PORTREVISION</varname> is not bumped. Without
|
||||
increasing <varname>PORTREVISION</varname>, the
|
||||
package builders have no way to detect the change and
|
||||
thus, will not rebuild the package.</para>
|
||||
|
@ -215,13 +217,13 @@
|
|||
the package name as described in section 0 above.
|
||||
<varname>PORTEPOCH</varname> must never be decreased or
|
||||
reset to zero, because that would cause comparison to a
|
||||
package from an earlier epoch to fail. For example, the package
|
||||
would not be detected as out of date. The new version
|
||||
number, <literal>1.0,1</literal> in the above
|
||||
example, is still numerically less than the previous version,
|
||||
20000801, but the <literal>,1</literal> suffix is treated
|
||||
specially by automated tools and found to be greater than
|
||||
the implied suffix <literal>,0</literal> on the earlier
|
||||
package from an earlier epoch to fail. For example, the
|
||||
package would not be detected as out of date. The new
|
||||
version number, <literal>1.0,1</literal> in the above
|
||||
example, is still numerically less than the previous
|
||||
version, 20000801, but the <literal>,1</literal> suffix is
|
||||
treated specially by automated tools and found to be greater
|
||||
than the implied suffix <literal>,0</literal> on the earlier
|
||||
package.</para>
|
||||
|
||||
<para>Dropping or resetting <varname>PORTEPOCH</varname>
|
||||
|
@ -242,8 +244,8 @@
|
|||
release is made.</para>
|
||||
|
||||
<para>For example, if a snapshot release is made on the date
|
||||
<literal>20000917</literal>, and the previous version of the software was
|
||||
version <literal>1.2</literal>, do not use
|
||||
<literal>20000917</literal>, and the previous version of the
|
||||
software was version <literal>1.2</literal>, do not use
|
||||
<literal>20000917</literal> for
|
||||
<varname>PORTVERSION</varname>. The correct way is a
|
||||
<varname>PORTVERSION</varname> of
|
||||
|
@ -398,14 +400,15 @@ PORTEPOCH= 1</programlisting>
|
|||
version part is if the upstream distribution is really
|
||||
named that way, as in the
|
||||
<package role="port">textproc/libxml2</package> or
|
||||
<package role="port">japanese/kinput2-freewnn</package> ports.
|
||||
Otherwise, <varname>PORTNAME</varname> cannot
|
||||
<package role="port">japanese/kinput2-freewnn</package>
|
||||
ports. Otherwise, <varname>PORTNAME</varname> cannot
|
||||
contain any version-specific information. It is quite
|
||||
normal for several ports to have the same
|
||||
<varname>PORTNAME</varname>, as the
|
||||
<package role="port">www/apache*</package> ports do; in that case,
|
||||
different versions (and different index entries) are
|
||||
distinguished by <varname>PKGNAMEPREFIX</varname>
|
||||
<package role="port">www/apache*</package> ports do; in
|
||||
that case, different versions (and different index
|
||||
entries) are distinguished by
|
||||
<varname>PKGNAMEPREFIX</varname>
|
||||
and <varname>PKGNAMESUFFIX</varname> values.</para>
|
||||
|
||||
<para>There is a tradition of naming
|
||||
|
@ -806,8 +809,8 @@ PORTEPOCH= 1</programlisting>
|
|||
<entry><filename>editors</filename></entry>
|
||||
<entry>General editors.</entry>
|
||||
<entry>Specialized editors go in the section for those
|
||||
tools. For example, a mathematical-formula editor will
|
||||
go in <filename>math</filename>, and have
|
||||
tools. For example, a mathematical-formula editor
|
||||
will go in <filename>math</filename>, and have
|
||||
<filename>editors</filename> as a second
|
||||
category.</entry>
|
||||
</row>
|
||||
|
@ -844,8 +847,10 @@ PORTEPOCH= 1</programlisting>
|
|||
|
||||
<row>
|
||||
<entry><filename>ftp</filename></entry>
|
||||
<entry><acronym>FTP</acronym> client and server utilities.</entry>
|
||||
<entry>If the port speaks both <acronym>FTP</acronym> and <acronym>HTTP</acronym>, put it
|
||||
<entry><acronym>FTP</acronym> client and server
|
||||
utilities.</entry>
|
||||
<entry>If the port speaks both <acronym>FTP</acronym>
|
||||
and <acronym>HTTP</acronym>, put it
|
||||
in <filename>ftp</filename> with a secondary
|
||||
category of <filename>www</filename>.</entry>
|
||||
</row>
|
||||
|
@ -1648,186 +1653,186 @@ PORTEPOCH= 1</programlisting>
|
|||
<varname>MASTER_SITE_<replaceable>*</replaceable></varname>
|
||||
Variables</title>
|
||||
|
||||
<para>Shortcut abbreviations are available for popular archives
|
||||
like SourceForge (<literal>SF</literal>), GNU
|
||||
(<literal>GNU</literal>), or Perl CPAN
|
||||
(<literal>CPAN</literal>). <varname>MASTER_SITES</varname> can
|
||||
use them directly:</para>
|
||||
<para>Shortcut abbreviations are available for popular
|
||||
archives like SourceForge (<literal>SF</literal>), GNU
|
||||
(<literal>GNU</literal>), or Perl CPAN
|
||||
(<literal>CPAN</literal>). <varname>MASTER_SITES</varname>
|
||||
can use them directly:</para>
|
||||
|
||||
<programlisting>MASTER_SITES= GNU/make</programlisting>
|
||||
<programlisting>MASTER_SITES= GNU/make</programlisting>
|
||||
|
||||
<para>The older expanded format still works, but all ports
|
||||
should be converted to the compact format. The expanded
|
||||
format looks like this:</para>
|
||||
<para>The older expanded format still works, but all ports
|
||||
should be converted to the compact format. The expanded
|
||||
format looks like this:</para>
|
||||
|
||||
<programlisting>MASTER_SITES= ${MASTER_SITE_GNU}
|
||||
<programlisting>MASTER_SITES= ${MASTER_SITE_GNU}
|
||||
MASTER_SITE_SUBDIR= make</programlisting>
|
||||
|
||||
<para>These values and variables are defined in <link
|
||||
xlink:href="https://svnweb.freebsd.org/ports/head/Mk/bsd.sites.mk?view=markup"><filename>Mk/bsd.sites.mk</filename></link>.
|
||||
New entries are added often, so make sure to check the latest
|
||||
version of this file before submitting a port.</para>
|
||||
<para>These values and variables are defined in <link
|
||||
xlink:href="https://svnweb.freebsd.org/ports/head/Mk/bsd.sites.mk?view=markup"><filename>Mk/bsd.sites.mk</filename></link>.
|
||||
New entries are added often, so make sure to check the
|
||||
latest version of this file before submitting a port.</para>
|
||||
|
||||
<tip>
|
||||
<para>For any
|
||||
<varname>MASTER_SITE_<replaceable>FOO</replaceable></varname>
|
||||
variable, the shorthand
|
||||
<literal><replaceable>FOO</replaceable></literal> can be
|
||||
used. For example, use:</para>
|
||||
<tip>
|
||||
<para>For any
|
||||
<varname>MASTER_SITE_<replaceable>FOO</replaceable></varname>
|
||||
variable, the shorthand
|
||||
<literal><replaceable>FOO</replaceable></literal> can be
|
||||
used. For example, use:</para>
|
||||
|
||||
<programlisting>MASTER_SITES= <replaceable>FOO</replaceable></programlisting>
|
||||
<programlisting>MASTER_SITES= <replaceable>FOO</replaceable></programlisting>
|
||||
|
||||
<para>If <varname>MASTER_SITE_SUBDIR</varname> is needed, use
|
||||
this:</para>
|
||||
<para>If <varname>MASTER_SITE_SUBDIR</varname> is needed,
|
||||
use this:</para>
|
||||
|
||||
<programlisting>MASTER_SITES= <replaceable>FOO</replaceable>/<replaceable>bar</replaceable></programlisting>
|
||||
</tip>
|
||||
<programlisting>MASTER_SITES= <replaceable>FOO</replaceable>/<replaceable>bar</replaceable></programlisting>
|
||||
</tip>
|
||||
</sect3>
|
||||
|
||||
<sect3 xml:id="makefile-master_sites-magic">
|
||||
<title>Magic MASTER_SITES Macros</title>
|
||||
|
||||
<para>Several <emphasis>magic</emphasis> macros exist for
|
||||
popular sites with a predictable directory structure. For
|
||||
these, just use the abbreviation and the system will try to
|
||||
guess the correct subdirectory automatically. For a port
|
||||
named <literal>Stardict</literal>, of version
|
||||
<literal>1.2.3</literal>, and hosted on SourceForge, adding
|
||||
this line:</para>
|
||||
<para>Several <emphasis>magic</emphasis> macros exist for
|
||||
popular sites with a predictable directory structure. For
|
||||
these, just use the abbreviation and the system will try to
|
||||
guess the correct subdirectory automatically. For a port
|
||||
named <literal>Stardict</literal>, of version
|
||||
<literal>1.2.3</literal>, and hosted on SourceForge, adding
|
||||
this line:</para>
|
||||
|
||||
<programlisting>MASTER_SITES= SF</programlisting>
|
||||
<programlisting>MASTER_SITES= SF</programlisting>
|
||||
|
||||
<para>Will infer a subdirectory named
|
||||
<literal>/project/stardict/stardict/1.2.3</literal>. If the
|
||||
guess is incorrect, it can be overridden as follows.</para>
|
||||
<para>Will infer a subdirectory named
|
||||
<literal>/project/stardict/stardict/1.2.3</literal>. If the
|
||||
guess is incorrect, it can be overridden as follows.</para>
|
||||
|
||||
<programlisting>MASTER_SITES= SF/stardict/WyabdcRealPeopleTTS/${PORTVERSION}</programlisting>
|
||||
<programlisting>MASTER_SITES= SF/stardict/WyabdcRealPeopleTTS/${PORTVERSION}</programlisting>
|
||||
|
||||
<para>This can also be written as</para>
|
||||
<para>This can also be written as</para>
|
||||
|
||||
<programlisting>MASTER_SITES= SF
|
||||
<programlisting>MASTER_SITES= SF
|
||||
MASTER_SITE_SUBDIR= stardict/WyabdcRealPeopleTTS/${PORTVERSION}</programlisting>
|
||||
|
||||
<table frame="none" xml:id="makefile-master_sites-popular">
|
||||
<title>Popular Magic <varname>MASTER_SITES</varname>
|
||||
Macros</title>
|
||||
<table frame="none" xml:id="makefile-master_sites-popular">
|
||||
<title>Popular Magic <varname>MASTER_SITES</varname>
|
||||
Macros</title>
|
||||
|
||||
<tgroup cols="2">
|
||||
<thead>
|
||||
<row>
|
||||
<entry>Macro</entry>
|
||||
<entry>Assumed subdirectory</entry>
|
||||
</row>
|
||||
</thead>
|
||||
<tgroup cols="2">
|
||||
<thead>
|
||||
<row>
|
||||
<entry>Macro</entry>
|
||||
<entry>Assumed subdirectory</entry>
|
||||
</row>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
<row>
|
||||
<entry><varname>APACHE_JAKARTA</varname></entry>
|
||||
<entry><literal>${PORTNAME:S,-,/,}/source</literal></entry>
|
||||
</row>
|
||||
<tbody>
|
||||
<row>
|
||||
<entry><varname>APACHE_JAKARTA</varname></entry>
|
||||
<entry><literal>${PORTNAME:S,-,/,}/source</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>BERLIOS</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}.berlios</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>BERLIOS</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}.berlios</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>CHEESESHOP</varname></entry>
|
||||
<entry><literal>source/${DISTNAME:C/(.).*/\1/}/${DISTNAME:C/(.*)-[0-9].*/\1/}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>CHEESESHOP</varname></entry>
|
||||
<entry><literal>source/${DISTNAME:C/(.).*/\1/}/${DISTNAME:C/(.*)-[0-9].*/\1/}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>DEBIAN</varname></entry>
|
||||
<entry><literal>pool/main/${PORTNAME:C/^((lib)?.).*$/\1/}/${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>DEBIAN</varname></entry>
|
||||
<entry><literal>pool/main/${PORTNAME:C/^((lib)?.).*$/\1/}/${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>FARSIGHT</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>FARSIGHT</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GCC</varname></entry>
|
||||
<entry><literal>releases/${DISTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GCC</varname></entry>
|
||||
<entry><literal>releases/${DISTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GH</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/tar.gz/${GH_TAGNAME}?dummy=/</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GH</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/tar.gz/${GH_TAGNAME}?dummy=/</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GHC</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GHC</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GHL</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/legacy.tar.gz/${GH_TAGNAME}?dummy=/</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GHL</varname></entry>
|
||||
<entry><literal>${GH_ACCOUNT}/${GH_PROJECT}/legacy.tar.gz/${GH_TAGNAME}?dummy=/</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GNOME</varname></entry>
|
||||
<entry><literal>sources/${PORTNAME}/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GNOME</varname></entry>
|
||||
<entry><literal>sources/${PORTNAME}/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GIMP</varname></entry>
|
||||
<entry><literal>${PORTNAME}/${PORTVERSION:R}/</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GIMP</varname></entry>
|
||||
<entry><literal>${PORTNAME}/${PORTVERSION:R}/</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GNU</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GNU</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>GNU_ALPHA</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>GNU_ALPHA</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>HORDE</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>HORDE</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>LODEV</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>LODEV</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>MATE</varname></entry>
|
||||
<entry><literal>${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>MATE</varname></entry>
|
||||
<entry><literal>${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>MOZDEV</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>MOZDEV</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>NL</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>NL</varname></entry>
|
||||
<entry><literal>${PORTNAME}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>CPAN</varname></entry>
|
||||
<entry><literal>${PORTNAME:C/-.*//}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>CPAN</varname></entry>
|
||||
<entry><literal>${PORTNAME:C/-.*//}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>SAVANNAH</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}</literal></entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><varname>SAVANNAH</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}</literal></entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><varname>SF</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}/${PORTNAME:tl}/${PORTVERSION}</literal></entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</table>
|
||||
<row>
|
||||
<entry><varname>SF</varname></entry>
|
||||
<entry><literal>${PORTNAME:tl}/${PORTNAME:tl}/${PORTVERSION}</literal></entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</table>
|
||||
</sect3>
|
||||
|
||||
<sect3 xml:id="makefile-master_sites-github">
|
||||
|
@ -2025,7 +2030,8 @@ EXTRACT_ONLY= source.tar.gz</programlisting>
|
|||
<title><varname>PATCHFILES</varname></title>
|
||||
|
||||
<para>If the port requires some additional patches that are
|
||||
available by <acronym>FTP</acronym> or <acronym>HTTP</acronym>, set <varname>PATCHFILES</varname> to
|
||||
available by <acronym>FTP</acronym> or
|
||||
<acronym>HTTP</acronym>, set <varname>PATCHFILES</varname> to
|
||||
the names of the files and <varname>PATCH_SITES</varname> to
|
||||
the URL of the directory that contains them (the format is the
|
||||
same as <varname>MASTER_SITES</varname>).</para>
|
||||
|
@ -2224,8 +2230,8 @@ DISTFILES= source1.tar.gz:source1 \
|
|||
<literal>[a-zA-Z_][0-9a-zA-Z_]+</literal> for
|
||||
now.</para>
|
||||
|
||||
<para>Moreover, string matching is case sensitive; that is,
|
||||
<literal>n</literal> is different from
|
||||
<para>Moreover, string matching is case sensitive; that
|
||||
is, <literal>n</literal> is different from
|
||||
<literal>N</literal>.</para>
|
||||
|
||||
<para>However, these words cannot be used for
|
||||
|
@ -3373,7 +3379,7 @@ xmlcatmgr:${PORTSDIR}/textproc/xmlcatmgr</programlisting>
|
|||
world, will have their &os; installation broken
|
||||
almost immediately, with many others quickly to follow. These
|
||||
can really be hard to detect. If in doubt, before making
|
||||
that change, make sure to run:
|
||||
that change, make sure to run:
|
||||
<command>cd /usr/ports; make index</command>. That process
|
||||
can be quite slow on older machines, but it may be able to
|
||||
save a large number of people, including yourself,
|
||||
|
@ -3431,22 +3437,23 @@ BAR_LIB_DEPENDS= libbar.so:${PORTSDIR}/foo/bar</programlisting>
|
|||
<title><varname>USE_<replaceable>*</replaceable></varname> and
|
||||
<varname>WANT_<replaceable>*</replaceable></varname></title>
|
||||
|
||||
<para><varname>USE_<replaceable>*</replaceable></varname> are set by the port
|
||||
maintainer to define software on which this port depends. A
|
||||
port that needs Firefox would set</para>
|
||||
<para><varname>USE_<replaceable>*</replaceable></varname> are
|
||||
set by the port maintainer to define software on which this
|
||||
port depends. A port that needs Firefox would set</para>
|
||||
|
||||
<programlisting>USE_FIREFOX= yes</programlisting>
|
||||
|
||||
<para>Some <varname>USE_<replaceable>*</replaceable></varname> can accept version
|
||||
numbers or other parameters. For example, a port that
|
||||
requires Apache 2.2 would set</para>
|
||||
<para>Some <varname>USE_<replaceable>*</replaceable></varname>
|
||||
can accept version numbers or other parameters. For example,
|
||||
a port that requires Apache 2.2 would set</para>
|
||||
|
||||
<programlisting>USE_APACHE= 22</programlisting>
|
||||
|
||||
<para>For more control over dependencies in some cases,
|
||||
<varname>WANT_<replaceable>*</replaceable></varname> are available to more
|
||||
precisely specify what is needed. For example, consider the
|
||||
<package role="port">mail/squirrelmail</package> port. This
|
||||
<varname>WANT_<replaceable>*</replaceable></varname> are
|
||||
available to more precisely specify what is needed. For
|
||||
example, consider the <package
|
||||
role="port">mail/squirrelmail</package> port. This
|
||||
port needs some PHP modules, which are listed in
|
||||
<varname>USE_PHP</varname>:</para>
|
||||
|
||||
|
@ -3458,8 +3465,10 @@ BAR_LIB_DEPENDS= libbar.so:${PORTSDIR}/foo/bar</programlisting>
|
|||
|
||||
<programlisting>WANT_PHP_WEB= yes</programlisting>
|
||||
|
||||
<para>Available <varname>USE_<replaceable>*</replaceable></varname> and
|
||||
<varname>WANT_<replaceable>*</replaceable></varname> are defined in the files in
|
||||
<para>Available
|
||||
<varname>USE_<replaceable>*</replaceable></varname> and
|
||||
<varname>WANT_<replaceable>*</replaceable></varname> are
|
||||
defined in the files in
|
||||
<filename>/usr/ports/Mk</filename>.</para>
|
||||
</sect2>
|
||||
</sect1>
|
||||
|
@ -3540,8 +3549,8 @@ MASTERDIR= ${.CURDIR}/../xdvi300
|
|||
<sect1 xml:id="makefile-info">
|
||||
<title>Info Files</title>
|
||||
|
||||
<para>If the package needs to install <acronym>GNU</acronym> info files, list them
|
||||
in <varname>INFO</varname> (without the
|
||||
<para>If the package needs to install <acronym>GNU</acronym> info
|
||||
files, list them in <varname>INFO</varname> (without the
|
||||
trailing <literal>.info</literal>), one entry per document.
|
||||
These files are assumed to be installed to
|
||||
<filename>PREFIX/INFO_PATH</filename>. Change
|
||||
|
@ -3579,12 +3588,12 @@ MASTERDIR= ${.CURDIR}/../xdvi300
|
|||
<sect3 xml:id="makefile-options-background">
|
||||
<title>Background</title>
|
||||
|
||||
<para><varname>OPTIONS_<replaceable>*</replaceable></varname> give the
|
||||
user installing the port a dialog showing the available
|
||||
options, and then saves those options to
|
||||
<para><varname>OPTIONS_<replaceable>*</replaceable></varname>
|
||||
give the user installing the port a dialog showing the
|
||||
available options, and then saves those options to
|
||||
<filename>${PORT_DBDIR}/${OPTIONS_NAME}/options</filename>.
|
||||
The next time the port is built, the options are
|
||||
reused. <varname>PORT_DBDIR</varname> defaults to
|
||||
reused. <varname>PORT_DBDIR</varname> defaults to
|
||||
<filename>/var/db/ports</filename>.
|
||||
<varname>OPTIONS_NAME</varname> is to the port origin with
|
||||
an underscore as the space separator, for example, for
|
||||
|
@ -3596,7 +3605,8 @@ MASTERDIR= ${.CURDIR}/../xdvi300
|
|||
framework checks for
|
||||
<filename>${PORT_DBDIR}/${OPTIONS_NAME}/options</filename>.
|
||||
If that file does not exist, the values of
|
||||
<varname>OPTIONS_<replaceable>*</replaceable></varname> are used, and a dialog box is
|
||||
<varname>OPTIONS_<replaceable>*</replaceable></varname>
|
||||
are used, and a dialog box is
|
||||
displayed where the options can be enabled or disabled.
|
||||
Then <filename>options</filename> is saved and the
|
||||
configured variables are used when building the port.</para>
|
||||
|
@ -3708,7 +3718,9 @@ OPTIONS_GROUP_GG1= OPT9 OPT10</programlisting>
|
|||
introduction of <filename>bsd.port.options.mk</filename>.
|
||||
But be aware that some variables will not work as expected
|
||||
after the inclusion of <filename>bsd.port.pre.mk</filename>,
|
||||
typically some <varname>USE_<replaceable>*</replaceable></varname> flags.</para>
|
||||
typically some
|
||||
<varname>USE_<replaceable>*</replaceable></varname>
|
||||
flags.</para>
|
||||
|
||||
<example xml:id="ports-options-simple-use">
|
||||
<title>Simple Use of <varname>OPTIONS</varname></title>
|
||||
|
@ -3734,7 +3746,7 @@ BAR_RUN_DEPENDS= bar:${PORTSDIR}/bar/bar
|
|||
CONFIGURE_ARGS+=--without-examples
|
||||
.endif</programlisting>
|
||||
|
||||
<para>The form shown above is discouraged. The preferred
|
||||
<para>The form shown above is discouraged. The preferred
|
||||
method is using a configure knob to really enable and
|
||||
disable the feature to match the option:</para>
|
||||
|
||||
|
@ -3974,12 +3986,13 @@ USE_XORG= x11 xextproto xext xrandr
|
|||
<varname><replaceable>OPT</replaceable>_CONFIGURE_ENABLE</varname>
|
||||
then
|
||||
<literal>--enable-<replaceable>entry</replaceable></literal>
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. When option
|
||||
<replaceable>OPT</replaceable> is not selected,
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. When
|
||||
option <replaceable>OPT</replaceable> is not selected,
|
||||
<literal>--disable-<replaceable>entry</replaceable></literal>
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. An optional
|
||||
argument can be specified with an <literal>=</literal>
|
||||
symbol. This argument is only appended to the
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. An
|
||||
optional argument can be specified with an
|
||||
<literal>=</literal> symbol. This argument is only appended
|
||||
to the
|
||||
<literal>--enable-<replaceable>entry</replaceable></literal>
|
||||
configure option. For example:</para>
|
||||
|
||||
|
@ -4014,12 +4027,13 @@ CONFIGURE_ARGS+= --disable-test2
|
|||
<varname><replaceable>OPT</replaceable>_CONFIGURE_ENABLE</varname>
|
||||
then
|
||||
<literal>--with-<replaceable>entry</replaceable></literal>
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. When option
|
||||
<replaceable>OPT</replaceable> is not selected,
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. When
|
||||
option <replaceable>OPT</replaceable> is not selected,
|
||||
<literal>--without-<replaceable>entry</replaceable></literal>
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. An optional
|
||||
argument can be specified with an <literal>=</literal>
|
||||
symbol. This argument is only appended to the
|
||||
is appended to <varname>CONFIGURE_ARGS</varname>. An
|
||||
optional argument can be specified with an
|
||||
<literal>=</literal> symbol. This argument is only appended
|
||||
to the
|
||||
<literal>--with-<replaceable>entry</replaceable></literal>
|
||||
configure option. For example:</para>
|
||||
|
||||
|
@ -4529,20 +4543,21 @@ PORTVERSION= 1.0</programlisting>
|
|||
that <varname>CONFLICTS_INSTALL</varname> does not match this
|
||||
port's package itself. Otherwise enforcing its installation
|
||||
with <varname>FORCE_PKG_REGISTER</varname> will no longer
|
||||
work. <varname>CONFLICTS_INSTALL</varname> check is done after the build
|
||||
stage and prior to the install stage.</para>
|
||||
work. <varname>CONFLICTS_INSTALL</varname> check is done
|
||||
after the build stage and prior to the install stage.</para>
|
||||
</sect2>
|
||||
|
||||
<sect2 xml:id="conflicts-conflicts_build">
|
||||
<title><varname>CONFLICTS_BUILD</varname></title>
|
||||
|
||||
<para>If the port cannot be built when other specific ports are already
|
||||
installed, list the other port names in
|
||||
<para>If the port cannot be built when other specific ports are
|
||||
already installed, list the other port names in
|
||||
<varname>CONFLICTS_BUILD</varname>. Use
|
||||
shell globs like <literal>*</literal> and <literal>?</literal>
|
||||
here. Use package names, not port names or origins.
|
||||
<varname>CONFLICTS_BUILD</varname> check is done prior to the build stage. Build
|
||||
conflicts are not recorded in the resulting package.</para>
|
||||
<varname>CONFLICTS_BUILD</varname> check is done prior to the
|
||||
build stage. Build conflicts are not recorded in the
|
||||
resulting package.</para>
|
||||
</sect2>
|
||||
|
||||
<sect2 xml:id="conflicts-conflicts">
|
||||
|
@ -4558,8 +4573,8 @@ PORTVERSION= 1.0</programlisting>
|
|||
<varname>CONFLICTS</varname> does not match this
|
||||
port's package itself. Otherwise enforcing its installation
|
||||
with <varname>FORCE_PKG_REGISTER</varname> will no longer
|
||||
work. <varname>CONFLICTS</varname> check is done prior to the build stage
|
||||
and prior to the install stage.</para>
|
||||
work. <varname>CONFLICTS</varname> check is done prior to the
|
||||
build stage and prior to the install stage.</para>
|
||||
</sect2>
|
||||
</sect1>
|
||||
|
||||
|
@ -4567,7 +4582,8 @@ PORTVERSION= 1.0</programlisting>
|
|||
<title>Installing Files</title>
|
||||
|
||||
<sect2 xml:id="install-macros">
|
||||
<title><varname>INSTALL_<replaceable>*</replaceable></varname> Macros</title>
|
||||
<title><varname>INSTALL_<replaceable>*</replaceable></varname>
|
||||
Macros</title>
|
||||
|
||||
<para>Use the macros provided in
|
||||
<filename>bsd.port.mk</filename> to ensure correct modes of
|
||||
|
@ -4707,7 +4723,8 @@ PORTVERSION= 1.0</programlisting>
|
|||
|
||||
<para>Additional <command>find</command> arguments can be
|
||||
passed via the third argument to
|
||||
<varname>COPYTREE_<replaceable>*</replaceable></varname> macros. For example, to install
|
||||
<varname>COPYTREE_<replaceable>*</replaceable></varname>
|
||||
macros. For example, to install
|
||||
all files from the first example except Makefiles, one can use
|
||||
these commands.</para>
|
||||
|
||||
|
|
Loading…
Reference in a new issue