2 .\" Copyright (c) 1997 David E. O'Brien
4 .\" All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
11 .\" 2. Redistributions in binary form must reproduce the above copyright
12 .\" notice, this list of conditions and the following disclaimer in the
13 .\" documentation and/or other materials provided with the distribution.
15 .\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR
16 .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17 .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18 .\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT,
19 .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 .\" $FreeBSD: src/share/man/man7/ports.7,v 1.76 2013/03/05 00:49:42 svnexp Exp $
33 .Nd contributed applications
38 offers a simple way for users and
39 administrators to install applications.
42 ports collection and most of ports' documentation applies.
46 contains any patches necessary to make the original
47 application source code compile and run on
50 application is as simple as typing
52 in the port directory!
55 automatically fetches the
56 application source code, either from a local disk or via FTP, unpacks it
57 on your system, applies the patches, and compiles it.
61 to install the application.
63 For more information about using ports, see
64 .Dq "Packages and Ports"
66 .%B "The FreeBSD Handbook" ,
67 .Pa ( file:/usr/share/doc/en_US.ISO8859-1/books/handbook/ports.html
69 .Pa http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/ports.html ) .
70 For information about creating new ports, see
71 .%B "The Porter's Handbook"
72 .Pa ( file:/usr/share/doc/en_US.ISO8859-1/books/porters-handbook/index.html
74 .Pa http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/porters-handbook/ ) .
76 Some of the targets work recursively through subdirectories.
77 This lets you, for example, install all of the
80 The targets that do this are
81 .Cm build , checksum , clean , configure ,
82 .Cm depends , extract , fetch , install ,
86 The following targets will be run automatically by each proceeding
94 and so on all the way to
96 Usually, you will only use the
99 .Bl -tag -width ".Cm configure"
106 Fetch all of the files needed to build this port from the sites
112 .Va FETCH_CMD , MASTER_SITE_OVERRIDE
114 .Va MASTER_SITE_BACKUP .
116 Verify that the fetched distfile's checksum matches the one the port was
118 If the distfile's checksum does not match, it also fetches the distfiles
119 which are missing or failed the checksum calculation.
125 (or compile if only compilation is necessary)
126 any dependencies of the current port.
131 targets, this is run in piecemeal as
132 .Cm fetch-depends , build-depends ,
138 Expand the distfile into a work directory.
140 Apply any patches that are necessary for the port.
143 Some ports will ask you questions during this stage.
150 This is the same as calling the
154 Install the port and register it with the package system.
155 This is all you really need to do.
158 The following targets are not run during the normal install process.
159 .Bl -tag -width ".Cm fetch-recursive"
163 config for this port.
164 .It Cm showconfig-recursive
167 config for this port and all its dependencies.
171 config for this port.
172 .It Cm rmconfig-recursive
175 config for this port and all its dependencies.
176 .It Cm config-conditional
177 Skip the ports which have already had their
180 .It Cm config-recursive
183 for this port and all its dependencies using
186 Show list of files to be fetched in order to build the port.
187 .It Cm fetch-recursive
188 Fetch the distfiles of the port and all its dependencies.
189 .It Cm fetch-recursive-list
190 Show list of files that would be retrieved by
191 .Cm fetch-recursive .
192 .It Cm run-depends-list , build-depends-list
193 Print a list of all the compile and run dependencies, and dependencies
194 of those dependencies, by port directory.
195 .It Cm all-depends-list
196 Print a list of all dependencies for the port.
197 .It Cm pretty-print-run-depends-list , pretty-print-build-depends-list
198 Print a list of all the compile and run dependencies, and dependencies
199 of those dependencies, by port name and version.
201 Print a list of missing dependencies to be installed for the port.
203 Remove the expanded source code.
204 This recurses to dependencies unless
208 Remove the port's distfiles and perform the
213 portion recurses to dependencies unless
217 portion never recurses
218 (this is perhaps a bug).
220 Use this to restore a port after using
222 when you should have used
225 Remove an installed port from the system, similar to
228 Remove all installed ports with the same
232 Make a binary package for the port.
233 The port will be installed if it has not already been.
236 file that you can use to
237 install the port on other machines with
239 If the directory specified by
241 does not exist, the package will be put into the current directory.
246 .It Cm package-recursive
249 but makes a package for each depending port as well.
251 Prints the name with version of the port.
255 This can be used from
257 to create a browsable web of all ports on your system!
261 .\"file for the pattern specified by the
263 .\"(searches the port name, comment, and dependencies),
265 .\"(searches the port name only),
267 .\"(searches the port path),
269 .\"(searches the port info),
271 .\"(searches the port maintainer),
273 .\"(searches the port category),
275 .\"(searches the port build-time dependency),
277 .\"(searches the port run-time dependency),
279 .\"(searches the port web site)
281 .\"variables, and their exclusion counterparts:
284 .\"For example, one would type:
286 .\".Dl "cd /usr/dports && make search name=query"
288 .\"to find all ports whose
291 .\"Results include the matching ports' path, comment, maintainer,
292 .\"build dependencies, and run dependencies.
293 .\".Bd -literal -offset indent
294 .\"cd /usr/dports && make search name=pear- \e
298 .\"To find all ports whose
301 .\"and which do not have apache
302 .\"listed in build-time dependencies.
303 .\".Bd -literal -offset indent
304 .\"cd /usr/dports && make search name=pear- \e
305 .\" xname='ht(tp|ml)'
308 .\"To find all ports whose names contain
314 .\".Bd -literal -offset indent
315 .\"make search key=apache display=name,path,info keylim=1
318 .\"To find ports that contain
320 .\"in either of the name, path, info
321 .\"fields, ignore the rest of the record.
323 .\"By default the search is not case-sensitive.
324 .\"In order to make it case-sensitive you can use the
327 .\".Bd -literal -offset indent
328 .\"make search name=p5-R icase=0
330 .\".It Cm quicksearch
334 .\"Only display name, path and info.
336 Generate a one-line description of each port for use in the
340 Display the port maintainer's email address.
343 .\".Pa /usr/dports/INDEX ,
344 .\"which is used by the
345 .\".Cm pretty-print-*
351 .\"target will ensure your
353 .\"file is up to date with your ports tree.
362 You can change all of these.
363 .Bl -tag -width ".Va MASTER_SITES"
365 Location of the ports tree.
380 Where to create any temporary files.
383 is read-only (perhaps mounted from a CD-ROM).
384 Its default value is /usr/obj/dports .
386 Where to find/put distfiles, normally
391 target; the base directory for the packages tree, normally
393 If this directory exists, the package tree will be (partially) constructed.
394 This directory does not have to exist; if it does not, packages will be
395 placed into the current directory, or you can define one of
396 .Bl -tag -width ".Va PKGREPOSITORY"
398 Directory to put the package in.
400 The full path to the package.
403 Where existing things are installed and where to search for files when
404 resolving dependencies (usually
407 Where to install this port (usually set to the same as
410 Primary sites for distribution files if not found locally.
412 Primary locations for distribution patch files if not found
414 .It Va MASTER_SITE_FREEBSD
415 If set, go to the master
418 .It Va MASTER_SITE_OVERRIDE
419 Try going to these sites for all files and patches, first.
420 .It Va MASTER_SITE_BACKUP
421 Try going to these sites for all files and patches, last.
422 .It Va RANDOMIZE_MASTER_SITES
423 Try the download locations in a random order.
425 Sort the download locations according to user supplied pattern.
427 .Dl .dk .sunet.se .se dk.php.net .no .de heanet.dl.sourceforge.net
428 .\".It Va MASTER_SITE_INDEX
437 .\".Pa http://www.FreeBSD.org/ports/ .
445 .\".Dq Nm fetch Fl am .
446 .It Va NOCLEANDEPENDS
447 If defined, do not let
449 recurse to dependencies.
451 Command to use to fetch files.
454 .It Va FORCE_PKG_REGISTER
455 If set, overwrite any existing package registration on the system.
458 .Pa libXm. Ns Brq Pa a , Ns Pa so .
460 If defined, only operate on a port if it requires interaction.
462 If defined, only operate on a port if it can be installed 100% automatically.
463 .It Va DISABLE_VULNERABILITIES
464 If defined, disable check for security vulnerabilities using
465 .Xr portaudit 1 Pq Pa ports/ports-mgmt/portaudit
466 when installing new ports.
468 If defined, allow installation of ports marked as
470 The default behavior of the Ports framework is to abort when the
471 installation of a forbidden port is attempted.
472 Of course, these ports may not work as expected, but if you really know
473 what you are doing and are sure about installing a forbidden port, then
477 If defined, skip verifying the port's checksum.
479 If defined, attempt to build a port even if it is marked as
482 Directory where the results of configuring
489 have been configured will have a uniquely named sub-directory, containing a
494 .Bl -tag -width ".Pa /usr/dports/Mk/bsd.port.mk" -compact
496 The default ports directory
497 .It Pa /usr/dports/Mk/bsd.port.mk
505 The following are part of the ports collection:
510 .%B "The FreeBSD Handbook"
513 .Pa http://www.FreeBSD.org/ports
514 (searchable index of all ports)
519 It has since spread to
526 This manual page was originated by
529 Ports documentation is split over four places \(em
530 .Pa /usr/dports/Mk/bsd.port.mk ,
531 .%B "The Porter's Handbook" ,
533 .Dq "Packages and Ports"
535 .%B "The FreeBSD Handbook" ,