Wed Apr 4 10:24:23 2018 UTC ()
doc/pkgsrc.*: regen


(leot)
diff -r1.249 -r1.250 pkgsrc/doc/pkgsrc.html
diff -r1.245 -r1.246 pkgsrc/doc/pkgsrc.txt

cvs diff -r1.249 -r1.250 pkgsrc/doc/pkgsrc.html (expand / switch to unified diff)

--- pkgsrc/doc/pkgsrc.html 2017/11/27 11:52:49 1.249
+++ pkgsrc/doc/pkgsrc.html 2018/04/04 10:24:23 1.250
@@ -20,28 +20,28 @@ @@ -20,28 +20,28 @@
20</h3> 20</h3>
21<div class="affiliation"><div class="address"><p><code class="email">&lt;<a class="email" href="mailto:agc@NetBSD.org">agc@NetBSD.org</a>&gt;</code></p></div></div> 21<div class="affiliation"><div class="address"><p><code class="email">&lt;<a class="email" href="mailto:agc@NetBSD.org">agc@NetBSD.org</a>&gt;</code></p></div></div>
22</div> 22</div>
23<div class="author"> 23<div class="author">
24<h3 class="author"> 24<h3 class="author">
25<span class="firstname">Hubert</span> <span class="surname">Feyrer</span> 25<span class="firstname">Hubert</span> <span class="surname">Feyrer</span>
26</h3> 26</h3>
27<div class="affiliation"><div class="address"><p><code class="email">&lt;<a class="email" href="mailto:hubertf@NetBSD.org">hubertf@NetBSD.org</a>&gt;</code></p></div></div> 27<div class="affiliation"><div class="address"><p><code class="email">&lt;<a class="email" href="mailto:hubertf@NetBSD.org">hubertf@NetBSD.org</a>&gt;</code></p></div></div>
28</div> 28</div>
29<h3 class="corpauthor"> 29<h3 class="corpauthor">
30 The pkgsrc Developers 30 The pkgsrc Developers
31 </h3> 31 </h3>
32</div></div> 32</div></div>
33<div><p class="copyright">Copyright © 1994-2017 The NetBSD Foundation, Inc</p></div> 33<div><p class="copyright">Copyright © 1994-2018 The NetBSD Foundation, Inc</p></div>
34<div><p class="pubdate">$NetBSD: pkgsrc.xml,v 1.31 2017/07/30 22:07:39 jnemeth Exp $</p></div> 34<div><p class="pubdate">$NetBSD: pkgsrc.xml,v 1.32 2018/01/01 01:26:07 jakllsch Exp $</p></div>
35<div><div class="abstract"> 35<div><div class="abstract">
36<p class="title"><b>Abstract</b></p> 36<p class="title"><b>Abstract</b></p>
37<p>pkgsrc is a centralized package management system for 37<p>pkgsrc is a centralized package management system for
38 Unix-like operating systems. This guide provides information for 38 Unix-like operating systems. This guide provides information for
39 users and developers of pkgsrc. It covers installation of binary 39 users and developers of pkgsrc. It covers installation of binary
40 and source packages, creation of binary and source packages and 40 and source packages, creation of binary and source packages and
41 a high-level overview about the infrastructure.</p> 41 a high-level overview about the infrastructure.</p>
42</div></div> 42</div></div>
43</div> 43</div>
44<hr> 44<hr>
45</div> 45</div>
46<div class="toc"> 46<div class="toc">
47<p><b>Table of Contents</b></p> 47<p><b>Table of Contents</b></p>
@@ -478,33 +478,33 @@ source packages @@ -478,33 +478,33 @@ source packages
478<div class="sect1"> 478<div class="sect1">
479<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 479<div class="titlepage"><div><div><h2 class="title" style="clear: both">
480<a name="introduction-section"></a>1.1. Introduction</h2></div></div></div> 480<a name="introduction-section"></a>1.1. Introduction</h2></div></div></div>
481<p>There is a lot of software freely available for Unix-based 481<p>There is a lot of software freely available for Unix-based
482systems, which is usually available in form of the source code. Before 482systems, which is usually available in form of the source code. Before
483such software can be used, it needs to be configured to the local 483such software can be used, it needs to be configured to the local
484system, compiled and installed, and this is exactly what The NetBSD 484system, compiled and installed, and this is exactly what The NetBSD
485Packages Collection (pkgsrc) does. pkgsrc also has some basic commands 485Packages Collection (pkgsrc) does. pkgsrc also has some basic commands
486to handle binary packages, so that not every user has to build the 486to handle binary packages, so that not every user has to build the
487packages for himself, which is a time-costly task.</p> 487packages for himself, which is a time-costly task.</p>
488<p>pkgsrc currently contains several thousand packages, 488<p>pkgsrc currently contains several thousand packages,
489 including:</p> 489 including:</p>
490<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 490<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
491<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/apache24/README.html" target="_top"><code class="filename">www/apache24</code></a> - The Apache 491<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/apache24/README.html" target="_top"><code class="filename">www/apache24</code></a> - The Apache
492 web server</p></li> 492 web server</p></li>
493<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a> - The Firefox 493<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a> - The Firefox
494 web browser</p></li> 494 web browser</p></li>
495<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome/README.html" target="_top"><code class="filename">meta-pkgs/gnome</code></a> - The GNOME 495<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome/README.html" target="_top"><code class="filename">meta-pkgs/gnome</code></a> - The GNOME
496 Desktop Environment</p></li> 496 Desktop Environment</p></li>
497<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/kde4/README.html" target="_top"><code class="filename">meta-pkgs/kde4</code></a> - The K 497<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/kde4/README.html" target="_top"><code class="filename">meta-pkgs/kde4</code></a> - The K
498 Desktop Environment</p></li> 498 Desktop Environment</p></li>
499</ul></div> 499</ul></div>
500<p>&#8230; just to name a few.</p> 500<p>&#8230; just to name a few.</p>
501<p>pkgsrc has built-in support for handling varying dependencies, 501<p>pkgsrc has built-in support for handling varying dependencies,
502 such as pthreads and X11, and extended features such as IPv6 support on 502 such as pthreads and X11, and extended features such as IPv6 support on
503 a range of platforms.</p> 503 a range of platforms.</p>
504<div class="sect2"> 504<div class="sect2">
505<div class="titlepage"><div><div><h3 class="title"> 505<div class="titlepage"><div><div><h3 class="title">
506<a name="why-pkgsrc"></a>1.1.1. Why pkgsrc?</h3></div></div></div> 506<a name="why-pkgsrc"></a>1.1.1. Why pkgsrc?</h3></div></div></div>
507<p> 507<p>
508pkgsrc provides the following key features: 508pkgsrc provides the following key features:
509</p> 509</p>
510<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 510<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
@@ -532,27 +532,27 @@ pkgsrc provides the following key featur @@ -532,27 +532,27 @@ pkgsrc provides the following key featur
532 configuration file.</p></li> 532 configuration file.</p></li>
533<li class="listitem"><p>The entire source (not including the distribution files) is 533<li class="listitem"><p>The entire source (not including the distribution files) is
534 freely available under a BSD license, so you may extend and adapt 534 freely available under a BSD license, so you may extend and adapt
535 pkgsrc to your needs. Support for local packages and patches is 535 pkgsrc to your needs. Support for local packages and patches is
536 available right out of the box, so you can configure it specifically 536 available right out of the box, so you can configure it specifically
537 for your environment.</p></li> 537 for your environment.</p></li>
538</ul></div> 538</ul></div>
539<p>The following principles are basic to pkgsrc:</p> 539<p>The following principles are basic to pkgsrc:</p>
540<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 540<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
541<li class="listitem"><p><span class="quote">&#8220;<span class="quote">It should only work if it's right.</span>&#8221;</span> 541<li class="listitem"><p><span class="quote">&#8220;<span class="quote">It should only work if it's right.</span>&#8221;</span>
542&mdash; That means, if a package contains bugs, it's better to find 542&mdash; That means, if a package contains bugs, it's better to find
543them and to complain about them rather than to just install the package 543them and to complain about them rather than to just install the package
544and hope that it works. There are numerous checks in pkgsrc that try to 544and hope that it works. There are numerous checks in pkgsrc that try to
545find such bugs: Static analysis tools (<a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>), build-time checks (portability 545find such bugs: Static analysis tools (<a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>), build-time checks (portability
546of shell scripts), and post-installation checks (installed files, 546of shell scripts), and post-installation checks (installed files,
547references to shared libraries, script interpreters).</p></li> 547references to shared libraries, script interpreters).</p></li>
548<li class="listitem"><p><span class="quote">&#8220;<span class="quote">If it works, it should work everywhere</span>&#8221;</span> 548<li class="listitem"><p><span class="quote">&#8220;<span class="quote">If it works, it should work everywhere</span>&#8221;</span>
549&mdash; Like NetBSD has been ported to many hardware architectures, 549&mdash; Like NetBSD has been ported to many hardware architectures,
550pkgsrc has been ported to many operating systems. Care is taken that 550pkgsrc has been ported to many operating systems. Care is taken that
551packages behave the same on all platforms.</p></li> 551packages behave the same on all platforms.</p></li>
552</ul></div> 552</ul></div>
553</div> 553</div>
554<div class="sect2"> 554<div class="sect2">
555<div class="titlepage"><div><div><h3 class="title"> 555<div class="titlepage"><div><div><h3 class="title">
556<a name="intro.platforms"></a>1.1.2. Supported platforms</h3></div></div></div> 556<a name="intro.platforms"></a>1.1.2. Supported platforms</h3></div></div></div>
557<p>pkgsrc consists of both a source distribution and a binary 557<p>pkgsrc consists of both a source distribution and a binary
558distribution for these operating systems. After retrieving the required 558distribution for these operating systems. After retrieving the required
@@ -917,72 +917,72 @@ free to install the sources and binary p @@ -917,72 +917,72 @@ free to install the sources and binary p
917your filesystem, provided that the pathname does not contain white-space 917your filesystem, provided that the pathname does not contain white-space
918or other characters that are interpreted specially by the shell and some 918or other characters that are interpreted specially by the shell and some
919other programs. A safe bet is to use only letters, digits, underscores 919other programs. A safe bet is to use only letters, digits, underscores
920and dashes.</p> 920and dashes.</p>
921<div class="sect1"> 921<div class="sect1">
922<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 922<div class="titlepage"><div><div><h2 class="title" style="clear: both">
923<a name="getting-first"></a>2.1. Getting pkgsrc for the first time</h2></div></div></div> 923<a name="getting-first"></a>2.1. Getting pkgsrc for the first time</h2></div></div></div>
924<p>Before you download any pkgsrc files, you should decide 924<p>Before you download any pkgsrc files, you should decide
925 whether you want the <span class="emphasis"><em>current</em></span> branch or the 925 whether you want the <span class="emphasis"><em>current</em></span> branch or the
926 <span class="emphasis"><em>stable</em></span> branch. The latter is forked on a 926 <span class="emphasis"><em>stable</em></span> branch. The latter is forked on a
927 quarterly basis from the current branch and only gets modified 927 quarterly basis from the current branch and only gets modified
928 for security updates. The names of the stable branches are built 928 for security updates. The names of the stable branches are built
929 from the year and the quarter, for example 929 from the year and the quarter, for example
930 <code class="literal">2017Q3</code>.</p> 930 <code class="literal">2018Q1</code>.</p>
931<p>The second step is to decide <span class="emphasis"><em>how</em></span> you 931<p>The second step is to decide <span class="emphasis"><em>how</em></span> you
932 want to download pkgsrc. You can get it as a tar file or via CVS. 932 want to download pkgsrc. You can get it as a tar file or via CVS.
933 Both ways are described here.</p> 933 Both ways are described here.</p>
934<p>Note that tar archive contains CVS working copy. 934<p>Note that tar archive contains CVS working copy.
935 Thus you can switch to using CVS at any later time.</p> 935 Thus you can switch to using CVS at any later time.</p>
936<div class="sect2"> 936<div class="sect2">
937<div class="titlepage"><div><div><h3 class="title"> 937<div class="titlepage"><div><div><h3 class="title">
938<a name="getting-via-tar"></a>2.1.1. As tar archive</h3></div></div></div> 938<a name="getting-via-tar"></a>2.1.1. As tar archive</h3></div></div></div>
939<p>The primary download location for all pkgsrc files is 939<p>The primary download location for all pkgsrc files is
940 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/" target="_top">http://ftp.NetBSD.org/pub/pkgsrc/</a> or 940 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/" target="_top">http://ftp.NetBSD.org/pub/pkgsrc/</a> or
941 <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/" target="_top">ftp://ftp.NetBSD.org/pub/pkgsrc/</a> 941 <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/" target="_top">ftp://ftp.NetBSD.org/pub/pkgsrc/</a>
942 (it points to the same location). 942 (it points to the same location).
943 There are a number of subdirectories for different purposes, 943 There are a number of subdirectories for different purposes,
944 which are described in detail in <a class="xref" href="#ftp-layout" title="Appendix C. Directory layout of the pkgsrc FTP server">Appendix C, <i>Directory layout of the pkgsrc FTP server</i></a>.</p> 944 which are described in detail in <a class="xref" href="#ftp-layout" title="Appendix C. Directory layout of the pkgsrc FTP server">Appendix C, <i>Directory layout of the pkgsrc FTP server</i></a>.</p>
945<p>The tar archive for the current branch is in the directory 945<p>The tar archive for the current branch is in the directory
946 <code class="filename">current</code> and is called <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz" target="_top"><code class="filename">pkgsrc.tar.gz</code></a>. 946 <code class="filename">current</code> and is called <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz" target="_top"><code class="filename">pkgsrc.tar.gz</code></a>.
947 It is autogenerated weekly.</p> 947 It is autogenerated weekly.</p>
948<p>To save download time we provide bzip2- and 948<p>To save download time we provide bzip2- and
949 xz-compressed archives which are published at 949 xz-compressed archives which are published at
950 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.bz2" target="_top"><code class="filename">pkgsrc.tar.bz2</code></a> 950 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.bz2" target="_top"><code class="filename">pkgsrc.tar.bz2</code></a>
951 and 951 and
952 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.xz" target="_top"><code class="filename">pkgsrc.tar.xz</code></a> 952 <a class="ulink" href="http://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.xz" target="_top"><code class="filename">pkgsrc.tar.xz</code></a>
953 respectively. 953 respectively.
954 </p> 954 </p>
955<p>You can fetch the same files using FTP.</p> 955<p>You can fetch the same files using FTP.</p>
956<p>The tar file for the stable branch 2017Q3 is in the 956<p>The tar file for the stable branch 2018Q1 is in the
957 directory <code class="filename">pkgsrc-2017Q3</code> and is also called <a class="ulink" href="http://cdn.NetBSD.org/pub/pkgsrc/pkgsrc-2017Q3/pkgsrc.tar.gz" target="_top"><code class="filename">pkgsrc.tar.gz</code></a>.</p> 957 directory <code class="filename">pkgsrc-2018Q1</code> and is also called <a class="ulink" href="https://cdn.NetBSD.org/pub/pkgsrc/pkgsrc-2018Q1/pkgsrc.tar.gz" target="_top"><code class="filename">pkgsrc.tar.gz</code></a>.</p>
958<p>To download the latest pkgsrc stable tarball, run:</p> 958<p>To download the latest pkgsrc stable tarball, run:</p>
959<pre class="screen"> 959<pre class="screen">
960<code class="prompt">$</code> <strong class="userinput"><code>ftp ftp://ftp.NetBSD.org/pub/pkgsrc/pkgsrc-2017Q3/pkgsrc.tar.gz</code></strong></pre> 960<code class="prompt">$</code> <strong class="userinput"><code>ftp ftp://ftp.NetBSD.org/pub/pkgsrc/pkgsrc-2018Q1/pkgsrc.tar.gz</code></strong></pre>
961<p>If you prefer, you can also fetch it using "wget", "curl", 961<p>If you prefer, you can also fetch it using "wget", "curl",
962 or your web browser.</p> 962 or your web browser.</p>
963<p>Then, extract it with:</p> 963<p>Then, extract it with:</p>
964<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>tar -xzf pkgsrc.tar.gz -C /usr</code></strong></pre> 964<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>tar -xzf pkgsrc.tar.gz -C /usr</code></strong></pre>
965<p>This will create the directory <code class="filename">pkgsrc/</code> 965<p>This will create the directory <code class="filename">pkgsrc/</code>
966 in <code class="filename">/usr/</code> and all the package source will be  966 in <code class="filename">/usr/</code> and all the package source will be
967 stored under <code class="filename">/usr/pkgsrc/</code>.</p> 967 stored under <code class="filename">/usr/pkgsrc/</code>.</p>
968<p>To download pkgsrc-current, run:</p> 968<p>To download pkgsrc-current, run:</p>
969<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>ftp ftp://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz</code></strong></pre> 969<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>ftp ftp://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz</code></strong></pre>
970</div> 970</div>
971<div class="sect2"> 971<div class="sect2">
972<div class="titlepage"><div><div><h3 class="title"> 972<div class="titlepage"><div><div><h3 class="title">
973<a name="getting-via-cvs"></a>2.1.2. Via anonymous CVS</h3></div></div></div> 973<a name="getting-via-cvs"></a>2.1.2. Via anonymous CVS</h3></div></div></div>
974<p>To fetch a specific pkgsrc stable branch, run:</p> 974<p>To fetch a specific pkgsrc stable branch, run:</p>
975<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -r pkgsrc-2017Q3 -P pkgsrc</code></strong> 975<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -r pkgsrc-2018Q1 -P pkgsrc</code></strong>
976</pre> 976</pre>
977<p>This will create the directory <code class="filename">pkgsrc/</code>  977<p>This will create the directory <code class="filename">pkgsrc/</code>
978 in your <code class="filename">/usr/</code> directory and all the package source  978 in your <code class="filename">/usr/</code> directory and all the package source
979 will be stored under <code class="filename">/usr/pkgsrc/</code>.</p> 979 will be stored under <code class="filename">/usr/pkgsrc/</code>.</p>
980<p>To fetch the pkgsrc current branch, run:</p> 980<p>To fetch the pkgsrc current branch, run:</p>
981<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc</code></strong> 981<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc</code></strong>
982</pre> 982</pre>
983<p>Refer to the <a class="ulink" href="http://www.NetBSD.org/mirrors/#anoncvs" target="_top">list of available mirrors</a> to choose a faster CVS mirror, if needed.</p> 983<p>Refer to the <a class="ulink" href="http://www.NetBSD.org/mirrors/#anoncvs" target="_top">list of available mirrors</a> to choose a faster CVS mirror, if needed.</p>
984<p>If you get error messages from <code class="literal">rsh</code>, you need to set CVS_RSH variable. E.g.:</p> 984<p>If you get error messages from <code class="literal">rsh</code>, you need to set CVS_RSH variable. E.g.:</p>
985<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; env CVS_RSH=ssh cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc</code></strong> 985<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr &amp;&amp; env CVS_RSH=ssh cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc</code></strong>
986</pre> 986</pre>
987<p>Refer to documentation on your command shell how to set CVS_RSH=ssh permanently. 987<p>Refer to documentation on your command shell how to set CVS_RSH=ssh permanently.
988 For Bourne shells, you can set it in your <code class="filename">.profile</code> 988 For Bourne shells, you can set it in your <code class="filename">.profile</code>
@@ -1047,27 +1047,27 @@ release -d @@ -1047,27 +1047,27 @@ release -d
1047</pre> 1047</pre>
1048<p>If you get error messages from <code class="literal">rsh</code>, you need to set CVS_RSH variable as described above. E.g.:</p> 1048<p>If you get error messages from <code class="literal">rsh</code>, you need to set CVS_RSH variable as described above. E.g.:</p>
1049<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr/pkgsrc &amp;&amp; env CVS_RSH=ssh cvs up -dP</code></strong> 1049<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>cd /usr/pkgsrc &amp;&amp; env CVS_RSH=ssh cvs up -dP</code></strong>
1050</pre> 1050</pre>
1051<div class="sect3"> 1051<div class="sect3">
1052<div class="titlepage"><div><div><h4 class="title"> 1052<div class="titlepage"><div><div><h4 class="title">
1053<a name="uptodate-cvs-switch"></a>2.2.2.1. Switching between different pkgsrc branches</h4></div></div></div> 1053<a name="uptodate-cvs-switch"></a>2.2.2.1. Switching between different pkgsrc branches</h4></div></div></div>
1054<p>When updating pkgsrc, the CVS program keeps track of the 1054<p>When updating pkgsrc, the CVS program keeps track of the
1055 branch you selected. But if you, for whatever reason, want to 1055 branch you selected. But if you, for whatever reason, want to
1056 switch from the stable branch to the current one, you can do it 1056 switch from the stable branch to the current one, you can do it
1057 by adding the option <span class="quote">&#8220;<span class="quote">-A</span>&#8221;</span> after the 1057 by adding the option <span class="quote">&#8220;<span class="quote">-A</span>&#8221;</span> after the
1058 <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span> keyword. To switch from the current branch 1058 <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span> keyword. To switch from the current branch
1059 back to the stable branch, add the 1059 back to the stable branch, add the
1060 <span class="quote">&#8220;<span class="quote">-rpkgsrc-2017Q3</span>&#8221;</span> option.</p> 1060 <span class="quote">&#8220;<span class="quote">-rpkgsrc-2018Q1</span>&#8221;</span> option.</p>
1061</div> 1061</div>
1062<div class="sect3"> 1062<div class="sect3">
1063<div class="titlepage"><div><div><h4 class="title"> 1063<div class="titlepage"><div><div><h4 class="title">
1064<a name="uptodate-cvs-changes"></a>2.2.2.2. What happens to my changes when updating?</h4></div></div></div> 1064<a name="uptodate-cvs-changes"></a>2.2.2.2. What happens to my changes when updating?</h4></div></div></div>
1065<p>When you update pkgsrc, the CVS program will only touch 1065<p>When you update pkgsrc, the CVS program will only touch
1066 those files that are registered in the CVS repository. That 1066 those files that are registered in the CVS repository. That
1067 means that any packages that you created on your own will stay 1067 means that any packages that you created on your own will stay
1068 unmodified. If you change files that are managed by CVS, later 1068 unmodified. If you change files that are managed by CVS, later
1069 updates will try to merge your changes with those that have been 1069 updates will try to merge your changes with those that have been
1070 done by others. See the CVS manual, chapter 1070 done by others. See the CVS manual, chapter
1071 <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span> for details.</p> 1071 <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span> for details.</p>
1072</div> 1072</div>
1073</div> 1073</div>
@@ -1292,27 +1292,27 @@ and you can still use binary packages fr @@ -1292,27 +1292,27 @@ and you can still use binary packages fr
1292 is for downloading 1292 is for downloading
1293 the list of vulnerabilities from the NetBSD FTP site. The second 1293 the list of vulnerabilities from the NetBSD FTP site. The second
1294 step, <span class="command"><strong>pkg_admin audit</strong></span>, checks to see if any of your 1294 step, <span class="command"><strong>pkg_admin audit</strong></span>, checks to see if any of your
1295 installed packages are vulnerable. If a package is vulnerable, you 1295 installed packages are vulnerable. If a package is vulnerable, you
1296 will see output similar to the following: 1296 will see output similar to the following:
1297 </p> 1297 </p>
1298<pre class="screen">Package samba-2.0.9 has a local-root-shell vulnerability, see 1298<pre class="screen">Package samba-2.0.9 has a local-root-shell vulnerability, see
1299 http://www.samba.org/samba/whatsnew/macroexploit.html</pre> 1299 http://www.samba.org/samba/whatsnew/macroexploit.html</pre>
1300<p> 1300<p>
1301 You may wish to have the 1301 You may wish to have the
1302 <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/distfiles/vulnerabilities" target="_top">vulnerabilities</a> 1302 <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/distfiles/vulnerabilities" target="_top">vulnerabilities</a>
1303 file downloaded daily so that 1303 file downloaded daily so that
1304 it remains current. This may be done by adding an appropriate entry 1304 it remains current. This may be done by adding an appropriate entry
1305 to the root users <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?crontab+5.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">crontab</span>(5)</span></a> entry. For example the entry 1305 to the root users <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?crontab+5.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">crontab</span>(5)</span></a> entry. For example the entry
1306 </p> 1306 </p>
1307<pre class="screen"> 1307<pre class="screen">
1308# Download vulnerabilities file 1308# Download vulnerabilities file
13090 3 * * * /usr/pkg/sbin/pkg_admin fetch-pkg-vulnerabilities &gt;/dev/null 2&gt;&amp;1 13090 3 * * * /usr/pkg/sbin/pkg_admin fetch-pkg-vulnerabilities &gt;/dev/null 2&gt;&amp;1
1310# Audit the installed packages and email results to root 1310# Audit the installed packages and email results to root
13119 3 * * * /usr/pkg/sbin/pkg_admin audit |mail -s "Installed package audit result" \ 13119 3 * * * /usr/pkg/sbin/pkg_admin audit |mail -s "Installed package audit result" \
1312 root &gt;/dev/null 2&gt;&amp;1 1312 root &gt;/dev/null 2&gt;&amp;1
1313 </pre> 1313 </pre>
1314<p> 1314<p>
1315 will update the vulnerability list every day at 3AM, followed by an audit 1315 will update the vulnerability list every day at 3AM, followed by an audit
1316 at 3:09AM. The result of the audit are then emailed to root. 1316 at 3:09AM. The result of the audit are then emailed to root.
1317 1317
1318 On NetBSD this may be accomplished instead by adding the following 1318 On NetBSD this may be accomplished instead by adding the following
@@ -1321,34 +1321,34 @@ and you can still use binary packages fr @@ -1321,34 +1321,34 @@ and you can still use binary packages fr
1321<pre class="screen"> 1321<pre class="screen">
1322fetch_pkg_vulnerabilities=YES 1322fetch_pkg_vulnerabilities=YES
1323 </pre> 1323 </pre>
1324<p> 1324<p>
1325 to fetch the vulnerability list from the daily security script. The system 1325 to fetch the vulnerability list from the daily security script. The system
1326 is set to audit the packages by default but can be set explicitly, if 1326 is set to audit the packages by default but can be set explicitly, if
1327 desired (not required), by adding the following line to 1327 desired (not required), by adding the following line to
1328<code class="filename">/etc/security.conf</code>: 1328<code class="filename">/etc/security.conf</code>:
1329 </p> 1329 </p>
1330<pre class="screen"> 1330<pre class="screen">
1331check_pkg_vulnerabilities=YES 1331check_pkg_vulnerabilities=YES
1332 </pre> 1332 </pre>
1333<p> 1333<p>
1334 see <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?daily.conf+5.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">daily.conf</span>(5)</span></a> and <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?security.conf+5.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">security.conf</span>(5)</span></a> for more details. 1334 see <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?daily.conf+5.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">daily.conf</span>(5)</span></a> and <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?security.conf+5.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">security.conf</span>(5)</span></a> for more details.
1335 </p> 1335 </p>
1336</div> 1336</div>
1337<div class="sect2"> 1337<div class="sect2">
1338<div class="titlepage"><div><div><h3 class="title"> 1338<div class="titlepage"><div><div><h3 class="title">
1339<a name="pkg_versions"></a>4.1.6. Finding if newer versions of your installed packages are in pkgsrc</h3></div></div></div> 1339<a name="pkg_versions"></a>4.1.6. Finding if newer versions of your installed packages are in pkgsrc</h3></div></div></div>
1340<p> 1340<p>
1341 Install <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/lintpkgsrc/README.html" target="_top"><code class="filename">pkgtools/lintpkgsrc</code></a> and run 1341 Install <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/lintpkgsrc/README.html" target="_top"><code class="filename">pkgtools/lintpkgsrc</code></a> and run
1342 <span class="command"><strong>lintpkgsrc</strong></span> with the <span class="quote">&#8220;<span class="quote">-i</span>&#8221;</span> 1342 <span class="command"><strong>lintpkgsrc</strong></span> with the <span class="quote">&#8220;<span class="quote">-i</span>&#8221;</span>
1343 argument to check if your packages are up-to-date, e.g. 1343 argument to check if your packages are up-to-date, e.g.
1344 </p> 1344 </p>
1345<pre class="screen"> 1345<pre class="screen">
1346<code class="prompt">%</code> <strong class="userinput"><code>lintpkgsrc -i</code></strong> 1346<code class="prompt">%</code> <strong class="userinput"><code>lintpkgsrc -i</code></strong>
1347... 1347...
1348Version mismatch: 'tcsh' 6.09.00 vs 6.10.00 1348Version mismatch: 'tcsh' 6.09.00 vs 6.10.00
1349 </pre> 1349 </pre>
1350<p>You can then use <span class="command"><strong>make update</strong></span> to update the 1350<p>You can then use <span class="command"><strong>make update</strong></span> to update the
1351 package on your system and rebuild any dependencies. 1351 package on your system and rebuild any dependencies.
1352 </p> 1352 </p>
1353</div> 1353</div>
1354<div class="sect2"> 1354<div class="sect2">
@@ -1356,27 +1356,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10 @@ -1356,27 +1356,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10
1356<a name="using.pkg_admin"></a>4.1.7. Other administrative functions</h3></div></div></div> 1356<a name="using.pkg_admin"></a>4.1.7. Other administrative functions</h3></div></div></div>
1357<p>The <span class="command"><strong>pkg_admin</strong></span> executes various 1357<p>The <span class="command"><strong>pkg_admin</strong></span> executes various
1358 administrative functions on the package system.</p> 1358 administrative functions on the package system.</p>
1359</div> 1359</div>
1360</div> 1360</div>
1361<div class="sect1"> 1361<div class="sect1">
1362<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 1362<div class="titlepage"><div><div><h2 class="title" style="clear: both">
1363<a name="building-packages-from-source"></a>4.2. Building packages from source</h2></div></div></div> 1363<a name="building-packages-from-source"></a>4.2. Building packages from source</h2></div></div></div>
1364<p>After obtaining pkgsrc, the <code class="filename">pkgsrc</code> 1364<p>After obtaining pkgsrc, the <code class="filename">pkgsrc</code>
1365 directory now contains a set of packages, organized into 1365 directory now contains a set of packages, organized into
1366 categories. You can browse the online index of packages, or run 1366 categories. You can browse the online index of packages, or run
1367 <span class="command"><strong>make readme</strong></span> from the <code class="filename">pkgsrc</code> 1367 <span class="command"><strong>make readme</strong></span> from the <code class="filename">pkgsrc</code>
1368 directory to build local <code class="filename">README.html</code> files for 1368 directory to build local <code class="filename">README.html</code> files for
1369 all packages, viewable with any web browser such as <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/lynx/README.html" target="_top"><code class="filename">www/lynx</code></a> or <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a>.</p> 1369 all packages, viewable with any web browser such as <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/lynx/README.html" target="_top"><code class="filename">www/lynx</code></a> or <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a>.</p>
1370<p>The default <span class="emphasis"><em>prefix</em></span> for installed packages 1370<p>The default <span class="emphasis"><em>prefix</em></span> for installed packages
1371 is <code class="filename">/usr/pkg</code>. If you wish to change this, you 1371 is <code class="filename">/usr/pkg</code>. If you wish to change this, you
1372 should do so by setting <code class="varname">LOCALBASE</code> in 1372 should do so by setting <code class="varname">LOCALBASE</code> in
1373 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>. You should not try to use multiple 1373 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>. You should not try to use multiple
1374 different <code class="varname">LOCALBASE</code> definitions on the same 1374 different <code class="varname">LOCALBASE</code> definitions on the same
1375 system (inside a chroot is an exception). </p> 1375 system (inside a chroot is an exception). </p>
1376<p>The rest of this chapter assumes that the package is already 1376<p>The rest of this chapter assumes that the package is already
1377 in pkgsrc. If it is not, see <a class="xref" href="#developers-guide" title="Part II. The pkgsrc developer's guide">Part II, &#8220;The pkgsrc developer's guide&#8221;</a> for 1377 in pkgsrc. If it is not, see <a class="xref" href="#developers-guide" title="Part II. The pkgsrc developer's guide">Part II, &#8220;The pkgsrc developer's guide&#8221;</a> for
1378 instructions how to create your own packages.</p> 1378 instructions how to create your own packages.</p>
1379<div class="sect2"> 1379<div class="sect2">
1380<div class="titlepage"><div><div><h3 class="title"> 1380<div class="titlepage"><div><div><h3 class="title">
1381<a name="requirements"></a>4.2.1. Requirements</h3></div></div></div> 1381<a name="requirements"></a>4.2.1. Requirements</h3></div></div></div>
1382<p>To build packages from source, you need a working C 1382<p>To build packages from source, you need a working C
@@ -1414,27 +1414,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10 @@ -1414,27 +1414,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10
1414 delimited list of domain suffixes. 1414 delimited list of domain suffixes.
1415 <code class="varname">MASTER_SORT_REGEX</code> is even more flexible, it 1415 <code class="varname">MASTER_SORT_REGEX</code> is even more flexible, it
1416 contains a whitespace delimited list of regular expressions. It 1416 contains a whitespace delimited list of regular expressions. It
1417 has higher priority than <code class="varname">MASTER_SORT</code>. Have a 1417 has higher priority than <code class="varname">MASTER_SORT</code>. Have a
1418 look at <code class="filename">pkgsrc/mk/defaults/mk.conf</code> to find 1418 look at <code class="filename">pkgsrc/mk/defaults/mk.conf</code> to find
1419 some examples. This may save some of your bandwidth and 1419 some examples. This may save some of your bandwidth and
1420 time.</p> 1420 time.</p>
1421<p>You can change these settings either in your shell's environment, or, 1421<p>You can change these settings either in your shell's environment, or,
1422 if you want to keep the settings, by editing the 1422 if you want to keep the settings, by editing the
1423 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> file, 1423 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> file,
1424 and adding the definitions there.</p> 1424 and adding the definitions there.</p>
1425<p> 1425<p>
1426 If a package depends on many other packages (such as 1426 If a package depends on many other packages (such as
1427 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/kde4/README.html" target="_top"><code class="filename">meta-pkgs/kde4</code></a>), the build process may 1427 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/kde4/README.html" target="_top"><code class="filename">meta-pkgs/kde4</code></a>), the build process may
1428 alternate between periods of 1428 alternate between periods of
1429 downloading source, and compiling. To ensure you have all the source 1429 downloading source, and compiling. To ensure you have all the source
1430 downloaded initially you can run the command: 1430 downloaded initially you can run the command:
1431 </p> 1431 </p>
1432<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make fetch-list | sh</code></strong></pre> 1432<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make fetch-list | sh</code></strong></pre>
1433<p> 1433<p>
1434 which will output and run a set of shell commands to fetch the 1434 which will output and run a set of shell commands to fetch the
1435 necessary files into the <code class="filename">distfiles</code> directory. You can 1435 necessary files into the <code class="filename">distfiles</code> directory. You can
1436 also choose to download the files manually. 1436 also choose to download the files manually.
1437 </p> 1437 </p>
1438</div> 1438</div>
1439<div class="sect2"> 1439<div class="sect2">
1440<div class="titlepage"><div><div><h3 class="title"> 1440<div class="titlepage"><div><div><h3 class="title">
@@ -1512,55 +1512,55 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10 @@ -1512,55 +1512,55 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10
1512 alter some configuration options at build time. Have a look at 1512 alter some configuration options at build time. Have a look at
1513 <code class="filename">pkgsrc/mk/defaults/mk.conf</code> to get an overview 1513 <code class="filename">pkgsrc/mk/defaults/mk.conf</code> to get an overview
1514 of what will be set there by default. Environment variables such 1514 of what will be set there by default. Environment variables such
1515 as <code class="varname">LOCALBASE</code> can be set in 1515 as <code class="varname">LOCALBASE</code> can be set in
1516 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> to save having to remember to 1516 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> to save having to remember to
1517 set them each time you want to use pkgsrc.</p> 1517 set them each time you want to use pkgsrc.</p>
1518<p>Occasionally, people want to <span class="quote">&#8220;<span class="quote">look under the 1518<p>Occasionally, people want to <span class="quote">&#8220;<span class="quote">look under the
1519 covers</span>&#8221;</span> to see what is going on when a package is building 1519 covers</span>&#8221;</span> to see what is going on when a package is building
1520 or being installed. This may be for debugging purposes, or out of 1520 or being installed. This may be for debugging purposes, or out of
1521 simple curiosity. A number of utility values have been added to 1521 simple curiosity. A number of utility values have been added to
1522 help with this.</p> 1522 help with this.</p>
1523<div class="orderedlist"><ol class="orderedlist" type="1"> 1523<div class="orderedlist"><ol class="orderedlist" type="1">
1524<li class="listitem"> 1524<li class="listitem">
1525<p>If you invoke the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> command with 1525<p>If you invoke the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> command with
1526 <code class="varname">PKG_DEBUG_LEVEL=2</code>, then a huge amount of 1526 <code class="varname">PKG_DEBUG_LEVEL=2</code>, then a huge amount of
1527 information will be displayed. For example,</p> 1527 information will be displayed. For example,</p>
1528<pre class="screen"><strong class="userinput"><code>make patch PKG_DEBUG_LEVEL=2</code></strong></pre> 1528<pre class="screen"><strong class="userinput"><code>make patch PKG_DEBUG_LEVEL=2</code></strong></pre>
1529<p>will show all the commands that are invoked, up to and 1529<p>will show all the commands that are invoked, up to and
1530 including the <span class="quote">&#8220;<span class="quote">patch</span>&#8221;</span> stage.</p> 1530 including the <span class="quote">&#8220;<span class="quote">patch</span>&#8221;</span> stage.</p>
1531</li> 1531</li>
1532<li class="listitem"> 1532<li class="listitem">
1533<p>If you want to know the value of a certain <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> 1533<p>If you want to know the value of a certain <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>
1534 definition, then the <code class="varname">VARNAME</code> definition 1534 definition, then the <code class="varname">VARNAME</code> definition
1535 should be used, in conjunction with the show-var 1535 should be used, in conjunction with the show-var
1536 target. e.g. to show the expansion of the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> 1536 target. e.g. to show the expansion of the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>
1537 variable <code class="varname">LOCALBASE</code>:</p> 1537 variable <code class="varname">LOCALBASE</code>:</p>
1538<pre class="screen"> 1538<pre class="screen">
1539<code class="prompt">%</code> <strong class="userinput"><code>make show-var VARNAME=LOCALBASE</code></strong> 1539<code class="prompt">%</code> <strong class="userinput"><code>make show-var VARNAME=LOCALBASE</code></strong>
1540/usr/pkg 1540/usr/pkg
1541<code class="prompt">%</code> 1541<code class="prompt">%</code>
1542 </pre> 1542 </pre>
1543</li> 1543</li>
1544</ol></div> 1544</ol></div>
1545<p>If you want to install a binary package that you've either 1545<p>If you want to install a binary package that you've either
1546 created yourself (see next section), that you put into 1546 created yourself (see next section), that you put into
1547 pkgsrc/packages manually or that is located on a remote FTP 1547 pkgsrc/packages manually or that is located on a remote FTP
1548 server, you can use the "bin-install" target. This target will 1548 server, you can use the "bin-install" target. This target will
1549 install a binary package - if available - via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>, 1549 install a binary package - if available - via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>,
1550 else do a <span class="command"><strong>make package</strong></span>. The list of remote FTP 1550 else do a <span class="command"><strong>make package</strong></span>. The list of remote FTP
1551 sites searched is kept in the variable 1551 sites searched is kept in the variable
1552 <code class="varname">BINPKG_SITES</code>, which defaults to 1552 <code class="varname">BINPKG_SITES</code>, which defaults to
1553 ftp.NetBSD.org. Any flags that should be added to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a> 1553 ftp.NetBSD.org. Any flags that should be added to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>
1554 can be put into <code class="varname">BIN_INSTALL_FLAGS</code>. See 1554 can be put into <code class="varname">BIN_INSTALL_FLAGS</code>. See
1555 <code class="filename">pkgsrc/mk/defaults/mk.conf</code> for more 1555 <code class="filename">pkgsrc/mk/defaults/mk.conf</code> for more
1556 details.</p> 1556 details.</p>
1557<p>A final word of warning: If you set up a system that has a 1557<p>A final word of warning: If you set up a system that has a
1558 non-standard setting for <code class="varname">LOCALBASE</code>, be sure to 1558 non-standard setting for <code class="varname">LOCALBASE</code>, be sure to
1559 set that before any packages are installed, as you cannot use 1559 set that before any packages are installed, as you cannot use
1560 several directories for the same purpose. Doing so will result in 1560 several directories for the same purpose. Doing so will result in
1561 pkgsrc not being able to properly detect your installed packages, 1561 pkgsrc not being able to properly detect your installed packages,
1562 and fail miserably. Note also that precompiled binary packages are 1562 and fail miserably. Note also that precompiled binary packages are
1563 usually built with the default <code class="varname">LOCALBASE</code> of 1563 usually built with the default <code class="varname">LOCALBASE</code> of
1564 <code class="filename">/usr/pkg</code>, and that you should 1564 <code class="filename">/usr/pkg</code>, and that you should
1565 <span class="emphasis"><em>not</em></span> install any if you use a non-standard 1565 <span class="emphasis"><em>not</em></span> install any if you use a non-standard
1566 <code class="varname">LOCALBASE</code>.</p> 1566 <code class="varname">LOCALBASE</code>.</p>
@@ -1579,27 +1579,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10 @@ -1579,27 +1579,27 @@ Version mismatch: 'tcsh' 6.09.00 vs 6.10
1579<dt><span class="sect1"><a href="#conf.compiler">5.4. Selecting and configuring the compiler</a></span></dt> 1579<dt><span class="sect1"><a href="#conf.compiler">5.4. Selecting and configuring the compiler</a></span></dt>
1580<dd><dl> 1580<dd><dl>
1581<dt><span class="sect2"><a href="#selecting-the-compiler">5.4.1. Selecting the compiler</a></span></dt> 1581<dt><span class="sect2"><a href="#selecting-the-compiler">5.4.1. Selecting the compiler</a></span></dt>
1582<dt><span class="sect2"><a href="#conf.cflags">5.4.2. Additional flags to the compiler (<code class="varname">CFLAGS</code>)</a></span></dt> 1582<dt><span class="sect2"><a href="#conf.cflags">5.4.2. Additional flags to the compiler (<code class="varname">CFLAGS</code>)</a></span></dt>
1583<dt><span class="sect2"><a href="#conf.ldflags">5.4.3. Additional flags to the linker (<code class="varname">LDFLAGS</code>)</a></span></dt> 1583<dt><span class="sect2"><a href="#conf.ldflags">5.4.3. Additional flags to the linker (<code class="varname">LDFLAGS</code>)</a></span></dt>
1584</dl></dd> 1584</dl></dd>
1585<dt><span class="sect1"><a href="#developer-advanced-settings">5.5. Developer/advanced settings</a></span></dt> 1585<dt><span class="sect1"><a href="#developer-advanced-settings">5.5. Developer/advanced settings</a></span></dt>
1586<dt><span class="sect1"><a href="#selecting-build-options">5.6. Selecting Build Options</a></span></dt> 1586<dt><span class="sect1"><a href="#selecting-build-options">5.6. Selecting Build Options</a></span></dt>
1587</dl> 1587</dl>
1588</div> 1588</div>
1589<a name="mk.conf"></a><p>The whole pkgsrc system is configured in a single file, usually 1589<a name="mk.conf"></a><p>The whole pkgsrc system is configured in a single file, usually
1590called <code class="filename">mk.conf</code>. In which directory pkgsrc looks for 1590called <code class="filename">mk.conf</code>. In which directory pkgsrc looks for
1591that file depends on the installation. On NetBSD, when you use 1591that file depends on the installation. On NetBSD, when you use
1592<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> from the base system, it is in the directory 1592<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> from the base system, it is in the directory
1593<code class="filename">/etc/</code>. In all other cases the default location is 1593<code class="filename">/etc/</code>. In all other cases the default location is
1594<code class="literal">${PREFIX}/etc/</code>, depending on where you told the 1594<code class="literal">${PREFIX}/etc/</code>, depending on where you told the
1595bootstrap program to install the binary packages.</p> 1595bootstrap program to install the binary packages.</p>
1596<p>The format of the configuration file is that of the usual 1596<p>The format of the configuration file is that of the usual
1597BSD-style <code class="filename">Makefile</code>s. The whole pkgsrc configuration 1597BSD-style <code class="filename">Makefile</code>s. The whole pkgsrc configuration
1598is done by setting variables in this file. Note that you can define all 1598is done by setting variables in this file. Note that you can define all
1599kinds of variables, and no special error checking (for example for 1599kinds of variables, and no special error checking (for example for
1600spelling mistakes) takes place.</p> 1600spelling mistakes) takes place.</p>
1601<div class="sect1"> 1601<div class="sect1">
1602<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 1602<div class="titlepage"><div><div><h2 class="title" style="clear: both">
1603<a name="general-configuration"></a>5.1. General configuration</h2></div></div></div> 1603<a name="general-configuration"></a>5.1. General configuration</h2></div></div></div>
1604<p>The following variables apply to all 1604<p>The following variables apply to all
1605 pkgsrc packages. A complete list of the variables that can be 1605 pkgsrc packages. A complete list of the variables that can be
@@ -1725,27 +1725,27 @@ uid=1000(myusername) gid=100(users) grou @@ -1725,27 +1725,27 @@ uid=1000(myusername) gid=100(users) grou
1725<code class="prompt">$</code> make stage-install 1725<code class="prompt">$</code> make stage-install
1726</pre> 1726</pre>
1727<p> 1727<p>
1728 1728
1729 Create a package without root privileges 1729 Create a package without root privileges
1730 1730
1731</p> 1731</p>
1732<pre class="programlisting"> 1732<pre class="programlisting">
1733<code class="prompt">$</code> make PACKAGES=$HOME/packages package 1733<code class="prompt">$</code> make PACKAGES=$HOME/packages package
1734</pre> 1734</pre>
1735<p> 1735<p>
1736 1736
1737 For the following command, you must be able to gain root 1737 For the following command, you must be able to gain root
1738 privileges using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?su+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">su</span>(1)</span></a> 1738 privileges using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?su+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">su</span>(1)</span></a>
1739 1739
1740</p> 1740</p>
1741<pre class="programlisting"> 1741<pre class="programlisting">
1742<code class="prompt">$</code> make PACKAGES=$HOME/packages install 1742<code class="prompt">$</code> make PACKAGES=$HOME/packages install
1743</pre> 1743</pre>
1744<p> 1744<p>
1745 1745
1746 Then, as a simple user 1746 Then, as a simple user
1747 1747
1748</p> 1748</p>
1749<pre class="programlisting"> 1749<pre class="programlisting">
1750<code class="prompt">$</code> make clean 1750<code class="prompt">$</code> make clean
1751</pre> 1751</pre>
@@ -1826,27 +1826,27 @@ uid=1000(myusername) gid=100(users) grou @@ -1826,27 +1826,27 @@ uid=1000(myusername) gid=100(users) grou
1826</div> 1826</div>
1827<div class="sect2"> 1827<div class="sect2">
1828<div class="titlepage"><div><div><h3 class="title"> 1828<div class="titlepage"><div><div><h3 class="title">
1829<a name="conf.cflags"></a>5.4.2. Additional flags to the compiler (<code class="varname">CFLAGS</code>)</h3></div></div></div> 1829<a name="conf.cflags"></a>5.4.2. Additional flags to the compiler (<code class="varname">CFLAGS</code>)</h3></div></div></div>
1830<p>If you wish to set the <code class="varname">CFLAGS</code> variable, 1830<p>If you wish to set the <code class="varname">CFLAGS</code> variable,
1831 please make sure to use the <code class="literal">+=</code> operator 1831 please make sure to use the <code class="literal">+=</code> operator
1832 instead of the <code class="literal">=</code> operator:</p> 1832 instead of the <code class="literal">=</code> operator:</p>
1833<pre class="programlisting"> 1833<pre class="programlisting">
1834CFLAGS+= -your -flags 1834CFLAGS+= -your -flags
1835</pre> 1835</pre>
1836<p>Using <code class="varname">CFLAGS=</code> (i.e. without the 1836<p>Using <code class="varname">CFLAGS=</code> (i.e. without the
1837 <span class="quote">&#8220;<span class="quote">+</span>&#8221;</span>) may lead to problems with packages that 1837 <span class="quote">&#8220;<span class="quote">+</span>&#8221;</span>) may lead to problems with packages that
1838 need to add their own flags. You may want to take a look 1838 need to add their own flags. You may want to take a look
1839 at the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/cpuflags/README.html" target="_top"><code class="filename">devel/cpuflags</code></a> 1839 at the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/cpuflags/README.html" target="_top"><code class="filename">devel/cpuflags</code></a>
1840 package if you're interested in optimization specifically 1840 package if you're interested in optimization specifically
1841 for the current CPU. </p> 1841 for the current CPU. </p>
1842</div> 1842</div>
1843<div class="sect2"> 1843<div class="sect2">
1844<div class="titlepage"><div><div><h3 class="title"> 1844<div class="titlepage"><div><div><h3 class="title">
1845<a name="conf.ldflags"></a>5.4.3. Additional flags to the linker (<code class="varname">LDFLAGS</code>)</h3></div></div></div> 1845<a name="conf.ldflags"></a>5.4.3. Additional flags to the linker (<code class="varname">LDFLAGS</code>)</h3></div></div></div>
1846<p>If you want to pass flags to the linker, both in the configure 1846<p>If you want to pass flags to the linker, both in the configure
1847step and the build step, you can do this in two ways. Either set 1847step and the build step, you can do this in two ways. Either set
1848<code class="varname">LDFLAGS</code> or <code class="varname">LIBS</code>. The difference 1848<code class="varname">LDFLAGS</code> or <code class="varname">LIBS</code>. The difference
1849between the two is that <code class="varname">LIBS</code> will be appended to 1849between the two is that <code class="varname">LIBS</code> will be appended to
1850the command line, while <code class="varname">LDFLAGS</code> come earlier. 1850the command line, while <code class="varname">LDFLAGS</code> come earlier.
1851<code class="varname">LDFLAGS</code> is pre-loaded with rpath settings for ELF 1851<code class="varname">LDFLAGS</code> is pre-loaded with rpath settings for ELF
1852machines depending on the setting of <code class="varname">USE_IMAKE</code> or 1852machines depending on the setting of <code class="varname">USE_IMAKE</code> or
@@ -1966,44 +1966,44 @@ PKG_OPTIONS.apache= suexec  @@ -1966,44 +1966,44 @@ PKG_OPTIONS.apache= suexec
1966<a name="binary"></a>Chapter 6. Creating binary packages</h2></div></div></div> 1966<a name="binary"></a>Chapter 6. Creating binary packages</h2></div></div></div>
1967<div class="toc"> 1967<div class="toc">
1968<p><b>Table of Contents</b></p> 1968<p><b>Table of Contents</b></p>
1969<dl class="toc"> 1969<dl class="toc">
1970<dt><span class="sect1"><a href="#building-a-single-binary-package">6.1. Building a single binary package</a></span></dt> 1970<dt><span class="sect1"><a href="#building-a-single-binary-package">6.1. Building a single binary package</a></span></dt>
1971<dt><span class="sect1"><a href="#settings-for-creationg-of-binary-packages">6.2. Settings for creation of binary packages</a></span></dt> 1971<dt><span class="sect1"><a href="#settings-for-creationg-of-binary-packages">6.2. Settings for creation of binary packages</a></span></dt>
1972</dl> 1972</dl>
1973</div> 1973</div>
1974<div class="sect1"> 1974<div class="sect1">
1975<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 1975<div class="titlepage"><div><div><h2 class="title" style="clear: both">
1976<a name="building-a-single-binary-package"></a>6.1. Building a single binary package</h2></div></div></div> 1976<a name="building-a-single-binary-package"></a>6.1. Building a single binary package</h2></div></div></div>
1977<p>Once you have built and installed a package, you can create 1977<p>Once you have built and installed a package, you can create
1978 a <span class="emphasis"><em>binary package</em></span> which can be installed on 1978 a <span class="emphasis"><em>binary package</em></span> which can be installed on
1979 another system with <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>. This saves having to build 1979 another system with <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>. This saves having to build
1980 the same package on a group of hosts and wasting CPU time. It also 1980 the same package on a group of hosts and wasting CPU time. It also
1981 provides a simple means for others to install your package, should 1981 provides a simple means for others to install your package, should
1982 you distribute it.</p> 1982 you distribute it.</p>
1983<p>To create a binary package, change into the appropriate 1983<p>To create a binary package, change into the appropriate
1984 directory in pkgsrc, and run <span class="command"><strong>make 1984 directory in pkgsrc, and run <span class="command"><strong>make
1985 package</strong></span>:</p> 1985 package</strong></span>:</p>
1986<pre class="screen"> 1986<pre class="screen">
1987<code class="prompt">$</code> <strong class="userinput"><code>cd misc/figlet</code></strong> 1987<code class="prompt">$</code> <strong class="userinput"><code>cd misc/figlet</code></strong>
1988<code class="prompt">$</code> <strong class="userinput"><code>make package</code></strong> 1988<code class="prompt">$</code> <strong class="userinput"><code>make package</code></strong>
1989</pre> 1989</pre>
1990<p>This will build and install your package (if not already done), 1990<p>This will build and install your package (if not already done),
1991 and then build a binary package from what was installed. You can 1991 and then build a binary package from what was installed. You can
1992 then use the <span class="command"><strong>pkg_*</strong></span> tools to manipulate 1992 then use the <span class="command"><strong>pkg_*</strong></span> tools to manipulate
1993 it. Binary packages are created by default in 1993 it. Binary packages are created by default in
1994 <code class="filename">/usr/pkgsrc/packages</code>, in the form of a 1994 <code class="filename">/usr/pkgsrc/packages</code>, in the form of a
1995 gzipped tar file. See <a class="xref" href="#logs.package" title="B.2. Packaging figlet">Section B.2, &#8220;Packaging figlet&#8221;</a> for a 1995 gzipped tar file. See <a class="xref" href="#logs.package" title="B.2. Packaging figlet">Section B.2, &#8220;Packaging figlet&#8221;</a> for a
1996 continuation of the above <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/misc/figlet/README.html" target="_top"><code class="filename">misc/figlet</code></a> example.</p> 1996 continuation of the above <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/misc/figlet/README.html" target="_top"><code class="filename">misc/figlet</code></a> example.</p>
1997<p>See <a class="xref" href="#submit" title="Chapter 21. Submitting and Committing">Chapter 21, <i>Submitting and Committing</i></a> for information on how to submit 1997<p>See <a class="xref" href="#submit" title="Chapter 21. Submitting and Committing">Chapter 21, <i>Submitting and Committing</i></a> for information on how to submit
1998 such a binary package.</p> 1998 such a binary package.</p>
1999</div> 1999</div>
2000<div class="sect1"> 2000<div class="sect1">
2001<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2001<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2002<a name="settings-for-creationg-of-binary-packages"></a>6.2. Settings for creation of binary packages</h2></div></div></div> 2002<a name="settings-for-creationg-of-binary-packages"></a>6.2. Settings for creation of binary packages</h2></div></div></div>
2003<p>See <a class="xref" href="#build.helpful-targets" title="17.17. Other helpful targets">Section 17.17, &#8220;Other helpful targets&#8221;</a>.</p> 2003<p>See <a class="xref" href="#build.helpful-targets" title="17.17. Other helpful targets">Section 17.17, &#8220;Other helpful targets&#8221;</a>.</p>
2004</div> 2004</div>
2005</div> 2005</div>
2006<div class="chapter"> 2006<div class="chapter">
2007<div class="titlepage"><div><div><h2 class="title"> 2007<div class="titlepage"><div><div><h2 class="title">
2008<a name="bulk"></a>Chapter 7. Creating binary packages for everything in pkgsrc (bulk 2008<a name="bulk"></a>Chapter 7. Creating binary packages for everything in pkgsrc (bulk
2009builds)</h2></div></div></div> 2009builds)</h2></div></div></div>
@@ -2133,27 +2133,27 @@ temporary filesystems, others must survi @@ -2133,27 +2133,27 @@ temporary filesystems, others must survi
2133<li class="listitem"><p>30 GB for the binary packages (read-write, remote, permanent)</p></li> 2133<li class="listitem"><p>30 GB for the binary packages (read-write, remote, permanent)</p></li>
2134<li class="listitem"><p>1 GB for the pkgsrc tree (read-only, remote, permanent)</p></li> 2134<li class="listitem"><p>1 GB for the pkgsrc tree (read-only, remote, permanent)</p></li>
2135<li class="listitem"><p>5 GB for <code class="filename">LOCALBASE</code> (read-write, local, temporary)</p></li> 2135<li class="listitem"><p>5 GB for <code class="filename">LOCALBASE</code> (read-write, local, temporary)</p></li>
2136<li class="listitem"><p>10 GB for the log files (read-write, remote, permanent)</p></li> 2136<li class="listitem"><p>10 GB for the log files (read-write, remote, permanent)</p></li>
2137<li class="listitem"><p>5 GB for temporary files (read-write, local, temporary)</p></li> 2137<li class="listitem"><p>5 GB for temporary files (read-write, local, temporary)</p></li>
2138</ul></div> 2138</ul></div>
2139</div> 2139</div>
2140<div class="sect1"> 2140<div class="sect1">
2141<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2141<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2142<a name="creating-cdroms"></a>7.4. Creating a multiple CD-ROM packages collection</h2></div></div></div> 2142<a name="creating-cdroms"></a>7.4. Creating a multiple CD-ROM packages collection</h2></div></div></div>
2143<p>After your pkgsrc bulk-build has completed, you may wish to 2143<p>After your pkgsrc bulk-build has completed, you may wish to
2144 create a CD-ROM set of the resulting binary packages to assist 2144 create a CD-ROM set of the resulting binary packages to assist
2145 in installing packages on other machines. The 2145 in installing packages on other machines. The
2146 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/cdpack/README.html" target="_top"><code class="filename">pkgtools/cdpack</code></a> package provides 2146 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/cdpack/README.html" target="_top"><code class="filename">pkgtools/cdpack</code></a> package provides
2147 a simple tool for creating the ISO 9660 images. 2147 a simple tool for creating the ISO 9660 images.
2148 <span class="command"><strong>cdpack</strong></span> arranges the packages on the CD-ROMs in a 2148 <span class="command"><strong>cdpack</strong></span> arranges the packages on the CD-ROMs in a
2149 way that keeps all the dependencies for a given package on the same 2149 way that keeps all the dependencies for a given package on the same
2150 CD as that package.</p> 2150 CD as that package.</p>
2151<div class="sect2"> 2151<div class="sect2">
2152<div class="titlepage"><div><div><h3 class="title"> 2152<div class="titlepage"><div><div><h3 class="title">
2153<a name="cdpack-example"></a>7.4.1. Example of cdpack</h3></div></div></div> 2153<a name="cdpack-example"></a>7.4.1. Example of cdpack</h3></div></div></div>
2154<p>Complete documentation for cdpack is found in the cdpack(1) 2154<p>Complete documentation for cdpack is found in the cdpack(1)
2155 man page. The following short example assumes that the binary 2155 man page. The following short example assumes that the binary
2156 packages are left in 2156 packages are left in
2157 <code class="filename">/usr/pkgsrc/packages/All</code> and that 2157 <code class="filename">/usr/pkgsrc/packages/All</code> and that
2158 sufficient disk space exists in <code class="filename">/u2</code> to 2158 sufficient disk space exists in <code class="filename">/u2</code> to
2159 hold the ISO 9660 images.</p> 2159 hold the ISO 9660 images.</p>
@@ -2383,90 +2383,90 @@ it contains items for both pkgsrc users  @@ -2383,90 +2383,90 @@ it contains items for both pkgsrc users
2383</pre> 2383</pre>
2384<p>Archives for all these mailing lists are available from 2384<p>Archives for all these mailing lists are available from
2385<a class="ulink" href="http://mail-index.NetBSD.org/" target="_top">http://mail-index.NetBSD.org/</a>.</p> 2385<a class="ulink" href="http://mail-index.NetBSD.org/" target="_top">http://mail-index.NetBSD.org/</a>.</p>
2386</div> 2386</div>
2387<div class="sect1"> 2387<div class="sect1">
2388<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2388<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2389<a name="faq-pkgtools"></a>9.2. Utilities for package management (pkgtools)</h2></div></div></div> 2389<a name="faq-pkgtools"></a>9.2. Utilities for package management (pkgtools)</h2></div></div></div>
2390<p>The directory <code class="filename">pkgsrc/pkgtools</code> contains 2390<p>The directory <code class="filename">pkgsrc/pkgtools</code> contains
2391a number of useful utilities for both users and developers of pkgsrc. This 2391a number of useful utilities for both users and developers of pkgsrc. This
2392section attempts only to make the reader aware of some of the utilities and when 2392section attempts only to make the reader aware of some of the utilities and when
2393they might be useful, and not to duplicate the documentation that comes 2393they might be useful, and not to duplicate the documentation that comes
2394with each package.</p> 2394with each package.</p>
2395<p>Utilities used by pkgsrc (automatically installed when needed):</p> 2395<p>Utilities used by pkgsrc (automatically installed when needed):</p>
2396<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/x11-links/README.html" target="_top"><code class="filename">pkgtools/x11-links</code></a>: 2396<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/x11-links/README.html" target="_top"><code class="filename">pkgtools/x11-links</code></a>:
2397 Symlinks for use by buildlink.</p></li></ul></div> 2397 Symlinks for use by buildlink.</p></li></ul></div>
2398<p>OS tool augmentation (automatically installed when needed):</p> 2398<p>OS tool augmentation (automatically installed when needed):</p>
2399<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 2399<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2400<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/digest/README.html" target="_top"><code class="filename">pkgtools/digest</code></a>: 2400<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/digest/README.html" target="_top"><code class="filename">pkgtools/digest</code></a>:
2401 Calculates various kinds of checksums (including SHA3).</p></li> 2401 Calculates various kinds of checksums (including SHA3).</p></li>
2402<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/libnbcompat/README.html" target="_top"><code class="filename">pkgtools/libnbcompat</code></a>: 2402<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/libnbcompat/README.html" target="_top"><code class="filename">pkgtools/libnbcompat</code></a>:
2403 Compatibility library for pkgsrc tools.</p></li> 2403 Compatibility library for pkgsrc tools.</p></li>
2404<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/mtree/README.html" target="_top"><code class="filename">pkgtools/mtree</code></a>: Installed on 2404<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/mtree/README.html" target="_top"><code class="filename">pkgtools/mtree</code></a>: Installed on
2405 non-BSD systems due to lack of native mtree.</p></li> 2405 non-BSD systems due to lack of native mtree.</p></li>
2406<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a>: 2406<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a>:
2407 Up-to-date replacement for 2407 Up-to-date replacement for
2408 <code class="filename">/usr/sbin/pkg_install</code>, or for use on operating 2408 <code class="filename">/usr/sbin/pkg_install</code>, or for use on operating
2409 systems where pkg_install is not present.</p></li> 2409 systems where pkg_install is not present.</p></li>
2410</ul></div> 2410</ul></div>
2411<p>Utilities used by pkgsrc (not automatically installed):</p> 2411<p>Utilities used by pkgsrc (not automatically installed):</p>
2412<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 2412<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2413<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_tarup/README.html" target="_top"><code class="filename">pkgtools/pkg_tarup</code></a>: 2413<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_tarup/README.html" target="_top"><code class="filename">pkgtools/pkg_tarup</code></a>:
2414 Create a binary package from an 2414 Create a binary package from an
2415 already-installed package. Used by <span class="command"><strong>make replace</strong></span> to 2415 already-installed package. Used by <span class="command"><strong>make replace</strong></span> to
2416 save the old package.</p></li> 2416 save the old package.</p></li>
2417<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/dfdisk/README.html" target="_top"><code class="filename">pkgtools/dfdisk</code></a>: 2417<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/dfdisk/README.html" target="_top"><code class="filename">pkgtools/dfdisk</code></a>:
2418 Adds extra functionality to pkgsrc, allowing it to fetch distfiles 2418 Adds extra functionality to pkgsrc, allowing it to fetch distfiles
2419 from multiple locations. It currently supports the following 2419 from multiple locations. It currently supports the following
2420 methods: multiple CD-ROMs and network FTP/HTTP connections.</p></li> 2420 methods: multiple CD-ROMs and network FTP/HTTP connections.</p></li>
2421<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/cpuflags/README.html" target="_top"><code class="filename">devel/cpuflags</code></a>: Determine 2421<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/cpuflags/README.html" target="_top"><code class="filename">devel/cpuflags</code></a>: Determine
2422 the best compiler flags to optimise code for your current 2422 the best compiler flags to optimise code for your current
2423 CPU and compiler. </p></li> 2423 CPU and compiler. </p></li>
2424</ul></div> 2424</ul></div>
2425<p>Utilities for keeping track of installed packages, being up to date, 2425<p>Utilities for keeping track of installed packages, being up to date,
2426etc:</p> 2426etc:</p>
2427<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 2427<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2428<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgin/README.html" target="_top"><code class="filename">pkgtools/pkgin</code></a>: A package 2428<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgin/README.html" target="_top"><code class="filename">pkgtools/pkgin</code></a>: A package
2429 update tool similar to apt(1). Download, install, and upgrade 2429 update tool similar to apt(1). Download, install, and upgrade
2430 binary packages easily.</p></li> 2430 binary packages easily.</p></li>
2431<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_chk/README.html" target="_top"><code class="filename">pkgtools/pkg_chk</code></a>: Reports on 2431<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_chk/README.html" target="_top"><code class="filename">pkgtools/pkg_chk</code></a>: Reports on
2432 packages whose installed versions do not match the latest pkgsrc 2432 packages whose installed versions do not match the latest pkgsrc
2433 entries.</p></li> 2433 entries.</p></li>
2434<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdep/README.html" target="_top"><code class="filename">pkgtools/pkgdep</code></a>: Makes 2434<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdep/README.html" target="_top"><code class="filename">pkgtools/pkgdep</code></a>: Makes
2435 dependency graphs of packages, to aid in choosing a strategy for 2435 dependency graphs of packages, to aid in choosing a strategy for
2436 updating.</p></li> 2436 updating.</p></li>
2437<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdepgraph/README.html" target="_top"><code class="filename">pkgtools/pkgdepgraph</code></a>: Makes 2437<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdepgraph/README.html" target="_top"><code class="filename">pkgtools/pkgdepgraph</code></a>: Makes
2438 graphs from the output of <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdep/README.html" target="_top"><code class="filename">pkgtools/pkgdep</code></a> (uses graphviz).</p></li> 2438 graphs from the output of <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdep/README.html" target="_top"><code class="filename">pkgtools/pkgdep</code></a> (uses graphviz).</p></li>
2439<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>: The 2439<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>: The
2440 pkglint(1) program checks a pkgsrc entry for errors.</p></li> 2440 pkglint(1) program checks a pkgsrc entry for errors.</p></li>
2441<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/lintpkgsrc/README.html" target="_top"><code class="filename">pkgtools/lintpkgsrc</code></a>: The lintpkgsrc(1) program 2441<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/lintpkgsrc/README.html" target="_top"><code class="filename">pkgtools/lintpkgsrc</code></a>: The lintpkgsrc(1) program
2442 does various checks on the complete pkgsrc system.</p></li> 2442 does various checks on the complete pkgsrc system.</p></li>
2443<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgsurvey/README.html" target="_top"><code class="filename">pkgtools/pkgsurvey</code></a>: Report what 2443<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgsurvey/README.html" target="_top"><code class="filename">pkgtools/pkgsurvey</code></a>: Report what
2444 packages you have installed.</p></li> 2444 packages you have installed.</p></li>
2445</ul></div> 2445</ul></div>
2446<p>Utilities for people maintaining or creating individual packages:</p> 2446<p>Utilities for people maintaining or creating individual packages:</p>
2447<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 2447<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2448<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a>: Automate 2448<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a>: Automate
2449 making and maintaining patches for a package (includes pkgdiff, 2449 making and maintaining patches for a package (includes pkgdiff,
2450 pkgvi, mkpatches, etc.).</p></li> 2450 pkgvi, mkpatches, etc.).</p></li>
2451<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a>: Aids in 2451<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a>: Aids in
2452 converting to pkgsrc.</p></li> 2452 converting to pkgsrc.</p></li>
2453</ul></div> 2453</ul></div>
2454<p>Utilities for people maintaining pkgsrc (or: more obscure pkg 2454<p>Utilities for people maintaining pkgsrc (or: more obscure pkg
2455utilities)</p> 2455utilities)</p>
2456<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 2456<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
2457<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_comp/README.html" target="_top"><code class="filename">pkgtools/pkg_comp</code></a>: Build 2457<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_comp/README.html" target="_top"><code class="filename">pkgtools/pkg_comp</code></a>: Build
2458 packages in a chrooted area.</p></li> 2458 packages in a chrooted area.</p></li>
2459<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/libkver/README.html" target="_top"><code class="filename">pkgtools/libkver</code></a>: Spoof 2459<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/libkver/README.html" target="_top"><code class="filename">pkgtools/libkver</code></a>: Spoof
2460 kernel version for chrooted cross builds.</p></li> 2460 kernel version for chrooted cross builds.</p></li>
2461</ul></div> 2461</ul></div>
2462</div> 2462</div>
2463<div class="sect1"> 2463<div class="sect1">
2464<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2464<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2465<a name="non-root-pkgsrc"></a>9.3. How to use pkgsrc as non-root</h2></div></div></div> 2465<a name="non-root-pkgsrc"></a>9.3. How to use pkgsrc as non-root</h2></div></div></div>
2466<p>To install packages from source as a non-root user, download 2466<p>To install packages from source as a non-root user, download
2467pkgsrc as described in <a class="xref" href="#getting" title="Chapter 2. Where to get pkgsrc and how to keep it up-to-date">Chapter 2, <i>Where to get pkgsrc and how to keep it up-to-date</i></a>, cd into that 2467pkgsrc as described in <a class="xref" href="#getting" title="Chapter 2. Where to get pkgsrc and how to keep it up-to-date">Chapter 2, <i>Where to get pkgsrc and how to keep it up-to-date</i></a>, cd into that
2468directory and run the command <span class="command"><strong>./bootstrap/bootstrap 2468directory and run the command <span class="command"><strong>./bootstrap/bootstrap
2469--unprivileged</strong></span>.</p> 2469--unprivileged</strong></span>.</p>
2470<p>This will install the binary part of pkgsrc to 2470<p>This will install the binary part of pkgsrc to
2471<code class="filename">~/pkg</code> and put the pkgsrc configuration <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> 2471<code class="filename">~/pkg</code> and put the pkgsrc configuration <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>
2472into <code class="filename">~/pkg/etc</code>.</p> 2472into <code class="filename">~/pkg/etc</code>.</p>
@@ -2557,83 +2557,83 @@ refuses to do passive. For the other to @@ -2557,83 +2557,83 @@ refuses to do passive. For the other to
2557<code class="filename">/usr/bin/ftp</code> from falling back to active 2557<code class="filename">/usr/bin/ftp</code> from falling back to active
2558transfers.</p> 2558transfers.</p>
2559</div> 2559</div>
2560<div class="sect1"> 2560<div class="sect1">
2561<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2561<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2562<a name="fetching-all-distfiles"></a>9.9. How to fetch all distfiles at once</h2></div></div></div> 2562<a name="fetching-all-distfiles"></a>9.9. How to fetch all distfiles at once</h2></div></div></div>
2563<p>You would like to download all the distfiles in a single batch 2563<p>You would like to download all the distfiles in a single batch
2564from work or university, where you can't run a <span class="command"><strong>make 2564from work or university, where you can't run a <span class="command"><strong>make
2565fetch</strong></span>. There is an archive of distfiles on <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/distfiles/" target="_top">ftp.NetBSD.org</a>, 2565fetch</strong></span>. There is an archive of distfiles on <a class="ulink" href="ftp://ftp.NetBSD.org/pub/pkgsrc/distfiles/" target="_top">ftp.NetBSD.org</a>,
2566but downloading the entire directory may not be appropriate.</p> 2566but downloading the entire directory may not be appropriate.</p>
2567<p>The answer here is to do a <span class="command"><strong>make fetch-list</strong></span> in 2567<p>The answer here is to do a <span class="command"><strong>make fetch-list</strong></span> in
2568<code class="filename">/usr/pkgsrc</code> or one of its subdirectories, carry the 2568<code class="filename">/usr/pkgsrc</code> or one of its subdirectories, carry the
2569resulting list to your machine at work/school and use it there. If you 2569resulting list to your machine at work/school and use it there. If you
2570don't have a NetBSD-compatible <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ftp+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">ftp</span>(1)</span></a> (like tnftp) at work, don't 2570don't have a NetBSD-compatible <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ftp+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">ftp</span>(1)</span></a> (like tnftp) at work, don't
2571forget to set <code class="varname">FETCH_CMD</code> to something that fetches a 2571forget to set <code class="varname">FETCH_CMD</code> to something that fetches a
2572URL:</p> 2572URL:</p>
2573<p>At home:</p> 2573<p>At home:</p>
2574<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc</code></strong> 2574<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc</code></strong>
2575<code class="prompt">%</code> <strong class="userinput"><code>make fetch-list FETCH_CMD=wget DISTDIR=/tmp/distfiles &gt;/tmp/fetch.sh</code></strong> 2575<code class="prompt">%</code> <strong class="userinput"><code>make fetch-list FETCH_CMD=wget DISTDIR=/tmp/distfiles &gt;/tmp/fetch.sh</code></strong>
2576<code class="prompt">%</code> <strong class="userinput"><code>scp /tmp/fetch.sh work:/tmp</code></strong></pre> 2576<code class="prompt">%</code> <strong class="userinput"><code>scp /tmp/fetch.sh work:/tmp</code></strong></pre>
2577<p>At work:</p> 2577<p>At work:</p>
2578<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>sh /tmp/fetch.sh</code></strong></pre> 2578<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>sh /tmp/fetch.sh</code></strong></pre>
2579<p>then tar up <code class="filename">/tmp/distfiles</code> and take it 2579<p>then tar up <code class="filename">/tmp/distfiles</code> and take it
2580home.</p> 2580home.</p>
2581<p>If you have a machine running NetBSD, and you want to get 2581<p>If you have a machine running NetBSD, and you want to get
2582<span class="emphasis"><em>all</em></span> distfiles (even ones that aren't for your 2582<span class="emphasis"><em>all</em></span> distfiles (even ones that aren't for your
2583machine architecture), you can do so by using the above-mentioned 2583machine architecture), you can do so by using the above-mentioned
2584<span class="command"><strong>make fetch-list</strong></span> approach, or fetch the distfiles 2584<span class="command"><strong>make fetch-list</strong></span> approach, or fetch the distfiles
2585directly by running:</p> 2585directly by running:</p>
2586<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make mirror-distfiles</code></strong></pre> 2586<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make mirror-distfiles</code></strong></pre>
2587<p>If you even decide to ignore 2587<p>If you even decide to ignore
2588<code class="varname">NO_{SRC,BIN}_ON_{FTP,CDROM}</code>, then you can get everything 2588<code class="varname">NO_{SRC,BIN}_ON_{FTP,CDROM}</code>, then you can get everything
2589by running:</p> 2589by running:</p>
2590<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make fetch NO_SKIP=yes</code></strong></pre> 2590<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make fetch NO_SKIP=yes</code></strong></pre>
2591</div> 2591</div>
2592<div class="sect1"> 2592<div class="sect1">
2593<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2593<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2594<a name="tmac.andoc-missing"></a>9.10. What does <span class="quote">&#8220;<span class="quote">Don't know how to make 2594<a name="tmac.andoc-missing"></a>9.10. What does <span class="quote">&#8220;<span class="quote">Don't know how to make
2595/usr/share/tmac/tmac.andoc</span>&#8221;</span> mean?</h2></div></div></div> 2595/usr/share/tmac/tmac.andoc</span>&#8221;</span> mean?</h2></div></div></div>
2596<p>When compiling the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a> 2596<p>When compiling the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a>
2597package, you get the error from make that it doesn't know how to make 2597package, you get the error from make that it doesn't know how to make
2598<code class="filename">/usr/share/tmac/tmac.andoc</code>? This indicates that 2598<code class="filename">/usr/share/tmac/tmac.andoc</code>? This indicates that
2599you don't have installed the <span class="quote">&#8220;<span class="quote">text</span>&#8221;</span> set (nroff, ...) from 2599you don't have installed the <span class="quote">&#8220;<span class="quote">text</span>&#8221;</span> set (nroff, ...) from
2600the NetBSD base distribution on your machine. It is recommended to do 2600the NetBSD base distribution on your machine. It is recommended to do
2601that to format man pages.</p> 2601that to format man pages.</p>
2602<p>In the case of the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a> package, you 2602<p>In the case of the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a> package, you
2603can get away with setting <code class="varname">NOMAN=YES</code> either in the 2603can get away with setting <code class="varname">NOMAN=YES</code> either in the
2604environment or in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p> 2604environment or in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p>
2605</div> 2605</div>
2606<div class="sect1"> 2606<div class="sect1">
2607<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2607<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2608<a name="bsd.own.mk-missing"></a>9.11. What does <span class="quote">&#8220;<span class="quote">Could not find bsd.own.mk</span>&#8221;</span> mean?</h2></div></div></div> 2608<a name="bsd.own.mk-missing"></a>9.11. What does <span class="quote">&#8220;<span class="quote">Could not find bsd.own.mk</span>&#8221;</span> mean?</h2></div></div></div>
2609<p>You didn't install the compiler set, <code class="filename">comp.tgz</code>, 2609<p>You didn't install the compiler set, <code class="filename">comp.tgz</code>,
2610when you installed your NetBSD machine. Please get and install it, by 2610when you installed your NetBSD machine. Please get and install it, by
2611extracting it in <code class="filename">/</code>:</p> 2611extracting it in <code class="filename">/</code>:</p>
2612<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>cd /</code></strong> 2612<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>cd /</code></strong>
2613<code class="prompt">#</code> <strong class="userinput"><code>tar --unlink -zxvpf .../comp.tgz</code></strong></pre> 2613<code class="prompt">#</code> <strong class="userinput"><code>tar --unlink -zxvpf .../comp.tgz</code></strong></pre>
2614<p><code class="filename">comp.tgz</code> is part of every NetBSD release. Get 2614<p><code class="filename">comp.tgz</code> is part of every NetBSD release. Get
2615the one that corresponds to your release (determine via <span class="command"><strong>uname 2615the one that corresponds to your release (determine via <span class="command"><strong>uname
2616-r</strong></span>).</p> 2616-r</strong></span>).</p>
2617</div> 2617</div>
2618<div class="sect1"> 2618<div class="sect1">
2619<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2619<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2620<a name="using-sudo-with-pkgsrc"></a>9.12. Using 'sudo' with pkgsrc</h2></div></div></div> 2620<a name="using-sudo-with-pkgsrc"></a>9.12. Using 'sudo' with pkgsrc</h2></div></div></div>
2621<p>When installing packages as non-root user and using the just-in-time 2621<p>When installing packages as non-root user and using the just-in-time
2622<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?su+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">su</span>(1)</span></a> feature of pkgsrc, it can become annoying to type in the root 2622<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?su+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">su</span>(1)</span></a> feature of pkgsrc, it can become annoying to type in the root
2623password for each required package installed. To avoid this, the sudo 2623password for each required package installed. To avoid this, the sudo
2624package can be used, which does password caching over a limited time. To 2624package can be used, which does password caching over a limited time. To
2625use it, install sudo (either as binary package or from 2625use it, install sudo (either as binary package or from
2626<a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/security/sudo/README.html" target="_top"><code class="filename">security/sudo</code></a>) and then put the 2626<a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/security/sudo/README.html" target="_top"><code class="filename">security/sudo</code></a>) and then put the
2627following into your <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, somewhere 2627following into your <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, somewhere
2628<span class="emphasis"><em>after</em></span> the definition of the 2628<span class="emphasis"><em>after</em></span> the definition of the
2629<code class="varname">LOCALBASE</code> variable:</p> 2629<code class="varname">LOCALBASE</code> variable:</p>
2630<pre class="programlisting"> 2630<pre class="programlisting">
2631.if exists(${LOCALBASE}/bin/sudo) 2631.if exists(${LOCALBASE}/bin/sudo)
2632SU_CMD= ${LOCALBASE}/bin/sudo /bin/sh -c 2632SU_CMD= ${LOCALBASE}/bin/sudo /bin/sh -c
2633.endif 2633.endif
2634</pre> 2634</pre>
2635</div> 2635</div>
2636<div class="sect1"> 2636<div class="sect1">
2637<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2637<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2638<a name="faq.conf"></a>9.13. How do I change the location of configuration files?</h2></div></div></div> 2638<a name="faq.conf"></a>9.13. How do I change the location of configuration files?</h2></div></div></div>
2639<p>As the system administrator, you can choose where configuration files 2639<p>As the system administrator, you can choose where configuration files
@@ -2655,27 +2655,27 @@ package you would like to modify, that i @@ -2655,27 +2655,27 @@ package you would like to modify, that i
2655<p>Note that after changing these settings, you must rebuild and 2655<p>Note that after changing these settings, you must rebuild and
2656reinstall any affected packages.</p> 2656reinstall any affected packages.</p>
2657</div> 2657</div>
2658<div class="sect1"> 2658<div class="sect1">
2659<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2659<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2660<a name="audit-packages"></a>9.14. Automated security checks</h2></div></div></div> 2660<a name="audit-packages"></a>9.14. Automated security checks</h2></div></div></div>
2661<p>Please be aware that there can often be bugs in third-party software, 2661<p>Please be aware that there can often be bugs in third-party software,
2662and some of these bugs can leave a machine vulnerable to exploitation by 2662and some of these bugs can leave a machine vulnerable to exploitation by
2663attackers. In an effort to lessen the exposure, the NetBSD packages team 2663attackers. In an effort to lessen the exposure, the NetBSD packages team
2664maintains a database of known-exploits to packages which have at one time 2664maintains a database of known-exploits to packages which have at one time
2665been included in pkgsrc. The database can be downloaded automatically, and 2665been included in pkgsrc. The database can be downloaded automatically, and
2666a security audit of all packages installed on a system can take place. To 2666a security audit of all packages installed on a system can take place. To
2667do this, refer to the following two tools (installed as part of the 2667do this, refer to the following two tools (installed as part of the
2668<a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a> package):</p> 2668<a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_install/README.html" target="_top"><code class="filename">pkgtools/pkg_install</code></a> package):</p>
2669<div class="orderedlist"><ol class="orderedlist" type="1"> 2669<div class="orderedlist"><ol class="orderedlist" type="1">
2670<li class="listitem"> 2670<li class="listitem">
2671<p><span class="command"><strong>pkg_admin fetch-pkg-vulnerabilities</strong></span>, an easy way to 2671<p><span class="command"><strong>pkg_admin fetch-pkg-vulnerabilities</strong></span>, an easy way to
2672 download a list of the security vulnerabilities information. This list 2672 download a list of the security vulnerabilities information. This list
2673 is kept up to date by the pkgsrc security team, and is distributed 2673 is kept up to date by the pkgsrc security team, and is distributed
2674 from the NetBSD ftp server:</p> 2674 from the NetBSD ftp server:</p>
2675<p><a class="ulink" href="ftp://ftp.NetBSD.org/pkgsrc/distfiles/pkg-vulnerabilities" target="_top">ftp://ftp.NetBSD.org/pkgsrc/distfiles/pkg-vulnerabilities</a></p> 2675<p><a class="ulink" href="ftp://ftp.NetBSD.org/pkgsrc/distfiles/pkg-vulnerabilities" target="_top">ftp://ftp.NetBSD.org/pkgsrc/distfiles/pkg-vulnerabilities</a></p>
2676</li> 2676</li>
2677<li class="listitem"><p><span class="command"><strong>pkg_admin audit</strong></span>, an easy way to audit the 2677<li class="listitem"><p><span class="command"><strong>pkg_admin audit</strong></span>, an easy way to audit the
2678 current machine, checking each known vulnerability. If a 2678 current machine, checking each known vulnerability. If a
2679 vulnerable package is installed, it will be shown by output to stdout, 2679 vulnerable package is installed, it will be shown by output to stdout,
2680 including a description of the type of vulnerability, and a URL 2680 including a description of the type of vulnerability, and a URL
2681 containing more information.</p></li> 2681 containing more information.</p></li>
@@ -2683,27 +2683,27 @@ do this, refer to the following two tool @@ -2683,27 +2683,27 @@ do this, refer to the following two tool
2683<p>Use of these tools is strongly recommended! 2683<p>Use of these tools is strongly recommended!
2684See <a class="xref" href="#vulnerabilities" title="4.1.5. Checking for security vulnerabilities in installed packages">Section 4.1.5, &#8220;Checking for security vulnerabilities in installed packages&#8221;</a> for instructions on how to automate checking and 2684See <a class="xref" href="#vulnerabilities" title="4.1.5. Checking for security vulnerabilities in installed packages">Section 4.1.5, &#8220;Checking for security vulnerabilities in installed packages&#8221;</a> for instructions on how to automate checking and
2685reporting.</p> 2685reporting.</p>
2686<p>If this database is installed, pkgsrc builds will use it to 2686<p>If this database is installed, pkgsrc builds will use it to
2687perform a security check before building any package.</p> 2687perform a security check before building any package.</p>
2688</div> 2688</div>
2689<div class="sect1"> 2689<div class="sect1">
2690<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 2690<div class="titlepage"><div><div><h2 class="title" style="clear: both">
2691<a name="ufaq-cflags"></a>9.15. Why do some packages ignore my <code class="varname">CFLAGS</code>?</h2></div></div></div> 2691<a name="ufaq-cflags"></a>9.15. Why do some packages ignore my <code class="varname">CFLAGS</code>?</h2></div></div></div>
2692<p>When you add your own preferences to the 2692<p>When you add your own preferences to the
2693 <code class="varname">CFLAGS</code> variable in your 2693 <code class="varname">CFLAGS</code> variable in your
2694 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, these flags are passed in 2694 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, these flags are passed in
2695 environment variables to the <code class="filename">./configure</code> 2695 environment variables to the <code class="filename">./configure</code>
2696 scripts and to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>. Some package authors ignore the 2696 scripts and to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>. Some package authors ignore the
2697 <code class="varname">CFLAGS</code> from the environment variable by 2697 <code class="varname">CFLAGS</code> from the environment variable by
2698 overriding them in the <code class="filename">Makefile</code>s of their 2698 overriding them in the <code class="filename">Makefile</code>s of their
2699 package.</p> 2699 package.</p>
2700<p>Currently there is no solution to this problem. If you 2700<p>Currently there is no solution to this problem. If you
2701 really need the package to use your <code class="varname">CFLAGS</code> 2701 really need the package to use your <code class="varname">CFLAGS</code>
2702 you should run <span class="command"><strong>make patch</strong></span> in the package 2702 you should run <span class="command"><strong>make patch</strong></span> in the package
2703 directory and then inspect any <code class="filename">Makefile</code> and 2703 directory and then inspect any <code class="filename">Makefile</code> and
2704 <code class="filename">Makefile.in</code> for whether they define 2704 <code class="filename">Makefile.in</code> for whether they define
2705 <code class="varname">CFLAGS</code> explicitly. Usually you can remove 2705 <code class="varname">CFLAGS</code> explicitly. Usually you can remove
2706 these lines. But be aware that some <span class="quote">&#8220;<span class="quote">smart</span>&#8221;</span> 2706 these lines. But be aware that some <span class="quote">&#8220;<span class="quote">smart</span>&#8221;</span>
2707 programmers write so bad code that it only works for the 2707 programmers write so bad code that it only works for the
2708 specific combination of <code class="varname">CFLAGS</code> they have 2708 specific combination of <code class="varname">CFLAGS</code> they have
2709 chosen.</p> 2709 chosen.</p>
@@ -2994,27 +2994,27 @@ anymore, you can remove that file and ru @@ -2994,27 +2994,27 @@ anymore, you can remove that file and ru
2994<dd><dl> 2994<dd><dl>
2995<dt><span class="sect2"><a href="#creating.perl-module">10.1.1. Perl modules</a></span></dt> 2995<dt><span class="sect2"><a href="#creating.perl-module">10.1.1. Perl modules</a></span></dt>
2996<dt><span class="sect2"><a href="#creating.python-module">10.1.2. Python modules and programs</a></span></dt> 2996<dt><span class="sect2"><a href="#creating.python-module">10.1.2. Python modules and programs</a></span></dt>
2997</dl></dd> 2997</dl></dd>
2998<dt><span class="sect1"><a href="#creating.examples">10.2. Examples</a></span></dt> 2998<dt><span class="sect1"><a href="#creating.examples">10.2. Examples</a></span></dt>
2999<dd><dl><dt><span class="sect2"><a href="#creating.nvu">10.2.1. How the www/nvu package came into pkgsrc</a></span></dt></dl></dd> 2999<dd><dl><dt><span class="sect2"><a href="#creating.nvu">10.2.1. How the www/nvu package came into pkgsrc</a></span></dt></dl></dd>
3000</dl> 3000</dl>
3001</div> 3001</div>
3002<p>When you find a package that is not yet in pkgsrc, you 3002<p>When you find a package that is not yet in pkgsrc, you
3003most likely have a URL from where you can download the source 3003most likely have a URL from where you can download the source
3004code. Starting with this URL, creating a package involves only a 3004code. Starting with this URL, creating a package involves only a
3005few steps.</p> 3005few steps.</p>
3006<div class="procedure"><ol class="procedure" type="1"> 3006<div class="procedure"><ol class="procedure" type="1">
3007<li class="step"><p>First, install the packages <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a> and <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>.</p></li> 3007<li class="step"><p>First, install the packages <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a> and <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>.</p></li>
3008<li class="step"><p>Then, choose one of the top-level directories as the 3008<li class="step"><p>Then, choose one of the top-level directories as the
3009category in which you want to place your package. You can also create a 3009category in which you want to place your package. You can also create a
3010directory of your own (maybe called <code class="filename">local</code>). In that 3010directory of your own (maybe called <code class="filename">local</code>). In that
3011category directory, create another directory for your package and change 3011category directory, create another directory for your package and change
3012into it.</p></li> 3012into it.</p></li>
3013<li class="step"><p>Run the program <span class="command"><strong>url2pkg</strong></span>, which will ask 3013<li class="step"><p>Run the program <span class="command"><strong>url2pkg</strong></span>, which will ask
3014you for a URL. Enter the URL of the distribution file (in most cases a 3014you for a URL. Enter the URL of the distribution file (in most cases a
3015<code class="filename">.tar.gz</code> file) and watch how the basic ingredients 3015<code class="filename">.tar.gz</code> file) and watch how the basic ingredients
3016of your package are created automatically. The distribution file is 3016of your package are created automatically. The distribution file is
3017extracted automatically to fill in some details in the 3017extracted automatically to fill in some details in the
3018<code class="filename">Makefile</code> that would otherwise have to be done 3018<code class="filename">Makefile</code> that would otherwise have to be done
3019manually.</p></li> 3019manually.</p></li>
3020<li class="step"> 3020<li class="step">
@@ -3349,27 +3349,27 @@ again. But the error didn't change. Afte @@ -3349,27 +3349,27 @@ again. But the error didn't change. Afte
3349code, I concluded that the build process of the package was broken and 3349code, I concluded that the build process of the package was broken and
3350couldn't have ever worked, but since the Mozilla source tree is quite 3350couldn't have ever worked, but since the Mozilla source tree is quite
3351large, I didn't want to fix it. So I added the following to the package 3351large, I didn't want to fix it. So I added the following to the package
3352<code class="filename">Makefile</code> and tried again:</p> 3352<code class="filename">Makefile</code> and tried again:</p>
3353<pre class="programlisting"> 3353<pre class="programlisting">
3354CPPFLAGS+= -I${BUILDLINK_PREFIX.libIDL}/include/libIDL-2.0 3354CPPFLAGS+= -I${BUILDLINK_PREFIX.libIDL}/include/libIDL-2.0
3355BUILDLINK_TRANSFORM+= -l:IDL:IDL-2 3355BUILDLINK_TRANSFORM+= -l:IDL:IDL-2
3356</pre> 3356</pre>
3357<p>The latter line is needed because the package expects the library 3357<p>The latter line is needed because the package expects the library
3358<code class="filename">libIDL.so</code>, but only 3358<code class="filename">libIDL.so</code>, but only
3359<code class="filename">libIDL-2.so</code> is available. So I told the compiler 3359<code class="filename">libIDL-2.so</code> is available. So I told the compiler
3360wrapper to rewrite that on the fly.</p> 3360wrapper to rewrite that on the fly.</p>
3361<p>The next problem was related to a recent change of the FreeType 3361<p>The next problem was related to a recent change of the FreeType
3362interface. I looked up in <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/seamonkey/README.html" target="_top"><code class="filename">www/seamonkey</code></a> 3362interface. I looked up in <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/seamonkey/README.html" target="_top"><code class="filename">www/seamonkey</code></a>
3363which patch files were relevant for this issue and copied them to the 3363which patch files were relevant for this issue and copied them to the
3364<code class="filename">patches</code> directory. Then I retried, fixed the 3364<code class="filename">patches</code> directory. Then I retried, fixed the
3365patches so that they applied cleanly and retried again. This time, 3365patches so that they applied cleanly and retried again. This time,
3366everything worked.</p> 3366everything worked.</p>
3367</div> 3367</div>
3368<div class="sect3"> 3368<div class="sect3">
3369<div class="titlepage"><div><div><h4 class="title"> 3369<div class="titlepage"><div><div><h4 class="title">
3370<a name="creating.nvu.inst"></a>10.2.1.3. Installing the package</h4></div></div></div> 3370<a name="creating.nvu.inst"></a>10.2.1.3. Installing the package</h4></div></div></div>
3371<pre class="programlisting"> 3371<pre class="programlisting">
3372<code class="prompt">$</code> bmake CHECK_FILES=no install 3372<code class="prompt">$</code> bmake CHECK_FILES=no install
3373[...] 3373[...]
3374<code class="prompt">$</code> bmake print-PLIST &gt;PLIST 3374<code class="prompt">$</code> bmake print-PLIST &gt;PLIST
3375<code class="prompt">$</code> bmake deinstall 3375<code class="prompt">$</code> bmake deinstall
@@ -3467,37 +3467,37 @@ converters games mbone  @@ -3467,37 +3467,37 @@ converters games mbone
3467 </p> 3467 </p>
3468<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 3468<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
3469<li class="listitem"><p><code class="varname">PATCHFILES</code>: 3469<li class="listitem"><p><code class="varname">PATCHFILES</code>:
3470 Name(s) of additional files that contain distribution patches. 3470 Name(s) of additional files that contain distribution patches.
3471 There is no default. pkgsrc will look for them at 3471 There is no default. pkgsrc will look for them at
3472 <code class="varname">PATCH_SITES</code>. 3472 <code class="varname">PATCH_SITES</code>.
3473 They will automatically be uncompressed before patching if 3473 They will automatically be uncompressed before patching if
3474 the names end with <code class="filename">.gz</code> or 3474 the names end with <code class="filename">.gz</code> or
3475 <code class="filename">.Z</code>.</p></li> 3475 <code class="filename">.Z</code>.</p></li>
3476<li class="listitem"><p><code class="varname">PATCH_SITES</code>: 3476<li class="listitem"><p><code class="varname">PATCH_SITES</code>:
3477 Primary location(s) for distribution patch files (see 3477 Primary location(s) for distribution patch files (see
3478 <code class="varname">PATCHFILES</code> above) if not found locally.</p></li> 3478 <code class="varname">PATCHFILES</code> above) if not found locally.</p></li>
3479<li class="listitem"><p><code class="varname">PATCH_DIST_STRIP</code>: 3479<li class="listitem"><p><code class="varname">PATCH_DIST_STRIP</code>:
3480 an argument to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> that sets the pathname strip count to 3480 an argument to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> that sets the pathname strip count to
3481 help find the correct files to patch. It defaults to 3481 help find the correct files to patch. It defaults to
3482 <span class="command"><strong>-p0</strong></span>.</p></li> 3482 <span class="command"><strong>-p0</strong></span>.</p></li>
3483</ul></div> 3483</ul></div>
3484<p>The third section contains the following variables. 3484<p>The third section contains the following variables.
3485 </p> 3485 </p>
3486<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 3486<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
3487<li class="listitem"><p><code class="varname">MAINTAINER</code> is the email 3487<li class="listitem"><p><code class="varname">MAINTAINER</code> is the email
3488 address of the person who feels responsible for this package, 3488 address of the person who feels responsible for this package,
3489 and who is most likely to look at problems or questions regarding 3489 and who is most likely to look at problems or questions regarding
3490 this package which have been reported with <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a>. 3490 this package which have been reported with <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a>.
3491 Other developers may contact the <code class="varname">MAINTAINER</code> 3491 Other developers may contact the <code class="varname">MAINTAINER</code>
3492 before making changes to the package, but are not required to 3492 before making changes to the package, but are not required to
3493 do so. When packaging a new program, set <code class="varname">MAINTAINER</code> 3493 do so. When packaging a new program, set <code class="varname">MAINTAINER</code>
3494 to yourself. If you really can't maintain the package for future 3494 to yourself. If you really can't maintain the package for future
3495 updates, set it to 3495 updates, set it to
3496 <code class="email">&lt;<a class="email" href="mailto:pkgsrc-users@NetBSD.org">pkgsrc-users@NetBSD.org</a>&gt;</code>.</p></li> 3496 <code class="email">&lt;<a class="email" href="mailto:pkgsrc-users@NetBSD.org">pkgsrc-users@NetBSD.org</a>&gt;</code>.</p></li>
3497<li class="listitem"><p><code class="varname">OWNER</code> should be used instead 3497<li class="listitem"><p><code class="varname">OWNER</code> should be used instead
3498 of <code class="varname">MAINTAINER</code> when you do not want other 3498 of <code class="varname">MAINTAINER</code> when you do not want other
3499 developers to update or change the package without contacting 3499 developers to update or change the package without contacting
3500 you first. A package Makefile should contain one of 3500 you first. A package Makefile should contain one of
3501 <code class="varname">MAINTAINER</code> or <code class="varname">OWNER</code>, but 3501 <code class="varname">MAINTAINER</code> or <code class="varname">OWNER</code>, but
3502 not both. </p></li> 3502 not both. </p></li>
3503<li class="listitem"><p><code class="varname">HOMEPAGE</code> is a URL where users can 3503<li class="listitem"><p><code class="varname">HOMEPAGE</code> is a URL where users can
@@ -3514,27 +3514,27 @@ converters games mbone  @@ -3514,27 +3514,27 @@ converters games mbone
3514<p><code class="varname">WRKSRC</code>: The directory where the 3514<p><code class="varname">WRKSRC</code>: The directory where the
3515 interesting distribution files of the package are found. The 3515 interesting distribution files of the package are found. The
3516 default is <code class="filename">${WRKDIR}/${DISTNAME}</code>, which 3516 default is <code class="filename">${WRKDIR}/${DISTNAME}</code>, which
3517 works for most packages.</p> 3517 works for most packages.</p>
3518<p>If a package doesn't create a subdirectory for itself 3518<p>If a package doesn't create a subdirectory for itself
3519 (most GNU software does, for instance), but extracts itself in 3519 (most GNU software does, for instance), but extracts itself in
3520 the current directory, you should set 3520 the current directory, you should set
3521 <code class="varname">WRKSRC=${WRKDIR}</code>.</p> 3521 <code class="varname">WRKSRC=${WRKDIR}</code>.</p>
3522<p>If a package doesn't create a subdirectory with the 3522<p>If a package doesn't create a subdirectory with the
3523 name of <code class="varname">DISTNAME</code> but some different name, 3523 name of <code class="varname">DISTNAME</code> but some different name,
3524 set <code class="varname">WRKSRC</code> to point to the proper name in 3524 set <code class="varname">WRKSRC</code> to point to the proper name in
3525 <code class="filename">${WRKDIR}</code>, for example 3525 <code class="filename">${WRKDIR}</code>, for example
3526 <code class="varname">WRKSRC=${WRKDIR}/${DISTNAME}/unix</code>. See 3526 <code class="varname">WRKSRC=${WRKDIR}/${DISTNAME}/unix</code>. See
3527 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/tcl/README.html" target="_top"><code class="filename">lang/tcl</code></a> and <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/tk/README.html" target="_top"><code class="filename">x11/tk</code></a> for other examples.</p> 3527 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/tcl/README.html" target="_top"><code class="filename">lang/tcl</code></a> and <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/tk/README.html" target="_top"><code class="filename">x11/tk</code></a> for other examples.</p>
3528<p>The name of the working directory created by pkgsrc is 3528<p>The name of the working directory created by pkgsrc is
3529 taken from the <code class="varname">WRKDIR_BASENAME</code> 3529 taken from the <code class="varname">WRKDIR_BASENAME</code>
3530 variable. By default, its value is 3530 variable. By default, its value is
3531 <code class="filename">work</code>. If you want to use the same 3531 <code class="filename">work</code>. If you want to use the same
3532 pkgsrc tree for building different kinds of binary packages, 3532 pkgsrc tree for building different kinds of binary packages,
3533 you can change the variable according to your needs. Two 3533 you can change the variable according to your needs. Two
3534 other variables handle common cases of setting 3534 other variables handle common cases of setting
3535 <code class="varname">WRKDIR_BASENAME</code> individually. If 3535 <code class="varname">WRKDIR_BASENAME</code> individually. If
3536 <code class="varname">OBJHOSTNAME</code> is defined in 3536 <code class="varname">OBJHOSTNAME</code> is defined in
3537 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, the first component of 3537 <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>, the first component of
3538 the host's name is attached to the directory name. If 3538 the host's name is attached to the directory name. If
3539 <code class="varname">OBJMACHINE</code> is defined, the platform name 3539 <code class="varname">OBJMACHINE</code> is defined, the platform name
3540 is attached, which might look like 3540 is attached, which might look like
@@ -3560,27 +3560,27 @@ converters games mbone  @@ -3560,27 +3560,27 @@ converters games mbone
3560<p>The <code class="filename">distinfo</code> file contains the message 3560<p>The <code class="filename">distinfo</code> file contains the message
3561 digest, or checksum, of each distfile needed for the package. This 3561 digest, or checksum, of each distfile needed for the package. This
3562 ensures that the distfiles retrieved from the Internet have not been 3562 ensures that the distfiles retrieved from the Internet have not been
3563 corrupted during transfer or altered by a malign force to introduce 3563 corrupted during transfer or altered by a malign force to introduce
3564 a security hole. To provide maximum security, all distfiles are 3564 a security hole. To provide maximum security, all distfiles are
3565 protected using three different message digest algorithms (SHA1, 3565 protected using three different message digest algorithms (SHA1,
3566 RMD160, SHA512), as well as the file size.</p> 3566 RMD160, SHA512), as well as the file size.</p>
3567<p>The <code class="filename">distinfo</code> file also contains the 3567<p>The <code class="filename">distinfo</code> file also contains the
3568 checksums for all the patches found in the 3568 checksums for all the patches found in the
3569 <code class="filename">patches</code> directory (see <a class="xref" href="#components.patches" title="11.3. patches/*">Section 11.3, &#8220;<code class="filename">patches/*</code>&#8221;</a>).</p> 3569 <code class="filename">patches</code> directory (see <a class="xref" href="#components.patches" title="11.3. patches/*">Section 11.3, &#8220;<code class="filename">patches/*</code>&#8221;</a>).</p>
3570<p>To regenerate the <code class="filename">distinfo</code> file, use the 3570<p>To regenerate the <code class="filename">distinfo</code> file, use the
3571 <span class="command"><strong>make distinfo</strong></span> command.</p> 3571 <span class="command"><strong>make distinfo</strong></span> command.</p>
3572<p>Some packages have different sets of distfiles depending on 3572<p>Some packages have different sets of distfiles depending on
3573 the platform, for example <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/openjdk7/README.html" target="_top"><code class="filename">lang/openjdk7</code></a>. These are kept in the same 3573 the platform, for example <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/openjdk7/README.html" target="_top"><code class="filename">lang/openjdk7</code></a>. These are kept in the same
3574 <code class="filename">distinfo</code> file and care should be taken when 3574 <code class="filename">distinfo</code> file and care should be taken when
3575 upgrading such a package to ensure distfile information is not 3575 upgrading such a package to ensure distfile information is not
3576 lost.</p> 3576 lost.</p>
3577</div> 3577</div>
3578<div class="sect1"> 3578<div class="sect1">
3579<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 3579<div class="titlepage"><div><div><h2 class="title" style="clear: both">
3580<a name="components.patches"></a>11.3. <code class="filename">patches/*</code> 3580<a name="components.patches"></a>11.3. <code class="filename">patches/*</code>
3581</h2></div></div></div> 3581</h2></div></div></div>
3582<p>Some packages don't work out-of-the box on the various 3582<p>Some packages don't work out-of-the box on the various
3583 platforms that are supported by pkgsrc. These packages need 3583 platforms that are supported by pkgsrc. These packages need
3584 to be patched to make them work. The patch files can be 3584 to be patched to make them work. The patch files can be
3585 found in the <code class="filename">patches/</code> directory.</p> 3585 found in the <code class="filename">patches/</code> directory.</p>
3586<p>In the <span class="emphasis"><em>patch</em></span> phase, these patches are 3586<p>In the <span class="emphasis"><em>patch</em></span> phase, these patches are
@@ -3610,54 +3610,54 @@ converters games mbone  @@ -3610,54 +3610,54 @@ converters games mbone
3610</ul></div> 3610</ul></div>
3611<p>The patch should be commented so that any 3611<p>The patch should be commented so that any
3612 developer who knows the code of the application can make some use of 3612 developer who knows the code of the application can make some use of
3613 the patch. Special care should be taken for the upstream developers, 3613 the patch. Special care should be taken for the upstream developers,
3614 since we generally want that they accept our patches, so we have less 3614 since we generally want that they accept our patches, so we have less
3615 work in the future.</p> 3615 work in the future.</p>
3616</div> 3616</div>
3617<div class="sect2"> 3617<div class="sect2">
3618<div class="titlepage"><div><div><h3 class="title"> 3618<div class="titlepage"><div><div><h3 class="title">
3619<a name="components.patches.caveats"></a>11.3.2. Creating patch files</h3></div></div></div> 3619<a name="components.patches.caveats"></a>11.3.2. Creating patch files</h3></div></div></div>
3620<p>One important thing to mention is to pay attention that no RCS 3620<p>One important thing to mention is to pay attention that no RCS
3621 IDs get stored in the patch files, as these will cause problems when 3621 IDs get stored in the patch files, as these will cause problems when
3622 later checked into the NetBSD CVS tree. Use the 3622 later checked into the NetBSD CVS tree. Use the
3623 <span class="command"><strong>pkgdiff</strong></span> command from the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a> package to avoid these 3623 <span class="command"><strong>pkgdiff</strong></span> command from the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a> package to avoid these
3624 problems.</p> 3624 problems.</p>
3625<p>For even more automation, we recommend using 3625<p>For even more automation, we recommend using
3626 <span class="command"><strong>mkpatches</strong></span> from the same package to make a 3626 <span class="command"><strong>mkpatches</strong></span> from the same package to make a
3627 whole set of patches. You just have to backup files before you 3627 whole set of patches. You just have to backup files before you
3628 edit them to <code class="filename">filename.orig</code>, e.g. with 3628 edit them to <code class="filename">filename.orig</code>, e.g. with
3629 <span class="command"><strong>cp -p filename filename.orig</strong></span> or, easier, by 3629 <span class="command"><strong>cp -p filename filename.orig</strong></span> or, easier, by
3630 using <span class="command"><strong>pkgvi</strong></span> again from the same package. If 3630 using <span class="command"><strong>pkgvi</strong></span> again from the same package. If
3631 you upgrade a package this way, you can easily compare the new 3631 you upgrade a package this way, you can easily compare the new
3632 set of patches with the previously existing one with 3632 set of patches with the previously existing one with
3633 <span class="command"><strong>patchdiff</strong></span>. The files in <code class="filename">patches</code> 3633 <span class="command"><strong>patchdiff</strong></span>. The files in <code class="filename">patches</code>
3634 are replaced by new files, so carefully check if you want to take all 3634 are replaced by new files, so carefully check if you want to take all
3635 the changes.</p> 3635 the changes.</p>
3636<p>When you have finished a package, remember to generate 3636<p>When you have finished a package, remember to generate
3637 the checksums for the patch files by using the <span class="command"><strong>make 3637 the checksums for the patch files by using the <span class="command"><strong>make
3638 makepatchsum</strong></span> command, see <a class="xref" href="#components.distinfo" title="11.2. distinfo">Section 11.2, &#8220;<code class="filename">distinfo</code>&#8221;</a>.</p> 3638 makepatchsum</strong></span> command, see <a class="xref" href="#components.distinfo" title="11.2. distinfo">Section 11.2, &#8220;<code class="filename">distinfo</code>&#8221;</a>.</p>
3639<p>When adding a patch that corrects a problem in the 3639<p>When adding a patch that corrects a problem in the
3640 distfile (rather than e.g. enforcing pkgsrc's view of where 3640 distfile (rather than e.g. enforcing pkgsrc's view of where
3641 man pages should go), send the patch as a bug report to the 3641 man pages should go), send the patch as a bug report to the
3642 maintainer. This benefits non-pkgsrc users of the package, 3642 maintainer. This benefits non-pkgsrc users of the package,
3643 and usually makes it possible to remove the patch in future 3643 and usually makes it possible to remove the patch in future
3644 version.</p> 3644 version.</p>
3645<p>The file names of the patch files are usually of the form 3645<p>The file names of the patch files are usually of the form
3646 <code class="filename">patch-<em class="replaceable"><code>path_to_file__with__underscores.c</code></em></code>. 3646 <code class="filename">patch-<em class="replaceable"><code>path_to_file__with__underscores.c</code></em></code>.
3647 Many packages still use the previous convention 3647 Many packages still use the previous convention
3648 <code class="filename">patch-<em class="replaceable"><code>[a-z][a-z]</code></em></code>, 3648 <code class="filename">patch-<em class="replaceable"><code>[a-z][a-z]</code></em></code>,
3649 but new patches should be of the form containing the filename. 3649 but new patches should be of the form containing the filename.
3650 <span class="command"><strong>mkpatches</strong></span> included in <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a> takes care of the name 3650 <span class="command"><strong>mkpatches</strong></span> included in <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a> takes care of the name
3651 automatically.</p> 3651 automatically.</p>
3652</div> 3652</div>
3653<div class="sect2"> 3653<div class="sect2">
3654<div class="titlepage"><div><div><h3 class="title"> 3654<div class="titlepage"><div><div><h3 class="title">
3655<a name="components.patches.sources"></a>11.3.3. Sources where the patch files come from</h3></div></div></div> 3655<a name="components.patches.sources"></a>11.3.3. Sources where the patch files come from</h3></div></div></div>
3656<p>If you want to share patches between multiple packages 3656<p>If you want to share patches between multiple packages
3657 in pkgsrc, e.g. because they use the same distfiles, set 3657 in pkgsrc, e.g. because they use the same distfiles, set
3658 <code class="varname">PATCHDIR</code> to the path where the patch files 3658 <code class="varname">PATCHDIR</code> to the path where the patch files
3659 can be found, e.g.:</p> 3659 can be found, e.g.:</p>
3660<pre class="programlisting"> 3660<pre class="programlisting">
3661PATCHDIR= ${.CURDIR}/../xemacs/patches 3661PATCHDIR= ${.CURDIR}/../xemacs/patches
3662</pre> 3662</pre>
3663<p>Patch files that are distributed by the author or other 3663<p>Patch files that are distributed by the author or other
@@ -3831,54 +3831,54 @@ monitor_file(...) @@ -3831,54 +3831,54 @@ monitor_file(...)
3831 inserted files. See <a class="xref" href="#plist" title="Chapter 13. PLIST issues">Chapter 13, <i>PLIST issues</i></a> for more 3831 inserted files. See <a class="xref" href="#plist" title="Chapter 13. PLIST issues">Chapter 13, <i>PLIST issues</i></a> for more
3832 information.</p></dd> 3832 information.</p></dd>
3833</dl></div> 3833</dl></div>
3834</div> 3834</div>
3835<div class="sect1"> 3835<div class="sect1">
3836<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 3836<div class="titlepage"><div><div><h2 class="title" style="clear: both">
3837<a name="components.optional"></a>11.5. Optional files</h2></div></div></div> 3837<a name="components.optional"></a>11.5. Optional files</h2></div></div></div>
3838<div class="sect2"> 3838<div class="sect2">
3839<div class="titlepage"><div><div><h3 class="title"> 3839<div class="titlepage"><div><div><h3 class="title">
3840<a name="components.optional.bin"></a>11.5.1. Files affecting the binary package</h3></div></div></div> 3840<a name="components.optional.bin"></a>11.5.1. Files affecting the binary package</h3></div></div></div>
3841<div class="variablelist"><dl class="variablelist"> 3841<div class="variablelist"><dl class="variablelist">
3842<dt><span class="term"><code class="filename">INSTALL</code></span></dt> 3842<dt><span class="term"><code class="filename">INSTALL</code></span></dt>
3843<dd> 3843<dd>
3844<p>This shell script is invoked twice by <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>. 3844<p>This shell script is invoked twice by <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>.
3845 First time after package extraction and before files are 3845 First time after package extraction and before files are
3846 moved in place, the second time after the files to install 3846 moved in place, the second time after the files to install
3847 are moved in place. This can be used to do any custom 3847 are moved in place. This can be used to do any custom
3848 procedures not possible with @exec commands in 3848 procedures not possible with @exec commands in
3849 <code class="filename">PLIST</code>. See <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a> and 3849 <code class="filename">PLIST</code>. See <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a> and
3850 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> for more information. See also <a class="xref" href="#files-and-dirs-outside-prefix" title="15.1. Files and directories outside the installation prefix">Section 15.1, &#8220;Files and directories outside the installation prefix&#8221;</a>. 3850 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> for more information. See also <a class="xref" href="#files-and-dirs-outside-prefix" title="15.1. Files and directories outside the installation prefix">Section 15.1, &#8220;Files and directories outside the installation prefix&#8221;</a>.
3851 Please note that you can modify variables in it easily by using 3851 Please note that you can modify variables in it easily by using
3852 <code class="varname">FILES_SUBST</code> in the package's 3852 <code class="varname">FILES_SUBST</code> in the package's
3853 <code class="filename">Makefile</code>:</p> 3853 <code class="filename">Makefile</code>:</p>
3854<pre class="programlisting"> 3854<pre class="programlisting">
3855FILES_SUBST+= SOMEVAR="somevalue" 3855FILES_SUBST+= SOMEVAR="somevalue"
3856</pre> 3856</pre>
3857<p>replaces "@SOMEVAR@" with <span class="quote">&#8220;<span class="quote">somevalue</span>&#8221;</span> in the 3857<p>replaces "@SOMEVAR@" with <span class="quote">&#8220;<span class="quote">somevalue</span>&#8221;</span> in the
3858 <code class="filename">INSTALL</code>. By default, substitution is 3858 <code class="filename">INSTALL</code>. By default, substitution is
3859 performed for <code class="varname">PREFIX</code>, 3859 performed for <code class="varname">PREFIX</code>,
3860 <code class="varname">LOCALBASE</code>, <code class="varname">X11BASE</code>, 3860 <code class="varname">LOCALBASE</code>, <code class="varname">X11BASE</code>,
3861 <code class="varname">VARBASE</code>, and a few others, type 3861 <code class="varname">VARBASE</code>, and a few others, type
3862 <span class="command"><strong>make help topic=FILES_SUBST</strong></span> for a 3862 <span class="command"><strong>make help topic=FILES_SUBST</strong></span> for a
3863 complete list.</p> 3863 complete list.</p>
3864</dd> 3864</dd>
3865<dt><span class="term"><code class="filename">DEINSTALL</code></span></dt> 3865<dt><span class="term"><code class="filename">DEINSTALL</code></span></dt>
3866<dd><p>This script is executed before and after any files are removed. It is 3866<dd><p>This script is executed before and after any files are removed. It is
3867 this script's responsibility to clean up any additional messy details 3867 this script's responsibility to clean up any additional messy details
3868 around the package's installation, since all pkg_delete knows is how to 3868 around the package's installation, since all pkg_delete knows is how to
3869 delete the files created in the original distribution. 3869 delete the files created in the original distribution.
3870 See <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> 3870 See <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a>
3871 and <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> for more information. 3871 and <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> for more information.
3872 The same methods to replace variables can be used as for 3872 The same methods to replace variables can be used as for
3873 the <code class="filename">INSTALL</code> file.</p></dd> 3873 the <code class="filename">INSTALL</code> file.</p></dd>
3874<dt><span class="term"><code class="filename">MESSAGE</code></span></dt> 3874<dt><span class="term"><code class="filename">MESSAGE</code></span></dt>
3875<dd> 3875<dd>
3876<p>This file is displayed after installation of the package. 3876<p>This file is displayed after installation of the package.
3877 Useful for things like legal notices on almost-free 3877 Useful for things like legal notices on almost-free
3878 software and hints for updating config files after 3878 software and hints for updating config files after
3879 installing modules for apache, PHP etc. 3879 installing modules for apache, PHP etc.
3880 Please note that you can modify variables in it easily by using 3880 Please note that you can modify variables in it easily by using
3881 <code class="varname">MESSAGE_SUBST</code> in the package's 3881 <code class="varname">MESSAGE_SUBST</code> in the package's
3882 <code class="filename">Makefile</code>:</p> 3882 <code class="filename">Makefile</code>:</p>
3883<pre class="programlisting"> 3883<pre class="programlisting">
3884MESSAGE_SUBST+= SOMEVAR="somevalue" 3884MESSAGE_SUBST+= SOMEVAR="somevalue"
@@ -3997,97 +3997,97 @@ FILESDIR=${.CURDIR}/../xemacs/files @@ -3997,97 +3997,97 @@ FILESDIR=${.CURDIR}/../xemacs/files
3997<dt><span class="sect1"><a href="#makefile.variables">12.2. <code class="filename">Makefile</code> variables</a></span></dt> 3997<dt><span class="sect1"><a href="#makefile.variables">12.2. <code class="filename">Makefile</code> variables</a></span></dt>
3998<dd><dl><dt><span class="sect2"><a href="#makefile.variables.names">12.2.1. Naming conventions</a></span></dt></dl></dd> 3998<dd><dl><dt><span class="sect2"><a href="#makefile.variables.names">12.2.1. Naming conventions</a></span></dt></dl></dd>
3999<dt><span class="sect1"><a href="#makefile.code">12.3. Code snippets</a></span></dt> 3999<dt><span class="sect1"><a href="#makefile.code">12.3. Code snippets</a></span></dt>
4000<dd><dl> 4000<dd><dl>
4001<dt><span class="sect2"><a href="#adding-to-list">12.3.1. Adding things to a list</a></span></dt> 4001<dt><span class="sect2"><a href="#adding-to-list">12.3.1. Adding things to a list</a></span></dt>
4002<dt><span class="sect2"><a href="#echo-literal">12.3.2. Echoing a string exactly as-is</a></span></dt> 4002<dt><span class="sect2"><a href="#echo-literal">12.3.2. Echoing a string exactly as-is</a></span></dt>
4003<dt><span class="sect2"><a href="#cflags-gnu-configure">12.3.3. Passing <code class="varname">CFLAGS</code> to GNU configure scripts</a></span></dt> 4003<dt><span class="sect2"><a href="#cflags-gnu-configure">12.3.3. Passing <code class="varname">CFLAGS</code> to GNU configure scripts</a></span></dt>
4004<dt><span class="sect2"><a href="#empty-variables">12.3.4. Handling possibly empty variables</a></span></dt> 4004<dt><span class="sect2"><a href="#empty-variables">12.3.4. Handling possibly empty variables</a></span></dt>
4005</dl></dd> 4005</dl></dd>
4006</dl> 4006</dl>
4007</div> 4007</div>
4008<p>Pkgsrc consists of many <code class="filename">Makefile</code> fragments, 4008<p>Pkgsrc consists of many <code class="filename">Makefile</code> fragments,
4009 each of which forms a well-defined part of the pkgsrc system. Using 4009 each of which forms a well-defined part of the pkgsrc system. Using
4010 the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> system as a programming language for a big system 4010 the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> system as a programming language for a big system
4011 like pkgsrc requires some discipline to keep the code correct and 4011 like pkgsrc requires some discipline to keep the code correct and
4012 understandable.</p> 4012 understandable.</p>
4013<p>The basic ingredients for <code class="filename">Makefile</code> 4013<p>The basic ingredients for <code class="filename">Makefile</code>
4014 programming are variables (which are actually macros) and shell 4014 programming are variables (which are actually macros) and shell
4015 commands. Among these shell commands may even be more complex ones 4015 commands. Among these shell commands may even be more complex ones
4016 like <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?awk+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">awk</span>(1)</span></a> programs. To make sure that every shell command runs 4016 like <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?awk+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">awk</span>(1)</span></a> programs. To make sure that every shell command runs
4017 as intended it is necessary to quote all variables correctly when they 4017 as intended it is necessary to quote all variables correctly when they
4018 are used.</p> 4018 are used.</p>
4019<p>This chapter describes some patterns, that appear quite often in 4019<p>This chapter describes some patterns, that appear quite often in
4020 <code class="filename">Makefile</code>s, including the pitfalls that come along 4020 <code class="filename">Makefile</code>s, including the pitfalls that come along
4021 with them.</p> 4021 with them.</p>
4022<div class="sect1"> 4022<div class="sect1">
4023<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4023<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4024<a name="makefile.style"></a>12.1. Caveats</h2></div></div></div> 4024<a name="makefile.style"></a>12.1. Caveats</h2></div></div></div>
4025<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem"> 4025<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
4026<p>When you are creating a file as a 4026<p>When you are creating a file as a
4027 target of a rule, always write the data to a temporary file first 4027 target of a rule, always write the data to a temporary file first
4028 and finally rename that file. Otherwise there might occur an error 4028 and finally rename that file. Otherwise there might occur an error
4029 in the middle of generating the file, and when the user runs 4029 in the middle of generating the file, and when the user runs
4030 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> for the second time, the file exists and will not be 4030 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> for the second time, the file exists and will not be
4031 regenerated properly. Example:</p> 4031 regenerated properly. Example:</p>
4032<pre class="programlisting"> 4032<pre class="programlisting">
4033wrong: 4033wrong:
4034 @echo "line 1" &gt; ${.TARGET} 4034 @echo "line 1" &gt; ${.TARGET}
4035 @echo "line 2" &gt;&gt; ${.TARGET} 4035 @echo "line 2" &gt;&gt; ${.TARGET}
4036 @false 4036 @false
4037 4037
4038correct: 4038correct:
4039 @echo "line 1" &gt; ${.TARGET}.tmp 4039 @echo "line 1" &gt; ${.TARGET}.tmp
4040 @echo "line 2" &gt;&gt; ${.TARGET}.tmp 4040 @echo "line 2" &gt;&gt; ${.TARGET}.tmp
4041 @false 4041 @false
4042 @mv ${.TARGET}.tmp ${.TARGET} 4042 @mv ${.TARGET}.tmp ${.TARGET}
4043</pre> 4043</pre>
4044<p>When you run <span class="command"><strong>make wrong</strong></span> twice, the file 4044<p>When you run <span class="command"><strong>make wrong</strong></span> twice, the file
4045 <code class="filename">wrong</code> will exist, although there was an error 4045 <code class="filename">wrong</code> will exist, although there was an error
4046 message in the first run. On the other hand, running <span class="command"><strong>make 4046 message in the first run. On the other hand, running <span class="command"><strong>make
4047 correct</strong></span> gives an error message twice, as expected.</p> 4047 correct</strong></span> gives an error message twice, as expected.</p>
4048<p>You might remember that <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> sometimes removes 4048<p>You might remember that <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> sometimes removes
4049 <code class="literal">${.TARGET}</code> in case of error, but this only 4049 <code class="literal">${.TARGET}</code> in case of error, but this only
4050 happens when it is interrupted, for example by pressing 4050 happens when it is interrupted, for example by pressing
4051 <code class="literal">^C</code>. This does <span class="emphasis"><em>not</em></span> happen 4051 <code class="literal">^C</code>. This does <span class="emphasis"><em>not</em></span> happen
4052 when one of the commands fails (like <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?false+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">false</span>(1)</span></a> above).</p> 4052 when one of the commands fails (like <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?false+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">false</span>(1)</span></a> above).</p>
4053</li></ul></div> 4053</li></ul></div>
4054</div> 4054</div>
4055<div class="sect1"> 4055<div class="sect1">
4056<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4056<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4057<a name="makefile.variables"></a>12.2. <code class="filename">Makefile</code> variables</h2></div></div></div> 4057<a name="makefile.variables"></a>12.2. <code class="filename">Makefile</code> variables</h2></div></div></div>
4058<p><code class="filename">Makefile</code> variables contain strings that 4058<p><code class="filename">Makefile</code> variables contain strings that
4059 can be processed using the five operators ``='', ``+='', ``?='', 4059 can be processed using the five operators ``='', ``+='', ``?='',
4060 ``:='', and ``!='', which are described in the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> man 4060 ``:='', and ``!='', which are described in the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> man
4061 page.</p> 4061 page.</p>
4062<p>When a variable's value is parsed from a 4062<p>When a variable's value is parsed from a
4063 <code class="filename">Makefile</code>, the hash character ``#'' and the 4063 <code class="filename">Makefile</code>, the hash character ``#'' and the
4064 backslash character ``\'' are handled specially. If a backslash is 4064 backslash character ``\'' are handled specially. If a backslash is
4065 followed by a newline, any whitespace immediately in front of the 4065 followed by a newline, any whitespace immediately in front of the
4066 backslash, the backslash, the newline, and any whitespace 4066 backslash, the backslash, the newline, and any whitespace
4067 immediately behind the newline are replaced with a single space. A 4067 immediately behind the newline are replaced with a single space. A
4068 backslash character and an immediately following hash character are 4068 backslash character and an immediately following hash character are
4069 replaced with a single hash character. Otherwise, the backslash is 4069 replaced with a single hash character. Otherwise, the backslash is
4070 passed as is. In a variable assignment, any hash character that is 4070 passed as is. In a variable assignment, any hash character that is
4071 not preceded by a backslash starts a comment that continues upto the 4071 not preceded by a backslash starts a comment that continues upto the
4072 end of the logical line.</p> 4072 end of the logical line.</p>
4073<p>The evaluation of variables either happens immediately or lazy. 4073<p>The evaluation of variables either happens immediately or lazy.
4074 It happens immediately when the variable occurs 4074 It happens immediately when the variable occurs
4075 on the right-hand side of the ``:='' or the ``!='' operator, in a 4075 on the right-hand side of the ``:='' or the ``!='' operator, in a
4076 <code class="varname">.if</code> condition or a <code class="varname">.for</code> loop. 4076 <code class="varname">.if</code> condition or a <code class="varname">.for</code> loop.
4077 In the other cases, it is evaluated lazily.</p> 4077 In the other cases, it is evaluated lazily.</p>
4078<p>Some of the modifiers split the string into words and then 4078<p>Some of the modifiers split the string into words and then
4079 operate on the words, others operate on the string as a whole. When 4079 operate on the words, others operate on the string as a whole. When
4080 a string is split into words, it is split like in <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?sh+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">sh</span>(1)</span></a>.</p> 4080 a string is split into words, it is split like in <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?sh+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">sh</span>(1)</span></a>.</p>
4081<p>There are several types of variables that should be handled 4081<p>There are several types of variables that should be handled
4082 differently. Strings and two types of lists.</p> 4082 differently. Strings and two types of lists.</p>
4083<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 4083<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
4084<li class="listitem"><p><span class="emphasis"><em>Strings</em></span> can contain arbitrary 4084<li class="listitem"><p><span class="emphasis"><em>Strings</em></span> can contain arbitrary
4085 characters. Nevertheless, you should restrict yourself to only 4085 characters. Nevertheless, you should restrict yourself to only
4086 using printable characters. Examples are 4086 using printable characters. Examples are
4087 <code class="varname">PREFIX</code> and 4087 <code class="varname">PREFIX</code> and
4088 <code class="varname">COMMENT</code>.</p></li> 4088 <code class="varname">COMMENT</code>.</p></li>
4089<li class="listitem"><p><span class="emphasis"><em>Internal lists</em></span> are lists that 4089<li class="listitem"><p><span class="emphasis"><em>Internal lists</em></span> are lists that
4090 are never exported to any shell command. Their elements are 4090 are never exported to any shell command. Their elements are
4091 separated by whitespace. Therefore, the elements themselves cannot 4091 separated by whitespace. Therefore, the elements themselves cannot
4092 have embedded whitespace. Any other characters are allowed. 4092 have embedded whitespace. Any other characters are allowed.
4093 Internal lists can be used in <span class="command"><strong>.for</strong></span> loops. 4093 Internal lists can be used in <span class="command"><strong>.for</strong></span> loops.
@@ -4147,27 +4147,27 @@ STRING= foo bar < > * ` @@ -4147,27 +4147,27 @@ STRING= foo bar < > * `
4147EXAMPLE_ENV= string=${STRING:Q} x=multiple\ quoted\ words 4147EXAMPLE_ENV= string=${STRING:Q} x=multiple\ quoted\ words
4148 4148
4149all: 4149all:
4150 echo ${STRING} # 1 4150 echo ${STRING} # 1
4151 echo ${STRING:Q} # 2 4151 echo ${STRING:Q} # 2
4152 printf '%s\n' ${STRING:Q}'' # 3 4152 printf '%s\n' ${STRING:Q}'' # 3
4153 env ${EXAMPLE_ENV} sh -c 'echo "$$string"; echo "$$x"' # 4 4153 env ${EXAMPLE_ENV} sh -c 'echo "$$string"; echo "$$x"' # 4
4154</pre> 4154</pre>
4155<p>Example 1 leads to a syntax error in the shell, as the characters 4155<p>Example 1 leads to a syntax error in the shell, as the characters
4156are just copied.</p> 4156are just copied.</p>
4157<p>Example 2 quotes the string so that the shell interprets it 4157<p>Example 2 quotes the string so that the shell interprets it
4158correctly. But the echo command may additionally interpret strings with a 4158correctly. But the echo command may additionally interpret strings with a
4159leading dash or those containing backslashes.</p> 4159leading dash or those containing backslashes.</p>
4160<p>Example 3 can handle arbitrary strings, since <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?printf+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">printf</span>(1)</span></a> only 4160<p>Example 3 can handle arbitrary strings, since <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?printf+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">printf</span>(1)</span></a> only
4161interprets the format string, but not the next argument.</p> 4161interprets the format string, but not the next argument.</p>
4162<p>In example 4, the <code class="varname">EXAMPLE_ENV</code> does not 4162<p>In example 4, the <code class="varname">EXAMPLE_ENV</code> does not
4163need to be quoted because the quoting has already been done 4163need to be quoted because the quoting has already been done
4164when adding elements to the list.</p> 4164when adding elements to the list.</p>
4165</div> 4165</div>
4166<div class="sect2"> 4166<div class="sect2">
4167<div class="titlepage"><div><div><h3 class="title"> 4167<div class="titlepage"><div><div><h3 class="title">
4168<a name="cflags-gnu-configure"></a>12.3.3. Passing <code class="varname">CFLAGS</code> to GNU configure scripts</h3></div></div></div> 4168<a name="cflags-gnu-configure"></a>12.3.3. Passing <code class="varname">CFLAGS</code> to GNU configure scripts</h3></div></div></div>
4169<p>When passing <code class="varname">CFLAGS</code> or similar variables to a 4169<p>When passing <code class="varname">CFLAGS</code> or similar variables to a
4170GNU-style configure script (especially those that call other configure 4170GNU-style configure script (especially those that call other configure
4171scripts), it must not have leading or trailing whitespace, since 4171scripts), it must not have leading or trailing whitespace, since
4172otherwise the configure script gets confused. To trim leading and 4172otherwise the configure script gets confused. To trim leading and
4173trailing whitespace, use the <code class="code">:M</code> modifier, as in the 4173trailing whitespace, use the <code class="code">:M</code> modifier, as in the
@@ -4191,27 +4191,27 @@ space.

 @@ -4191,27 +4191,27 @@ space.

4191<div class="titlepage"><div><div><h3 class="title"> 4191<div class="titlepage"><div><div><h3 class="title">
4192<a name="empty-variables"></a>12.3.4. Handling possibly empty variables</h3></div></div></div> 4192<a name="empty-variables"></a>12.3.4. Handling possibly empty variables</h3></div></div></div>
4193<p>When a possibly empty variable is used in a shell program, it may 4193<p>When a possibly empty variable is used in a shell program, it may
4194lead to a syntax error.</p> 4194lead to a syntax error.</p>
4195<pre class="programlisting"> 4195<pre class="programlisting">
4196EGFILES= # empty 4196EGFILES= # empty
4197 4197
4198install-examples: # produces a syntax error in the shell 4198install-examples: # produces a syntax error in the shell
4199 for egfile in ${EGFILES}; do \ 4199 for egfile in ${EGFILES}; do \
4200 echo "Installing $$egfile"; \ 4200 echo "Installing $$egfile"; \
4201 done 4201 done
4202</pre> 4202</pre>
4203<p>The shell only sees the text <code class="code">for egfile in ; do</code>, since 4203<p>The shell only sees the text <code class="code">for egfile in ; do</code>, since
4204<code class="code">${EGFILES}</code> is replaced with an empty string by <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>. 4204<code class="code">${EGFILES}</code> is replaced with an empty string by <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>.
4205To fix this syntax error, use one of the snippets below.</p> 4205To fix this syntax error, use one of the snippets below.</p>
4206<pre class="programlisting"> 4206<pre class="programlisting">
4207EMPTY= # empty 4207EMPTY= # empty
4208 4208
4209install-examples: 4209install-examples:
4210 for egfile in ${EGFILES} ""; do \ 4210 for egfile in ${EGFILES} ""; do \
4211 [ -n "$$egfile" ] || continue; \ 4211 [ -n "$$egfile" ] || continue; \
4212 echo "Installing $$egfile"; \ 4212 echo "Installing $$egfile"; \
4213 done 4213 done
4214</pre> 4214</pre>
4215<p>In this case, an empty string is appended to the iteration list (to 4215<p>In this case, an empty string is appended to the iteration list (to
4216prevent the syntax error) and filtered out later.</p> 4216prevent the syntax error) and filtered out later.</p>
4217<pre class="programlisting"> 4217<pre class="programlisting">
@@ -4241,27 +4241,27 @@ the following code: $ @@ -4241,27 +4241,27 @@ the following code: $
4241<dt><span class="sect1"><a href="#print-PLIST">13.3. Tweaking output of <span class="command"><strong>make print-PLIST</strong></span></a></span></dt> 4241<dt><span class="sect1"><a href="#print-PLIST">13.3. Tweaking output of <span class="command"><strong>make print-PLIST</strong></span></a></span></dt>
4242<dt><span class="sect1"><a href="#plist.misc">13.4. Variable substitution in PLIST</a></span></dt> 4242<dt><span class="sect1"><a href="#plist.misc">13.4. Variable substitution in PLIST</a></span></dt>
4243<dt><span class="sect1"><a href="#manpage-compression">13.5. Man page compression</a></span></dt> 4243<dt><span class="sect1"><a href="#manpage-compression">13.5. Man page compression</a></span></dt>
4244<dt><span class="sect1"><a href="#using-PLIST_SRC">13.6. Changing PLIST source with <code class="varname">PLIST_SRC</code></a></span></dt> 4244<dt><span class="sect1"><a href="#using-PLIST_SRC">13.6. Changing PLIST source with <code class="varname">PLIST_SRC</code></a></span></dt>
4245<dt><span class="sect1"><a href="#platform-specific-plist">13.7. Platform-specific and differing PLISTs</a></span></dt> 4245<dt><span class="sect1"><a href="#platform-specific-plist">13.7. Platform-specific and differing PLISTs</a></span></dt>
4246<dt><span class="sect1"><a href="#build-plist">13.8. Build-specific PLISTs</a></span></dt> 4246<dt><span class="sect1"><a href="#build-plist">13.8. Build-specific PLISTs</a></span></dt>
4247<dt><span class="sect1"><a href="#faq.common-dirs">13.9. Sharing directories between packages</a></span></dt> 4247<dt><span class="sect1"><a href="#faq.common-dirs">13.9. Sharing directories between packages</a></span></dt>
4248</dl> 4248</dl>
4249</div> 4249</div>
4250<p>The <code class="filename">PLIST</code> file contains a package's 4250<p>The <code class="filename">PLIST</code> file contains a package's
4251 <span class="quote">&#8220;<span class="quote">packing list</span>&#8221;</span>, i.e. a list of files that belong to 4251 <span class="quote">&#8220;<span class="quote">packing list</span>&#8221;</span>, i.e. a list of files that belong to
4252 the package (relative to the <code class="filename">${PREFIX}</code> 4252 the package (relative to the <code class="filename">${PREFIX}</code>
4253 directory it's been installed in) plus some additional statements 4253 directory it's been installed in) plus some additional statements
4254 - see the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> man page for a full list. 4254 - see the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_create+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_create</span>(1)</span></a> man page for a full list.
4255 This chapter addresses some issues that need attention when 4255 This chapter addresses some issues that need attention when
4256 dealing with the <code class="filename">PLIST</code> file (or files, see 4256 dealing with the <code class="filename">PLIST</code> file (or files, see
4257 below!).</p> 4257 below!).</p>
4258<div class="sect1"> 4258<div class="sect1">
4259<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4259<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4260<a name="rcs-id"></a>13.1. RCS ID</h2></div></div></div> 4260<a name="rcs-id"></a>13.1. RCS ID</h2></div></div></div>
4261<p>Be sure to add a RCS ID line as the first thing in any 4261<p>Be sure to add a RCS ID line as the first thing in any
4262 <code class="filename">PLIST</code> file you write:</p> 4262 <code class="filename">PLIST</code> file you write:</p>
4263<pre class="programlisting"> 4263<pre class="programlisting">
4264@comment $NetBSD $ 4264@comment $NetBSD $
4265</pre> 4265</pre>
4266<p>An artificial space has been added between NetBSD and $, this is a 4266<p>An artificial space has been added between NetBSD and $, this is a
4267workaround here to prevent CVS expanding to the filename of the guide. When 4267workaround here to prevent CVS expanding to the filename of the guide. When
@@ -4385,27 +4385,27 @@ adding the RCS ID the space should be om @@ -4385,27 +4385,27 @@ adding the RCS ID the space should be om
4385 appended/removed automatically for man pages according to 4385 appended/removed automatically for man pages according to
4386 <code class="varname">MANZ</code> and <code class="varname">MANCOMPRESSED</code> being set 4386 <code class="varname">MANZ</code> and <code class="varname">MANCOMPRESSED</code> being set
4387 or not, see above for details. This modification of the 4387 or not, see above for details. This modification of the
4388 <code class="filename">PLIST</code> file is done on a copy of it, not 4388 <code class="filename">PLIST</code> file is done on a copy of it, not
4389 <code class="filename">PLIST</code> itself.</p> 4389 <code class="filename">PLIST</code> itself.</p>
4390</div> 4390</div>
4391<div class="sect1"> 4391<div class="sect1">
4392<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4392<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4393<a name="using-PLIST_SRC"></a>13.6. Changing PLIST source with <code class="varname">PLIST_SRC</code> 4393<a name="using-PLIST_SRC"></a>13.6. Changing PLIST source with <code class="varname">PLIST_SRC</code>
4394</h2></div></div></div> 4394</h2></div></div></div>
4395<p>To use one or more files as source for the <code class="filename">PLIST</code> used 4395<p>To use one or more files as source for the <code class="filename">PLIST</code> used
4396 in generating the binary package, set the variable 4396 in generating the binary package, set the variable
4397 <code class="varname">PLIST_SRC</code> to the names of that file(s). 4397 <code class="varname">PLIST_SRC</code> to the names of that file(s).
4398 The files are later concatenated using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cat+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">cat</span>(1)</span></a>, and the order of things is 4398 The files are later concatenated using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cat+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">cat</span>(1)</span></a>, and the order of things is
4399 important. The default for <code class="varname">PLIST_SRC</code> is 4399 important. The default for <code class="varname">PLIST_SRC</code> is
4400 <code class="filename">${PKGDIR}/PLIST</code>.</p> 4400 <code class="filename">${PKGDIR}/PLIST</code>.</p>
4401</div> 4401</div>
4402<div class="sect1"> 4402<div class="sect1">
4403<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4403<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4404<a name="platform-specific-plist"></a>13.7. Platform-specific and differing PLISTs</h2></div></div></div> 4404<a name="platform-specific-plist"></a>13.7. Platform-specific and differing PLISTs</h2></div></div></div>
4405<p>Some packages decide to install a different set of files based on 4405<p>Some packages decide to install a different set of files based on
4406 the operating system being used. These differences can be 4406 the operating system being used. These differences can be
4407 automatically handled by using the following files:</p> 4407 automatically handled by using the following files:</p>
4408<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 4408<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
4409<li class="listitem"><p><code class="filename">PLIST.common</code></p></li> 4409<li class="listitem"><p><code class="filename">PLIST.common</code></p></li>
4410<li class="listitem"><p><code class="filename">PLIST.${OPSYS}</code></p></li> 4410<li class="listitem"><p><code class="filename">PLIST.${OPSYS}</code></p></li>
4411<li class="listitem"><p><code class="filename">PLIST.${MACHINE_ARCH}</code></p></li> 4411<li class="listitem"><p><code class="filename">PLIST.${MACHINE_ARCH}</code></p></li>
@@ -4542,77 +4542,77 @@ DEPENDS+= foo>=1.1.0:../../cate @@ -4542,77 +4542,77 @@ DEPENDS+= foo>=1.1.0:../../cate
4542BUILDLINK_API_DEPENDS.foo+= foo&gt;=1.1.0 4542BUILDLINK_API_DEPENDS.foo+= foo&gt;=1.1.0
4543.include "../../category/foo/buildlink3.mk" 4543.include "../../category/foo/buildlink3.mk"
4544</pre> 4544</pre>
4545<p>There are several <code class="filename">buildlink3.mk</code> 4545<p>There are several <code class="filename">buildlink3.mk</code>
4546 files in <code class="filename">pkgsrc/mk</code> 4546 files in <code class="filename">pkgsrc/mk</code>
4547 that handle special package issues:</p> 4547 that handle special package issues:</p>
4548<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 4548<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
4549<li class="listitem"><p><code class="filename">bdb.buildlink3.mk</code> chooses either 4549<li class="listitem"><p><code class="filename">bdb.buildlink3.mk</code> chooses either
4550 the native or a pkgsrc Berkeley DB implementation based on 4550 the native or a pkgsrc Berkeley DB implementation based on
4551 the values of <code class="varname">BDB_ACCEPTED</code> and 4551 the values of <code class="varname">BDB_ACCEPTED</code> and
4552 <code class="varname">BDB_DEFAULT</code>.</p></li> 4552 <code class="varname">BDB_DEFAULT</code>.</p></li>
4553<li class="listitem"><p><code class="filename">curses.buildlink3.mk</code>: If the system 4553<li class="listitem"><p><code class="filename">curses.buildlink3.mk</code>: If the system
4554 comes with neither Curses nor NCurses, this will take care 4554 comes with neither Curses nor NCurses, this will take care
4555 to install the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/ncurses/README.html" target="_top"><code class="filename">devel/ncurses</code></a> package.</p></li> 4555 to install the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/ncurses/README.html" target="_top"><code class="filename">devel/ncurses</code></a> package.</p></li>
4556<li class="listitem"><p><code class="filename">krb5.buildlink3.mk</code> uses the value 4556<li class="listitem"><p><code class="filename">krb5.buildlink3.mk</code> uses the value
4557 of <code class="varname">KRB5_ACCEPTED</code> to choose between 4557 of <code class="varname">KRB5_ACCEPTED</code> to choose between
4558 adding a dependency on Heimdal or MIT-krb5 for packages that 4558 adding a dependency on Heimdal or MIT-krb5 for packages that
4559 require a Kerberos 5 implementation.</p></li> 4559 require a Kerberos 5 implementation.</p></li>
4560<li class="listitem"><p><code class="filename">motif.buildlink3.mk</code> checks for a 4560<li class="listitem"><p><code class="filename">motif.buildlink3.mk</code> checks for a
4561 system-provided Motif installation or adds a dependency on 4561 system-provided Motif installation or adds a dependency on
4562 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/lesstif/README.html" target="_top"><code class="filename">x11/lesstif</code></a> or <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/motif/README.html" target="_top"><code class="filename">x11/motif</code></a>. The user can set 4562 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/lesstif/README.html" target="_top"><code class="filename">x11/lesstif</code></a> or <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/x11/motif/README.html" target="_top"><code class="filename">x11/motif</code></a>. The user can set
4563 <code class="varname">MOTIF_TYPE</code> to <span class="quote">&#8220;<span class="quote">dt</span>&#8221;</span>, 4563 <code class="varname">MOTIF_TYPE</code> to <span class="quote">&#8220;<span class="quote">dt</span>&#8221;</span>,
4564 <span class="quote">&#8220;<span class="quote">lesstif</span>&#8221;</span> or <span class="quote">&#8220;<span class="quote">motif</span>&#8221;</span> 4564 <span class="quote">&#8220;<span class="quote">lesstif</span>&#8221;</span> or <span class="quote">&#8220;<span class="quote">motif</span>&#8221;</span>
4565 to choose which Motif version will be used.</p></li> 4565 to choose which Motif version will be used.</p></li>
4566<li class="listitem"><p><code class="filename">readline.buildlink3.mk</code> checks for a 4566<li class="listitem"><p><code class="filename">readline.buildlink3.mk</code> checks for a
4567 system-provided GNU readline or editline (libedit) installation, 4567 system-provided GNU readline or editline (libedit) installation,
4568 or adds a dependency on <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/readline/README.html" target="_top"><code class="filename">devel/readline</code></a>, 4568 or adds a dependency on <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/readline/README.html" target="_top"><code class="filename">devel/readline</code></a>,
4569 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/editline/README.html" target="_top"><code class="filename">devel/editline</code></a>. The user can set 4569 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/editline/README.html" target="_top"><code class="filename">devel/editline</code></a>. The user can set
4570 <code class="varname">READLINE_DEFAULT</code> to choose readline implementation. 4570 <code class="varname">READLINE_DEFAULT</code> to choose readline implementation.
4571 If your package really needs GNU readline library, its Makefile 4571 If your package really needs GNU readline library, its Makefile
4572 should include <code class="filename">devel/readline/buildlink3.mk</code> 4572 should include <code class="filename">devel/readline/buildlink3.mk</code>
4573 instead of <code class="filename">readline.buildlink3.mk</code>.</p></li> 4573 instead of <code class="filename">readline.buildlink3.mk</code>.</p></li>
4574<li class="listitem"><p><code class="filename">oss.buildlink3.mk</code> defines several 4574<li class="listitem"><p><code class="filename">oss.buildlink3.mk</code> defines several
4575 variables that may be used by packages that use the 4575 variables that may be used by packages that use the
4576 Open Sound System (OSS) API.</p></li> 4576 Open Sound System (OSS) API.</p></li>
4577<li class="listitem"><p><code class="filename">pgsql.buildlink3.mk</code> will accept 4577<li class="listitem"><p><code class="filename">pgsql.buildlink3.mk</code> will accept
4578 any of the Postgres versions in the variable 4578 any of the Postgres versions in the variable
4579 <code class="varname">PGSQL_VERSIONS_ACCEPTED</code> and default to 4579 <code class="varname">PGSQL_VERSIONS_ACCEPTED</code> and default to
4580 the version <code class="varname">PGSQL_VERSION_DEFAULT</code>. See 4580 the version <code class="varname">PGSQL_VERSION_DEFAULT</code>. See
4581 the file for more information.</p></li> 4581 the file for more information.</p></li>
4582<li class="listitem"><p><code class="filename">pthread.buildlink3.mk</code> uses the value of 4582<li class="listitem"><p><code class="filename">pthread.buildlink3.mk</code> uses the value of
4583 <code class="varname">PTHREAD_OPTS</code> and checks for native pthreads or adds 4583 <code class="varname">PTHREAD_OPTS</code> and checks for native pthreads or adds
4584 a dependency on <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/pth/README.html" target="_top"><code class="filename">devel/pth</code></a> as needed.</p></li> 4584 a dependency on <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/pth/README.html" target="_top"><code class="filename">devel/pth</code></a> as needed.</p></li>
4585<li class="listitem"><p><code class="filename">xaw.buildlink3.mk</code> uses the value of 4585<li class="listitem"><p><code class="filename">xaw.buildlink3.mk</code> uses the value of
4586 <code class="varname">XAW_TYPE</code> to choose a particular Athena widgets 4586 <code class="varname">XAW_TYPE</code> to choose a particular Athena widgets
4587 library.</p></li> 4587 library.</p></li>
4588</ul></div> 4588</ul></div>
4589<p>The comments in those <code class="filename">buildlink3.mk</code> 4589<p>The comments in those <code class="filename">buildlink3.mk</code>
4590 files provide a more complete 4590 files provide a more complete
4591 description of how to use them properly.</p> 4591 description of how to use them properly.</p>
4592</div> 4592</div>
4593<div class="sect1"> 4593<div class="sect1">
4594<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 4594<div class="titlepage"><div><div><h2 class="title" style="clear: both">
4595<a name="creating-buildlink3.mk"></a>14.2. Writing <code class="filename">buildlink3.mk</code> files</h2></div></div></div> 4595<a name="creating-buildlink3.mk"></a>14.2. Writing <code class="filename">buildlink3.mk</code> files</h2></div></div></div>
4596<a name="buildlink3.mk"></a><p>A package's <code class="filename">buildlink3.mk</code> file is 4596<a name="buildlink3.mk"></a><p>A package's <code class="filename">buildlink3.mk</code> file is
4597 included by Makefiles to indicate the need to compile and link 4597 included by Makefiles to indicate the need to compile and link
4598 against header files and libraries provided by the package. A 4598 against header files and libraries provided by the package. A
4599 <code class="filename">buildlink3.mk</code> file should always provide 4599 <code class="filename">buildlink3.mk</code> file should always provide
4600 enough information to add the correct type of dependency 4600 enough information to add the correct type of dependency
4601 relationship and include any other 4601 relationship and include any other
4602 <code class="filename">buildlink3.mk</code> files that it needs to find 4602 <code class="filename">buildlink3.mk</code> files that it needs to find
4603 headers and libraries that it needs in turn.</p> 4603 headers and libraries that it needs in turn.</p>
4604<p>To generate an initial <code class="filename">buildlink3.mk</code> 4604<p>To generate an initial <code class="filename">buildlink3.mk</code>
4605 file for further editing, Rene Hexel's <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/createbuildlink/README.html" target="_top"><code class="filename">pkgtools/createbuildlink</code></a> 4605 file for further editing, Rene Hexel's <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/createbuildlink/README.html" target="_top"><code class="filename">pkgtools/createbuildlink</code></a>
4606 package is highly recommended. For most packages, the following 4606 package is highly recommended. For most packages, the following
4607 command will generate a good starting point for 4607 command will generate a good starting point for
4608 <code class="filename">buildlink3.mk</code> files:</p> 4608 <code class="filename">buildlink3.mk</code> files:</p>
4609<pre class="screen"> 4609<pre class="screen">
4610<code class="prompt">%</code> <strong class="userinput"><code>cd pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>pkgdir</code></em> 4610<code class="prompt">%</code> <strong class="userinput"><code>cd pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>pkgdir</code></em>
4611<code class="prompt">%</code> createbuildlink &gt;buildlink3.mk</code></strong> 4611<code class="prompt">%</code> createbuildlink &gt;buildlink3.mk</code></strong>
4612 </pre> 4612 </pre>
4613<div class="sect2"> 4613<div class="sect2">
4614<div class="titlepage"><div><div><h3 class="title"> 4614<div class="titlepage"><div><div><h3 class="title">
4615<a name="anatomy-of-bl3"></a>14.2.1. Anatomy of a buildlink3.mk file</h3></div></div></div> 4615<a name="anatomy-of-bl3"></a>14.2.1. Anatomy of a buildlink3.mk file</h3></div></div></div>
4616<p>The following real-life example 4616<p>The following real-life example
4617 <code class="filename">buildlink3.mk</code> is taken 4617 <code class="filename">buildlink3.mk</code> is taken
4618 from <code class="filename">pkgsrc/graphics/tiff</code>:</p> 4618 from <code class="filename">pkgsrc/graphics/tiff</code>:</p>
@@ -5130,27 +5130,27 @@ set based upon the following variables:< @@ -5130,27 +5130,27 @@ set based upon the following variables:<
5130<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 5130<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
5131<li class="listitem"><p><code class="varname">PKG_SYSCONFBASE</code>: The configuration's root 5131<li class="listitem"><p><code class="varname">PKG_SYSCONFBASE</code>: The configuration's root
5132 directory. Defaults to <code class="filename">${PREFIX}/etc</code> although it may 5132 directory. Defaults to <code class="filename">${PREFIX}/etc</code> although it may
5133 be overridden by the user to point to his preferred location (e.g., 5133 be overridden by the user to point to his preferred location (e.g.,
5134 <code class="filename">/etc</code>, <code class="filename">/etc/pkg</code>, etc.). 5134 <code class="filename">/etc</code>, <code class="filename">/etc/pkg</code>, etc.).
5135 Packages must not use it directly.</p></li> 5135 Packages must not use it directly.</p></li>
5136<li class="listitem"> 5136<li class="listitem">
5137<p><code class="varname">PKG_SYSCONFSUBDIR</code>: A subdirectory of 5137<p><code class="varname">PKG_SYSCONFSUBDIR</code>: A subdirectory of
5138 <code class="varname">PKG_SYSCONFBASE</code> under which the configuration files 5138 <code class="varname">PKG_SYSCONFBASE</code> under which the configuration files
5139 for the package being built shall be installed. The definition of this 5139 for the package being built shall be installed. The definition of this
5140 variable only makes sense in the package's 5140 variable only makes sense in the package's
5141 <code class="filename">Makefile</code> (i.e., it is not user-customizable).</p> 5141 <code class="filename">Makefile</code> (i.e., it is not user-customizable).</p>
5142<p>As an example, consider the Apache package, 5142<p>As an example, consider the Apache package,
5143 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/apache24/README.html" target="_top"><code class="filename">www/apache24</code></a>, which places its 5143 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/apache24/README.html" target="_top"><code class="filename">www/apache24</code></a>, which places its
5144 configuration files under the 5144 configuration files under the
5145 <code class="filename">httpd/</code> subdirectory of 5145 <code class="filename">httpd/</code> subdirectory of
5146 <code class="varname">PKG_SYSCONFBASE</code>. This should be set in the package 5146 <code class="varname">PKG_SYSCONFBASE</code>. This should be set in the package
5147 Makefile.</p> 5147 Makefile.</p>
5148</li> 5148</li>
5149<li class="listitem"><p><code class="varname">PKG_SYSCONFVAR</code>: Specifies the name of the 5149<li class="listitem"><p><code class="varname">PKG_SYSCONFVAR</code>: Specifies the name of the
5150 variable that holds this package's configuration directory (if 5150 variable that holds this package's configuration directory (if
5151 different from <code class="varname">PKG_SYSCONFBASE</code>). It defaults to 5151 different from <code class="varname">PKG_SYSCONFBASE</code>). It defaults to
5152 <code class="varname">PKGBASE</code>'s value, and is always prefixed with 5152 <code class="varname">PKGBASE</code>'s value, and is always prefixed with
5153 <code class="literal">PKG_SYSCONFDIR</code>.</p></li> 5153 <code class="literal">PKG_SYSCONFDIR</code>.</p></li>
5154<li class="listitem"><p><code class="varname">PKG_SYSCONFDIR.${PKG_SYSCONFVAR}</code>: Holds the 5154<li class="listitem"><p><code class="varname">PKG_SYSCONFDIR.${PKG_SYSCONFVAR}</code>: Holds the
5155 directory where the configuration files for the package identified by 5155 directory where the configuration files for the package identified by
5156 <code class="varname">PKG_SYSCONFVAR</code>'s shall be placed.</p></li> 5156 <code class="varname">PKG_SYSCONFVAR</code>'s shall be placed.</p></li>
@@ -5203,27 +5203,27 @@ will, out of the box, mess with the cont @@ -5203,27 +5203,27 @@ will, out of the box, mess with the cont
5203the correct procedure to fix this issue?</p> 5203the correct procedure to fix this issue?</p>
5204<p>You must teach the package (usually by manually patching it) to 5204<p>You must teach the package (usually by manually patching it) to
5205install any configuration files under the examples hierarchy, 5205install any configuration files under the examples hierarchy,
5206<code class="filename">share/examples/${PKGBASE}/</code>. This way, the 5206<code class="filename">share/examples/${PKGBASE}/</code>. This way, the
5207<code class="filename">PLIST</code> registers them and the administrator always 5207<code class="filename">PLIST</code> registers them and the administrator always
5208has the original copies available.</p> 5208has the original copies available.</p>
5209<p>Once the required configuration files are in place (i.e., under the 5209<p>Once the required configuration files are in place (i.e., under the
5210examples hierarchy), the pkginstall framework can use them as master copies 5210examples hierarchy), the pkginstall framework can use them as master copies
5211during the package installation to update what is in 5211during the package installation to update what is in
5212<code class="filename">${PKG_SYSCONFDIR}</code>. To achieve this, the variables 5212<code class="filename">${PKG_SYSCONFDIR}</code>. To achieve this, the variables
5213<code class="varname">CONF_FILES</code> and <code class="varname">CONF_FILES_PERMS</code> are 5213<code class="varname">CONF_FILES</code> and <code class="varname">CONF_FILES_PERMS</code> are
5214used. Check out <a class="xref" href="#files-outside-prefix" title="15.1.2. File manipulation">Section 15.1.2, &#8220;File manipulation&#8221;</a> for information 5214used. Check out <a class="xref" href="#files-outside-prefix" title="15.1.2. File manipulation">Section 15.1.2, &#8220;File manipulation&#8221;</a> for information
5215about their syntax and their purpose. Here is an example, taken from the 5215about their syntax and their purpose. Here is an example, taken from the
5216<a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/mail/mutt/README.html" target="_top"><code class="filename">mail/mutt</code></a> package:</p> 5216<a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/mail/mutt/README.html" target="_top"><code class="filename">mail/mutt</code></a> package:</p>
5217<pre class="programlisting"> 5217<pre class="programlisting">
5218EGDIR= ${PREFIX}/share/doc/mutt/samples 5218EGDIR= ${PREFIX}/share/doc/mutt/samples
5219CONF_FILES= ${EGDIR}/Muttrc ${PKG_SYSCONFDIR}/Muttrc 5219CONF_FILES= ${EGDIR}/Muttrc ${PKG_SYSCONFDIR}/Muttrc
5220</pre> 5220</pre>
5221<p>Note that the <code class="varname">EGDIR</code> variable is specific to that 5221<p>Note that the <code class="varname">EGDIR</code> variable is specific to that
5222package and has no meaning outside it.</p> 5222package and has no meaning outside it.</p>
5223</div> 5223</div>
5224<div class="sect2"> 5224<div class="sect2">
5225<div class="titlepage"><div><div><h3 class="title"> 5225<div class="titlepage"><div><div><h3 class="title">
5226<a name="conf-files-disable"></a>15.2.4. Disabling handling of configuration files</h3></div></div></div> 5226<a name="conf-files-disable"></a>15.2.4. Disabling handling of configuration files</h3></div></div></div>
5227<p>The automatic copying of config files can be toggled by setting the 5227<p>The automatic copying of config files can be toggled by setting the
5228environment variable <code class="varname">PKG_CONFIG</code> prior to package 5228environment variable <code class="varname">PKG_CONFIG</code> prior to package
5229installation.</p> 5229installation.</p>
@@ -5232,27 +5232,27 @@ installation.

 @@ -5232,27 +5232,27 @@ installation.

5232<div class="sect1"> 5232<div class="sect1">
5233<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5233<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5234<a name="rcd-scripts"></a>15.3. System startup scripts</h2></div></div></div> 5234<a name="rcd-scripts"></a>15.3. System startup scripts</h2></div></div></div>
5235<p>System startup scripts are special files because they must be 5235<p>System startup scripts are special files because they must be
5236installed in a place known by the underlying OS, usually outside the 5236installed in a place known by the underlying OS, usually outside the
5237installation prefix. Therefore, the same rules described in <a class="xref" href="#files-and-dirs-outside-prefix" title="15.1. Files and directories outside the installation prefix">Section 15.1, &#8220;Files and directories outside the installation prefix&#8221;</a> apply, and the same solutions 5237installation prefix. Therefore, the same rules described in <a class="xref" href="#files-and-dirs-outside-prefix" title="15.1. Files and directories outside the installation prefix">Section 15.1, &#8220;Files and directories outside the installation prefix&#8221;</a> apply, and the same solutions
5238can be used. However, pkginstall provides a special mechanism to handle 5238can be used. However, pkginstall provides a special mechanism to handle
5239these files.</p> 5239these files.</p>
5240<p>In order to provide system startup scripts, the package has 5240<p>In order to provide system startup scripts, the package has
5241to:</p> 5241to:</p>
5242<div class="orderedlist"><ol class="orderedlist" type="1"> 5242<div class="orderedlist"><ol class="orderedlist" type="1">
5243<li class="listitem"><p>Store the script inside <code class="filename">${FILESDIR}</code>, with 5243<li class="listitem"><p>Store the script inside <code class="filename">${FILESDIR}</code>, with
5244 the <code class="literal">.sh</code> suffix appended. Considering the 5244 the <code class="literal">.sh</code> suffix appended. Considering the
5245 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/cups/README.html" target="_top"><code class="filename">print/cups</code></a> package as an example, it has a 5245 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/cups/README.html" target="_top"><code class="filename">print/cups</code></a> package as an example, it has a
5246 <code class="filename">cupsd.sh</code> in its files directory.</p></li> 5246 <code class="filename">cupsd.sh</code> in its files directory.</p></li>
5247<li class="listitem"> 5247<li class="listitem">
5248<p>Tell pkginstall to handle it, appending the name of the script, 5248<p>Tell pkginstall to handle it, appending the name of the script,
5249 without its extension, to the <code class="varname">RCD_SCRIPTS</code> variable. 5249 without its extension, to the <code class="varname">RCD_SCRIPTS</code> variable.
5250 Continuing the previous example:</p> 5250 Continuing the previous example:</p>
5251<pre class="programlisting"> 5251<pre class="programlisting">
5252RCD_SCRIPTS+= cupsd 5252RCD_SCRIPTS+= cupsd
5253</pre> 5253</pre>
5254</li> 5254</li>
5255</ol></div> 5255</ol></div>
5256<p>Once this is done, pkginstall will do the following steps for each 5256<p>Once this is done, pkginstall will do the following steps for each
5257script in an automated fashion:</p> 5257script in an automated fashion:</p>
5258<div class="orderedlist"><ol class="orderedlist" type="1"> 5258<div class="orderedlist"><ol class="orderedlist" type="1">
@@ -5316,53 +5316,53 @@ of the created users and groups are auto @@ -5316,53 +5316,53 @@ of the created users and groups are auto
5316final installation scripts.</p> 5316final installation scripts.</p>
5317</div> 5317</div>
5318<div class="sect1"> 5318<div class="sect1">
5319<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5319<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5320<a name="shells"></a>15.5. System shells</h2></div></div></div> 5320<a name="shells"></a>15.5. System shells</h2></div></div></div>
5321<p>Packages that install system shells should register them in the shell 5321<p>Packages that install system shells should register them in the shell
5322database, <code class="filename">/etc/shells</code>, to make things easier to the 5322database, <code class="filename">/etc/shells</code>, to make things easier to the
5323administrator. This must be done from the installation scripts to keep 5323administrator. This must be done from the installation scripts to keep
5324binary packages working on any system. pkginstall provides an easy way to 5324binary packages working on any system. pkginstall provides an easy way to
5325accomplish this task.</p> 5325accomplish this task.</p>
5326<p>When a package provides a shell interpreter, it has to set the 5326<p>When a package provides a shell interpreter, it has to set the
5327<code class="varname">PKG_SHELL</code> variable to its absolute file name. This will 5327<code class="varname">PKG_SHELL</code> variable to its absolute file name. This will
5328add some hooks to the installation scripts to handle it. Consider the 5328add some hooks to the installation scripts to handle it. Consider the
5329following example, taken from <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/shells/zsh/README.html" target="_top"><code class="filename">shells/zsh</code></a>:</p> 5329following example, taken from <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/shells/zsh/README.html" target="_top"><code class="filename">shells/zsh</code></a>:</p>
5330<pre class="programlisting"> 5330<pre class="programlisting">
5331PKG_SHELL= ${PREFIX}/bin/zsh 5331PKG_SHELL= ${PREFIX}/bin/zsh
5332</pre> 5332</pre>
5333<div class="sect2"> 5333<div class="sect2">
5334<div class="titlepage"><div><div><h3 class="title"> 5334<div class="titlepage"><div><div><h3 class="title">
5335<a name="shells-disable"></a>15.5.1. Disabling shell registration</h3></div></div></div> 5335<a name="shells-disable"></a>15.5.1. Disabling shell registration</h3></div></div></div>
5336<p>The automatic registration of shell interpreters can be disabled by 5336<p>The automatic registration of shell interpreters can be disabled by
5337the administrator by setting the <code class="filename">PKG_REGISTER_SHELLS</code> 5337the administrator by setting the <code class="filename">PKG_REGISTER_SHELLS</code>
5338environment variable to <code class="literal">NO</code>.</p> 5338environment variable to <code class="literal">NO</code>.</p>
5339</div> 5339</div>
5340</div> 5340</div>
5341<div class="sect1"> 5341<div class="sect1">
5342<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5342<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5343<a name="fonts"></a>15.6. Fonts</h2></div></div></div> 5343<a name="fonts"></a>15.6. Fonts</h2></div></div></div>
5344<p>Packages that install X11 fonts should update the database files 5344<p>Packages that install X11 fonts should update the database files
5345that index the fonts within each fonts directory. This can easily be 5345that index the fonts within each fonts directory. This can easily be
5346accomplished within the pkginstall framework.</p> 5346accomplished within the pkginstall framework.</p>
5347<p>When a package installs X11 fonts, it must list the directories in 5347<p>When a package installs X11 fonts, it must list the directories in
5348which fonts are installed in the 5348which fonts are installed in the
5349<code class="varname">FONTS_DIRS.<em class="replaceable"><code>type</code></em></code> variables, 5349<code class="varname">FONTS_DIRS.<em class="replaceable"><code>type</code></em></code> variables,
5350where <em class="replaceable"><code>type</code></em> can be one of <span class="quote">&#8220;<span class="quote">ttf</span>&#8221;</span>, 5350where <em class="replaceable"><code>type</code></em> can be one of <span class="quote">&#8220;<span class="quote">ttf</span>&#8221;</span>,
5351<span class="quote">&#8220;<span class="quote">type1</span>&#8221;</span> or <span class="quote">&#8220;<span class="quote">x11</span>&#8221;</span>. This will add hooks to the 5351<span class="quote">&#8220;<span class="quote">type1</span>&#8221;</span> or <span class="quote">&#8220;<span class="quote">x11</span>&#8221;</span>. This will add hooks to the
5352installation scripts to run the appropriate commands to update the fonts 5352installation scripts to run the appropriate commands to update the fonts
5353database files within each of those directories. For convenience, if the 5353database files within each of those directories. For convenience, if the
5354directory path is relative, it is taken to be relative to the package's 5354directory path is relative, it is taken to be relative to the package's
5355installation prefix. Consider the following example, taken from <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/fonts/dbz-ttf/README.html" target="_top"><code class="filename">fonts/dbz-ttf</code></a>:</p> 5355installation prefix. Consider the following example, taken from <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/fonts/dbz-ttf/README.html" target="_top"><code class="filename">fonts/dbz-ttf</code></a>:</p>
5356<pre class="programlisting"> 5356<pre class="programlisting">
5357FONTS_DIRS.ttf= ${PREFIX}/share/fonts/X11/TTF 5357FONTS_DIRS.ttf= ${PREFIX}/share/fonts/X11/TTF
5358</pre> 5358</pre>
5359<div class="sect2"> 5359<div class="sect2">
5360<div class="titlepage"><div><div><h3 class="title"> 5360<div class="titlepage"><div><div><h3 class="title">
5361<a name="fonts-disable"></a>15.6.1. Disabling automatic update of the fonts databases</h3></div></div></div> 5361<a name="fonts-disable"></a>15.6.1. Disabling automatic update of the fonts databases</h3></div></div></div>
5362<p>The automatic update of fonts databases can be disabled by 5362<p>The automatic update of fonts databases can be disabled by
5363the administrator by setting the <code class="filename">PKG_UPDATE_FONTS_DB</code> 5363the administrator by setting the <code class="filename">PKG_UPDATE_FONTS_DB</code>
5364environment variable to <code class="literal">NO</code>.</p> 5364environment variable to <code class="literal">NO</code>.</p>
5365</div> 5365</div>
5366</div> 5366</div>
5367</div> 5367</div>
5368<div class="chapter"> 5368<div class="chapter">
@@ -5471,27 +5471,27 @@ CONFIGURE_ARGS+= --enable-ldap=${BUIL @@ -5471,27 +5471,27 @@ CONFIGURE_ARGS+= --enable-ldap=${BUIL
5471### 5471###
5472.if !empty(PKG_OPTIONS:Mmysql) 5472.if !empty(PKG_OPTIONS:Mmysql)
5473. include "../../mk/mysql.buildlink3.mk" 5473. include "../../mk/mysql.buildlink3.mk"
5474.endif 5474.endif
5475.if !empty(PKG_OPTIONS:Mpgsql) 5475.if !empty(PKG_OPTIONS:Mpgsql)
5476. include "../../mk/pgsql.buildlink3.mk" 5476. include "../../mk/pgsql.buildlink3.mk"
5477.endif 5477.endif
5478</pre> 5478</pre>
5479<p>The first section contains the information about which build 5479<p>The first section contains the information about which build
5480options are supported by the package, and any default options settings 5480options are supported by the package, and any default options settings
5481if needed.</p> 5481if needed.</p>
5482<div class="orderedlist"><ol class="orderedlist" type="1"> 5482<div class="orderedlist"><ol class="orderedlist" type="1">
5483<li class="listitem"><p><code class="varname">PKG_OPTIONS_VAR</code> is the name of the 5483<li class="listitem"><p><code class="varname">PKG_OPTIONS_VAR</code> is the name of the
5484<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> variable that the user can set to override the default 5484<a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> variable that the user can set to override the default
5485options. It should be set to 5485options. It should be set to
5486PKG_OPTIONS.<em class="replaceable"><code>pkgbase</code></em>. Do not set it to 5486PKG_OPTIONS.<em class="replaceable"><code>pkgbase</code></em>. Do not set it to
5487PKG_OPTIONS.${PKGBASE}, since <code class="varname">PKGBASE</code> is not defined 5487PKG_OPTIONS.${PKGBASE}, since <code class="varname">PKGBASE</code> is not defined
5488at the point where the options are processed.</p></li> 5488at the point where the options are processed.</p></li>
5489<li class="listitem"><p><code class="varname">PKG_SUPPORTED_OPTIONS</code> is a list of 5489<li class="listitem"><p><code class="varname">PKG_SUPPORTED_OPTIONS</code> is a list of
5490build options supported by the package.</p></li> 5490build options supported by the package.</p></li>
5491<li class="listitem"><p><code class="varname">PKG_OPTIONS_OPTIONAL_GROUPS</code> is a 5491<li class="listitem"><p><code class="varname">PKG_OPTIONS_OPTIONAL_GROUPS</code> is a
5492list of names of groups of mutually exclusive options. The options in 5492list of names of groups of mutually exclusive options. The options in
5493each group are listed in 5493each group are listed in
5494<code class="varname">PKG_OPTIONS_GROUP.<em class="replaceable"><code>groupname</code></em></code>. 5494<code class="varname">PKG_OPTIONS_GROUP.<em class="replaceable"><code>groupname</code></em></code>.
5495The most specific setting of any option from the group takes 5495The most specific setting of any option from the group takes
5496precedence over all other options in the group. Options from the 5496precedence over all other options in the group. Options from the
5497groups will be automatically added to 5497groups will be automatically added to
@@ -5689,27 +5689,27 @@ details.

 @@ -5689,27 +5689,27 @@ details.

5689 another non-X11 pkg, use <span class="quote">&#8220;<span class="quote">${LOCALBASE}</span>&#8221;</span>. The name 5689 another non-X11 pkg, use <span class="quote">&#8220;<span class="quote">${LOCALBASE}</span>&#8221;</span>. The name
5690 <code class="varname">LOCALBASE</code> stems from FreeBSD, which 5690 <code class="varname">LOCALBASE</code> stems from FreeBSD, which
5691 installed all packages in <code class="filename">/usr/local</code>. As 5691 installed all packages in <code class="filename">/usr/local</code>. As
5692 pkgsrc leaves <code class="filename">/usr/local</code> for the system 5692 pkgsrc leaves <code class="filename">/usr/local</code> for the system
5693 administrator, this variable is a misnomer.</p></li> 5693 administrator, this variable is a misnomer.</p></li>
5694<li class="listitem"><p><code class="varname">X11BASE</code> is where the actual X11 5694<li class="listitem"><p><code class="varname">X11BASE</code> is where the actual X11
5695 distribution (from xsrc, etc.) is installed. When looking for 5695 distribution (from xsrc, etc.) is installed. When looking for
5696 <span class="emphasis"><em>standard</em></span> X11 includes (not those 5696 <span class="emphasis"><em>standard</em></span> X11 includes (not those
5697 installed by a package), use <span class="quote">&#8220;<span class="quote">${X11BASE}</span>&#8221;</span>.</p></li> 5697 installed by a package), use <span class="quote">&#8220;<span class="quote">${X11BASE}</span>&#8221;</span>.</p></li>
5698<li class="listitem"><p>X11-based packages using imake must set 5698<li class="listitem"><p>X11-based packages using imake must set
5699 <code class="varname">USE_IMAKE</code> to be installed correctly under 5699 <code class="varname">USE_IMAKE</code> to be installed correctly under
5700 <code class="varname">LOCALBASE</code>.</p></li> 5700 <code class="varname">LOCALBASE</code>.</p></li>
5701<li class="listitem"><p>Within <code class="filename">${PREFIX}</code>, packages should 5701<li class="listitem"><p>Within <code class="filename">${PREFIX}</code>, packages should
5702 install files according to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?hier+7.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">hier</span>(7)</span></a>, with the exception that 5702 install files according to <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?hier+7.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">hier</span>(7)</span></a>, with the exception that
5703 manual pages go into <code class="filename">${PREFIX}/man</code>, not 5703 manual pages go into <code class="filename">${PREFIX}/man</code>, not
5704 <code class="filename">${PREFIX}/share/man</code>.</p></li> 5704 <code class="filename">${PREFIX}/share/man</code>.</p></li>
5705</ul></div> 5705</ul></div>
5706</div> 5706</div>
5707<div class="sect1"> 5707<div class="sect1">
5708<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5708<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5709<a name="build.builddirs"></a>17.3. Directories used during the build process</h2></div></div></div> 5709<a name="build.builddirs"></a>17.3. Directories used during the build process</h2></div></div></div>
5710<p>When building a package, various directories are used to store 5710<p>When building a package, various directories are used to store
5711 source files, temporary files, pkgsrc-internal files, and so on. These 5711 source files, temporary files, pkgsrc-internal files, and so on. These
5712 directories are explained here.</p> 5712 directories are explained here.</p>
5713<p>Some of the directory variables contain relative pathnames. There 5713<p>Some of the directory variables contain relative pathnames. There
5714 are two common base directories for these relative directories: 5714 are two common base directories for these relative directories:
5715 <code class="varname">PKGSRCDIR/PKGPATH</code> is used for directories that are 5715 <code class="varname">PKGSRCDIR/PKGPATH</code> is used for directories that are
@@ -5970,29 +5970,29 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -5970,29 +5970,29 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
5970</div> 5970</div>
5971<div class="sect1"> 5971<div class="sect1">
5972<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5972<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5973<a name="build.patch"></a>17.8. The <span class="emphasis"><em>patch</em></span> phase</h2></div></div></div> 5973<a name="build.patch"></a>17.8. The <span class="emphasis"><em>patch</em></span> phase</h2></div></div></div>
5974<p>After extraction, all the patches named by the 5974<p>After extraction, all the patches named by the
5975 <code class="varname">PATCHFILES</code>, those present in the patches 5975 <code class="varname">PATCHFILES</code>, those present in the patches
5976 subdirectory of the package as well as in 5976 subdirectory of the package as well as in
5977 $LOCALPATCHES/$PKGPATH (e.g. 5977 $LOCALPATCHES/$PKGPATH (e.g.
5978 <code class="filename">/usr/local/patches/graphics/png</code>) are 5978 <code class="filename">/usr/local/patches/graphics/png</code>) are
5979 applied. Patchfiles ending in <code class="filename">.Z</code> or 5979 applied. Patchfiles ending in <code class="filename">.Z</code> or
5980 <code class="filename">.gz</code> are uncompressed before they are 5980 <code class="filename">.gz</code> are uncompressed before they are
5981 applied, files ending in <code class="filename">.orig</code> or 5981 applied, files ending in <code class="filename">.orig</code> or
5982 <code class="filename">.rej</code> are ignored. Any special options to 5982 <code class="filename">.rej</code> are ignored. Any special options to
5983 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> can be handed in 5983 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> can be handed in
5984 <code class="varname">PATCH_DIST_ARGS</code>. See <a class="xref" href="#components.patches" title="11.3. patches/*">Section 11.3, &#8220;<code class="filename">patches/*</code>&#8221;</a> for more details.</p> 5984 <code class="varname">PATCH_DIST_ARGS</code>. See <a class="xref" href="#components.patches" title="11.3. patches/*">Section 11.3, &#8220;<code class="filename">patches/*</code>&#8221;</a> for more details.</p>
5985<p>By default <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> is given special args to make 5985<p>By default <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?patch+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">patch</span>(1)</span></a> is given special args to make
5986 it fail if the patches apply with some lines of fuzz. Please 5986 it fail if the patches apply with some lines of fuzz. Please
5987 fix (regen) the patches so that they apply cleanly. The 5987 fix (regen) the patches so that they apply cleanly. The
5988 rationale behind this is that patches that don't apply cleanly 5988 rationale behind this is that patches that don't apply cleanly
5989 may end up being applied in the wrong place, and cause severe 5989 may end up being applied in the wrong place, and cause severe
5990 harm there.</p> 5990 harm there.</p>
5991</div> 5991</div>
5992<div class="sect1"> 5992<div class="sect1">
5993<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 5993<div class="titlepage"><div><div><h2 class="title" style="clear: both">
5994<a name="build.tools"></a>17.9. The <span class="emphasis"><em>tools</em></span> phase</h2></div></div></div> 5994<a name="build.tools"></a>17.9. The <span class="emphasis"><em>tools</em></span> phase</h2></div></div></div>
5995<p>This is covered in <a class="xref" href="#tools" title="Chapter 18. Tools needed for building or running">Chapter 18, <i>Tools needed for building or running</i></a>. 5995<p>This is covered in <a class="xref" href="#tools" title="Chapter 18. Tools needed for building or running">Chapter 18, <i>Tools needed for building or running</i></a>.
5996 </p> 5996 </p>
5997</div> 5997</div>
5998<div class="sect1"> 5998<div class="sect1">
@@ -6151,27 +6151,27 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -6151,27 +6151,27 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
6151 ${INSTALL_TARGET} 6151 ${INSTALL_TARGET}
6152.endfor 6152.endfor
6153</pre> 6153</pre>
6154<p>The variable's meanings are analogous to the ones in the 6154<p>The variable's meanings are analogous to the ones in the
6155 <span class="emphasis"><em>build</em></span> phase. 6155 <span class="emphasis"><em>build</em></span> phase.
6156 <code class="varname">INSTALL_DIRS</code> defaults to 6156 <code class="varname">INSTALL_DIRS</code> defaults to
6157 <code class="varname">BUILD_DIRS</code>. <code class="varname">INSTALL_TARGET</code> 6157 <code class="varname">BUILD_DIRS</code>. <code class="varname">INSTALL_TARGET</code>
6158 is <span class="quote">&#8220;<span class="quote">install</span>&#8221;</span> by default, plus 6158 is <span class="quote">&#8220;<span class="quote">install</span>&#8221;</span> by default, plus
6159 <span class="quote">&#8220;<span class="quote">install.man</span>&#8221;</span> if <code class="varname">USE_IMAKE</code> is 6159 <span class="quote">&#8220;<span class="quote">install.man</span>&#8221;</span> if <code class="varname">USE_IMAKE</code> is
6160 defined and <code class="varname">NO_INSTALL_MANPAGES</code> is not 6160 defined and <code class="varname">NO_INSTALL_MANPAGES</code> is not
6161 defined.</p> 6161 defined.</p>
6162<p>In the <span class="emphasis"><em>install</em></span> phase, the following 6162<p>In the <span class="emphasis"><em>install</em></span> phase, the following
6163 variables are useful. They are all variations of the 6163 variables are useful. They are all variations of the
6164 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?install+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">install</span>(1)</span></a> command that have the owner, group and 6164 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?install+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">install</span>(1)</span></a> command that have the owner, group and
6165 permissions preset. <code class="varname">INSTALL</code> is the plain 6165 permissions preset. <code class="varname">INSTALL</code> is the plain
6166 install command. The specialized variants, together with their 6166 install command. The specialized variants, together with their
6167 intended use, are:</p> 6167 intended use, are:</p>
6168<div class="variablelist"><dl class="variablelist"> 6168<div class="variablelist"><dl class="variablelist">
6169<dt><span class="term"><code class="varname">INSTALL_PROGRAM_DIR</code></span></dt> 6169<dt><span class="term"><code class="varname">INSTALL_PROGRAM_DIR</code></span></dt>
6170<dd><p>directories that contain 6170<dd><p>directories that contain
6171 binaries</p></dd> 6171 binaries</p></dd>
6172<dt><span class="term"><code class="varname">INSTALL_SCRIPT_DIR</code></span></dt> 6172<dt><span class="term"><code class="varname">INSTALL_SCRIPT_DIR</code></span></dt>
6173<dd><p>directories that contain 6173<dd><p>directories that contain
6174 scripts</p></dd> 6174 scripts</p></dd>
6175<dt><span class="term"><code class="varname">INSTALL_LIB_DIR</code></span></dt> 6175<dt><span class="term"><code class="varname">INSTALL_LIB_DIR</code></span></dt>
6176<dd><p>directories that contain shared and static 6176<dd><p>directories that contain shared and static
6177 libraries</p></dd> 6177 libraries</p></dd>
@@ -6197,27 +6197,27 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -6197,27 +6197,27 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
6197<dd><p>shared and static 6197<dd><p>shared and static
6198 libraries</p></dd> 6198 libraries</p></dd>
6199<dt><span class="term"><code class="varname">INSTALL_DATA</code></span></dt> 6199<dt><span class="term"><code class="varname">INSTALL_DATA</code></span></dt>
6200<dd><p>data files</p></dd> 6200<dd><p>data files</p></dd>
6201<dt><span class="term"><code class="varname">INSTALL_GAME_DATA</code></span></dt> 6201<dt><span class="term"><code class="varname">INSTALL_GAME_DATA</code></span></dt>
6202<dd><p>data files for 6202<dd><p>data files for
6203 games</p></dd> 6203 games</p></dd>
6204<dt><span class="term"><code class="varname">INSTALL_MAN</code></span></dt> 6204<dt><span class="term"><code class="varname">INSTALL_MAN</code></span></dt>
6205<dd><p>man pages</p></dd> 6205<dd><p>man pages</p></dd>
6206</dl></div> 6206</dl></div>
6207<p>Some other variables are:</p> 6207<p>Some other variables are:</p>
6208<div class="variablelist"><dl class="variablelist"> 6208<div class="variablelist"><dl class="variablelist">
6209<dt><span class="term"><code class="varname">INSTALL_UNSTRIPPED</code></span></dt> 6209<dt><span class="term"><code class="varname">INSTALL_UNSTRIPPED</code></span></dt>
6210<dd><p>If set to <code class="literal">yes</code>, do not run <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?strip+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">strip</span>(1)</span></a> 6210<dd><p>If set to <code class="literal">yes</code>, do not run <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?strip+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">strip</span>(1)</span></a>
6211 when installing binaries. Any debugging sections and symbols present in 6211 when installing binaries. Any debugging sections and symbols present in
6212 binaries will be preserved. 6212 binaries will be preserved.
6213 </p></dd> 6213 </p></dd>
6214<dt><span class="term"><code class="varname">INSTALLATION_DIRS</code></span></dt> 6214<dt><span class="term"><code class="varname">INSTALLATION_DIRS</code></span></dt>
6215<dd><p>A list of directories relative to 6215<dd><p>A list of directories relative to
6216 <code class="varname">PREFIX</code> that are created by pkgsrc at the 6216 <code class="varname">PREFIX</code> that are created by pkgsrc at the
6217 beginning of the <span class="emphasis"><em>install</em></span> phase. 6217 beginning of the <span class="emphasis"><em>install</em></span> phase.
6218 The package is supposed to create all needed directories itself 6218 The package is supposed to create all needed directories itself
6219 before installing files to it and list all other directories here. 6219 before installing files to it and list all other directories here.
6220 </p></dd> 6220 </p></dd>
6221</dl></div> 6221</dl></div>
6222<p>In the rare cases that a package shouldn't install anything, 6222<p>In the rare cases that a package shouldn't install anything,
6223 set <code class="varname">NO_INSTALL</code> to <span class="quote">&#8220;<span class="quote">yes</span>&#8221;</span>. This is 6223 set <code class="varname">NO_INSTALL</code> to <span class="quote">&#8220;<span class="quote">yes</span>&#8221;</span>. This is
@@ -6274,42 +6274,42 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -6274,42 +6274,42 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
6274<p>If you did a <span class="command"><strong>make install</strong></span> and 6274<p>If you did a <span class="command"><strong>make install</strong></span> and
6275 you noticed some file was not installed properly, you 6275 you noticed some file was not installed properly, you
6276 can repeat the installation with this target, which will 6276 can repeat the installation with this target, which will
6277 ignore the <span class="quote">&#8220;<span class="quote">already installed</span>&#8221;</span> flag.</p> 6277 ignore the <span class="quote">&#8220;<span class="quote">already installed</span>&#8221;</span> flag.</p>
6278<p>This is the default value of 6278<p>This is the default value of
6279 <code class="varname">DEPENDS_TARGET</code> except in the case of 6279 <code class="varname">DEPENDS_TARGET</code> except in the case of
6280 <span class="command"><strong>make update</strong></span> and <span class="command"><strong>make 6280 <span class="command"><strong>make update</strong></span> and <span class="command"><strong>make
6281 package</strong></span>, where the defaults are 6281 package</strong></span>, where the defaults are
6282 <span class="quote">&#8220;<span class="quote">package</span>&#8221;</span> and <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span>, 6282 <span class="quote">&#8220;<span class="quote">package</span>&#8221;</span> and <span class="quote">&#8220;<span class="quote">update</span>&#8221;</span>,
6283 respectively.</p> 6283 respectively.</p>
6284</dd> 6284</dd>
6285<dt><span class="term">deinstall</span></dt> 6285<dt><span class="term">deinstall</span></dt>
6286<dd> 6286<dd>
6287<p>This target does a <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> in the 6287<p>This target does a <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> in the
6288 current directory, effectively de-installing the 6288 current directory, effectively de-installing the
6289 package. The following variables can be used to tune the 6289 package. The following variables can be used to tune the
6290 behaviour:</p> 6290 behaviour:</p>
6291<div class="variablelist"><dl class="variablelist"> 6291<div class="variablelist"><dl class="variablelist">
6292<dt><span class="term"><code class="varname">PKG_VERBOSE</code></span></dt> 6292<dt><span class="term"><code class="varname">PKG_VERBOSE</code></span></dt>
6293<dd><p>Add a "-v" to the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> command.</p></dd> 6293<dd><p>Add a "-v" to the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> command.</p></dd>
6294<dt><span class="term"><code class="varname">DEINSTALLDEPENDS</code></span></dt> 6294<dt><span class="term"><code class="varname">DEINSTALLDEPENDS</code></span></dt>
6295<dd><p>Remove all packages that require (depend on) 6295<dd><p>Remove all packages that require (depend on)
6296 the given package. This can be used to remove any 6296 the given package. This can be used to remove any
6297 packages that may have been pulled in by a given 6297 packages that may have been pulled in by a given
6298 package, e.g. if <span class="command"><strong>make deinstall 6298 package, e.g. if <span class="command"><strong>make deinstall
6299 DEINSTALLDEPENDS=1</strong></span> is done in 6299 DEINSTALLDEPENDS=1</strong></span> is done in
6300 <code class="filename">pkgsrc/x11/kde</code>, this is 6300 <code class="filename">pkgsrc/x11/kde</code>, this is
6301 likely to remove whole KDE. Works by adding 6301 likely to remove whole KDE. Works by adding
6302 <span class="quote">&#8220;<span class="quote">-R</span>&#8221;</span> to the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> 6302 <span class="quote">&#8220;<span class="quote">-R</span>&#8221;</span> to the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a>
6303 command line.</p></dd> 6303 command line.</p></dd>
6304</dl></div> 6304</dl></div>
6305</dd> 6305</dd>
6306<dt><span class="term">bin-install</span></dt> 6306<dt><span class="term">bin-install</span></dt>
6307<dd><p>Install a binary package from local disk and via FTP 6307<dd><p>Install a binary package from local disk and via FTP
6308 from a list of sites (see the 6308 from a list of sites (see the
6309 <code class="varname">BINPKG_SITES</code> variable), and do a 6309 <code class="varname">BINPKG_SITES</code> variable), and do a
6310 <span class="command"><strong>make package</strong></span> if no binary package is 6310 <span class="command"><strong>make package</strong></span> if no binary package is
6311 available anywhere. The arguments given to 6311 available anywhere. The arguments given to
6312 <span class="command"><strong>pkg_add</strong></span> can be set via 6312 <span class="command"><strong>pkg_add</strong></span> can be set via
6313 <code class="varname">BIN_INSTALL_FLAGS</code> e.g., to do verbose 6313 <code class="varname">BIN_INSTALL_FLAGS</code> e.g., to do verbose
6314 operation, etc.</p></dd> 6314 operation, etc.</p></dd>
6315<dt><span class="term">install-clean</span></dt> 6315<dt><span class="term">install-clean</span></dt>
@@ -6429,66 +6429,66 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -6429,66 +6429,66 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
6429 this package. Only use this if <span class="command"><strong>make 6429 this package. Only use this if <span class="command"><strong>make
6430 update</strong></span> successfully installed all 6430 update</strong></span> successfully installed all
6431 packages you wanted to update. Normally, this is 6431 packages you wanted to update. Normally, this is
6432 done automatically on <span class="command"><strong>make 6432 done automatically on <span class="command"><strong>make
6433 update</strong></span>, but may have been suppressed by 6433 update</strong></span>, but may have been suppressed by
6434 the <code class="varname">NOCLEAN</code> variable (see 6434 the <code class="varname">NOCLEAN</code> variable (see
6435 above).</p></dd> 6435 above).</p></dd>
6436</dl></div> 6436</dl></div>
6437</dd> 6437</dd>
6438<dt><span class="term">replace</span></dt> 6438<dt><span class="term">replace</span></dt>
6439<dd> 6439<dd>
6440<p>Update the installation of the current package. This 6440<p>Update the installation of the current package. This
6441 differs from update in that it does not replace dependent 6441 differs from update in that it does not replace dependent
6442 packages. You will need to install <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_tarup/README.html" target="_top"><code class="filename">pkgtools/pkg_tarup</code></a> for this 6442 packages. You will need to install <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_tarup/README.html" target="_top"><code class="filename">pkgtools/pkg_tarup</code></a> for this
6443 target to work.</p> 6443 target to work.</p>
6444<p><span class="emphasis"><em>Be careful when using this 6444<p><span class="emphasis"><em>Be careful when using this
6445 target!</em></span> There are no guarantees that dependent 6445 target!</em></span> There are no guarantees that dependent
6446 packages will still work, in particular they will most 6446 packages will still work, in particular they will most
6447 certainly break if you <span class="command"><strong>make replace</strong></span> a 6447 certainly break if you <span class="command"><strong>make replace</strong></span> a
6448 library package whose shared library major version changed 6448 library package whose shared library major version changed
6449 between your installed version and the new one. For this 6449 between your installed version and the new one. For this
6450 reason, this target is not officially supported and only 6450 reason, this target is not officially supported and only
6451 recommended for advanced users.</p> 6451 recommended for advanced users.</p>
6452</dd> 6452</dd>
6453<dt><span class="term">info</span></dt> 6453<dt><span class="term">info</span></dt>
6454<dd><p>This target invokes <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_info+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_info</span>(1)</span></a> for the current 6454<dd><p>This target invokes <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_info+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_info</span>(1)</span></a> for the current
6455 package. You can use this to check which version of a 6455 package. You can use this to check which version of a
6456 package is installed.</p></dd> 6456 package is installed.</p></dd>
6457<dt><span class="term">index</span></dt> 6457<dt><span class="term">index</span></dt>
6458<dd> 6458<dd>
6459<p>This is a top-level command, i.e. it should be used in 6459<p>This is a top-level command, i.e. it should be used in
6460 the <code class="filename">pkgsrc</code> directory. It creates a 6460 the <code class="filename">pkgsrc</code> directory. It creates a
6461 database of all packages in the local pkgsrc tree, including 6461 database of all packages in the local pkgsrc tree, including
6462 dependencies, comment, maintainer, and some other useful 6462 dependencies, comment, maintainer, and some other useful
6463 information. Individual entries are created by running 6463 information. Individual entries are created by running
6464 <span class="command"><strong>make describe</strong></span> in the packages' 6464 <span class="command"><strong>make describe</strong></span> in the packages'
6465 directories. This index file is saved as 6465 directories. This index file is saved as
6466 <code class="filename">pkgsrc/INDEX</code>. It can be displayed in 6466 <code class="filename">pkgsrc/INDEX</code>. It can be displayed in
6467 verbose format by running <span class="command"><strong>make 6467 verbose format by running <span class="command"><strong>make
6468 print-index</strong></span>. You can search in it with 6468 print-index</strong></span>. You can search in it with
6469 <span class="command"><strong>make search 6469 <span class="command"><strong>make search
6470 key=<em class="replaceable"><code>something</code></em></strong></span>. You can 6470 key=<em class="replaceable"><code>something</code></em></strong></span>. You can
6471 extract a list of all packages that depend on a particular 6471 extract a list of all packages that depend on a particular
6472 one by running <span class="command"><strong>make show-deps 6472 one by running <span class="command"><strong>make show-deps
6473 PKG=<em class="replaceable"><code>somepackage</code></em></strong></span>.</p> 6473 PKG=<em class="replaceable"><code>somepackage</code></em></strong></span>.</p>
6474<p>Running this command takes a very long time, some 6474<p>Running this command takes a very long time, some
6475 hours even on fast machines!</p> 6475 hours even on fast machines!</p>
6476</dd> 6476</dd>
6477<dt><span class="term">readme</span></dt> 6477<dt><span class="term">readme</span></dt>
6478<dd> 6478<dd>
6479<p>This target generates a 6479<p>This target generates a
6480 <code class="filename">README.html</code> file, which can be 6480 <code class="filename">README.html</code> file, which can be
6481 viewed using a browser such as <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a> or <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/links/README.html" target="_top"><code class="filename">www/links</code></a>. The generated files 6481 viewed using a browser such as <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/firefox/README.html" target="_top"><code class="filename">www/firefox</code></a> or <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/www/links/README.html" target="_top"><code class="filename">www/links</code></a>. The generated files
6482 contain references to any packages which are in the 6482 contain references to any packages which are in the
6483 <code class="varname">PACKAGES</code> directory on the local 6483 <code class="varname">PACKAGES</code> directory on the local
6484 host. The generated files can be made to refer to URLs 6484 host. The generated files can be made to refer to URLs
6485 based on <code class="varname">FTP_PKG_URL_HOST</code> and 6485 based on <code class="varname">FTP_PKG_URL_HOST</code> and
6486 <code class="varname">FTP_PKG_URL_DIR</code>. For example, if I 6486 <code class="varname">FTP_PKG_URL_DIR</code>. For example, if I
6487 wanted to generate <code class="filename">README.html</code> 6487 wanted to generate <code class="filename">README.html</code>
6488 files which pointed to binary packages on the local 6488 files which pointed to binary packages on the local
6489 machine, in the directory 6489 machine, in the directory
6490 <code class="filename">/usr/packages</code>, set 6490 <code class="filename">/usr/packages</code>, set
6491 <code class="varname">FTP_PKG_URL_HOST=file://localhost</code> and 6491 <code class="varname">FTP_PKG_URL_HOST=file://localhost</code> and
6492 <code class="varname">FTP_PKG_URL_DIR=/usr/packages</code>. The 6492 <code class="varname">FTP_PKG_URL_DIR=/usr/packages</code>. The
6493 <code class="varname">${PACKAGES}</code> directory and its 6493 <code class="varname">${PACKAGES}</code> directory and its
6494 subdirectories will be searched for all the binary 6494 subdirectories will be searched for all the binary
@@ -6557,59 +6557,59 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site @@ -6557,59 +6557,59 @@ ${FETCH_CMD} ${FETCH_BEFORE_ARGS} ${site
6557 if <code class="varname">PKG_DEVELOPER</code> is set in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p></dd> 6557 if <code class="varname">PKG_DEVELOPER</code> is set in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p></dd>
6558<dt><span class="term">print-PLIST</span></dt> 6558<dt><span class="term">print-PLIST</span></dt>
6559<dd> 6559<dd>
6560<p>After a <span class="quote">&#8220;<span class="quote">make install</span>&#8221;</span> from a new or 6560<p>After a <span class="quote">&#8220;<span class="quote">make install</span>&#8221;</span> from a new or
6561 upgraded pkg, this prints out an attempt to generate a 6561 upgraded pkg, this prints out an attempt to generate a
6562 new <code class="filename">PLIST</code> from a <span class="command"><strong>find 6562 new <code class="filename">PLIST</code> from a <span class="command"><strong>find
6563 -newer work/.extract_done</strong></span>. An attempt is made 6563 -newer work/.extract_done</strong></span>. An attempt is made
6564 to care for shared libs etc., but it is 6564 to care for shared libs etc., but it is
6565 <span class="emphasis"><em>strongly</em></span> recommended to review the 6565 <span class="emphasis"><em>strongly</em></span> recommended to review the
6566 result before putting it into 6566 result before putting it into
6567 <code class="filename">PLIST</code>. On upgrades, it's useful to 6567 <code class="filename">PLIST</code>. On upgrades, it's useful to
6568 diff the output of this command against an already 6568 diff the output of this command against an already
6569 existing <code class="filename">PLIST</code> file.</p> 6569 existing <code class="filename">PLIST</code> file.</p>
6570<p>If the package installs files via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?tar+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">tar</span>(1)</span></a> or 6570<p>If the package installs files via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?tar+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">tar</span>(1)</span></a> or
6571 other methods that don't update file access times, be 6571 other methods that don't update file access times, be
6572 sure to add these files manually to your 6572 sure to add these files manually to your
6573 <code class="filename">PLIST</code>, as the <span class="quote">&#8220;<span class="quote">find 6573 <code class="filename">PLIST</code>, as the <span class="quote">&#8220;<span class="quote">find
6574 -newer</span>&#8221;</span> command used by this target won't catch 6574 -newer</span>&#8221;</span> command used by this target won't catch
6575 them!</p> 6575 them!</p>
6576<p>See <a class="xref" href="#print-PLIST" title="13.3. Tweaking output of make print-PLIST">Section 13.3, &#8220;Tweaking output of <span class="command"><strong>make print-PLIST</strong></span>&#8221;</a> for more 6576<p>See <a class="xref" href="#print-PLIST" title="13.3. Tweaking output of make print-PLIST">Section 13.3, &#8220;Tweaking output of <span class="command"><strong>make print-PLIST</strong></span>&#8221;</a> for more
6577 information on this target.</p> 6577 information on this target.</p>
6578</dd> 6578</dd>
6579<dt><span class="term">bulk-package</span></dt> 6579<dt><span class="term">bulk-package</span></dt>
6580<dd> 6580<dd>
6581<p>Used to do bulk builds. If an appropriate binary 6581<p>Used to do bulk builds. If an appropriate binary
6582 package already exists, no action is taken. If not, this 6582 package already exists, no action is taken. If not, this
6583 target will compile, install and package it (and its 6583 target will compile, install and package it (and its
6584 depends, if <code class="varname">PKG_DEPENDS</code> is set 6584 depends, if <code class="varname">PKG_DEPENDS</code> is set
6585 properly. See <a class="xref" href="#bulk" title="Chapter 7. Creating binary packages for everything in pkgsrc (bulk builds)">Chapter 7, <i>Creating binary packages for everything in pkgsrc (bulk 6585 properly. See <a class="xref" href="#bulk" title="Chapter 7. Creating binary packages for everything in pkgsrc (bulk builds)">Chapter 7, <i>Creating binary packages for everything in pkgsrc (bulk
6586builds)</i></a>). 6586builds)</i></a>).
6587 After creating the binary package, the sources, the 6587 After creating the binary package, the sources, the
6588 just-installed package and its required packages are 6588 just-installed package and its required packages are
6589 removed, preserving free disk space.</p> 6589 removed, preserving free disk space.</p>
6590<p><span class="emphasis"><em>Beware that this target may deinstall 6590<p><span class="emphasis"><em>Beware that this target may deinstall
6591 all packages installed on a system!</em></span></p> 6591 all packages installed on a system!</em></span></p>
6592</dd> 6592</dd>
6593<dt><span class="term">bulk-install</span></dt> 6593<dt><span class="term">bulk-install</span></dt>
6594<dd> 6594<dd>
6595<p>Used during bulk-installs to install required 6595<p>Used during bulk-installs to install required
6596 packages. If an up-to-date binary package is available, 6596 packages. If an up-to-date binary package is available,
6597 it will be installed via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>. If not, 6597 it will be installed via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a>. If not,
6598 <span class="command"><strong>make bulk-package</strong></span> will be executed, 6598 <span class="command"><strong>make bulk-package</strong></span> will be executed,
6599 but the installed binary won't be removed.</p> 6599 but the installed binary won't be removed.</p>
6600<p>A binary package is considered 6600<p>A binary package is considered
6601 <span class="quote">&#8220;<span class="quote">up-to-date</span>&#8221;</span> to be installed via 6601 <span class="quote">&#8220;<span class="quote">up-to-date</span>&#8221;</span> to be installed via
6602 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a> if:</p> 6602 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_add+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_add</span>(1)</span></a> if:</p>
6603<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 6603<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
6604<li class="listitem"><p>None of the package's files 6604<li class="listitem"><p>None of the package's files
6605 (<code class="filename">Makefile</code>, ...) were modified 6605 (<code class="filename">Makefile</code>, ...) were modified
6606 since it was built.</p></li> 6606 since it was built.</p></li>
6607<li class="listitem"><p>None of the package's required (binary) 6607<li class="listitem"><p>None of the package's required (binary)
6608 packages were modified since it was built.</p></li> 6608 packages were modified since it was built.</p></li>
6609</ul></div> 6609</ul></div>
6610<p><span class="emphasis"><em>Beware that this target may deinstall 6610<p><span class="emphasis"><em>Beware that this target may deinstall
6611 all packages installed on a system!</em></span></p> 6611 all packages installed on a system!</em></span></p>
6612</dd> 6612</dd>
6613</dl></div> 6613</dl></div>
6614</div> 6614</div>
6615</div> 6615</div>
@@ -6774,27 +6774,27 @@ TOOLS_PLATFORM.true?= true  @@ -6774,27 +6774,27 @@ TOOLS_PLATFORM.true?= true
6774<p>One appealing feature of pkgsrc is that it runs on many 6774<p>One appealing feature of pkgsrc is that it runs on many
6775 different platforms. As a result, it is important to ensure, 6775 different platforms. As a result, it is important to ensure,
6776 where possible, that packages in pkgsrc are portable. This 6776 where possible, that packages in pkgsrc are portable. This
6777 chapter mentions some particular details you should pay 6777 chapter mentions some particular details you should pay
6778 attention to while working on pkgsrc.</p> 6778 attention to while working on pkgsrc.</p>
6779<div class="sect2"> 6779<div class="sect2">
6780<div class="titlepage"><div><div><h3 class="title"> 6780<div class="titlepage"><div><div><h3 class="title">
6781<a name="pulling-vars-from-etc-mk.conf"></a>19.1.1. How to pull in user-settable variables from <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> 6781<a name="pulling-vars-from-etc-mk.conf"></a>19.1.1. How to pull in user-settable variables from <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>
6782</h3></div></div></div> 6782</h3></div></div></div>
6783<p>The pkgsrc user can configure pkgsrc by overriding several 6783<p>The pkgsrc user can configure pkgsrc by overriding several
6784 variables in the file pointed to by <code class="varname">MAKECONF</code>, 6784 variables in the file pointed to by <code class="varname">MAKECONF</code>,
6785 which is <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> by default. When you 6785 which is <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a> by default. When you
6786 want to use those variables in the preprocessor directives of 6786 want to use those variables in the preprocessor directives of
6787 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> (for example <code class="literal">.if</code> or 6787 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> (for example <code class="literal">.if</code> or
6788 <code class="literal">.for</code>), you need to include the file 6788 <code class="literal">.for</code>), you need to include the file
6789 <code class="filename">../../mk/bsd.prefs.mk</code> before, which in turn 6789 <code class="filename">../../mk/bsd.prefs.mk</code> before, which in turn
6790 loads the user preferences.</p> 6790 loads the user preferences.</p>
6791<p>But note that some variables may not be completely defined 6791<p>But note that some variables may not be completely defined
6792 after <code class="filename">../../mk/bsd.prefs.mk</code> has been 6792 after <code class="filename">../../mk/bsd.prefs.mk</code> has been
6793 included, as they may contain references to variables that are 6793 included, as they may contain references to variables that are
6794 not yet defined. In shell commands (the lines in 6794 not yet defined. In shell commands (the lines in
6795 <code class="filename">Makefile</code> that are indented with a tab) this 6795 <code class="filename">Makefile</code> that are indented with a tab) this
6796 is no problem, since variables are only expanded when they are 6796 is no problem, since variables are only expanded when they are
6797 used. But in the preprocessor directives mentioned above and in 6797 used. But in the preprocessor directives mentioned above and in
6798 dependency lines (of the form <code class="literal">target: 6798 dependency lines (of the form <code class="literal">target:
6799 dependencies</code>) the variables are expanded at load 6799 dependencies</code>) the variables are expanded at load
6800 time.</p> 6800 time.</p>
@@ -6852,27 +6852,27 @@ INTERACTIVE_STAGE= configure instal @@ -6852,27 +6852,27 @@ INTERACTIVE_STAGE= configure instal
6852 <code class="varname">DEFAULT_ACCEPTABLE_LICENSES</code> variable in the file 6852 <code class="varname">DEFAULT_ACCEPTABLE_LICENSES</code> variable in the file
6853 <code class="filename">pkgsrc/mk/license.mk</code>.</p> 6853 <code class="filename">pkgsrc/mk/license.mk</code>.</p>
6854<p>The license tag mechanism is intended to address 6854<p>The license tag mechanism is intended to address
6855 copyright-related issues surrounding building, installing and 6855 copyright-related issues surrounding building, installing and
6856 using a package, and not to address redistribution issues (see 6856 using a package, and not to address redistribution issues (see
6857 <code class="varname">RESTRICTED</code> and 6857 <code class="varname">RESTRICTED</code> and
6858 <code class="varname">NO_SRC_ON_FTP</code>, etc.). 6858 <code class="varname">NO_SRC_ON_FTP</code>, etc.).
6859 Packages with redistribution restrictions should set these 6859 Packages with redistribution restrictions should set these
6860 tags.</p> 6860 tags.</p>
6861<p>Denoting that a package may be copied according to a 6861<p>Denoting that a package may be copied according to a
6862 particular license is done by placing the license in 6862 particular license is done by placing the license in
6863 <code class="filename">pkgsrc/licenses</code> and setting the 6863 <code class="filename">pkgsrc/licenses</code> and setting the
6864 <code class="varname">LICENSE</code> variable to a string identifying the 6864 <code class="varname">LICENSE</code> variable to a string identifying the
6865 license, e.g. in <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/graphics/xv/README.html" target="_top"><code class="filename">graphics/xv</code></a>:</p> 6865 license, e.g. in <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/graphics/xv/README.html" target="_top"><code class="filename">graphics/xv</code></a>:</p>
6866<pre class="programlisting"> 6866<pre class="programlisting">
6867LICENSE= xv-license 6867LICENSE= xv-license
6868</pre> 6868</pre>
6869<p>When trying to build, the user will get a notice that the 6869<p>When trying to build, the user will get a notice that the
6870 package is covered by a license which has not been placed in the 6870 package is covered by a license which has not been placed in the
6871 <code class="varname">ACCEPTABLE_LICENSES</code> variable:</p> 6871 <code class="varname">ACCEPTABLE_LICENSES</code> variable:</p>
6872<pre class="programlisting"> 6872<pre class="programlisting">
6873<code class="prompt">%</code> <strong class="userinput"><code>make</code></strong> 6873<code class="prompt">%</code> <strong class="userinput"><code>make</code></strong>
6874===&gt; xv-3.10anb9 has an unacceptable license: xv-license. 6874===&gt; xv-3.10anb9 has an unacceptable license: xv-license.
6875===&gt; To view the license, enter "/usr/bin/make show-license". 6875===&gt; To view the license, enter "/usr/bin/make show-license".
6876===&gt; To indicate acceptance, add this line to your /etc/mk.conf: 6876===&gt; To indicate acceptance, add this line to your /etc/mk.conf:
6877===&gt; ACCEPTABLE_LICENSES+=xv-license 6877===&gt; ACCEPTABLE_LICENSES+=xv-license
6878*** Error code 1 6878*** Error code 1
@@ -7014,27 +7014,27 @@ ACCEPTABLE_LICENSES+=xv-license @@ -7014,27 +7014,27 @@ ACCEPTABLE_LICENSES+=xv-license
7014 when the binary package is later installed, whilst the 7014 when the binary package is later installed, whilst the
7015 <code class="varname">BUILD_DEPENDS</code> definition does not, marking a 7015 <code class="varname">BUILD_DEPENDS</code> definition does not, marking a
7016 dependency that is only needed for building the package.</p> 7016 dependency that is only needed for building the package.</p>
7017<p>This means that if you only need a package present whilst 7017<p>This means that if you only need a package present whilst
7018 you are building, it should be noted as a 7018 you are building, it should be noted as a
7019 <code class="varname">BUILD_DEPENDS</code>.</p> 7019 <code class="varname">BUILD_DEPENDS</code>.</p>
7020<p>The format for a <code class="varname">BUILD_DEPENDS</code> and a 7020<p>The format for a <code class="varname">BUILD_DEPENDS</code> and a
7021 <code class="varname">DEPENDS</code> definition is:</p> 7021 <code class="varname">DEPENDS</code> definition is:</p>
7022<pre class="programlisting"> 7022<pre class="programlisting">
7023&lt;pre-req-package-name&gt;:../../&lt;category&gt;/&lt;pre-req-package&gt; 7023&lt;pre-req-package-name&gt;:../../&lt;category&gt;/&lt;pre-req-package&gt;
7024</pre> 7024</pre>
7025<p>Please note that the <span class="quote">&#8220;<span class="quote">pre-req-package-name</span>&#8221;</span> 7025<p>Please note that the <span class="quote">&#8220;<span class="quote">pre-req-package-name</span>&#8221;</span>
7026 may include any of the wildcard version numbers recognized by 7026 may include any of the wildcard version numbers recognized by
7027 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_info+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_info</span>(1)</span></a>.</p> 7027 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_info+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_info</span>(1)</span></a>.</p>
7028<div class="orderedlist"><ol class="orderedlist" type="1"> 7028<div class="orderedlist"><ol class="orderedlist" type="1">
7029<li class="listitem"> 7029<li class="listitem">
7030<p>If your package needs another package's binaries or 7030<p>If your package needs another package's binaries or
7031 libraries to build and run, and if that package has a 7031 libraries to build and run, and if that package has a
7032 <code class="filename">buildlink3.mk</code> file available, use it:</p> 7032 <code class="filename">buildlink3.mk</code> file available, use it:</p>
7033<pre class="programlisting"> 7033<pre class="programlisting">
7034.include "../../graphics/jpeg/buildlink3.mk" 7034.include "../../graphics/jpeg/buildlink3.mk"
7035</pre> 7035</pre>
7036</li> 7036</li>
7037<li class="listitem"> 7037<li class="listitem">
7038<p>If your package needs another package's binaries or 7038<p>If your package needs another package's binaries or
7039 libraries only for building, and if that package has a 7039 libraries only for building, and if that package has a
7040 <code class="filename">buildlink3.mk</code> file available, use it:</p> 7040 <code class="filename">buildlink3.mk</code> file available, use it:</p>
@@ -7053,27 +7053,27 @@ ACCEPTABLE_LICENSES+=xv-license @@ -7053,27 +7053,27 @@ ACCEPTABLE_LICENSES+=xv-license
7053BUILD_DEPENDS+= scons-[0-9]*:../../devel/scons 7053BUILD_DEPENDS+= scons-[0-9]*:../../devel/scons
7054</pre> 7054</pre>
7055</li> 7055</li>
7056<li class="listitem"><p>If your package needs a library with which to link and 7056<li class="listitem"><p>If your package needs a library with which to link and
7057 there is no <code class="filename">buildlink3.mk</code> file 7057 there is no <code class="filename">buildlink3.mk</code> file
7058 available, create one. Using 7058 available, create one. Using
7059 <code class="varname">DEPENDS</code> won't be sufficient because the 7059 <code class="varname">DEPENDS</code> won't be sufficient because the
7060 include files and libraries will be hidden from the compiler.</p></li> 7060 include files and libraries will be hidden from the compiler.</p></li>
7061<li class="listitem"> 7061<li class="listitem">
7062<p>If your package needs some executable to be able to run 7062<p>If your package needs some executable to be able to run
7063 correctly and if there's no 7063 correctly and if there's no
7064 <code class="filename">buildlink3.mk</code> file, this is specified 7064 <code class="filename">buildlink3.mk</code> file, this is specified
7065 using the <code class="varname">DEPENDS</code> variable. The 7065 using the <code class="varname">DEPENDS</code> variable. The
7066 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/lyx/README.html" target="_top"><code class="filename">print/lyx</code></a> package needs to 7066 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/lyx/README.html" target="_top"><code class="filename">print/lyx</code></a> package needs to
7067 be able to execute the latex binary from the tex-latex-bin package 7067 be able to execute the latex binary from the tex-latex-bin package
7068 when it runs, and that is specified:</p> 7068 when it runs, and that is specified:</p>
7069<pre class="programlisting"> 7069<pre class="programlisting">
7070DEPENDS+= tex-latex-bin-[0-9]*:../../print/tex-latex-bin 7070DEPENDS+= tex-latex-bin-[0-9]*:../../print/tex-latex-bin
7071</pre> 7071</pre>
7072</li> 7072</li>
7073<li class="listitem"> 7073<li class="listitem">
7074<p>You can use wildcards in package dependencies. Note that 7074<p>You can use wildcards in package dependencies. Note that
7075 such wildcard dependencies are retained when creating binary 7075 such wildcard dependencies are retained when creating binary
7076 packages. The dependency is checked when installing the binary 7076 packages. The dependency is checked when installing the binary
7077 package and any package which matches the pattern will be 7077 package and any package which matches the pattern will be
7078 used. Wildcard dependencies should be used with care.</p> 7078 used. Wildcard dependencies should be used with care.</p>
7079<p>The <span class="quote">&#8220;<span class="quote">-[0-9]*</span>&#8221;</span> should be used instead of 7079<p>The <span class="quote">&#8220;<span class="quote">-[0-9]*</span>&#8221;</span> should be used instead of
@@ -7090,47 +7090,47 @@ DEPENDS+= ImageMagick>=6.0:../. @@ -7090,47 +7090,47 @@ DEPENDS+= ImageMagick>=6.0:../.
7090 of ImageMagick or newer. Such a dependency may be warranted 7090 of ImageMagick or newer. Such a dependency may be warranted
7091 if, for example, the command line options of an executable 7091 if, for example, the command line options of an executable
7092 have changed.</p> 7092 have changed.</p>
7093<p>If you need to depend on minimum versions of libraries, 7093<p>If you need to depend on minimum versions of libraries,
7094 see the buildlink section of the pkgsrc guide.</p> 7094 see the buildlink section of the pkgsrc guide.</p>
7095<p>For security fixes, please update the package 7095<p>For security fixes, please update the package
7096 vulnerabilities file. See <a class="xref" href="#security-handling" title="19.1.9. Handling packages with security problems">Section 19.1.9, &#8220;Handling packages with security problems&#8221;</a> for more 7096 vulnerabilities file. See <a class="xref" href="#security-handling" title="19.1.9. Handling packages with security problems">Section 19.1.9, &#8220;Handling packages with security problems&#8221;</a> for more
7097 information.</p> 7097 information.</p>
7098</li> 7098</li>
7099</ol></div> 7099</ol></div>
7100<p>If your package needs files from another package to build, 7100<p>If your package needs files from another package to build,
7101 add the relevant distribution files to 7101 add the relevant distribution files to
7102 <code class="varname">DISTFILES</code>, so they will be extracted 7102 <code class="varname">DISTFILES</code>, so they will be extracted
7103 automatically. See the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/ghostscript/README.html" target="_top"><code class="filename">print/ghostscript</code></a> package for an example. 7103 automatically. See the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/print/ghostscript/README.html" target="_top"><code class="filename">print/ghostscript</code></a> package for an example.
7104 (It relies on the jpeg sources being present in source form 7104 (It relies on the jpeg sources being present in source form
7105 during the build.)</p> 7105 during the build.)</p>
7106</div> 7106</div>
7107<div class="sect2"> 7107<div class="sect2">
7108<div class="titlepage"><div><div><h3 class="title"> 7108<div class="titlepage"><div><div><h3 class="title">
7109<a name="conflicts"></a>19.1.6. Handling conflicts with other packages</h3></div></div></div> 7109<a name="conflicts"></a>19.1.6. Handling conflicts with other packages</h3></div></div></div>
7110<p>Your package may conflict with other packages a user might 7110<p>Your package may conflict with other packages a user might
7111 already have installed on his system, e.g. if your package 7111 already have installed on his system, e.g. if your package
7112 installs the same set of files as another package in the pkgsrc 7112 installs the same set of files as another package in the pkgsrc
7113 tree or has the same <code class="varname">PKGNAME</code>.</p> 7113 tree or has the same <code class="varname">PKGNAME</code>.</p>
7114<p>These cases are handled automatically by the packaging tools 7114<p>These cases are handled automatically by the packaging tools
7115 at package installation time and do not need to be handled 7115 at package installation time and do not need to be handled
7116 manually.</p> 7116 manually.</p>
7117<p>In case the conflicts can not be recognized automatically 7117<p>In case the conflicts can not be recognized automatically
7118 (e.g., packages using the same config file location but no other 7118 (e.g., packages using the same config file location but no other
7119 shared files), you can set <code class="varname">CONFLICTS</code> to a 7119 shared files), you can set <code class="varname">CONFLICTS</code> to a
7120 space-separated list of packages (including version string) your 7120 space-separated list of packages (including version string) your
7121 package conflicts with.</p> 7121 package conflicts with.</p>
7122<p>For example, if both <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/foo/bar/README.html" target="_top"><code class="filename">foo/bar</code></a> 7122<p>For example, if both <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/foo/bar/README.html" target="_top"><code class="filename">foo/bar</code></a>
7123 and <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/foo/baz/README.html" target="_top"><code class="filename">foo/baz</code></a> 7123 and <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/foo/baz/README.html" target="_top"><code class="filename">foo/baz</code></a>
7124 use the same config file, you would set in 7124 use the same config file, you would set in
7125 <code class="filename">foo/bar/Makefile</code>:</p> 7125 <code class="filename">foo/bar/Makefile</code>:</p>
7126<pre class="programlisting"> 7126<pre class="programlisting">
7127CONFLICTS= baz-[0-9]* 7127CONFLICTS= baz-[0-9]*
7128</pre> 7128</pre>
7129<p>and in <code class="filename">pkgsrc/foo/baz/Makefile</code>:</p> 7129<p>and in <code class="filename">pkgsrc/foo/baz/Makefile</code>:</p>
7130<pre class="programlisting"> 7130<pre class="programlisting">
7131CONFLICTS= bar-[0-9]* 7131CONFLICTS= bar-[0-9]*
7132</pre> 7132</pre>
7133</div> 7133</div>
7134<div class="sect2"> 7134<div class="sect2">
7135<div class="titlepage"><div><div><h3 class="title"> 7135<div class="titlepage"><div><div><h3 class="title">
7136<a name="not-building-packages"></a>19.1.7. Packages that cannot or should not be built</h3></div></div></div> 7136<a name="not-building-packages"></a>19.1.7. Packages that cannot or should not be built</h3></div></div></div>
@@ -7146,49 +7146,49 @@ CONFLICTS= bar-[0-9]* @@ -7146,49 +7146,49 @@ CONFLICTS= bar-[0-9]*
7146 wildcards.</p> 7146 wildcards.</p>
7147<p>If a package is not appropriate for some platforms (as 7147<p>If a package is not appropriate for some platforms (as
7148 opposed to merely broken), a different set of variables should be 7148 opposed to merely broken), a different set of variables should be
7149 used as this affects failure reporting and statistics. 7149 used as this affects failure reporting and statistics.
7150 If the package is appropriate for most platforms, the exceptions 7150 If the package is appropriate for most platforms, the exceptions
7151 should be noted with <code class="varname">NOT_FOR_PLATFORM</code>. If 7151 should be noted with <code class="varname">NOT_FOR_PLATFORM</code>. If
7152 the package is appropriate for only a small handful of platforms 7152 the package is appropriate for only a small handful of platforms
7153 (often exactly one), set <code class="varname">ONLY_FOR_PLATFORM</code> instead. 7153 (often exactly one), set <code class="varname">ONLY_FOR_PLATFORM</code> instead.
7154 Both <code class="varname">ONLY_FOR_PLATFORM</code> and 7154 Both <code class="varname">ONLY_FOR_PLATFORM</code> and
7155 <code class="varname">NOT_FOR_PLATFORM</code> are OS triples 7155 <code class="varname">NOT_FOR_PLATFORM</code> are OS triples
7156 (OS-version-platform) that can use glob-style 7156 (OS-version-platform) that can use glob-style
7157 wildcards.</p> 7157 wildcards.</p>
7158<p>Some packages are tightly bound to a specific version of an 7158<p>Some packages are tightly bound to a specific version of an
7159 operating system, e.g. LKMs or <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/sysutils/lsof/README.html" target="_top"><code class="filename">sysutils/lsof</code></a>. Such binary packages are not 7159 operating system, e.g. LKMs or <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/sysutils/lsof/README.html" target="_top"><code class="filename">sysutils/lsof</code></a>. Such binary packages are not
7160 backwards compatible with other versions of the OS, and should be 7160 backwards compatible with other versions of the OS, and should be
7161 uploaded to a version specific directory on the FTP server. Mark 7161 uploaded to a version specific directory on the FTP server. Mark
7162 these packages by setting <code class="varname">OSVERSION_SPECIFIC</code> to 7162 these packages by setting <code class="varname">OSVERSION_SPECIFIC</code> to
7163 <span class="quote">&#8220;<span class="quote">yes</span>&#8221;</span>. This variable is not currently used by any of 7163 <span class="quote">&#8220;<span class="quote">yes</span>&#8221;</span>. This variable is not currently used by any of
7164 the package system internals, but may be used in the 7164 the package system internals, but may be used in the
7165 future.</p> 7165 future.</p>
7166<p>If the package should be skipped (for example, because it 7166<p>If the package should be skipped (for example, because it
7167 provides functionality already provided by the system), set 7167 provides functionality already provided by the system), set
7168 <code class="varname">PKG_SKIP_REASON</code> to a descriptive message. If 7168 <code class="varname">PKG_SKIP_REASON</code> to a descriptive message. If
7169 the package should fail because some preconditions are not met, 7169 the package should fail because some preconditions are not met,
7170 set <code class="varname">PKG_FAIL_REASON</code> to a descriptive 7170 set <code class="varname">PKG_FAIL_REASON</code> to a descriptive
7171 message.</p> 7171 message.</p>
7172</div> 7172</div>
7173<div class="sect2"> 7173<div class="sect2">
7174<div class="titlepage"><div><div><h3 class="title"> 7174<div class="titlepage"><div><div><h3 class="title">
7175<a name="undeletable-packages"></a>19.1.8. Packages which should not be deleted, once installed</h3></div></div></div> 7175<a name="undeletable-packages"></a>19.1.8. Packages which should not be deleted, once installed</h3></div></div></div>
7176<p>To ensure that a package may not be deleted, once it has been 7176<p>To ensure that a package may not be deleted, once it has been
7177 installed, the <code class="varname">PKG_PRESERVE</code> definition should 7177 installed, the <code class="varname">PKG_PRESERVE</code> definition should
7178 be set in the package Makefile. This will be carried into any 7178 be set in the package Makefile. This will be carried into any
7179 binary package that is made from this pkgsrc entry. A 7179 binary package that is made from this pkgsrc entry. A
7180 <span class="quote">&#8220;<span class="quote">preserved</span>&#8221;</span> package will 7180 <span class="quote">&#8220;<span class="quote">preserved</span>&#8221;</span> package will
7181 not be deleted using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> unless the 7181 not be deleted using <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_delete+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_delete</span>(1)</span></a> unless the
7182 <span class="quote">&#8220;<span class="quote">-f</span>&#8221;</span> option is used.</p> 7182 <span class="quote">&#8220;<span class="quote">-f</span>&#8221;</span> option is used.</p>
7183</div> 7183</div>
7184<div class="sect2"> 7184<div class="sect2">
7185<div class="titlepage"><div><div><h3 class="title"> 7185<div class="titlepage"><div><div><h3 class="title">
7186<a name="security-handling"></a>19.1.9. Handling packages with security problems</h3></div></div></div> 7186<a name="security-handling"></a>19.1.9. Handling packages with security problems</h3></div></div></div>
7187<p>When a vulnerability is found, this should be noted in 7187<p>When a vulnerability is found, this should be noted in
7188 <code class="filename">localsrc/security/advisories/pkg-vulnerabilities</code>, 7188 <code class="filename">localsrc/security/advisories/pkg-vulnerabilities</code>,
7189 and after committing that file, ask pkgsrc-security@NetBSD.org to 7189 and after committing that file, ask pkgsrc-security@NetBSD.org to
7190 update the file on ftp.NetBSD.org.</p> 7190 update the file on ftp.NetBSD.org.</p>
7191<p>After fixing the vulnerability by a patch, its 7191<p>After fixing the vulnerability by a patch, its
7192 <code class="varname">PKGREVISION</code> should be increased (this is of 7192 <code class="varname">PKGREVISION</code> should be increased (this is of
7193 course not necessary if the problem is fixed by using a newer 7193 course not necessary if the problem is fixed by using a newer
7194 release of the software), and the pattern in the 7194 release of the software), and the pattern in the
@@ -7301,46 +7301,46 @@ SUBST_SED.fix-paths+= -e 's,"/ @@ -7301,46 +7301,46 @@ SUBST_SED.fix-paths+= -e 's,"/
7301 <code class="literal">post-build</code> is preferred over 7301 <code class="literal">post-build</code> is preferred over
7302 <code class="literal">pre-install</code>, because the install phase should 7302 <code class="literal">pre-install</code>, because the install phase should
7303 generally be kept as simple as possible. When you use 7303 generally be kept as simple as possible. When you use
7304 <code class="literal">post-build</code>, you have the same files in the 7304 <code class="literal">post-build</code>, you have the same files in the
7305 working directory that will be installed later, so you can check 7305 working directory that will be installed later, so you can check
7306 if the substitution has succeeded.</p> 7306 if the substitution has succeeded.</p>
7307<p><code class="varname">SUBST_MESSAGE.*</code> is an optional text 7307<p><code class="varname">SUBST_MESSAGE.*</code> is an optional text
7308 that is printed just before the substitution is done.</p> 7308 that is printed just before the substitution is done.</p>
7309<p><code class="varname">SUBST_FILES.*</code> is the list of shell 7309<p><code class="varname">SUBST_FILES.*</code> is the list of shell
7310 globbing patterns that specifies the files in which the 7310 globbing patterns that specifies the files in which the
7311 substitution will take place. The patterns are interpreted 7311 substitution will take place. The patterns are interpreted
7312 relatively to the <code class="varname">WRKSRC</code> directory.</p> 7312 relatively to the <code class="varname">WRKSRC</code> directory.</p>
7313<p><code class="varname">SUBST_SED.*</code> is a list of arguments to 7313<p><code class="varname">SUBST_SED.*</code> is a list of arguments to
7314 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?sed+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">sed</span>(1)</span></a> that specify the actual substitution. Every sed 7314 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?sed+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">sed</span>(1)</span></a> that specify the actual substitution. Every sed
7315 command should be prefixed with <code class="literal">-e</code>, so that 7315 command should be prefixed with <code class="literal">-e</code>, so that
7316 all SUBST blocks look uniform.</p> 7316 all SUBST blocks look uniform.</p>
7317<p>There are some more variables, but they are so seldomly 7317<p>There are some more variables, but they are so seldomly
7318 used that they are only documented in the 7318 used that they are only documented in the
7319 <code class="filename">mk/subst.mk</code> file.</p> 7319 <code class="filename">mk/subst.mk</code> file.</p>
7320</div> 7320</div>
7321</div> 7321</div>
7322<div class="sect1"> 7322<div class="sect1">
7323<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 7323<div class="titlepage"><div><div><h2 class="title" style="clear: both">
7324<a name="fixes.fetch"></a>19.2. The <span class="emphasis"><em>fetch</em></span> phase</h2></div></div></div> 7324<a name="fixes.fetch"></a>19.2. The <span class="emphasis"><em>fetch</em></span> phase</h2></div></div></div>
7325<div class="sect2"> 7325<div class="sect2">
7326<div class="titlepage"><div><div><h3 class="title"> 7326<div class="titlepage"><div><div><h3 class="title">
7327<a name="no-plain-download"></a>19.2.1. Packages whose distfiles aren't available for plain downloading</h3></div></div></div> 7327<a name="no-plain-download"></a>19.2.1. Packages whose distfiles aren't available for plain downloading</h3></div></div></div>
7328<p>If you need to download from a dynamic URL you can set 7328<p>If you need to download from a dynamic URL you can set
7329 <code class="varname">DYNAMIC_MASTER_SITES</code> and a <span class="command"><strong>make 7329 <code class="varname">DYNAMIC_MASTER_SITES</code> and a <span class="command"><strong>make
7330 fetch</strong></span> will call <code class="filename">files/getsite.sh</code> 7330 fetch</strong></span> will call <code class="filename">files/getsite.sh</code>
7331 with the name of each file to download as an argument, expecting 7331 with the name of each file to download as an argument, expecting
7332 it to output the URL of the directory from which to download 7332 it to output the URL of the directory from which to download
7333 it. <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/graphics/ns-cult3d/README.html" target="_top"><code class="filename">graphics/ns-cult3d</code></a> is an 7333 it. <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/graphics/ns-cult3d/README.html" target="_top"><code class="filename">graphics/ns-cult3d</code></a> is an
7334 example of this usage.</p> 7334 example of this usage.</p>
7335<p>If the download can't be automated, because the user must 7335<p>If the download can't be automated, because the user must
7336 submit personal information to apply for a password, or must pay 7336 submit personal information to apply for a password, or must pay
7337 for the source, or whatever, you can set 7337 for the source, or whatever, you can set
7338 <code class="varname">FETCH_MESSAGE</code> to a list of lines that are 7338 <code class="varname">FETCH_MESSAGE</code> to a list of lines that are
7339 displayed to the user before aborting the build. Example:</p> 7339 displayed to the user before aborting the build. Example:</p>
7340<pre class="programlisting"> 7340<pre class="programlisting">
7341FETCH_MESSAGE= "Please download the files" 7341FETCH_MESSAGE= "Please download the files"
7342FETCH_MESSAGE+= " "${DISTFILES:Q} 7342FETCH_MESSAGE+= " "${DISTFILES:Q}
7343FETCH_MESSAGE+= "manually from "${MASTER_SITES:Q}"." 7343FETCH_MESSAGE+= "manually from "${MASTER_SITES:Q}"."
7344</pre> 7344</pre>
7345</div> 7345</div>
7346<div class="sect2"> 7346<div class="sect2">
@@ -7428,27 +7428,27 @@ EXTRACT_SUFX= .zip @@ -7428,27 +7428,27 @@ EXTRACT_SUFX= .zip
7428<div class="sect1"> 7428<div class="sect1">
7429<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 7429<div class="titlepage"><div><div><h2 class="title" style="clear: both">
7430<a name="fixes.configure"></a>19.3. The <span class="emphasis"><em>configure</em></span> phase</h2></div></div></div> 7430<a name="fixes.configure"></a>19.3. The <span class="emphasis"><em>configure</em></span> phase</h2></div></div></div>
7431<div class="sect2"> 7431<div class="sect2">
7432<div class="titlepage"><div><div><h3 class="title"> 7432<div class="titlepage"><div><div><h3 class="title">
7433<a name="fixes.libtool"></a>19.3.1. Shared libraries - libtool</h3></div></div></div> 7433<a name="fixes.libtool"></a>19.3.1. Shared libraries - libtool</h3></div></div></div>
7434<p>pkgsrc supports many different machines, with different 7434<p>pkgsrc supports many different machines, with different
7435 object formats like a.out and ELF, and varying abilities to do 7435 object formats like a.out and ELF, and varying abilities to do
7436 shared library and dynamic loading at all. To accompany this, 7436 shared library and dynamic loading at all. To accompany this,
7437 varying commands and options have to be passed to the 7437 varying commands and options have to be passed to the
7438 compiler, linker, etc. to get the Right Thing, which can be 7438 compiler, linker, etc. to get the Right Thing, which can be
7439 pretty annoying especially if you don't have all the machines 7439 pretty annoying especially if you don't have all the machines
7440 at your hand to test things. The 7440 at your hand to test things. The
7441 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/libtool/README.html" target="_top"><code class="filename">devel/libtool</code></a> pkg 7441 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/libtool/README.html" target="_top"><code class="filename">devel/libtool</code></a> pkg
7442 can help here, as it just <span class="quote">&#8220;<span class="quote">knows</span>&#8221;</span> how to build 7442 can help here, as it just <span class="quote">&#8220;<span class="quote">knows</span>&#8221;</span> how to build
7443 both static and dynamic libraries from a set of source files, 7443 both static and dynamic libraries from a set of source files,
7444 thus being platform-independent.</p> 7444 thus being platform-independent.</p>
7445<p>Here's how to use libtool in a package in seven simple 7445<p>Here's how to use libtool in a package in seven simple
7446 steps:</p> 7446 steps:</p>
7447<div class="orderedlist"><ol class="orderedlist" type="1"> 7447<div class="orderedlist"><ol class="orderedlist" type="1">
7448<li class="listitem"><p>Add <code class="varname">USE_LIBTOOL=yes</code> to the package 7448<li class="listitem"><p>Add <code class="varname">USE_LIBTOOL=yes</code> to the package
7449 Makefile.</p></li> 7449 Makefile.</p></li>
7450<li class="listitem"><p>For library objects, use <span class="quote">&#8220;<span class="quote">${LIBTOOL} --mode=compile 7450<li class="listitem"><p>For library objects, use <span class="quote">&#8220;<span class="quote">${LIBTOOL} --mode=compile
7451 ${CC}</span>&#8221;</span> in place of <span class="quote">&#8220;<span class="quote">${CC}</span>&#8221;</span>. You could even 7451 ${CC}</span>&#8221;</span> in place of <span class="quote">&#8220;<span class="quote">${CC}</span>&#8221;</span>. You could even
7452 add it to the definition of <code class="varname">CC</code>, if only 7452 add it to the definition of <code class="varname">CC</code>, if only
7453 libraries are being built in a given Makefile. This one command 7453 libraries are being built in a given Makefile. This one command
7454 will build both PIC and non-PIC library objects, so you need not 7454 will build both PIC and non-PIC library objects, so you need not
@@ -7500,63 +7500,63 @@ dynamic linker chooses the library with  @@ -7500,63 +7500,63 @@ dynamic linker chooses the library with
7500 <span class="quote">&#8220;<span class="quote">libfoo-release.so.<span class="emphasis"><em>x</em></span>.<span class="emphasis"><em>y</em></span></span>&#8221;</span> 7500 <span class="quote">&#8220;<span class="quote">libfoo-release.so.<span class="emphasis"><em>x</em></span>.<span class="emphasis"><em>y</em></span></span>&#8221;</span>
7501 will have a symlink of 7501 will have a symlink of
7502 <span class="quote">&#8220;<span class="quote">libfoo.so.<span class="emphasis"><em>x</em></span>.<span class="emphasis"><em>y</em></span></span>&#8221;</span> 7502 <span class="quote">&#8220;<span class="quote">libfoo.so.<span class="emphasis"><em>x</em></span>.<span class="emphasis"><em>y</em></span></span>&#8221;</span>
7503 on an a.out platform. This is handled 7503 on an a.out platform. This is handled
7504 automatically.</p> 7504 automatically.</p>
7505<p>The <span class="quote">&#8220;<span class="quote">-rpath argument</span>&#8221;</span> is the install 7505<p>The <span class="quote">&#8220;<span class="quote">-rpath argument</span>&#8221;</span> is the install
7506 directory of the library being built.</p> 7506 directory of the library being built.</p>
7507<p>In the <code class="filename">PLIST</code>, include only the 7507<p>In the <code class="filename">PLIST</code>, include only the
7508 <code class="filename">.la</code> file, the other files will be 7508 <code class="filename">.la</code> file, the other files will be
7509 added automatically.</p> 7509 added automatically.</p>
7510</li> 7510</li>
7511<li class="listitem"> 7511<li class="listitem">
7512<p>When linking shared object (<code class="filename">.so</code>) 7512<p>When linking shared object (<code class="filename">.so</code>)
7513 files, i.e. files that are loaded via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?dlopen+3.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">dlopen</span>(3)</span></a>, NOT 7513 files, i.e. files that are loaded via <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?dlopen+3.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">dlopen</span>(3)</span></a>, NOT
7514 shared libraries, use <span class="quote">&#8220;<span class="quote">-module 7514 shared libraries, use <span class="quote">&#8220;<span class="quote">-module
7515 -avoid-version</span>&#8221;</span> to prevent them getting version 7515 -avoid-version</span>&#8221;</span> to prevent them getting version
7516 tacked on.</p> 7516 tacked on.</p>
7517<p>The <code class="filename">PLIST</code> file gets the 7517<p>The <code class="filename">PLIST</code> file gets the
7518 <code class="filename">foo.so</code> entry.</p> 7518 <code class="filename">foo.so</code> entry.</p>
7519</li> 7519</li>
7520<li class="listitem"> 7520<li class="listitem">
7521<p>When linking programs that depend on these libraries 7521<p>When linking programs that depend on these libraries
7522 <span class="emphasis"><em>before</em></span> they are installed, preface 7522 <span class="emphasis"><em>before</em></span> they are installed, preface
7523 the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cc+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">cc</span>(1)</span></a> or <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ld+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">ld</span>(1)</span></a> line with <span class="quote">&#8220;<span class="quote">${LIBTOOL} 7523 the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cc+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">cc</span>(1)</span></a> or <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ld+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">ld</span>(1)</span></a> line with <span class="quote">&#8220;<span class="quote">${LIBTOOL}
7524 --mode=link</span>&#8221;</span>, and it will find the correct 7524 --mode=link</span>&#8221;</span>, and it will find the correct
7525 libraries (static or shared), but please be aware that 7525 libraries (static or shared), but please be aware that
7526 libtool will not allow you to specify a relative path in 7526 libtool will not allow you to specify a relative path in
7527 -L (such as <span class="quote">&#8220;<span class="quote">-L../somelib</span>&#8221;</span>), because it 7527 -L (such as <span class="quote">&#8220;<span class="quote">-L../somelib</span>&#8221;</span>), because it
7528 expects you to change that argument to be the 7528 expects you to change that argument to be the
7529 <code class="filename">.la</code> file. e.g.</p> 7529 <code class="filename">.la</code> file. e.g.</p>
7530<pre class="programlisting"> 7530<pre class="programlisting">
7531${LIBTOOL} --mode=link ${CC} -o someprog -L../somelib -lsomelib 7531${LIBTOOL} --mode=link ${CC} -o someprog -L../somelib -lsomelib
7532</pre> 7532</pre>
7533<p>should be changed to:</p> 7533<p>should be changed to:</p>
7534<pre class="programlisting"> 7534<pre class="programlisting">
7535${LIBTOOL} --mode=link ${CC} -o <em class="replaceable"><code>someprog</code></em> <em class="replaceable"><code>../somelib/somelib.la</code></em> 7535${LIBTOOL} --mode=link ${CC} -o <em class="replaceable"><code>someprog</code></em> <em class="replaceable"><code>../somelib/somelib.la</code></em>
7536</pre> 7536</pre>
7537<p>and it will do the right thing with the libraries.</p> 7537<p>and it will do the right thing with the libraries.</p>
7538</li> 7538</li>
7539<li class="listitem"> 7539<li class="listitem">
7540<p>When installing libraries, preface the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?install+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">install</span>(1)</span></a> 7540<p>When installing libraries, preface the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?install+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">install</span>(1)</span></a>
7541 or <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cp+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">cp</span>(1)</span></a> command with <span class="quote">&#8220;<span class="quote">${LIBTOOL} 7541 or <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?cp+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">cp</span>(1)</span></a> command with <span class="quote">&#8220;<span class="quote">${LIBTOOL}
7542 --mode=install</span>&#8221;</span>, and change the library name to 7542 --mode=install</span>&#8221;</span>, and change the library name to
7543 <code class="filename">.la</code>. e.g.</p> 7543 <code class="filename">.la</code>. e.g.</p>
7544<pre class="programlisting"> 7544<pre class="programlisting">
7545${LIBTOOL} --mode=install ${BSD_INSTALL_LIB} ${SOMELIB:.a=.la} ${PREFIX}/lib 7545${LIBTOOL} --mode=install ${BSD_INSTALL_LIB} ${SOMELIB:.a=.la} ${PREFIX}/lib
7546</pre> 7546</pre>
7547<p>This will install the static <code class="filename">.a</code>, 7547<p>This will install the static <code class="filename">.a</code>,
7548 shared library, any needed symlinks, and run 7548 shared library, any needed symlinks, and run
7549 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ldconfig+8.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">ldconfig</span>(8)</span></a>.</p> 7549 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?ldconfig+8.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">ldconfig</span>(8)</span></a>.</p>
7550</li> 7550</li>
7551<li class="listitem"><p>In your <code class="filename">PLIST</code>, include only 7551<li class="listitem"><p>In your <code class="filename">PLIST</code>, include only
7552 the <code class="filename">.la</code> 7552 the <code class="filename">.la</code>
7553 file (this is a change from previous behaviour).</p></li> 7553 file (this is a change from previous behaviour).</p></li>
7554</ol></div> 7554</ol></div>
7555</div> 7555</div>
7556<div class="sect2"> 7556<div class="sect2">
7557<div class="titlepage"><div><div><h3 class="title"> 7557<div class="titlepage"><div><div><h3 class="title">
7558<a name="using-libtool"></a>19.3.2. Using libtool on GNU packages that already support libtool</h3></div></div></div> 7558<a name="using-libtool"></a>19.3.2. Using libtool on GNU packages that already support libtool</h3></div></div></div>
7559<p>Add <code class="varname">USE_LIBTOOL=yes</code> to the 7559<p>Add <code class="varname">USE_LIBTOOL=yes</code> to the
7560 package Makefile. This will override the package's own libtool 7560 package Makefile. This will override the package's own libtool
7561 in most cases. For older libtool using packages, libtool is 7561 in most cases. For older libtool using packages, libtool is
7562 made by ltconfig script during the do-configure step; you can 7562 made by ltconfig script during the do-configure step; you can
@@ -7949,27 +7949,27 @@ ${INSTALL_DATA_DIR} ${PREFIX}/dir2 @@ -7949,27 +7949,27 @@ ${INSTALL_DATA_DIR} ${PREFIX}/dir2
7949<div class="titlepage"><div><div><h3 class="title"> 7949<div class="titlepage"><div><div><h3 class="title">
7950<a name="where-to-install-documentation"></a>19.6.2. Where to install documentation</h3></div></div></div> 7950<a name="where-to-install-documentation"></a>19.6.2. Where to install documentation</h3></div></div></div>
7951<p>In general, documentation should be installed into 7951<p>In general, documentation should be installed into
7952 <code class="filename">${PREFIX}/share/doc/${PKGBASE}</code> or 7952 <code class="filename">${PREFIX}/share/doc/${PKGBASE}</code> or
7953 <code class="filename">${PREFIX}/share/doc/${PKGNAME}</code> (the latter 7953 <code class="filename">${PREFIX}/share/doc/${PKGNAME}</code> (the latter
7954 includes the version number of the package).</p> 7954 includes the version number of the package).</p>
7955<p>Many modern packages using GNU autoconf allow to set the 7955<p>Many modern packages using GNU autoconf allow to set the
7956 directory where HTML documentation is installed with the 7956 directory where HTML documentation is installed with the
7957 <span class="quote">&#8220;<span class="quote">--with-html-dir</span>&#8221;</span> option. Sometimes using this flag 7957 <span class="quote">&#8220;<span class="quote">--with-html-dir</span>&#8221;</span> option. Sometimes using this flag
7958 is needed because otherwise the documentation ends up in 7958 is needed because otherwise the documentation ends up in
7959 <code class="filename">${PREFIX}/share/doc/html</code> or other 7959 <code class="filename">${PREFIX}/share/doc/html</code> or other
7960 places.</p> 7960 places.</p>
7961<p>An exception to the above is that library API documentation 7961<p>An exception to the above is that library API documentation
7962 generated with the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/textproc/gtk-doc/README.html" target="_top"><code class="filename">textproc/gtk-doc</code></a> tools, for use by special 7962 generated with the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/textproc/gtk-doc/README.html" target="_top"><code class="filename">textproc/gtk-doc</code></a> tools, for use by special
7963 browsers (devhelp) should be left at their default location, which 7963 browsers (devhelp) should be left at their default location, which
7964 is <code class="filename">${PREFIX}/share/gtk-doc</code>. Such 7964 is <code class="filename">${PREFIX}/share/gtk-doc</code>. Such
7965 documentation can be recognized from files ending in 7965 documentation can be recognized from files ending in
7966 <code class="filename">.devhelp</code> or <code class="filename">.devhelp2</code>. 7966 <code class="filename">.devhelp</code> or <code class="filename">.devhelp2</code>.
7967 (It is also acceptable to install such files in 7967 (It is also acceptable to install such files in
7968 <code class="filename">${PREFIX}/share/doc/${PKGBASE}</code> or 7968 <code class="filename">${PREFIX}/share/doc/${PKGBASE}</code> or
7969 <code class="filename">${PREFIX}/share/doc/${PKGNAME}</code>; the 7969 <code class="filename">${PREFIX}/share/doc/${PKGNAME}</code>; the
7970 <code class="filename">.devhelp*</code> file must be directly in that 7970 <code class="filename">.devhelp*</code> file must be directly in that
7971 directory then, no additional subdirectory level is allowed in 7971 directory then, no additional subdirectory level is allowed in
7972 this case. This is usually achieved by using 7972 this case. This is usually achieved by using
7973 <span class="quote">&#8220;<span class="quote">--with-html-dir=${PREFIX}/share/doc</span>&#8221;</span>. 7973 <span class="quote">&#8220;<span class="quote">--with-html-dir=${PREFIX}/share/doc</span>&#8221;</span>.
7974 <code class="filename">${PREFIX}/share/gtk-doc</code> is preferred 7974 <code class="filename">${PREFIX}/share/gtk-doc</code> is preferred
7975 though.)</p> 7975 though.)</p>
@@ -8128,27 +8128,27 @@ PERL5_PACKLIST= auto/Pg/.packlist @@ -8128,27 +8128,27 @@ PERL5_PACKLIST= auto/Pg/.packlist
8128 <span class="quote">&#8220;<span class="quote">info</span>&#8221;</span> and can be overridden by the user.</p> 8128 <span class="quote">&#8220;<span class="quote">info</span>&#8221;</span> and can be overridden by the user.</p>
8129<p>The info files for the package should be listed in the 8129<p>The info files for the package should be listed in the
8130 package <code class="filename">PLIST</code>; however any split info files 8130 package <code class="filename">PLIST</code>; however any split info files
8131 need not be listed.</p> 8131 need not be listed.</p>
8132<p>A package which needs the <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> command 8132<p>A package which needs the <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> command
8133 at build time must add <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> to 8133 at build time must add <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> to
8134 <code class="varname">USE_TOOLS</code> in its Makefile. If a minimum 8134 <code class="varname">USE_TOOLS</code> in its Makefile. If a minimum
8135 version of the <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> command is needed it 8135 version of the <span class="quote">&#8220;<span class="quote">makeinfo</span>&#8221;</span> command is needed it
8136 should be noted with the <code class="varname">TEXINFO_REQD</code> 8136 should be noted with the <code class="varname">TEXINFO_REQD</code>
8137 variable in the package <code class="filename">Makefile</code>. By 8137 variable in the package <code class="filename">Makefile</code>. By
8138 default, a minimum version of 3.12 is required. If the system 8138 default, a minimum version of 3.12 is required. If the system
8139 does not provide a <span class="command"><strong>makeinfo</strong></span> command or if it 8139 does not provide a <span class="command"><strong>makeinfo</strong></span> command or if it
8140 does not match the required minimum, a build dependency on the 8140 does not match the required minimum, a build dependency on the
8141 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/gtexinfo/README.html" target="_top"><code class="filename">devel/gtexinfo</code></a> package will 8141 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/devel/gtexinfo/README.html" target="_top"><code class="filename">devel/gtexinfo</code></a> package will
8142 be added automatically.</p> 8142 be added automatically.</p>
8143<p>The build and installation process of the software provided 8143<p>The build and installation process of the software provided
8144 by the package should not use the 8144 by the package should not use the
8145 <span class="command"><strong>install-info</strong></span> command as the registration of 8145 <span class="command"><strong>install-info</strong></span> command as the registration of
8146 info files is the task of the package 8146 info files is the task of the package
8147 <code class="filename">INSTALL</code> script, and it must use the 8147 <code class="filename">INSTALL</code> script, and it must use the
8148 appropriate <span class="command"><strong>makeinfo</strong></span> command.</p> 8148 appropriate <span class="command"><strong>makeinfo</strong></span> command.</p>
8149<p>To achieve this goal, the pkgsrc infrastructure creates 8149<p>To achieve this goal, the pkgsrc infrastructure creates
8150 overriding scripts for the <span class="command"><strong>install-info</strong></span> and 8150 overriding scripts for the <span class="command"><strong>install-info</strong></span> and
8151 <span class="command"><strong>makeinfo</strong></span> commands in a directory listed early 8151 <span class="command"><strong>makeinfo</strong></span> commands in a directory listed early
8152 in <code class="varname">PATH</code>.</p> 8152 in <code class="varname">PATH</code>.</p>
8153<p>The script overriding <span class="command"><strong>install-info</strong></span> has 8153<p>The script overriding <span class="command"><strong>install-info</strong></span> has
8154 no effect except the logging of a message. The script overriding 8154 no effect except the logging of a message. The script overriding
@@ -8410,27 +8410,27 @@ PERL5_PACKLIST= auto/Pg/.packlist @@ -8410,27 +8410,27 @@ PERL5_PACKLIST= auto/Pg/.packlist
8410<li class="listitem"><p>Make sure that none of <code class="filename">ls-R</code> 8410<li class="listitem"><p>Make sure that none of <code class="filename">ls-R</code>
8411 databases are included in <code class="filename">PLIST</code>, as 8411 databases are included in <code class="filename">PLIST</code>, as
8412 they will be removed only by the kpathsea package.</p></li> 8412 they will be removed only by the kpathsea package.</p></li>
8413</ol></div> 8413</ol></div>
8414</div> 8414</div>
8415<div class="sect2"> 8415<div class="sect2">
8416<div class="titlepage"><div><div><h3 class="title"> 8416<div class="titlepage"><div><div><h3 class="title">
8417<a name="emulation-packages"></a>19.6.18. Packages supporting running binaries in 8417<a name="emulation-packages"></a>19.6.18. Packages supporting running binaries in
8418 emulation</h3></div></div></div> 8418 emulation</h3></div></div></div>
8419<p>There are some packages that provide libraries and 8419<p>There are some packages that provide libraries and
8420 executables for running binaries from a one operating system 8420 executables for running binaries from a one operating system
8421 on a different one (if the latter supports it). One example 8421 on a different one (if the latter supports it). One example
8422 is running Linux binaries on NetBSD.</p> 8422 is running Linux binaries on NetBSD.</p>
8423<p>The <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/rpm2pkg/README.html" target="_top"><code class="filename">pkgtools/rpm2pkg</code></a> 8423<p>The <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/rpm2pkg/README.html" target="_top"><code class="filename">pkgtools/rpm2pkg</code></a>
8424 helps in extracting and packaging Linux rpm packages.</p> 8424 helps in extracting and packaging Linux rpm packages.</p>
8425<p>The <code class="varname">CHECK_SHLIBS</code> can be set to no to 8425<p>The <code class="varname">CHECK_SHLIBS</code> can be set to no to
8426 avoid the <span class="command"><strong>check-shlibs</strong></span> target, which tests 8426 avoid the <span class="command"><strong>check-shlibs</strong></span> target, which tests
8427 if all libraries for each installed executable can be found by 8427 if all libraries for each installed executable can be found by
8428 the dynamic linker. Since the standard dynamic linker is run, 8428 the dynamic linker. Since the standard dynamic linker is run,
8429 this fails for emulation packages, because the libraries used 8429 this fails for emulation packages, because the libraries used
8430 by the emulation are not in the standard directories.</p> 8430 by the emulation are not in the standard directories.</p>
8431</div> 8431</div>
8432<div class="sect2"> 8432<div class="sect2">
8433<div class="titlepage"><div><div><h3 class="title"> 8433<div class="titlepage"><div><div><h3 class="title">
8434<a name="hicolor-theme"></a>19.6.19. Packages installing hicolor theme icons</h3></div></div></div> 8434<a name="hicolor-theme"></a>19.6.19. Packages installing hicolor theme icons</h3></div></div></div>
8435<p>If a package installs images under the 8435<p>If a package installs images under the
8436 <code class="filename">share/icons/hicolor</code> and/or updates the 8436 <code class="filename">share/icons/hicolor</code> and/or updates the
@@ -8484,53 +8484,53 @@ PERL5_PACKLIST= auto/Pg/.packlist @@ -8484,53 +8484,53 @@ PERL5_PACKLIST= auto/Pg/.packlist
8484 intervals.</p> 8484 intervals.</p>
8485</div> 8485</div>
8486</div> 8486</div>
8487<div class="chapter"> 8487<div class="chapter">
8488<div class="titlepage"><div><div><h2 class="title"> 8488<div class="titlepage"><div><div><h2 class="title">
8489<a name="debug"></a>Chapter 20. Debugging</h2></div></div></div> 8489<a name="debug"></a>Chapter 20. Debugging</h2></div></div></div>
8490<p>To check out all the gotchas when building a package, here are 8490<p>To check out all the gotchas when building a package, here are
8491 the steps that I do in order to get a package working. Please note 8491 the steps that I do in order to get a package working. Please note
8492 this is basically the same as what was explained in the previous 8492 this is basically the same as what was explained in the previous
8493 sections, only with some debugging aids.</p> 8493 sections, only with some debugging aids.</p>
8494<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 8494<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
8495<li class="listitem"><p>Be sure to set <code class="varname">PKG_DEVELOPER=yes</code> in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p></li> 8495<li class="listitem"><p>Be sure to set <code class="varname">PKG_DEVELOPER=yes</code> in <a class="link" href="#mk.conf"><code class="filename">mk.conf</code></a>.</p></li>
8496<li class="listitem"> 8496<li class="listitem">
8497<p>Install <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a>, 8497<p>Install <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/url2pkg/README.html" target="_top"><code class="filename">pkgtools/url2pkg</code></a>,
8498 create a directory for a new package, change into it, then run 8498 create a directory for a new package, change into it, then run
8499 <span class="command"><strong>url2pkg</strong></span>:</p> 8499 <span class="command"><strong>url2pkg</strong></span>:</p>
8500<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>mkdir /usr/pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>examplepkg</code></em></code></strong> 8500<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>mkdir /usr/pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>examplepkg</code></em></code></strong>
8501<code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>examplepkg</code></em></code></strong> 8501<code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc/<em class="replaceable"><code>category</code></em>/<em class="replaceable"><code>examplepkg</code></em></code></strong>
8502<code class="prompt">%</code> <strong class="userinput"><code>url2pkg http://www.example.com/path/to/distfile.tar.gz</code></strong></pre> 8502<code class="prompt">%</code> <strong class="userinput"><code>url2pkg http://www.example.com/path/to/distfile.tar.gz</code></strong></pre>
8503</li> 8503</li>
8504<li class="listitem"><p>Edit the <code class="filename">Makefile</code> as requested.</p></li> 8504<li class="listitem"><p>Edit the <code class="filename">Makefile</code> as requested.</p></li>
8505<li class="listitem"><p>Fill in the <code class="filename">DESCR</code> file</p></li> 8505<li class="listitem"><p>Fill in the <code class="filename">DESCR</code> file</p></li>
8506<li class="listitem"><p>Run <span class="command"><strong>make configure</strong></span></p></li> 8506<li class="listitem"><p>Run <span class="command"><strong>make configure</strong></span></p></li>
8507<li class="listitem"><p>Add any dependencies glimpsed from documentation and the 8507<li class="listitem"><p>Add any dependencies glimpsed from documentation and the
8508 configure step to the package's 8508 configure step to the package's
8509 <code class="filename">Makefile</code>.</p></li> 8509 <code class="filename">Makefile</code>.</p></li>
8510<li class="listitem"> 8510<li class="listitem">
8511<p>Make the package compile, doing multiple rounds of</p> 8511<p>Make the package compile, doing multiple rounds of</p>
8512<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make</code></strong> 8512<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>make</code></strong>
8513<code class="prompt">%</code> <strong class="userinput"><code>pkgvi ${WRKSRC}/some/file/that/does/not/compile</code></strong> 8513<code class="prompt">%</code> <strong class="userinput"><code>pkgvi ${WRKSRC}/some/file/that/does/not/compile</code></strong>
8514<code class="prompt">%</code> <strong class="userinput"><code>mkpatches</code></strong> 8514<code class="prompt">%</code> <strong class="userinput"><code>mkpatches</code></strong>
8515<code class="prompt">%</code> <strong class="userinput"><code>patchdiff</code></strong> 8515<code class="prompt">%</code> <strong class="userinput"><code>patchdiff</code></strong>
8516<code class="prompt">%</code> <strong class="userinput"><code>mv ${WRKDIR}/.newpatches/* patches</code></strong> 8516<code class="prompt">%</code> <strong class="userinput"><code>mv ${WRKDIR}/.newpatches/* patches</code></strong>
8517<code class="prompt">%</code> <strong class="userinput"><code>make mps</code></strong> 8517<code class="prompt">%</code> <strong class="userinput"><code>make mps</code></strong>
8518<code class="prompt">%</code> <strong class="userinput"><code>make clean</code></strong></pre> 8518<code class="prompt">%</code> <strong class="userinput"><code>make clean</code></strong></pre>
8519<p>Doing this step as non-root user will ensure that no files 8519<p>Doing this step as non-root user will ensure that no files
8520 are modified that shouldn't be, especially during the build 8520 are modified that shouldn't be, especially during the build
8521 phase. <span class="command"><strong>mkpatches</strong></span>, 8521 phase. <span class="command"><strong>mkpatches</strong></span>,
8522 <span class="command"><strong>patchdiff</strong></span> and <span class="command"><strong>pkgvi</strong></span> are 8522 <span class="command"><strong>patchdiff</strong></span> and <span class="command"><strong>pkgvi</strong></span> are
8523 from the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a> 8523 from the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkgdiff/README.html" target="_top"><code class="filename">pkgtools/pkgdiff</code></a>
8524 package.</p> 8524 package.</p>
8525</li> 8525</li>
8526<li class="listitem"><p>Look at the <code class="filename">Makefile</code>, fix if 8526<li class="listitem"><p>Look at the <code class="filename">Makefile</code>, fix if
8527 necessary; see <a class="xref" href="#components.Makefile" title="11.1. Makefile">Section 11.1, &#8220;<code class="filename">Makefile</code>&#8221;</a>.</p></li> 8527 necessary; see <a class="xref" href="#components.Makefile" title="11.1. Makefile">Section 11.1, &#8220;<code class="filename">Makefile</code>&#8221;</a>.</p></li>
8528<li class="listitem"> 8528<li class="listitem">
8529<p>Generate a <code class="filename">PLIST</code>:</p> 8529<p>Generate a <code class="filename">PLIST</code>:</p>
8530<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>make install</code></strong> 8530<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>make install</code></strong>
8531<code class="prompt">#</code> <strong class="userinput"><code>make print-PLIST &gt;PLIST</code></strong> 8531<code class="prompt">#</code> <strong class="userinput"><code>make print-PLIST &gt;PLIST</code></strong>
8532<code class="prompt">#</code> <strong class="userinput"><code>make deinstall</code></strong> 8532<code class="prompt">#</code> <strong class="userinput"><code>make deinstall</code></strong>
8533<code class="prompt">#</code> <strong class="userinput"><code>make install</code></strong> 8533<code class="prompt">#</code> <strong class="userinput"><code>make install</code></strong>
8534<code class="prompt">#</code> <strong class="userinput"><code>make deinstall</code></strong></pre> 8534<code class="prompt">#</code> <strong class="userinput"><code>make deinstall</code></strong></pre>
8535<p>You usually need to be <code class="username">root</code> to do 8535<p>You usually need to be <code class="username">root</code> to do
8536 this. Look if there are any files left:</p> 8536 this. Look if there are any files left:</p>
@@ -8549,27 +8549,27 @@ PERL5_PACKLIST= auto/Pg/.packlist @@ -8549,27 +8549,27 @@ PERL5_PACKLIST= auto/Pg/.packlist
8549<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkg_delete <em class="replaceable"><code>examplepkg</code></em></code></strong></pre> 8549<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkg_delete <em class="replaceable"><code>examplepkg</code></em></code></strong></pre>
8550</li> 8550</li>
8551<li class="listitem"> 8551<li class="listitem">
8552<p>Repeat the above <span class="command"><strong>make print-PLIST</strong></span> 8552<p>Repeat the above <span class="command"><strong>make print-PLIST</strong></span>
8553 command, which shouldn't find anything now:</p> 8553 command, which shouldn't find anything now:</p>
8554<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>make print-PLIST</code></strong></pre> 8554<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>make print-PLIST</code></strong></pre>
8555</li> 8555</li>
8556<li class="listitem"> 8556<li class="listitem">
8557<p>Reinstall the binary package:</p> 8557<p>Reinstall the binary package:</p>
8558<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkg_add .../<em class="replaceable"><code>examplepkg</code></em>.tgz</code></strong></pre> 8558<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkg_add .../<em class="replaceable"><code>examplepkg</code></em>.tgz</code></strong></pre>
8559</li> 8559</li>
8560<li class="listitem"><p>Play with it. Make sure everything works.</p></li> 8560<li class="listitem"><p>Play with it. Make sure everything works.</p></li>
8561<li class="listitem"> 8561<li class="listitem">
8562<p>Run <span class="command"><strong>pkglint</strong></span> from <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>, and fix the problems it 8562<p>Run <span class="command"><strong>pkglint</strong></span> from <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>, and fix the problems it
8563 reports:</p> 8563 reports:</p>
8564<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkglint</code></strong></pre> 8564<pre class="screen"><code class="prompt">#</code> <strong class="userinput"><code>pkglint</code></strong></pre>
8565</li> 8565</li>
8566<li class="listitem"><p>Submit (or commit, if you have cvs access); see <a class="xref" href="#submit" title="Chapter 21. Submitting and Committing">Chapter 21, <i>Submitting and Committing</i></a>.</p></li> 8566<li class="listitem"><p>Submit (or commit, if you have cvs access); see <a class="xref" href="#submit" title="Chapter 21. Submitting and Committing">Chapter 21, <i>Submitting and Committing</i></a>.</p></li>
8567</ul></div> 8567</ul></div>
8568</div> 8568</div>
8569<div class="chapter"> 8569<div class="chapter">
8570<div class="titlepage"><div><div><h2 class="title"> 8570<div class="titlepage"><div><div><h2 class="title">
8571<a name="submit"></a>Chapter 21. Submitting and Committing</h2></div></div></div> 8571<a name="submit"></a>Chapter 21. Submitting and Committing</h2></div></div></div>
8572<div class="toc"> 8572<div class="toc">
8573<p><b>Table of Contents</b></p> 8573<p><b>Table of Contents</b></p>
8574<dl class="toc"> 8574<dl class="toc">
8575<dt><span class="sect1"><a href="#submitting-binary-packages">21.1. Submitting binary packages</a></span></dt> 8575<dt><span class="sect1"><a href="#submitting-binary-packages">21.1. Submitting binary packages</a></span></dt>
@@ -8589,35 +8589,35 @@ PERL5_PACKLIST= auto/Pg/.packlist @@ -8589,35 +8589,35 @@ PERL5_PACKLIST= auto/Pg/.packlist
8589 developers to guarantee that the packages don't contain any 8589 developers to guarantee that the packages don't contain any
8590 trojan horses etc. This is not to annoy anyone but rather to 8590 trojan horses etc. This is not to annoy anyone but rather to
8591 protect our users! You're still free to put up your home-made 8591 protect our users! You're still free to put up your home-made
8592 binary packages and tell the world where to get them. NetBSD 8592 binary packages and tell the world where to get them. NetBSD
8593 developers doing bulk builds and wanting to upload them please 8593 developers doing bulk builds and wanting to upload them please
8594 see <a class="xref" href="#bulk" title="Chapter 7. Creating binary packages for everything in pkgsrc (bulk builds)">Chapter 7, <i>Creating binary packages for everything in pkgsrc (bulk 8594 see <a class="xref" href="#bulk" title="Chapter 7. Creating binary packages for everything in pkgsrc (bulk builds)">Chapter 7, <i>Creating binary packages for everything in pkgsrc (bulk
8595builds)</i></a>.</p> 8595builds)</i></a>.</p>
8596</div> 8596</div>
8597<div class="sect1"> 8597<div class="sect1">
8598<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 8598<div class="titlepage"><div><div><h2 class="title" style="clear: both">
8599<a name="submitting-your-package"></a>21.2. Submitting source packages (for non-NetBSD-developers)</h2></div></div></div> 8599<a name="submitting-your-package"></a>21.2. Submitting source packages (for non-NetBSD-developers)</h2></div></div></div>
8600<p>First, check that your package is complete, compiles and 8600<p>First, check that your package is complete, compiles and
8601 runs well; see <a class="xref" href="#debug" title="Chapter 20. Debugging">Chapter 20, <i>Debugging</i></a> and the rest of this 8601 runs well; see <a class="xref" href="#debug" title="Chapter 20. Debugging">Chapter 20, <i>Debugging</i></a> and the rest of this
8602 document. Next, generate an uuencoded gzipped <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?tar+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">tar</span>(1)</span></a> 8602 document. Next, generate an uuencoded gzipped <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?tar+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">tar</span>(1)</span></a>
8603 archive that contains all files that make up the package. 8603 archive that contains all files that make up the package.
8604 Finally, send this package to the pkgsrc bug tracking system, 8604 Finally, send this package to the pkgsrc bug tracking system,
8605 either with the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a> command, or if you don't have 8605 either with the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a> command, or if you don't have
8606 that, go to the web page 8606 that, go to the web page
8607 <a class="ulink" href="http://www.NetBSD.org/support/send-pr.html" target="_top">http://www.NetBSD.org/support/send-pr.html</a>, 8607 <a class="ulink" href="http://www.NetBSD.org/support/send-pr.html" target="_top">http://www.NetBSD.org/support/send-pr.html</a>,
8608 which contains some instructions and a link to a form where you 8608 which contains some instructions and a link to a form where you
8609 can submit packages. The 8609 can submit packages. The
8610 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/sysutils/gtk-send-pr/README.html" target="_top"><code class="filename">sysutils/gtk-send-pr</code></a> package is 8610 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/sysutils/gtk-send-pr/README.html" target="_top"><code class="filename">sysutils/gtk-send-pr</code></a> package is
8611 also available as a substitute for either of the above two tools. 8611 also available as a substitute for either of the above two tools.
8612 </p> 8612 </p>
8613<p>In the form of the problem report, the category should be 8613<p>In the form of the problem report, the category should be
8614 <span class="quote">&#8220;<span class="quote">pkg</span>&#8221;</span>, the synopsis should include the package name 8614 <span class="quote">&#8220;<span class="quote">pkg</span>&#8221;</span>, the synopsis should include the package name
8615 and version number, and the description field should contain a 8615 and version number, and the description field should contain a
8616 short description of your package (contents of the COMMENT 8616 short description of your package (contents of the COMMENT
8617 variable or DESCR file are OK). The uuencoded package data should 8617 variable or DESCR file are OK). The uuencoded package data should
8618 go into the <span class="quote">&#8220;<span class="quote">fix</span>&#8221;</span> field.</p> 8618 go into the <span class="quote">&#8220;<span class="quote">fix</span>&#8221;</span> field.</p>
8619<p>If you want to submit several packages, please send a 8619<p>If you want to submit several packages, please send a
8620 separate PR for each one, it's easier for us to track things 8620 separate PR for each one, it's easier for us to track things
8621 that way.</p> 8621 that way.</p>
8622<p>Alternatively, you can also import new packages into 8622<p>Alternatively, you can also import new packages into
8623 pkgsrc-wip (<span class="quote">&#8220;<span class="quote">pkgsrc work-in-progress</span>&#8221;</span>); see the 8623 pkgsrc-wip (<span class="quote">&#8220;<span class="quote">pkgsrc work-in-progress</span>&#8221;</span>); see the
@@ -8789,27 +8789,27 @@ much easier to get wrong than  @@ -8789,27 +8789,27 @@ much easier to get wrong than
8789<li class="listitem"> 8789<li class="listitem">
8790<p>Remove all CVS dirs.</p> 8790<p>Remove all CVS dirs.</p>
8791<p>Alternatively to the first two steps you can also do:</p> 8791<p>Alternatively to the first two steps you can also do:</p>
8792<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cvs -d user@cvs.NetBSD.org:/cvsroot export -D today pkgsrc/category/package</code></strong></pre> 8792<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cvs -d user@cvs.NetBSD.org:/cvsroot export -D today pkgsrc/category/package</code></strong></pre>
8793<p>and use that for further work.</p> 8793<p>and use that for further work.</p>
8794</li> 8794</li>
8795<li class="listitem"><p>Fix <code class="varname">CATEGORIES</code> and any 8795<li class="listitem"><p>Fix <code class="varname">CATEGORIES</code> and any
8796<code class="varname">DEPENDS</code> paths that just did <span class="quote">&#8220;<span class="quote">../package</span>&#8221;</span> 8796<code class="varname">DEPENDS</code> paths that just did <span class="quote">&#8220;<span class="quote">../package</span>&#8221;</span>
8797instead of <span class="quote">&#8220;<span class="quote">../../category/package</span>&#8221;</span>.</p></li> 8797instead of <span class="quote">&#8220;<span class="quote">../../category/package</span>&#8221;</span>.</p></li>
8798<li class="listitem"><p>In the modified package's Makefile, consider setting 8798<li class="listitem"><p>In the modified package's Makefile, consider setting
8799<code class="varname">PREV_PKGPATH</code> to the previous category/package 8799<code class="varname">PREV_PKGPATH</code> to the previous category/package
8800pathname. The <code class="varname">PREV_PKGPATH</code> can be used by tools 8800pathname. The <code class="varname">PREV_PKGPATH</code> can be used by tools
8801for doing an update using pkgsrc building; for example, it can 8801for doing an update using pkgsrc building; for example, it can
8802search the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_summary+5.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">pkg_summary</span>(5)</span></a> database for <code class="varname">PREV_PKGPATH</code> 8802search the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?pkg_summary+5.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">pkg_summary</span>(5)</span></a> database for <code class="varname">PREV_PKGPATH</code>
8803(if no <code class="varname">SUPERSEDES</code>) and then use the corresponding 8803(if no <code class="varname">SUPERSEDES</code>) and then use the corresponding
8804new <code class="varname">PKGPATH</code> for that moved package. Note that 8804new <code class="varname">PKGPATH</code> for that moved package. Note that
8805it may have multiple matches, so the tool should also check on the 8805it may have multiple matches, so the tool should also check on the
8806<code class="varname">PKGBASE</code> too. The <code class="varname">PREV_PKGPATH</code> 8806<code class="varname">PKGBASE</code> too. The <code class="varname">PREV_PKGPATH</code>
8807probably has no value unless <code class="varname">SUPERSEDES</code> is not 8807probably has no value unless <code class="varname">SUPERSEDES</code> is not
8808set, i.e. <code class="varname">PKGBASE</code> stays the same. </p></li> 8808set, i.e. <code class="varname">PKGBASE</code> stays the same. </p></li>
8809<li class="listitem"><p><span class="command"><strong>cvs import</strong></span> the modified package in the new 8809<li class="listitem"><p><span class="command"><strong>cvs import</strong></span> the modified package in the new
8810place.</p></li> 8810place.</p></li>
8811<li class="listitem"> 8811<li class="listitem">
8812<p>Check if any package depends on it: 8812<p>Check if any package depends on it:
8813</p> 8813</p>
8814<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc</code></strong> 8814<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cd /usr/pkgsrc</code></strong>
8815<code class="prompt">%</code> <strong class="userinput"><code>grep /package */*/Makefile* */*/buildlink*</code></strong></pre> 8815<code class="prompt">%</code> <strong class="userinput"><code>grep /package */*/Makefile* */*/buildlink*</code></strong></pre>
@@ -8825,27 +8825,27 @@ place.

 @@ -8825,27 +8825,27 @@ place.

8825</li> 8825</li>
8826</ol></div> 8826</ol></div>
8827</div> 8827</div>
8828</div> 8828</div>
8829<div class="chapter"> 8829<div class="chapter">
8830<div class="titlepage"><div><div><h2 class="title"> 8830<div class="titlepage"><div><div><h2 class="title">
8831<a name="devfaq"></a>Chapter 22. Frequently Asked Questions</h2></div></div></div> 8831<a name="devfaq"></a>Chapter 22. Frequently Asked Questions</h2></div></div></div>
8832<p>This section contains the answers to questions that may 8832<p>This section contains the answers to questions that may
8833 arise when you are writing a package. If you don't find your 8833 arise when you are writing a package. If you don't find your
8834 question answered here, first have a look in the other chapters, 8834 question answered here, first have a look in the other chapters,
8835 and if you still don't have the answer, ask on the 8835 and if you still don't have the answer, ask on the
8836 <code class="literal">pkgsrc-users</code> mailing list.</p> 8836 <code class="literal">pkgsrc-users</code> mailing list.</p>
8837<div class="qandaset"> 8837<div class="qandaset">
8838<a name="idm79078192"></a><dl> 8838<a name="idm80785232"></a><dl>
8839<dt>22.1. <a href="#devfaq.makeflags">What is the difference between 8839<dt>22.1. <a href="#devfaq.makeflags">What is the difference between
8840 MAKEFLAGS, .MAKEFLAGS and 8840 MAKEFLAGS, .MAKEFLAGS and
8841 MAKE_FLAGS?</a> 8841 MAKE_FLAGS?</a>
8842</dt> 8842</dt>
8843<dt>22.2. <a href="#devfaq.make">What is the difference between 8843<dt>22.2. <a href="#devfaq.make">What is the difference between
8844 MAKE, GMAKE and 8844 MAKE, GMAKE and
8845 MAKE_PROGRAM?</a> 8845 MAKE_PROGRAM?</a>
8846</dt> 8846</dt>
8847<dt>22.3. <a href="#devfaq.cc">What is the difference between 8847<dt>22.3. <a href="#devfaq.cc">What is the difference between
8848 CC, PKG_CC and 8848 CC, PKG_CC and
8849 PKGSRC_COMPILER?</a> 8849 PKGSRC_COMPILER?</a>
8850</dt> 8850</dt>
8851<dt>22.4. <a href="#devfaq.bl3flags">What is the difference between 8851<dt>22.4. <a href="#devfaq.bl3flags">What is the difference between
@@ -8870,157 +8870,157 @@ place.

 @@ -8870,157 +8870,157 @@ place.

8870</dt> 8870</dt>
8871<dt>22.9. <a href="#devfaq.too-much-time">I have a little time to kill. What shall I 8871<dt>22.9. <a href="#devfaq.too-much-time">I have a little time to kill. What shall I
8872do?</a> 8872do?</a>
8873</dt> 8873</dt>
8874</dl> 8874</dl>
8875<table border="0" style="width: 100%;"> 8875<table border="0" style="width: 100%;">
8876<colgroup> 8876<colgroup>
8877<col align="left" width="1%"> 8877<col align="left" width="1%">
8878<col> 8878<col>
8879</colgroup> 8879</colgroup>
8880<tbody> 8880<tbody>
8881<tr class="question"> 8881<tr class="question">
8882<td align="left" valign="top"> 8882<td align="left" valign="top">
8883<a name="devfaq.makeflags"></a><a name="idm79077808"></a><p><b>22.1.</b></p> 8883<a name="devfaq.makeflags"></a><a name="idm80784848"></a><p><b>22.1.</b></p>
8884</td> 8884</td>
8885<td align="left" valign="top"><p>What is the difference between 8885<td align="left" valign="top"><p>What is the difference between
8886 <code class="varname">MAKEFLAGS</code>, <code class="varname">.MAKEFLAGS</code> and 8886 <code class="varname">MAKEFLAGS</code>, <code class="varname">.MAKEFLAGS</code> and
8887 <code class="varname">MAKE_FLAGS</code>?</p></td> 8887 <code class="varname">MAKE_FLAGS</code>?</p></td>
8888</tr> 8888</tr>
8889<tr class="answer"> 8889<tr class="answer">
8890<td align="left" valign="top"></td> 8890<td align="left" valign="top"></td>
8891<td align="left" valign="top"><p><code class="varname">MAKEFLAGS</code> are the flags passed 8891<td align="left" valign="top"><p><code class="varname">MAKEFLAGS</code> are the flags passed
8892 to the pkgsrc-internal invocations of <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>, while 8892 to the pkgsrc-internal invocations of <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a>, while
8893 <code class="varname">MAKE_FLAGS</code> are the flags that are passed to 8893 <code class="varname">MAKE_FLAGS</code> are the flags that are passed to
8894 the <code class="varname">MAKE_PROGRAM</code> when building the 8894 the <code class="varname">MAKE_PROGRAM</code> when building the
8895 package. [FIXME: What is .MAKEFLAGS for?]</p></td> 8895 package. [FIXME: What is .MAKEFLAGS for?]</p></td>
8896</tr> 8896</tr>
8897<tr class="question"> 8897<tr class="question">
8898<td align="left" valign="top"> 8898<td align="left" valign="top">
8899<a name="devfaq.make"></a><a name="idm79073712"></a><p><b>22.2.</b></p> 8899<a name="devfaq.make"></a><a name="idm80780880"></a><p><b>22.2.</b></p>
8900</td> 8900</td>
8901<td align="left" valign="top"><p>What is the difference between 8901<td align="left" valign="top"><p>What is the difference between
8902 <code class="varname">MAKE</code>, <code class="varname">GMAKE</code> and 8902 <code class="varname">MAKE</code>, <code class="varname">GMAKE</code> and
8903 <code class="varname">MAKE_PROGRAM</code>?</p></td> 8903 <code class="varname">MAKE_PROGRAM</code>?</p></td>
8904</tr> 8904</tr>
8905<tr class="answer"> 8905<tr class="answer">
8906<td align="left" valign="top"></td> 8906<td align="left" valign="top"></td>
8907<td align="left" valign="top"><p><code class="varname">MAKE</code> is the path to the 8907<td align="left" valign="top"><p><code class="varname">MAKE</code> is the path to the
8908 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> program that is used in the pkgsrc 8908 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> program that is used in the pkgsrc
8909 infrastructure. <code class="varname">GMAKE</code> is the path to GNU 8909 infrastructure. <code class="varname">GMAKE</code> is the path to GNU
8910 Make, but you need to say <code class="varname">USE_TOOLS+=gmake</code> to 8910 Make, but you need to say <code class="varname">USE_TOOLS+=gmake</code> to
8911 use that. <code class="varname">MAKE_PROGRAM</code> is the path to the 8911 use that. <code class="varname">MAKE_PROGRAM</code> is the path to the
8912 Make program that is used for building the 8912 Make program that is used for building the
8913 package.</p></td> 8913 package.</p></td>
8914</tr> 8914</tr>
8915<tr class="question"> 8915<tr class="question">
8916<td align="left" valign="top"> 8916<td align="left" valign="top">
8917<a name="devfaq.cc"></a><a name="idm79069360"></a><p><b>22.3.</b></p> 8917<a name="devfaq.cc"></a><a name="idm80776400"></a><p><b>22.3.</b></p>
8918</td> 8918</td>
8919<td align="left" valign="top"><p>What is the difference between 8919<td align="left" valign="top"><p>What is the difference between
8920 <code class="varname">CC</code>, <code class="varname">PKG_CC</code> and 8920 <code class="varname">CC</code>, <code class="varname">PKG_CC</code> and
8921 <code class="varname">PKGSRC_COMPILER</code>?</p></td> 8921 <code class="varname">PKGSRC_COMPILER</code>?</p></td>
8922</tr> 8922</tr>
8923<tr class="answer"> 8923<tr class="answer">
8924<td align="left" valign="top"></td> 8924<td align="left" valign="top"></td>
8925<td align="left" valign="top"><p><code class="varname">CC</code> is the path to the real C 8925<td align="left" valign="top"><p><code class="varname">CC</code> is the path to the real C
8926 compiler, which can be configured by the pkgsrc user. 8926 compiler, which can be configured by the pkgsrc user.
8927 <code class="varname">PKG_CC</code> is the path to the compiler wrapper. 8927 <code class="varname">PKG_CC</code> is the path to the compiler wrapper.
8928 <code class="varname">PKGSRC_COMPILER</code> is <span class="emphasis"><em>not</em></span> a 8928 <code class="varname">PKGSRC_COMPILER</code> is <span class="emphasis"><em>not</em></span> a
8929 path to a compiler, but the type of compiler that should be 8929 path to a compiler, but the type of compiler that should be
8930 used. See <code class="filename">mk/compiler.mk</code> for more 8930 used. See <code class="filename">mk/compiler.mk</code> for more
8931 information about the latter variable.</p></td> 8931 information about the latter variable.</p></td>
8932</tr> 8932</tr>
8933<tr class="question"> 8933<tr class="question">
8934<td align="left" valign="top"> 8934<td align="left" valign="top">
8935<a name="devfaq.bl3flags"></a><a name="idm79065136"></a><p><b>22.4.</b></p> 8935<a name="devfaq.bl3flags"></a><a name="idm80772304"></a><p><b>22.4.</b></p>
8936</td> 8936</td>
8937<td align="left" valign="top"><p>What is the difference between 8937<td align="left" valign="top"><p>What is the difference between
8938 <code class="varname">BUILDLINK_LDFLAGS</code>, 8938 <code class="varname">BUILDLINK_LDFLAGS</code>,
8939 <code class="varname">BUILDLINK_LDADD</code> and 8939 <code class="varname">BUILDLINK_LDADD</code> and
8940 <code class="varname">BUILDLINK_LIBS</code>?</p></td> 8940 <code class="varname">BUILDLINK_LIBS</code>?</p></td>
8941</tr> 8941</tr>
8942<tr class="answer"> 8942<tr class="answer">
8943<td align="left" valign="top"></td> 8943<td align="left" valign="top"></td>
8944<td align="left" valign="top"><p>[FIXME]</p></td> 8944<td align="left" valign="top"><p>[FIXME]</p></td>
8945</tr> 8945</tr>
8946<tr class="question"> 8946<tr class="question">
8947<td align="left" valign="top"> 8947<td align="left" valign="top">
8948<a name="devfaq.bl3prefix"></a><a name="idm79062960"></a><p><b>22.5.</b></p> 8948<a name="devfaq.bl3prefix"></a><a name="idm80770000"></a><p><b>22.5.</b></p>
8949</td> 8949</td>
8950<td align="left" valign="top"><p>Why does <span class="command"><strong>make show-var 8950<td align="left" valign="top"><p>Why does <span class="command"><strong>make show-var
8951 VARNAME=BUILDLINK_PREFIX.<em class="replaceable"><code>foo</code></em></strong></span> 8951 VARNAME=BUILDLINK_PREFIX.<em class="replaceable"><code>foo</code></em></strong></span>
8952 say it's empty?</p></td> 8952 say it's empty?</p></td>
8953</tr> 8953</tr>
8954<tr class="answer"> 8954<tr class="answer">
8955<td align="left" valign="top"></td> 8955<td align="left" valign="top"></td>
8956<td align="left" valign="top"><p>For optimization reasons, some variables are only 8956<td align="left" valign="top"><p>For optimization reasons, some variables are only
8957 available in the <span class="quote">&#8220;<span class="quote">wrapper</span>&#8221;</span> phase and later. To 8957 available in the <span class="quote">&#8220;<span class="quote">wrapper</span>&#8221;</span> phase and later. To
8958 <span class="quote">&#8220;<span class="quote">simulate</span>&#8221;</span> the wrapper phase, append 8958 <span class="quote">&#8220;<span class="quote">simulate</span>&#8221;</span> the wrapper phase, append
8959 <span class="command"><strong>PKG_PHASE=wrapper</strong></span> to the above 8959 <span class="command"><strong>PKG_PHASE=wrapper</strong></span> to the above
8960 command.</p></td> 8960 command.</p></td>
8961</tr> 8961</tr>
8962<tr class="question"> 8962<tr class="question">
8963<td align="left" valign="top"> 8963<td align="left" valign="top">
8964<a name="devfaq.master_sites"></a><a name="idm79059888"></a><p><b>22.6.</b></p> 8964<a name="devfaq.master_sites"></a><a name="idm80766928"></a><p><b>22.6.</b></p>
8965</td> 8965</td>
8966<td align="left" valign="top"><p>What does 8966<td align="left" valign="top"><p>What does
8967 <code class="code">${MASTER_SITE_SOURCEFORGE:=package/}</code> mean? I 8967 <code class="code">${MASTER_SITE_SOURCEFORGE:=package/}</code> mean? I
8968 don't understand the <code class="code">:=</code> inside 8968 don't understand the <code class="code">:=</code> inside
8969 it.</p></td> 8969 it.</p></td>
8970</tr> 8970</tr>
8971<tr class="answer"> 8971<tr class="answer">
8972<td align="left" valign="top"></td> 8972<td align="left" valign="top"></td>
8973<td align="left" valign="top"><p>The <code class="code">:=</code> is not really an 8973<td align="left" valign="top"><p>The <code class="code">:=</code> is not really an
8974 assignment operator, although it looks like it. 8974 assignment operator, although it looks like it.
8975 Instead, it is a degenerate form of 8975 Instead, it is a degenerate form of
8976 <code class="code">${LIST:<em class="replaceable"><code>old_string</code></em>=<em class="replaceable"><code>new_string</code></em>}</code>, 8976 <code class="code">${LIST:<em class="replaceable"><code>old_string</code></em>=<em class="replaceable"><code>new_string</code></em>}</code>,
8977 which is documented in the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> man page and which is 8977 which is documented in the <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?make+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">make</span>(1)</span></a> man page and which is
8978 commonly used in the form <code class="code">${SRCS:.c=.o}</code>. In the 8978 commonly used in the form <code class="code">${SRCS:.c=.o}</code>. In the
8979 case of <code class="varname">MASTER_SITE_*</code>, 8979 case of <code class="varname">MASTER_SITE_*</code>,
8980 <em class="replaceable"><code>old_string</code></em> is the empty string and 8980 <em class="replaceable"><code>old_string</code></em> is the empty string and
8981 <em class="replaceable"><code>new_string</code></em> is 8981 <em class="replaceable"><code>new_string</code></em> is
8982 <code class="code">package/</code>. That's where the 8982 <code class="code">package/</code>. That's where the
8983 <code class="code">:</code> and the <code class="code">=</code> fall 8983 <code class="code">:</code> and the <code class="code">=</code> fall
8984 together.</p></td> 8984 together.</p></td>
8985</tr> 8985</tr>
8986<tr class="question"> 8986<tr class="question">
8987<td align="left" valign="top"> 8987<td align="left" valign="top">
8988<a name="devfaq.mailinglists"></a><a name="idm79044784"></a><p><b>22.7.</b></p> 8988<a name="devfaq.mailinglists"></a><a name="idm80760016"></a><p><b>22.7.</b></p>
8989</td> 8989</td>
8990<td align="left" valign="top"><p>Which mailing lists are there for package 8990<td align="left" valign="top"><p>Which mailing lists are there for package
8991 developers?</p></td> 8991 developers?</p></td>
8992</tr> 8992</tr>
8993<tr class="answer"> 8993<tr class="answer">
8994<td align="left" valign="top"></td> 8994<td align="left" valign="top"></td>
8995<td align="left" valign="top"><div class="variablelist"><dl class="variablelist"> 8995<td align="left" valign="top"><div class="variablelist"><dl class="variablelist">
8996<dt><span class="term"><a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#tech-pkg" target="_top">tech-pkg</a></span></dt> 8996<dt><span class="term"><a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#tech-pkg" target="_top">tech-pkg</a></span></dt>
8997<dd><p>This is a list for technical discussions related 8997<dd><p>This is a list for technical discussions related
8998 to pkgsrc development, e.g. soliciting feedback for changes to 8998 to pkgsrc development, e.g. soliciting feedback for changes to
8999 pkgsrc infrastructure, proposed new features, questions related 8999 pkgsrc infrastructure, proposed new features, questions related
9000 to porting pkgsrc to a new platform, advice for maintaining a 9000 to porting pkgsrc to a new platform, advice for maintaining a
9001 package, patches that affect many packages, help requests moved 9001 package, patches that affect many packages, help requests moved
9002 from pkgsrc-users when an infrastructure bug is found, 9002 from pkgsrc-users when an infrastructure bug is found,
9003 etc.</p></dd> 9003 etc.</p></dd>
9004<dt><span class="term"><a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#pkgsrc-bugs" target="_top">pkgsrc-bugs</a></span></dt> 9004<dt><span class="term"><a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#pkgsrc-bugs" target="_top">pkgsrc-bugs</a></span></dt>
9005<dd><p>All bug reports in category "pkg" sent with 9005<dd><p>All bug reports in category "pkg" sent with
9006 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a> appear here. Please do not report your bugs here 9006 <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?send-pr+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">send-pr</span>(1)</span></a> appear here. Please do not report your bugs here
9007 directly; use one of the other mailing 9007 directly; use one of the other mailing
9008 lists.</p></dd> 9008 lists.</p></dd>
9009</dl></div></td> 9009</dl></div></td>
9010</tr> 9010</tr>
9011<tr class="question"> 9011<tr class="question">
9012<td align="left" valign="top"> 9012<td align="left" valign="top">
9013<a name="devfaq.documentation"></a><a name="idm79040944"></a><p><b>22.8.</b></p> 9013<a name="devfaq.documentation"></a><a name="idm80756304"></a><p><b>22.8.</b></p>
9014</td> 9014</td>
9015<td align="left" valign="top"><p>Where is the pkgsrc 9015<td align="left" valign="top"><p>Where is the pkgsrc
9016 documentation?</p></td> 9016 documentation?</p></td>
9017</tr> 9017</tr>
9018<tr class="answer"> 9018<tr class="answer">
9019<td align="left" valign="top"></td> 9019<td align="left" valign="top"></td>
9020<td align="left" valign="top"> 9020<td align="left" valign="top">
9021<p>There are many places where you can find 9021<p>There are many places where you can find
9022 documentation about pkgsrc:</p> 9022 documentation about pkgsrc:</p>
9023<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 9023<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
9024<li class="listitem"><p>The pkgsrc guide (this document) is a collection 9024<li class="listitem"><p>The pkgsrc guide (this document) is a collection
9025 of chapters that explain large parts of pkgsrc, but some 9025 of chapters that explain large parts of pkgsrc, but some
9026 chapters tend to be outdated. Which ones they are is hard to 9026 chapters tend to be outdated. Which ones they are is hard to
@@ -9048,39 +9048,39 @@ do? @@ -9048,39 +9048,39 @@ do?
9048 documented</span>&#8221;</span>, that is the documentation exists only in the 9048 documented</span>&#8221;</span>, that is the documentation exists only in the
9049 mind of the developer who wrote the code. To get this 9049 mind of the developer who wrote the code. To get this
9050 information, use the <span class="command"><strong>cvs annotate</strong></span> command 9050 information, use the <span class="command"><strong>cvs annotate</strong></span> command
9051 to see who has written it and ask on the 9051 to see who has written it and ask on the
9052 <code class="literal">tech-pkg</code> mailing list, so that others can 9052 <code class="literal">tech-pkg</code> mailing list, so that others can
9053 find your questions later (see above). To be sure that the 9053 find your questions later (see above). To be sure that the
9054 developer in charge reads the mail, you may CC him or 9054 developer in charge reads the mail, you may CC him or
9055 her.</p></li> 9055 her.</p></li>
9056</ul></div> 9056</ul></div>
9057</td> 9057</td>
9058</tr> 9058</tr>
9059<tr class="question"> 9059<tr class="question">
9060<td align="left" valign="top"> 9060<td align="left" valign="top">
9061<a name="devfaq.too-much-time"></a><a name="idm79034416"></a><p><b>22.9.</b></p> 9061<a name="devfaq.too-much-time"></a><a name="idm80749776"></a><p><b>22.9.</b></p>
9062</td> 9062</td>
9063<td align="left" valign="top"><p>I have a little time to kill. What shall I 9063<td align="left" valign="top"><p>I have a little time to kill. What shall I
9064do?</p></td> 9064do?</p></td>
9065</tr> 9065</tr>
9066<tr class="answer"> 9066<tr class="answer">
9067<td align="left" valign="top"></td> 9067<td align="left" valign="top"></td>
9068<td align="left" valign="top"> 9068<td align="left" valign="top">
9069<p>This is not really an FAQ yet, but here's the answer 9069<p>This is not really an FAQ yet, but here's the answer
9070anyway.</p> 9070anyway.</p>
9071<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 9071<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
9072<li class="listitem"><p>Run <span class="command"><strong>pkg_chk -N</strong></span> (from the 9072<li class="listitem"><p>Run <span class="command"><strong>pkg_chk -N</strong></span> (from the
9073 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_chk/README.html" target="_top"><code class="filename">pkgtools/pkg_chk</code></a> package). It 9073 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_chk/README.html" target="_top"><code class="filename">pkgtools/pkg_chk</code></a> package). It
9074 will tell you about newer versions of installed packages that are 9074 will tell you about newer versions of installed packages that are
9075 available, but not yet updated in pkgsrc.</p></li> 9075 available, but not yet updated in pkgsrc.</p></li>
9076<li class="listitem"><p>Browse <code class="filename">pkgsrc/doc/TODO</code> 9076<li class="listitem"><p>Browse <code class="filename">pkgsrc/doc/TODO</code>
9077 &mdash; it contains a list of suggested new packages and a list of 9077 &mdash; it contains a list of suggested new packages and a list of
9078 cleanups and enhancements for pkgsrc that would be nice to 9078 cleanups and enhancements for pkgsrc that would be nice to
9079 have.</p></li> 9079 have.</p></li>
9080<li class="listitem"><p>Review packages for which review was requested on 9080<li class="listitem"><p>Review packages for which review was requested on
9081 the <a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#tech-pkg" target="_top">tech-pkg</a> 9081 the <a class="ulink" href="http://www.NetBSD.org/mailinglists/index.html#tech-pkg" target="_top">tech-pkg</a>
9082 mailing list.</p></li> 9082 mailing list.</p></li>
9083</ul></div> 9083</ul></div>
9084</td> 9084</td>
9085</tr> 9085</tr>
9086</tbody> 9086</tbody>
@@ -9126,45 +9126,45 @@ important information regarding their in @@ -9126,45 +9126,45 @@ important information regarding their in
9126<h3 class="title">We need your help!</h3> 9126<h3 class="title">We need your help!</h3>
9127<p>Should you have some spare cycles to devote to NetBSD, pkgsrc 9127<p>Should you have some spare cycles to devote to NetBSD, pkgsrc
9128 and GNOME and are willing to learn new exciting stuff, please jump 9128 and GNOME and are willing to learn new exciting stuff, please jump
9129 straight to the <a class="ulink" href="http://www.NetBSD.org/contrib/projects.html#gnome" target="_top">pending 9129 straight to the <a class="ulink" href="http://www.NetBSD.org/contrib/projects.html#gnome" target="_top">pending
9130 work</a> list! There is still a long way to go to get a 9130 work</a> list! There is still a long way to go to get a
9131 fully-functional GNOME desktop under NetBSD and we need your help to 9131 fully-functional GNOME desktop under NetBSD and we need your help to
9132 achieve it!</p> 9132 achieve it!</p>
9133</div> 9133</div>
9134<div class="sect1"> 9134<div class="sect1">
9135<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 9135<div class="titlepage"><div><div><h2 class="title" style="clear: both">
9136<a name="meta-packages"></a>23.1. Meta packages</h2></div></div></div> 9136<a name="meta-packages"></a>23.1. Meta packages</h2></div></div></div>
9137<p>pkgsrc includes three GNOME-related meta packages:</p> 9137<p>pkgsrc includes three GNOME-related meta packages:</p>
9138<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "> 9138<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
9139<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-base/README.html" target="_top"><code class="filename">meta-pkgs/gnome-base</code></a>: Provides 9139<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-base/README.html" target="_top"><code class="filename">meta-pkgs/gnome-base</code></a>: Provides
9140 the core GNOME desktop environment. It only includes the necessary 9140 the core GNOME desktop environment. It only includes the necessary
9141 bits to get it to boot correctly, although it may lack important 9141 bits to get it to boot correctly, although it may lack important
9142 functionality for daily operation. The idea behind this package is 9142 functionality for daily operation. The idea behind this package is
9143 to let end users build their own configurations on top of this one, 9143 to let end users build their own configurations on top of this one,
9144 first installing this meta package to achieve a functional setup and 9144 first installing this meta package to achieve a functional setup and
9145 then adding individual applications.</p></li> 9145 then adding individual applications.</p></li>
9146<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome/README.html" target="_top"><code class="filename">meta-pkgs/gnome</code></a>: Provides a 9146<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome/README.html" target="_top"><code class="filename">meta-pkgs/gnome</code></a>: Provides a
9147 complete installation of the GNOME platform and desktop as defined 9147 complete installation of the GNOME platform and desktop as defined
9148 by the GNOME project; this is based on the components distributed in 9148 by the GNOME project; this is based on the components distributed in
9149 the <code class="filename">platform/x.y/x.y.z/sources</code> and 9149 the <code class="filename">platform/x.y/x.y.z/sources</code> and
9150 <code class="filename">desktop/x.y/x.y.z/sources</code> directories of the 9150 <code class="filename">desktop/x.y/x.y.z/sources</code> directories of the
9151 official FTP server. Developer-only tools found in those 9151 official FTP server. Developer-only tools found in those
9152 directories are not installed unless required by some other 9152 directories are not installed unless required by some other
9153 component to work properly. Similarly, packages from the bindings 9153 component to work properly. Similarly, packages from the bindings
9154 set (<code class="filename">bindings/x.y/x.y.z/sources</code>) are not pulled 9154 set (<code class="filename">bindings/x.y/x.y.z/sources</code>) are not pulled
9155 in unless required as a dependency for an end-user component. This 9155 in unless required as a dependency for an end-user component. This
9156 package "extends" <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-base/README.html" target="_top"><code class="filename">meta-pkgs/gnome-base</code></a>.</p></li> 9156 package "extends" <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-base/README.html" target="_top"><code class="filename">meta-pkgs/gnome-base</code></a>.</p></li>
9157<li class="listitem"><p><a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-devel/README.html" target="_top"><code class="filename">meta-pkgs/gnome-devel</code></a>: 9157<li class="listitem"><p><a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-devel/README.html" target="_top"><code class="filename">meta-pkgs/gnome-devel</code></a>:
9158 Installs all the tools required to build a GNOME component when 9158 Installs all the tools required to build a GNOME component when
9159 fetched from the CVS repository. These are required to let the 9159 fetched from the CVS repository. These are required to let the
9160 <span class="command"><strong>autogen.sh</strong></span> scripts work appropriately.</p></li> 9160 <span class="command"><strong>autogen.sh</strong></span> scripts work appropriately.</p></li>
9161</ul></div> 9161</ul></div>
9162<p>In all these packages, the <code class="varname">DEPENDS</code> lines are 9162<p>In all these packages, the <code class="varname">DEPENDS</code> lines are
9163sorted in a way that eases updates: a package may depend on other 9163sorted in a way that eases updates: a package may depend on other
9164packages listed before it but not on any listed after it. It is very 9164packages listed before it but not on any listed after it. It is very
9165important to keep this order to ease updates so... <span class="emphasis"><em>do not 9165important to keep this order to ease updates so... <span class="emphasis"><em>do not
9166change it to alphabetical sorting!</em></span></p> 9166change it to alphabetical sorting!</em></span></p>
9167</div> 9167</div>
9168<div class="sect1"> 9168<div class="sect1">
9169<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 9169<div class="titlepage"><div><div><h2 class="title" style="clear: both">
9170<a name="new-package"></a>23.2. Packaging a GNOME application</h2></div></div></div> 9170<a name="new-package"></a>23.2. Packaging a GNOME application</h2></div></div></div>
@@ -9179,27 +9179,27 @@ give you a general idea on the minimum r @@ -9179,27 +9179,27 @@ give you a general idea on the minimum r
9179 package:</p> 9179 package:</p>
9180<pre class="programlisting"> 9180<pre class="programlisting">
9181GNU_CONFIGURE=yes 9181GNU_CONFIGURE=yes
9182USE_LIBTOOL=yes 9182USE_LIBTOOL=yes
9183USE_TOOLS+=gmake 9183USE_TOOLS+=gmake
9184</pre> 9184</pre>
9185</li> 9185</li>
9186<li class="listitem"> 9186<li class="listitem">
9187<p>If the package uses pkg-config to detect dependencies, add this 9187<p>If the package uses pkg-config to detect dependencies, add this
9188 tool to the list of required utilities:</p> 9188 tool to the list of required utilities:</p>
9189<pre class="programlisting"> 9189<pre class="programlisting">
9190USE_TOOLS+=pkg-config 9190USE_TOOLS+=pkg-config
9191</pre> 9191</pre>
9192<p>Also use <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/verifypc/README.html" target="_top"><code class="filename">pkgtools/verifypc</code></a> at 9192<p>Also use <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/verifypc/README.html" target="_top"><code class="filename">pkgtools/verifypc</code></a> at
9193 the end of the build process to ensure that you did not miss to 9193 the end of the build process to ensure that you did not miss to
9194 specify any dependency in your package and that the version 9194 specify any dependency in your package and that the version
9195 requirements are all correct.</p> 9195 requirements are all correct.</p>
9196</li> 9196</li>
9197<li class="listitem"><p>If the package uses intltool, be sure to add 9197<li class="listitem"><p>If the package uses intltool, be sure to add
9198 <code class="literal">intltool</code> to the <code class="varname">USE_TOOLS</code> 9198 <code class="literal">intltool</code> to the <code class="varname">USE_TOOLS</code>
9199 to handle dependencies and to force the package to use the latest 9199 to handle dependencies and to force the package to use the latest
9200 available version.</p></li> 9200 available version.</p></li>
9201<li class="listitem"> 9201<li class="listitem">
9202<p>If the package uses gtk-doc (a documentation generation 9202<p>If the package uses gtk-doc (a documentation generation
9203 utility), do <span class="emphasis"><em>not</em></span> add a dependency on it. The 9203 utility), do <span class="emphasis"><em>not</em></span> add a dependency on it. The
9204 tool is rather big and the distfile should come with pregenerated 9204 tool is rather big and the distfile should come with pregenerated
9205 documentation anyway; if it does not, it is a bug that you ought to 9205 documentation anyway; if it does not, it is a bug that you ought to
@@ -9328,27 +9328,27 @@ followed:

 @@ -9328,27 +9328,27 @@ followed:

9328<li class="listitem"> 9328<li class="listitem">
9329<p>For each meta package, update all its 9329<p>For each meta package, update all its
9330 <code class="varname">DEPENDS</code> lines to match the latest versions as 9330 <code class="varname">DEPENDS</code> lines to match the latest versions as
9331 shown by the above commands. Do <span class="emphasis"><em>not</em></span> list any 9331 shown by the above commands. Do <span class="emphasis"><em>not</em></span> list any
9332 newer version (even if found in the FTP) because the meta packages 9332 newer version (even if found in the FTP) because the meta packages
9333 are supposed to list the exact versions that form a specific GNOME 9333 are supposed to list the exact versions that form a specific GNOME
9334 release. Exceptions are permitted here if a newer version solves a 9334 release. Exceptions are permitted here if a newer version solves a
9335 serious issue in the overall desktop experience; these typically 9335 serious issue in the overall desktop experience; these typically
9336 come in the form of a revision bump in pkgsrc, not in newer versions 9336 come in the form of a revision bump in pkgsrc, not in newer versions
9337 from the developers.</p> 9337 from the developers.</p>
9338<p>Packages not listed in the <code class="filename">list.txt</code> file 9338<p>Packages not listed in the <code class="filename">list.txt</code> file
9339 should be updated to the latest version available (if found in 9339 should be updated to the latest version available (if found in
9340 pkgsrc). This is the case, for example, of the dependencies on the 9340 pkgsrc). This is the case, for example, of the dependencies on the
9341 GNU Autotools in the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-devel/README.html" target="_top"><code class="filename">meta-pkgs/gnome-devel</code></a> meta package.</p> 9341 GNU Autotools in the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/gnome-devel/README.html" target="_top"><code class="filename">meta-pkgs/gnome-devel</code></a> meta package.</p>
9342</li> 9342</li>
9343<li class="listitem"> 9343<li class="listitem">
9344<p>Generate a patch from the modified meta packages and extract the 9344<p>Generate a patch from the modified meta packages and extract the
9345 list of "new" lines. This will provide you an outline on what 9345 list of "new" lines. This will provide you an outline on what
9346 packages need to be updated in pkgsrc and in what order:</p> 9346 packages need to be updated in pkgsrc and in what order:</p>
9347<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cvs diff -u gnome-devel gnome-base gnome | grep '^+D' &gt;todo.txt</code></strong></pre> 9347<pre class="screen"><code class="prompt">%</code> <strong class="userinput"><code>cvs diff -u gnome-devel gnome-base gnome | grep '^+D' &gt;todo.txt</code></strong></pre>
9348</li> 9348</li>
9349<li class="listitem"><p>For major desktop updates it is recommended to zap all your 9349<li class="listitem"><p>For major desktop updates it is recommended to zap all your
9350 installed packages and start over from scratch at this point.</p></li> 9350 installed packages and start over from scratch at this point.</p></li>
9351<li class="listitem"><p>Now comes the longest step by far: iterate over the contents 9351<li class="listitem"><p>Now comes the longest step by far: iterate over the contents
9352 of <code class="filename">todo.txt</code> and update the packages listed in 9352 of <code class="filename">todo.txt</code> and update the packages listed in
9353 it in order. For major desktop updates none of these should be 9353 it in order. For major desktop updates none of these should be
9354 committed until the entire set is completed because there are chances 9354 committed until the entire set is completed because there are chances
@@ -9723,27 +9723,27 @@ CFLAGS+= -Wall @@ -9723,27 +9723,27 @@ CFLAGS+= -Wall
9723</dl> 9723</dl>
9724</div> 9724</div>
9725<p>The pkgsrc infrastructure consists of a large codebase, 9725<p>The pkgsrc infrastructure consists of a large codebase,
9726 and there are many corners where every little bit of a file is 9726 and there are many corners where every little bit of a file is
9727 well thought out, making pkgsrc likely to fail as soon as 9727 well thought out, making pkgsrc likely to fail as soon as
9728 anything is changed near those parts. To prevent most changes 9728 anything is changed near those parts. To prevent most changes
9729 from breaking anything, a suite of regression tests should go 9729 from breaking anything, a suite of regression tests should go
9730 along with every important part of the pkgsrc infrastructure. 9730 along with every important part of the pkgsrc infrastructure.
9731 This chapter describes how regression tests work in pkgsrc and 9731 This chapter describes how regression tests work in pkgsrc and
9732 how you can add new tests.</p> 9732 how you can add new tests.</p>
9733<div class="sect1"> 9733<div class="sect1">
9734<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 9734<div class="titlepage"><div><div><h2 class="title" style="clear: both">
9735<a name="regression.run"></a>25.1. Running the regression tests</h2></div></div></div> 9735<a name="regression.run"></a>25.1. Running the regression tests</h2></div></div></div>
9736<p>You first need to install the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_regress/README.html" target="_top"><code class="filename">pkgtools/pkg_regress</code></a> package, which 9736<p>You first need to install the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkg_regress/README.html" target="_top"><code class="filename">pkgtools/pkg_regress</code></a> package, which
9737 provides the <span class="command"><strong>pkg_regress</strong></span> command. Then you 9737 provides the <span class="command"><strong>pkg_regress</strong></span> command. Then you
9738 can simply run that command, which will run all tests in the 9738 can simply run that command, which will run all tests in the
9739 <code class="filename">regress</code> category.</p> 9739 <code class="filename">regress</code> category.</p>
9740</div> 9740</div>
9741<div class="sect1"> 9741<div class="sect1">
9742<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 9742<div class="titlepage"><div><div><h2 class="title" style="clear: both">
9743<a name="regression.new"></a>25.2. Adding a new regression test</h2></div></div></div> 9743<a name="regression.new"></a>25.2. Adding a new regression test</h2></div></div></div>
9744<p>Every directory in the <code class="filename">regress</code> 9744<p>Every directory in the <code class="filename">regress</code>
9745 category that contains a file called <code class="filename">spec</code> 9745 category that contains a file called <code class="filename">spec</code>
9746 is considered a regression test. This file is a shell program 9746 is considered a regression test. This file is a shell program
9747 that is included by the <span class="command"><strong>pkg_regress</strong></span> command. 9747 that is included by the <span class="command"><strong>pkg_regress</strong></span> command.
9748 The following functions can be overridden to suit your 9748 The following functions can be overridden to suit your
9749 needs.</p> 9749 needs.</p>
@@ -9855,27 +9855,27 @@ output_require "^[[:alpha:]+[[:space:]][ @@ -9855,27 +9855,27 @@ output_require "^[[:alpha:]+[[:space:]][
9855 appear in this file.</p></dd> 9855 appear in this file.</p></dd>
9856<dt><span class="term"><code class="filename">mk/platform/<em class="replaceable"><code>MyOS</code></em>.mk</code></span></dt> 9856<dt><span class="term"><code class="filename">mk/platform/<em class="replaceable"><code>MyOS</code></em>.mk</code></span></dt>
9857<dd><p>This file contains the platform-specific 9857<dd><p>This file contains the platform-specific
9858 definitions that are used by pkgsrc. Start by copying one of the 9858 definitions that are used by pkgsrc. Start by copying one of the
9859 other files and edit it to your 9859 other files and edit it to your
9860 needs.</p></dd> 9860 needs.</p></dd>
9861<dt><span class="term"><code class="filename">mk/tools/tools.<em class="replaceable"><code>MyOS</code></em>.mk</code></span></dt> 9861<dt><span class="term"><code class="filename">mk/tools/tools.<em class="replaceable"><code>MyOS</code></em>.mk</code></span></dt>
9862<dd><p>This file defines the paths to all the tools 9862<dd><p>This file defines the paths to all the tools
9863 that are needed by one or the other package in pkgsrc, as well 9863 that are needed by one or the other package in pkgsrc, as well
9864 as by pkgsrc itself. Find out where these tools are on your 9864 as by pkgsrc itself. Find out where these tools are on your
9865 platform and add them.</p></dd> 9865 platform and add them.</p></dd>
9866</dl></div> 9866</dl></div>
9867<p>Now, you should be able to build some basic packages, like 9867<p>Now, you should be able to build some basic packages, like
9868 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/perl5/README.html" target="_top"><code class="filename">lang/perl5</code></a>, <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/shells/bash/README.html" target="_top"><code class="filename">shells/bash</code></a>.</p> 9868 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/lang/perl5/README.html" target="_top"><code class="filename">lang/perl5</code></a>, <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/shells/bash/README.html" target="_top"><code class="filename">shells/bash</code></a>.</p>
9869</div> 9869</div>
9870</div> 9870</div>
9871</div> 9871</div>
9872<div class="appendix"> 9872<div class="appendix">
9873<div class="titlepage"><div><div><h1 class="title"> 9873<div class="titlepage"><div><div><h1 class="title">
9874<a name="examples"></a>Appendix A. A simple example package: bison</h1></div></div></div> 9874<a name="examples"></a>Appendix A. A simple example package: bison</h1></div></div></div>
9875<div class="toc"> 9875<div class="toc">
9876<p><b>Table of Contents</b></p> 9876<p><b>Table of Contents</b></p>
9877<dl class="toc"> 9877<dl class="toc">
9878<dt><span class="sect1"><a href="#example-files">A.1. files</a></span></dt> 9878<dt><span class="sect1"><a href="#example-files">A.1. files</a></span></dt>
9879<dd><dl> 9879<dd><dl>
9880<dt><span class="sect2"><a href="#example-Makefile">A.1.1. Makefile</a></span></dt> 9880<dt><span class="sect2"><a href="#example-Makefile">A.1.1. Makefile</a></span></dt>
9881<dt><span class="sect2"><a href="#example-descr">A.1.2. DESCR</a></span></dt> 9881<dt><span class="sect2"><a href="#example-descr">A.1.2. DESCR</a></span></dt>
@@ -9909,47 +9909,47 @@ HOMEPAGE= http://www.gnu.org/softw @@ -9909,47 +9909,47 @@ HOMEPAGE= http://www.gnu.org/softw
9909COMMENT= GNU yacc clone 9909COMMENT= GNU yacc clone
9910 9910
9911GNU_CONFIGURE= yes 9911GNU_CONFIGURE= yes
9912INFO_FILES= yes 9912INFO_FILES= yes
9913 9913
9914.include "../../mk/bsd.pkg.mk" 9914.include "../../mk/bsd.pkg.mk"
9915</pre> 9915</pre>
9916</div> 9916</div>
9917<div class="sect2"> 9917<div class="sect2">
9918<div class="titlepage"><div><div><h3 class="title"> 9918<div class="titlepage"><div><div><h3 class="title">
9919<a name="example-descr"></a>A.1.2. DESCR</h3></div></div></div> 9919<a name="example-descr"></a>A.1.2. DESCR</h3></div></div></div>
9920<pre class="programlisting"> 9920<pre class="programlisting">
9921GNU version of yacc. Can make re-entrant parsers, and numerous other 9921GNU version of yacc. Can make re-entrant parsers, and numerous other
9922improvements. Why you would want this when Berkeley <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?yacc+1.i386+NetBSD-7.1"><span class="citerefentry"><span class="refentrytitle">yacc</span>(1)</span></a> is part 9922improvements. Why you would want this when Berkeley <a class="citerefentry" href="http://netbsd.gw.com/cgi-bin/man-cgi?yacc+1.i386+NetBSD-7.1.2"><span class="citerefentry"><span class="refentrytitle">yacc</span>(1)</span></a> is part
9923of the NetBSD source tree is beyond me. 9923of the NetBSD source tree is beyond me.
9924</pre> 9924</pre>
9925</div> 9925</div>
9926<div class="sect2"> 9926<div class="sect2">
9927<div class="titlepage"><div><div><h3 class="title"> 9927<div class="titlepage"><div><div><h3 class="title">
9928<a name="example-plist"></a>A.1.3. PLIST</h3></div></div></div> 9928<a name="example-plist"></a>A.1.3. PLIST</h3></div></div></div>
9929<pre class="programlisting"> 9929<pre class="programlisting">
9930@comment $NetBSD$ 9930@comment $NetBSD$
9931bin/bison 9931bin/bison
9932man/man1/bison.1.gz 9932man/man1/bison.1.gz
9933share/bison.simple 9933share/bison.simple
9934share/bison.hairy 9934share/bison.hairy
9935</pre> 9935</pre>
9936</div> 9936</div>
9937<div class="sect2"> 9937<div class="sect2">
9938<div class="titlepage"><div><div><h3 class="title"> 9938<div class="titlepage"><div><div><h3 class="title">
9939<a name="checking-package-with-pkglint"></a>A.1.4. Checking a package with <span class="command"><strong>pkglint</strong></span> 9939<a name="checking-package-with-pkglint"></a>A.1.4. Checking a package with <span class="command"><strong>pkglint</strong></span>
9940</h3></div></div></div> 9940</h3></div></div></div>
9941<p>The NetBSD package system comes with 9941<p>The NetBSD package system comes with
9942 <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a> 9942 <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/pkgtools/pkglint/README.html" target="_top"><code class="filename">pkgtools/pkglint</code></a>
9943 which helps to check the contents of these 9943 which helps to check the contents of these
9944 files. After installation it is quite easy to use, just change to the 9944 files. After installation it is quite easy to use, just change to the
9945 directory of the package you wish to examine and execute 9945 directory of the package you wish to examine and execute
9946 <span class="command"><strong>pkglint</strong></span>:</p> 9946 <span class="command"><strong>pkglint</strong></span>:</p>
9947<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>pkglint</code></strong> 9947<pre class="screen"><code class="prompt">$</code> <strong class="userinput"><code>pkglint</code></strong>
9948looks fine.</pre> 9948looks fine.</pre>
9949<p>Depending on the supplied command line arguments (see pkglint(1)), 9949<p>Depending on the supplied command line arguments (see pkglint(1)),
9950 more checks will be performed. Use e.g. <span class="command"><strong>pkglint -Call 9950 more checks will be performed. Use e.g. <span class="command"><strong>pkglint -Call
9951 -Wall</strong></span> for a very thorough check.</p> 9951 -Wall</strong></span> for a very thorough check.</p>
9952</div> 9952</div>
9953</div> 9953</div>
9954<div class="sect1"> 9954<div class="sect1">
9955<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 9955<div class="titlepage"><div><div><h2 class="title" style="clear: both">
@@ -10309,27 +10309,27 @@ source packages @@ -10309,27 +10309,27 @@ source packages
10309 The PDF version of the pkgsrc guide.</p></li> 10309 The PDF version of the pkgsrc guide.</p></li>
10310<li class="listitem"><p><a class="ulink" href="http://www.NetBSD.org/docs/pkgsrc/pkgsrc.ps" target="_top">http://www.NetBSD.org/docs/pkgsrc/pkgsrc.ps</a>: 10310<li class="listitem"><p><a class="ulink" href="http://www.NetBSD.org/docs/pkgsrc/pkgsrc.ps" target="_top">http://www.NetBSD.org/docs/pkgsrc/pkgsrc.ps</a>:
10311 PostScript version of the pkgsrc guide.</p></li> 10311 PostScript version of the pkgsrc guide.</p></li>
10312</ul></div> 10312</ul></div>
10313</div> 10313</div>
10314<div class="sect1"> 10314<div class="sect1">
10315<div class="titlepage"><div><div><h2 class="title" style="clear: both"> 10315<div class="titlepage"><div><div><h2 class="title" style="clear: both">
10316<a name="procedure"></a>D.2. Procedure</h2></div></div></div> 10316<a name="procedure"></a>D.2. Procedure</h2></div></div></div>
10317<p>The procedure to edit the pkgsrc guide is:</p> 10317<p>The procedure to edit the pkgsrc guide is:</p>
10318<div class="procedure"><ol class="procedure" type="1"> 10318<div class="procedure"><ol class="procedure" type="1">
10319<li class="step"><p>Make sure you have the packages needed to 10319<li class="step"><p>Make sure you have the packages needed to
10320 regenerate the pkgsrc guide (and other XML-based NetBSD 10320 regenerate the pkgsrc guide (and other XML-based NetBSD
10321 documentation) installed. These are automatically installed when 10321 documentation) installed. These are automatically installed when
10322 you install the <a href="http://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/pkgsrc-guide-tools/README.html" target="_top"><code class="filename">meta-pkgs/pkgsrc-guide-tools</code></a> package.</p></li> 10322 you install the <a href="https://cdn.NetBSD.org/pub/pkgsrc/current/pkgsrc/meta-pkgs/pkgsrc-guide-tools/README.html" target="_top"><code class="filename">meta-pkgs/pkgsrc-guide-tools</code></a> package.</p></li>
10323<li class="step"><p>Run <span class="command"><strong>cd doc/guide</strong></span> to get to the 10323<li class="step"><p>Run <span class="command"><strong>cd doc/guide</strong></span> to get to the
10324 right directory. All further steps will take place 10324 right directory. All further steps will take place
10325 here.</p></li> 10325 here.</p></li>
10326<li class="step"><p>Edit the XML file(s) in 10326<li class="step"><p>Edit the XML file(s) in
10327 <code class="filename">files/</code>.</p></li> 10327 <code class="filename">files/</code>.</p></li>
10328<li class="step"><p>Run <span class="command"><strong>bmake</strong></span> to check the pkgsrc 10328<li class="step"><p>Run <span class="command"><strong>bmake</strong></span> to check the pkgsrc
10329 guide for valid XML and to build the final output files. If you 10329 guide for valid XML and to build the final output files. If you
10330 get any errors at this stage, you can just edit the files, as 10330 get any errors at this stage, you can just edit the files, as
10331 there are only symbolic links in the working directory, pointing 10331 there are only symbolic links in the working directory, pointing
10332 to the files in <code class="filename">files/</code>.</p></li> 10332 to the files in <code class="filename">files/</code>.</p></li>
10333<li class="step"><p><span class="command"><strong>(cd files &amp;&amp; cvs 10333<li class="step"><p><span class="command"><strong>(cd files &amp;&amp; cvs
10334 commit)</strong></span></p></li> 10334 commit)</strong></span></p></li>
10335<li class="step"><p>Run <span class="command"><strong>bmake clean &amp;&amp; bmake</strong></span> to 10335<li class="step"><p>Run <span class="command"><strong>bmake clean &amp;&amp; bmake</strong></span> to

cvs diff -r1.245 -r1.246 pkgsrc/doc/pkgsrc.txt (expand / switch to unified diff)

--- pkgsrc/doc/pkgsrc.txt 2017/11/27 11:52:49 1.245
+++ pkgsrc/doc/pkgsrc.txt 2018/04/04 10:24:23 1.246
@@ -2,29 +2,29 @@ The pkgsrc guide @@ -2,29 +2,29 @@ The pkgsrc guide
2 2
3Documentation on the NetBSD packages system 3Documentation on the NetBSD packages system
4 4
5Alistair Crooks 5Alistair Crooks
6 6
7<agc@NetBSD.org> 7<agc@NetBSD.org>
8 8
9Hubert Feyrer 9Hubert Feyrer
10 10
11<hubertf@NetBSD.org> 11<hubertf@NetBSD.org>
12 12
13The pkgsrc Developers 13The pkgsrc Developers
14 14
15Copyright 1994-2017 The NetBSD Foundation, Inc 15Copyright 1994-2018 The NetBSD Foundation, Inc
16 16
17$NetBSD: pkgsrc.xml,v 1.31 2017/07/30 22:07:39 jnemeth Exp $ 17$NetBSD: pkgsrc.xml,v 1.32 2018/01/01 01:26:07 jakllsch Exp $
18 18
19Abstract 19Abstract
20 20
21pkgsrc is a centralized package management system for Unix-like operating 21pkgsrc is a centralized package management system for Unix-like operating
22systems. This guide provides information for users and developers of pkgsrc. It 22systems. This guide provides information for users and developers of pkgsrc. It
23covers installation of binary and source packages, creation of binary and 23covers installation of binary and source packages, creation of binary and
24source packages and a high-level overview about the infrastructure. 24source packages and a high-level overview about the infrastructure.
25 25
26------------------------------------------------------------------------------- 26-------------------------------------------------------------------------------
27 27
28Table of Contents 28Table of Contents
29 29
301. What is pkgsrc? 301. What is pkgsrc?
@@ -789,74 +789,74 @@ Before you download and extract the file @@ -789,74 +789,74 @@ Before you download and extract the file
789extract them. When using pkgsrc as root user, pkgsrc is usually installed in / 789extract them. When using pkgsrc as root user, pkgsrc is usually installed in /
790usr/pkgsrc. You are though free to install the sources and binary packages 790usr/pkgsrc. You are though free to install the sources and binary packages
791wherever you want in your filesystem, provided that the pathname does not 791wherever you want in your filesystem, provided that the pathname does not
792contain white-space or other characters that are interpreted specially by the 792contain white-space or other characters that are interpreted specially by the
793shell and some other programs. A safe bet is to use only letters, digits, 793shell and some other programs. A safe bet is to use only letters, digits,
794underscores and dashes. 794underscores and dashes.
795 795
7962.1. Getting pkgsrc for the first time 7962.1. Getting pkgsrc for the first time
797 797
798Before you download any pkgsrc files, you should decide whether you want the  798Before you download any pkgsrc files, you should decide whether you want the
799current branch or the stable branch. The latter is forked on a quarterly basis 799current branch or the stable branch. The latter is forked on a quarterly basis
800from the current branch and only gets modified for security updates. The names 800from the current branch and only gets modified for security updates. The names
801of the stable branches are built from the year and the quarter, for example 801of the stable branches are built from the year and the quarter, for example
8022017Q3. 8022018Q1.
803 803
804The second step is to decide how you want to download pkgsrc. You can get it as 804The second step is to decide how you want to download pkgsrc. You can get it as
805a tar file or via CVS. Both ways are described here. 805a tar file or via CVS. Both ways are described here.
806 806
807Note that tar archive contains CVS working copy. Thus you can switch to using 807Note that tar archive contains CVS working copy. Thus you can switch to using
808CVS at any later time. 808CVS at any later time.
809 809
8102.1.1. As tar archive 8102.1.1. As tar archive
811 811
812The primary download location for all pkgsrc files is http://ftp.NetBSD.org/pub 812The primary download location for all pkgsrc files is http://ftp.NetBSD.org/pub
813/pkgsrc/ or ftp://ftp.NetBSD.org/pub/pkgsrc/ (it points to the same location). 813/pkgsrc/ or ftp://ftp.NetBSD.org/pub/pkgsrc/ (it points to the same location).
814There are a number of subdirectories for different purposes, which are 814There are a number of subdirectories for different purposes, which are
815described in detail in Appendix C, Directory layout of the pkgsrc FTP server. 815described in detail in Appendix C, Directory layout of the pkgsrc FTP server.
816 816
817The tar archive for the current branch is in the directory current and is 817The tar archive for the current branch is in the directory current and is
818called pkgsrc.tar.gz. It is autogenerated weekly. 818called pkgsrc.tar.gz. It is autogenerated weekly.
819 819
820To save download time we provide bzip2- and xz-compressed archives which are 820To save download time we provide bzip2- and xz-compressed archives which are
821published at pkgsrc.tar.bz2 and pkgsrc.tar.xz respectively. 821published at pkgsrc.tar.bz2 and pkgsrc.tar.xz respectively.
822 822
823You can fetch the same files using FTP. 823You can fetch the same files using FTP.
824 824
825The tar file for the stable branch 2017Q3 is in the directory pkgsrc-2017Q3 and 825The tar file for the stable branch 2018Q1 is in the directory pkgsrc-2018Q1 and
826is also called pkgsrc.tar.gz. 826is also called pkgsrc.tar.gz.
827 827
828To download the latest pkgsrc stable tarball, run: 828To download the latest pkgsrc stable tarball, run:
829 829
830$ ftp ftp://ftp.NetBSD.org/pub/pkgsrc/pkgsrc-2017Q3/pkgsrc.tar.gz 830$ ftp ftp://ftp.NetBSD.org/pub/pkgsrc/pkgsrc-2018Q1/pkgsrc.tar.gz
831 831
832If you prefer, you can also fetch it using "wget", "curl", or your web browser. 832If you prefer, you can also fetch it using "wget", "curl", or your web browser.
833 833
834Then, extract it with: 834Then, extract it with:
835 835
836$ tar -xzf pkgsrc.tar.gz -C /usr 836$ tar -xzf pkgsrc.tar.gz -C /usr
837 837
838This will create the directory pkgsrc/ in /usr/ and all the package source will 838This will create the directory pkgsrc/ in /usr/ and all the package source will
839be stored under /usr/pkgsrc/. 839be stored under /usr/pkgsrc/.
840 840
841To download pkgsrc-current, run: 841To download pkgsrc-current, run:
842 842
843$ ftp ftp://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz 843$ ftp ftp://ftp.NetBSD.org/pub/pkgsrc/current/pkgsrc.tar.gz
844 844
8452.1.2. Via anonymous CVS 8452.1.2. Via anonymous CVS
846 846
847To fetch a specific pkgsrc stable branch, run: 847To fetch a specific pkgsrc stable branch, run:
848 848
849$ cd /usr && cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -r pkgsrc-2017Q3 -P pkgsrc 849$ cd /usr && cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -r pkgsrc-2018Q1 -P pkgsrc
850 850
851This will create the directory pkgsrc/ in your /usr/ directory and all the 851This will create the directory pkgsrc/ in your /usr/ directory and all the
852package source will be stored under /usr/pkgsrc/. 852package source will be stored under /usr/pkgsrc/.
853 853
854To fetch the pkgsrc current branch, run: 854To fetch the pkgsrc current branch, run:
855 855
856$ cd /usr && cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc 856$ cd /usr && cvs -q -z2 -d anoncvs@anoncvs.NetBSD.org:/cvsroot checkout -P pkgsrc
857 857
858Refer to the list of available mirrors to choose a faster CVS mirror, if 858Refer to the list of available mirrors to choose a faster CVS mirror, if
859needed. 859needed.
860 860
861If you get error messages from rsh, you need to set CVS_RSH variable. E.g.: 861If you get error messages from rsh, you need to set CVS_RSH variable. E.g.:
862 862
@@ -918,27 +918,27 @@ To update pkgsrc via CVS, change to the  @@ -918,27 +918,27 @@ To update pkgsrc via CVS, change to the
918$ cd /usr/pkgsrc && cvs update -dP 918$ cd /usr/pkgsrc && cvs update -dP
919 919
920If you get error messages from rsh, you need to set CVS_RSH variable as 920If you get error messages from rsh, you need to set CVS_RSH variable as
921described above. E.g.: 921described above. E.g.:
922 922
923$ cd /usr/pkgsrc && env CVS_RSH=ssh cvs up -dP 923$ cd /usr/pkgsrc && env CVS_RSH=ssh cvs up -dP
924 924
9252.2.2.1. Switching between different pkgsrc branches 9252.2.2.1. Switching between different pkgsrc branches
926 926
927When updating pkgsrc, the CVS program keeps track of the branch you selected. 927When updating pkgsrc, the CVS program keeps track of the branch you selected.
928But if you, for whatever reason, want to switch from the stable branch to the 928But if you, for whatever reason, want to switch from the stable branch to the
929current one, you can do it by adding the option "-A" after the "update" 929current one, you can do it by adding the option "-A" after the "update"
930keyword. To switch from the current branch back to the stable branch, add the " 930keyword. To switch from the current branch back to the stable branch, add the "
931-rpkgsrc-2017Q3" option. 931-rpkgsrc-2018Q1" option.
932 932
9332.2.2.2. What happens to my changes when updating? 9332.2.2.2. What happens to my changes when updating?
934 934
935When you update pkgsrc, the CVS program will only touch those files that are 935When you update pkgsrc, the CVS program will only touch those files that are
936registered in the CVS repository. That means that any packages that you created 936registered in the CVS repository. That means that any packages that you created
937on your own will stay unmodified. If you change files that are managed by CVS, 937on your own will stay unmodified. If you change files that are managed by CVS,
938later updates will try to merge your changes with those that have been done by 938later updates will try to merge your changes with those that have been done by
939others. See the CVS manual, chapter "update" for details. 939others. See the CVS manual, chapter "update" for details.
940 940
941Chapter 3. Using pkgsrc on systems other than NetBSD 941Chapter 3. Using pkgsrc on systems other than NetBSD
942 942
943Table of Contents 943Table of Contents
944 944