Changeset View
Standalone View
en_US.ISO8859-1/books/porters-handbook/upgrading/chapter.xml
<?xml version="1.0" encoding="iso-8859-1"?> | <?xml version="1.0" encoding="iso-8859-1"?> | ||||
<!-- | <!-- | ||||
The FreeBSD Documentation Project | The FreeBSD Documentation Project | ||||
$FreeBSD$ | $FreeBSD$ | ||||
--> | --> | ||||
<chapter xmlns="http://docbook.org/ns/docbook" | <chapter xmlns="http://docbook.org/ns/docbook" | ||||
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0" | xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0" | ||||
xml:id="port-upgrading"> | xml:id="port-upgrading"> | ||||
<title>Upgrading a Port</title> | <title>Upgrading a Port</title> | ||||
<para>When you notice that a port is out of date compared to the | <para>When a port is not the most recent version available from the | ||||
latest version from the original authors, you should first ensure | authors, update the local working copy of | ||||
that you have the latest port. You can find them in the | <filename>/usr/ports</filename>. The port might have already been | ||||
wblock: This is hard to understand. I think it is trying to say "make sure that the ports tree on the… | |||||
<filename>ports/ports-current</filename> directory of the &os; FTP | updated to the new version. When a port is out of date compared to the | ||||
Not Done Inline Actions<acronym> tags on FTP. wblock: <acronym> tags on FTP. | |||||
wblockUnsubmitted Not Done Inline ActionsThe addition helps, but I also meant to remove the rest of the paragraph. wblock: The addition helps, but I also meant to remove the rest of the paragraph. | |||||
mirror sites. However, if you are working with more than a few | latest version from the original authors, first ensure that the | ||||
ports, you will probably find it easier to use | installed port is the latest available. They can be found in | ||||
<filename>ports/ports-current</filename> of the &os; <acronym>FTP</acronym> | |||||
mirror sites. However, if working with more than a few | |||||
ports, it will probably be easier to use | |||||
<application>Subversion</application> or &man.portsnap.8; to keep | <application>Subversion</application> or &man.portsnap.8; to keep | ||||
your whole ports collection up-to-date, as described in the <link | the whole ports collection up-to-date, as described in the <link | ||||
xlink:href="&url.books.handbook;/ports-using.html">Handbook</link>. | xlink:href="&url.books.handbook;/ports-using.html">Handbook</link>. | ||||
This will have the added benefit of tracking all the port's | This will have the added benefit of tracking all the port's | ||||
dependencies.</para> | dependencies.</para> | ||||
<para>The next step is to see if there is an update already pending. | <para>The next step is to see if there is an update already pending. | ||||
To do this, you have two options. There is a searchable interface | To do this, there are two options. There is a searchable interface | ||||
to the <link | to the <link | ||||
xlink:href="http://www.FreeBSD.org/cgi/query-pr-summary.cgi?query">FreeBSD | xlink:href="https://bugs.freebsd.org/search/">FreeBSD | ||||
Problem Report (PR) database</link> (also known as | Problem Report (PR) or bug database</link>. | ||||
<literal>GNATS</literal>). Select <literal>ports</literal> in | Select <literal>Ports Tree</literal> in | ||||
the dropdown, and enter the name of the port.</para> | the <literal>Product</literal> dropdown, and enter the name of the port in the | ||||
<literal>Summary</literal> field.</para> | |||||
Not Done Inline ActionsIt would be better not to mention the particular bug tracking software. Also probably should mention it by both names: the PR or bug database. wblock: It would be better not to mention the particular bug tracking software. Also probably should… | |||||
<para>However, sometimes people forget to put the name of the port | <para>However, sometimes people forget to put the name of the port | ||||
into the Synopsis field in an unambiguous fashion. In that | into the Summary field in an unambiguous fashion. In that | ||||
case, you can try the | case, try searching in the <literal>Comment</literal> field in | ||||
Not Done Inline Actionss/the searching/searching/ wblock: s/the searching/searching/ | |||||
the <literal>Detailled Bug Information</literal> section, or try | |||||
the | |||||
<link linkend="portsmon">&os; Ports Monitoring System</link> | <link linkend="portsmon">&os; Ports Monitoring System</link> | ||||
(also known as <literal>portsmon</literal>). This system | (also known as <literal>portsmon</literal>). This system | ||||
attempts to classify port PRs by portname. To search for PRs | attempts to classify port PRs by portname. To search for PRs | ||||
about a particular port, use the <link | about a particular port, use the <link | ||||
xlink:href="http://portsmon.FreeBSD.org/portoverview.py">Overview | xlink:href="http://portsmon.FreeBSD.org/portoverview.py">Overview | ||||
of One Port</link>.</para> | of One Port</link>.</para> | ||||
<para>If there is no pending PR, the next step is to send an email | <para>If there is no pending PR, the next step is to send an email | ||||
to the port's maintainer, as shown by | to the port's maintainer, as shown by | ||||
<command>make maintainer</command>. That person may already be | <command>make maintainer</command>. That person may already be | ||||
working on an upgrade, or have a reason to not upgrade the port | working on an upgrade, or have a reason to not upgrade the port | ||||
right now (because of, for example, stability problems of the | right now (because of, for example, stability problems of the | ||||
new version); you would not want to duplicate their work. Note | new version), and there is no need to duplicate their work. Note | ||||
that unmaintained ports are listed with a maintainer of | that unmaintained ports are listed with a maintainer of | ||||
<literal>ports@FreeBSD.org</literal>, which is just the general | <literal>ports@FreeBSD.org</literal>, which is just the general | ||||
ports mailing list, so sending mail there probably will not help | ports mailing list, so sending mail there probably will not help | ||||
in this case.</para> | in this case.</para> | ||||
<para>If the maintainer asks you to do the upgrade or there is | <para>If the maintainer asks you to do the upgrade or there is | ||||
no maintainer, then you have a chance to help out &os; by | no maintainer, then help out &os; by | ||||
preparing the update yourself! Please do this by using the | preparing the update! Please do this by using the | ||||
&man.diff.1; command in the base system.</para> | &man.diff.1; command in the base system.</para> | ||||
<para>To create a suitable <command>diff</command> for a single | <para>To create a suitable <command>diff</command> for a single | ||||
patch, copy the file that needs patching to | patch, copy the file that needs patching to | ||||
<replaceable>something.orig</replaceable>, save your changes to | <filename><replaceable>something</replaceable>.orig</filename>, save the changes to | ||||
<replaceable>something</replaceable> and then create your | <filename><replaceable>something</replaceable></filename> and then create the | ||||
patch:</para> | patch:</para> | ||||
<informalexample> | <informalexample> | ||||
<screen>&prompt.user; <userinput>diff -u something.orig something > something.diff</userinput></screen> | <screen>&prompt.user; <userinput>diff -u <replaceable>something</replaceable>.orig <replaceable>something</replaceable> > something.diff</userinput></screen> | ||||
</informalexample> | </informalexample> | ||||
<para>Otherwise, you should either use the | <para>Otherwise, either use the | ||||
<command>svn diff</command> method (<xref linkend="svn-diff"/>) | <command>svn diff</command> method (<xref linkend="svn-diff"/>) | ||||
or copy the contents of the port to an entire different | or copy the contents of the port to an entire different | ||||
directory and use the result of the recursive &man.diff.1; | directory and use the result of the recursive &man.diff.1; | ||||
output of the new and old ports directories (e.g., if your | output of the new and old ports directories (for example, if the | ||||
modified port directory is called <filename>superedit</filename> | modified port directory is called <filename>superedit</filename> | ||||
and the original is in our tree as | and the original is in our tree as | ||||
<filename>superedit.bak</filename>, then save the result of | <filename>superedit.bak</filename>, then save the result of | ||||
<command>diff -ruN superedit.bak superedit</command>). Either | <command>diff -ruN superedit.bak superedit</command>). Either | ||||
unified or context diff is fine, but port committers generally | unified or context diff is fine, but port committers generally | ||||
prefer unified diffs. Note the use of the <literal>-N</literal> | prefer unified diffs. Note the use of the <literal>-N</literal> | ||||
option—this is the accepted way to force diff to properly | option—this is the accepted way to force diff to properly | ||||
deal with the case of new files being added or old files being | deal with the case of new files being added or old files being | ||||
deleted. Before sending us the diff, please examine the output | deleted. Before sending us the diff, please examine the output | ||||
to make sure all the changes make sense. (In particular, make | to make sure all the changes make sense. (In particular, make | ||||
sure you first clean out the work directories with | sure to first clean out the work directories with | ||||
<command>make clean</command>).</para> | <command>make clean</command>).</para> | ||||
<para>To simplify common operations with patch files, you can use | <para>To simplify common operations with patch files, use | ||||
<command>make makepatch</command> as described in <xref | |||||
linkend="slow-patch"/>. | |||||
Other tools exists, like | |||||
<filename>/usr/ports/Tools/scripts/patchtool.py</filename>. | <filename>/usr/ports/Tools/scripts/patchtool.py</filename>. | ||||
Before using it, please read | Before using it, please read | ||||
<filename>/usr/ports/Tools/scripts/README.patchtool</filename>.</para> | <filename>/usr/ports/Tools/scripts/README.patchtool</filename>.</para> | ||||
<para>If the port is unmaintained, and you are actively using | <para>If the port is unmaintained, and you are actively using | ||||
it yourself, please consider volunteering to become its | it, please consider volunteering to become its | ||||
maintainer. &os; has over 4000 ports without maintainers, and | maintainer. &os; has over 4000 ports without maintainers, and | ||||
this is an area where more volunteers are always needed. (For a | this is an area where more volunteers are always needed. (For a | ||||
detailed description of the responsibilities of maintainers, | detailed description of the responsibilities of maintainers, | ||||
refer to the section in the <link | refer to the section in the <link | ||||
xlink:href="&url.books.developers-handbook;/policies.html#POLICIES-MAINTAINER">Developer's | xlink:href="&url.books.developers-handbook;/policies.html#POLICIES-MAINTAINER">Developer's | ||||
Handbook</link>.)</para> | Handbook</link>.)</para> | ||||
<para>The best way to send us the diff is by including it via | <para>To submit the diff, use the <link | ||||
Not Done Inline Actionss/us// wblock: s/us// | |||||
&man.send-pr.1; (category <literal>ports</literal>). If you are | xlink:href="https://bugs.freebsd.org/submit/">bug submit | ||||
form</link> (category <literal>Ports Tree</literal>). If the | |||||
submitter is also | |||||
Not Done Inline Actionssend-pr is gone. wblock: send-pr is gone. | |||||
Not Done Inline ActionsOh, I did not know that, still use it myself 0:-) mat: Oh, I did not know that, still use it myself 0:-) | |||||
maintaining the port, be sure to put <literal>[maintainer | maintaining the port, be sure to put <literal>[maintainer | ||||
update]</literal> at the beginning of your synopsis line and set | update]</literal> at the beginning of the | ||||
the <quote>Class</quote> of your PR to | <literal>Summary</literal> line. | ||||
<literal>maintainer-update</literal>. Otherwise, the | Please mention any added or | ||||
<quote>Class</quote> of your PR should be | |||||
<literal>change-request</literal>. Please mention any added or | |||||
deleted files in the message, as they have to be explicitly | deleted files in the message, as they have to be explicitly | ||||
specified to &man.svn.1; when doing a commit. If the diff is | specified to &man.svn.1; when doing a commit. Do not compress or | ||||
more than about 20KB, please compress and uuencode it; | encode the diff.</para> | ||||
otherwise, just include it in the PR as is.</para> | |||||
<para>Before using &man.send-pr.1;, review the <link | <para>Before submitting the bug, review the <link | ||||
xlink:href="&url.articles.problem-reports;/pr-writing.html"> | xlink:href="&url.articles.problem-reports;/pr-writing.html"> | ||||
Not Done Inline ActionsSo I guess the problem-reports article should be updated too, to trim all the references to using send-pr. mat: So I guess the problem-reports article should be updated too, to trim all the references to… | |||||
Writing the problem report</link> section in the Problem | Writing the problem report</link> section in the Problem | ||||
Reports article. It contains far more information about how to | Reports article. It contains far more information about how to | ||||
write useful problem reports.</para> | write useful problem reports.</para> | ||||
<important> | <important> | ||||
<para>If the upgrade is motivated by security concerns or a | <para>If the upgrade is motivated by security concerns or a | ||||
serious fault in the currently committed port, please notify | serious fault in the currently committed port, please notify | ||||
the &a.portmgr; to request immediate rebuilding and | the &a.portmgr; to request immediate rebuilding and | ||||
redistribution of the port's package. Unsuspecting users | redistribution of the port's package. Unsuspecting users | ||||
of <command>pkg</command> will otherwise continue to install | of <command>pkg</command> will otherwise continue to install | ||||
the old version via <command>pkg install</command> for several | the old version via <command>pkg install</command> for several | ||||
weeks.</para> | weeks.</para> | ||||
</important> | </important> | ||||
<note> | <note> | ||||
<para>Once again, please use &man.diff.1; and not &man.shar.1; | <para>Once again, please use &man.diff.1; and not &man.shar.1; | ||||
to send updates to existing ports! This helps ports | to send updates to existing ports! This helps ports | ||||
committers understand exactly what is being changed.</para> | committers understand exactly what is being changed.</para> | ||||
</note> | </note> | ||||
<para>Now that you have done all that, read about | <para>Now that all of that is done, read about | ||||
how to keep up-to-date in <xref linkend="keeping-up"/>.</para> | how to keep up-to-date in <xref linkend="keeping-up"/>.</para> | ||||
<sect1 xml:id="svn-diff"> | <sect1 xml:id="svn-diff"> | ||||
<title>Using <application>Subversion</application> to Make | <title>Using <application>Subversion</application> to Make | ||||
Patches</title> | Patches</title> | ||||
<para>When possible, please submit a &man.svn.1; diff. They | <para>When possible, please submit a &man.svn.1; diff. They | ||||
are easier to handle than diffs between | are easier to handle than diffs between | ||||
<quote>new and old</quote> directories. It is easier | <quote>new and old</quote> directories. It is easier | ||||
to see what has changed, and to update the diff if | to see what has changed, and to update the diff if | ||||
something was modified in the Ports Collection since you | something was modified in the Ports Collection since the | ||||
began work on it, or if the | work on it began, or if the | ||||
committer asks for something to be fixed. Also, a patch | committer asks for something to be fixed. Also, a patch | ||||
generated with <command>svn diff</command> can be easily applied | generated with <command>svn diff</command> can be easily applied | ||||
with <command>svn patch</command> and will save some time to the | with <command>svn patch</command> and will save some time to the | ||||
committer.</para> | committer.</para> | ||||
<screen>&prompt.user; <userinput>cd ~/my_wrkdir</userinput> <co xml:id="my-wrkdir"/> | <screen>&prompt.user; <userinput>cd ~/my_wrkdir</userinput> <co xml:id="my-wrkdir"/> | ||||
&prompt.user; <userinput>svn co <replaceable>https://svn0.us-west.FreeBSD.org</replaceable>/ports/head/dns/pdnsd</userinput> <co xml:id="svn-FreeBSD-org"/> | &prompt.user; <userinput>svn co <replaceable>https://svn0.us-west.FreeBSD.org</replaceable>/ports/head/dns/pdnsd</userinput> <co xml:id="svn-FreeBSD-org"/> | ||||
&prompt.user; <userinput>cd ~/my_wrkdir/pdnsd</userinput></screen> | &prompt.user; <userinput>cd ~/my_wrkdir/pdnsd</userinput></screen> | ||||
<calloutlist> | <calloutlist> | ||||
<callout arearefs="my-wrkdir"> | <callout arearefs="my-wrkdir"> | ||||
<para>This can be anywhere you want, of course; building | <para>This can be anywhere, of course. Building | ||||
Not Done Inline ActionsBreak sentence on semicolon. wblock: Break sentence on semicolon. | |||||
ports is not limited to within | ports is not limited to within | ||||
<filename>/usr/ports/</filename>.</para> | <filename>/usr/ports/</filename>.</para> | ||||
</callout> | </callout> | ||||
<callout arearefs="svn-FreeBSD-org"> | <callout arearefs="svn-FreeBSD-org"> | ||||
<para><link | <para><link | ||||
xlink:href="https://svn0.us-west.FreeBSD.org/">svn0.us-west.FreeBSD.org</link> | xlink:href="https://svn0.us-west.FreeBSD.org/">svn0.us-west.FreeBSD.org</link> | ||||
is a public <application>Subversion</application> server. | is a public <application>Subversion</application> server. | ||||
Select the closest mirror and verify the mirror server | Select the closest mirror and verify the mirror server | ||||
certificate from the list of <link | certificate from the list of <link | ||||
xlink:href="&url.books.handbook;/svn.html#svn-mirrors">Subversion | xlink:href="&url.books.handbook;/svn.html#svn-mirrors">Subversion | ||||
mirror sites</link>.</para> | mirror sites</link>.</para> | ||||
</callout> | </callout> | ||||
</calloutlist> | </calloutlist> | ||||
<para>While in the working directory, make any changes that you | <para>While in the port directory, make any changes that are | ||||
would usually make to the port. If you add, move or remove a | needed. If adding, moving, or removing a | ||||
Not Done Inline Actionss/ports/port/ wblock: s/ports/port/ | |||||
Not Done Inline ActionsSerial comma: s/moving/moving,/ wblock: Serial comma: s/moving/moving,/ | |||||
file, use <command>svn</command> to track these changes:</para> | file, use <command>svn</command> to track these changes:</para> | ||||
<screen>&prompt.user; <userinput>svn add new_file</userinput> | <screen>&prompt.user; <userinput>svn add <replaceable>new_file</replaceable></userinput> | ||||
&prompt.user; <userinput>svn move old_name new_name</userinput> | &prompt.user; <userinput>svn move <replaceable>old_name</replaceable> <replaceable>new_name</replaceable></userinput> | ||||
&prompt.user; <userinput>svn remove deleted_file</userinput></screen> | &prompt.user; <userinput>svn remove <replaceable>deleted_file</replaceable></userinput></screen> | ||||
<para>Make sure that you check the port using the checklist in | <para>Make sure to check the port using the checklist in | ||||
<xref linkend="porting-testing"/> and | <xref linkend="porting-testing"/> and | ||||
<xref linkend="porting-portlint"/>.</para> | <xref linkend="porting-portlint"/>.</para> | ||||
<screen>&prompt.user; <userinput>svn status</userinput> | <screen>&prompt.user; <userinput>svn status</userinput> | ||||
&prompt.user; <userinput>svn update</userinput> <co xml:id="svn-update"/></screen> | &prompt.user; <userinput>svn update</userinput> <co xml:id="svn-update"/></screen> | ||||
<calloutlist> | <calloutlist> | ||||
<callout arearefs="svn-update"> | <callout arearefs="svn-update"> | ||||
<para>This will try to merge the differences between your | <para>This will attempt to merge the differences between the | ||||
Not Done Inline Actionss/try/attempt/ wblock: s/try/attempt/ | |||||
patch and current repository version; watch the output | patch and current repository version. Watch the output | ||||
Not Done Inline ActionsBreak sentence on semicolon. wblock: Break sentence on semicolon. | |||||
Not Done Inline ActionsMaybe igor should try to detect that, and tell people they should make separate sentences ? mat: Maybe igor should try to detect that, and tell people they should make separate sentences ? | |||||
carefully. The letter in front of each file name | carefully. The letter in front of each file name | ||||
indicates what was done with it. See | indicates what was done with it. See | ||||
<xref linkend="table-svn-up"/> for a complete list.</para> | <xref linkend="table-svn-up"/> for a complete list.</para> | ||||
</callout> | </callout> | ||||
</calloutlist> | </calloutlist> | ||||
<table pgwide="1" frame="none" xml:id="table-svn-up"> | <table pgwide="1" frame="none" xml:id="table-svn-up"> | ||||
<title><application>Subversion</application> Update File | <title><application>Subversion</application> Update File | ||||
Prefixes</title> | Prefixes</title> | ||||
<tgroup cols="2"> | <tgroup cols="2"> | ||||
<tbody> | <tbody> | ||||
<row> | <row> | ||||
<entry>U</entry> | <entry>U</entry> | ||||
<entry>The file was updated without problems.</entry> | <entry>The file was updated without problems.</entry> | ||||
</row> | </row> | ||||
<row> | <row> | ||||
<entry>G</entry> | <entry>G</entry> | ||||
<entry>The file was updated without problems (you will | <entry>The file was updated without problems (only when | ||||
only see this when working against a remote | working against a remote | ||||
Not Done Inline ActionsThe paren must not be followed by a space. wblock: The paren must not be followed by a space. | |||||
repository).</entry> | repository).</entry> | ||||
</row> | </row> | ||||
<row> | <row> | ||||
<entry>M</entry> | <entry>M</entry> | ||||
<entry>The file had been modified, and was merged | <entry>The file had been modified, and was merged | ||||
without conflicts.</entry> | without conflicts.</entry> | ||||
</row> | </row> | ||||
<row> | <row> | ||||
<entry>C</entry> | <entry>C</entry> | ||||
<entry>The file had been modified, and was merged with | <entry>The file had been modified, and was merged with | ||||
conflicts.</entry> | conflicts.</entry> | ||||
</row> | </row> | ||||
</tbody> | </tbody> | ||||
</tgroup> | </tgroup> | ||||
</table> | </table> | ||||
<para>If <literal>C</literal> is displayed as a result of | <para>If <literal>C</literal> is displayed as a result of | ||||
<command>svn update</command>, it means something changed in | <command>svn update</command>, it means something changed in | ||||
the <application>Subversion</application> repository and | the <application>Subversion</application> repository and | ||||
&man.svn.1; was not able to merge the local changes with those | &man.svn.1; was not able to merge the local changes with those | ||||
from the repository. It is always a good idea to inspect the | from the repository. It is always a good idea to inspect the | ||||
changes anyway, since &man.svn.1; does not know anything about | changes anyway, since &man.svn.1; does not know anything about | ||||
how a port should be, so it might (and probably will) merge | the structure of a port, so it might (and probably will) merge | ||||
Not Done Inline Actionss/how a port must be,/the structure of a port,/ wblock: s/how a port must be,/the structure of a port,/ | |||||
things that do not make sense.</para> | things that do not make sense.</para> | ||||
<para>The last step is to make a unified &man.diff.1; | <para>The last step is to make a unified &man.diff.1; | ||||
of the changes:</para> | of the changes:</para> | ||||
<screen>&prompt.user; <userinput>svn diff > ../`basename ${PWD}`.diff</userinput></screen> | <screen>&prompt.user; <userinput>svn diff > ../`make -VPKGNAME`.diff</userinput></screen> | ||||
<note> | <note> | ||||
<para>Any files that have been removed should be explicitly | <para>Any files that have been removed have to be explicitly | ||||
mentioned in the PR, because file removal may not be obvious | mentioned in the PR, because file removal may not be obvious | ||||
to the committer.</para> | to the committer.</para> | ||||
</note> | </note> | ||||
<para>Send your patch following the guidelines in | <para>Send the patch following the guidelines in | ||||
<xref linkend="port-upgrading"/>.</para> | <xref linkend="port-upgrading"/>.</para> | ||||
<tip> | <tip> | ||||
<para>You can have patch automatically generated and the PR | <para>The patch can be automatically generated and the PR | ||||
pre-filled with your contact information by using | pre-filled with the contact information by using | ||||
the <application>Port Tools</application> <command>port | <command>port submit</command>. See <xref | ||||
Not Done Inline Actionss/Patch/The patch/ wblock: s/Patch/The patch/ | |||||
submit</command> command. See <xref | |||||
linkend="testing-porttools"/> for more details.</para> | linkend="testing-porttools"/> for more details.</para> | ||||
</tip> | </tip> | ||||
</sect1> | </sect1> | ||||
<sect1 xml:id="moved-and-updating-files"> | <sect1 xml:id="moved-and-updating-files"> | ||||
<title>The Files <filename>UPDATING</filename> and | <title><filename>UPDATING</filename> and | ||||
Not Done Inline ActionsCould probably remove "The Files" here. wblock: Could probably remove "The Files" here. | |||||
<filename>MOVED</filename></title> | <filename>MOVED</filename></title> | ||||
<sect2 xml:id="moved-and-updating-updating"> | |||||
<title><filename>/usr/ports/UPDATING</filename></title> | |||||
<para>If upgrading the port requires special steps like | <para>If upgrading the port requires special steps like | ||||
changing configuration files or running a specific program, | changing configuration files or running a specific program, | ||||
you should document this in the file | it must be documented in this file. The format of | ||||
Not Done Inline Actionss/documented this in this/documented in this/ wblock: s/documented this in this/documented in this/ | |||||
<filename>/usr/ports/UPDATING</filename>. The format of | |||||
an entry in this file is as follows:</para> | an entry in this file is as follows:</para> | ||||
<programlisting>YYYYMMDD: | <programlisting>YYYYMMDD: | ||||
AFFECTS: users of portcategory/portname | AFFECTS: users of portcategory/portname | ||||
AUTHOR: Your name <Your email address> | AUTHOR: Your name <Your email address> | ||||
Special instructions</programlisting> | Special instructions</programlisting> | ||||
<para>If you are including exact portmaster or portupgrading | <tip> | ||||
instructions, please make sure to get the shell escaping | <para>When including exact | ||||
right.</para> | <application>portmaster</application>, | ||||
<application>portupgrade</application>, and/or | |||||
<application>pkg</application> instructions, please make sure | |||||
to get the shell escaping right. For example, do | |||||
<emphasis>not</emphasis> use:</para> | |||||
<screen>&prompt.root; <userinput>pkg delete -g -f docbook-xml* docbook-sk* docbook[2345]??-* docbook-4*</userinput></screen> | |||||
<para>As shown, the command will only work with | |||||
Not Done Inline Actions"As shown, the command will only work with ..." wblock: "As shown, the command will only work with ..." | |||||
<application>bourne shells</application>. Instead, use the | |||||
Not Done Inline Actionss/This will work with both/Instead, use the form shown below, which will work with both/ wblock: s/This will work with both/Instead, use the form shown below, which will work with both/ | |||||
form shown below, which will work with both | |||||
<application>bourne shell</application> and | |||||
<application>c-shell</application>:</para> | |||||
<screen>&prompt.root; <userinput>pkg delete -g -f docbook-xml\* docbook-sk\* docbook\[2345\]\?\?-\* docbook-4\*</userinput></screen> | |||||
</tip> | |||||
<note> | <note> | ||||
<para>It is recommended that the AFFECTS line contains a glob | <para>It is recommended that the AFFECTS line contains a glob | ||||
matching all the ports affected by the entry so that automated | matching all the ports affected by the entry so that automated | ||||
tools can parse it as easily as possible. If an update | tools can parse it as easily as possible. If an update | ||||
concerns all the existing <application>BIND 9</application> | concerns all the existing <application>BIND 9</application> | ||||
versions the <literal>AFFECTS</literal> content should be | versions the <literal>AFFECTS</literal> content must be | ||||
<literal>users of dns/bind9*</literal>, it should | <literal>users of dns/bind9*</literal>, it must | ||||
<emphasis>not</emphasis> be <literal>users of BIND | <emphasis>not</emphasis> be <literal>users of BIND | ||||
9</literal></para> | 9</literal></para> | ||||
</note> | </note> | ||||
<para>The <filename>/usr/ports/MOVED</filename> file is used to | </sect2> | ||||
<sect2 xml:id="moved-and-updating-moved"> | |||||
<title><filename>/usr/ports/MOVED</filename></title> | |||||
<para>This file is used to | |||||
list moved or removed ports. Each line in the file is made | list moved or removed ports. Each line in the file is made | ||||
up of the name of the port, where the port was moved to, when, | up of the name of the port, where the port was moved to, when, | ||||
and why. If the port was removed, the section detailing where | and why. If the port was removed, the section detailing where | ||||
it was moved to can be left blank. Each section must be | it was moved to can be left blank. Each section must be | ||||
separated by the <literal>|</literal> (pipe) character, like | separated by the <literal>|</literal> (pipe) character, like | ||||
so:</para> | so:</para> | ||||
<programlisting>old name|new name (blank for deleted)|date of move|reason</programlisting> | <programlisting>old name|new name (blank for deleted)|date of move|reason</programlisting> | ||||
<para>The date should be entered in the form | <para>The date must be entered in the form | ||||
Not Done Inline Actionss/New entries must be added to/New entries are added to/ wblock: s/New entries must be added to/New entries are added to/ | |||||
Not Done Inline Actionss/order/order,/ wblock: s/order/order,/ | |||||
<literal>YYYY-MM-DD</literal>. New entries should be added to | <literal>YYYY-MM-DD</literal>. New entries are added to | ||||
the top of the file to keep it in reverse chronological order | the top of the file to keep it in reverse chronological order, | ||||
(the latest entries first).</para> | with the last entry first.</para> | ||||
Not Done Inline Actionswith the latest entries first.</para> wblock: with the latest entries first.</para> | |||||
<para>If a port was removed but has since been restored, | <para>If a port was removed but has since been restored, | ||||
delete the line in this file that states that it was | delete the line in this file that states that it was | ||||
removed.</para> | removed.</para> | ||||
<para>If a port was renamed and then renamed back to its original | <para>If a port was renamed and then renamed back to its original | ||||
name, you should add a new one with the intermediate name to the | name, add a new one with the intermediate name to the | ||||
old name, and remove the old entry as to not create a | old name, and remove the old entry as to not create a | ||||
loop.</para> | loop.</para> | ||||
<para>The changes can be validated with | <note> | ||||
<para>Any changes must be validated with | |||||
<command>Tools/scripts/MOVEDlint.awk</command>.</para> | <command>Tools/scripts/MOVEDlint.awk</command>.</para> | ||||
<para>If using a ports directory other than <filename>/usr/ports</filename>, use:</para> | |||||
<informalexample> | |||||
<screen>&prompt.user; <userinput>cd <replaceable>/home/user/ports</replaceable></userinput> | |||||
&prompt.user; <userinput>env PORTSDIR=$PWD Tools/scripts/MOVEDlint.awk</userinput></screen> | |||||
</informalexample> | |||||
</note> | |||||
</sect2> | |||||
</sect1> | </sect1> | ||||
</chapter> | </chapter> | ||||
This is hard to understand. I think it is trying to say "make sure that the ports tree on the local machine is current, because the port might have already been upgraded. The most recent version of ports can be found..."
But that part about where they can be found is kind of obsolete. People now should just look in the repo.
"When a port is not the most recent version available from the authors, update the local working copy of <filename>/usr/ports</filename>. The port might have already been updated to the new version."