MPORTS(7) | MidnightBSD Miscellaneous Information Manual | MPORTS(7) |
mports
—
contributed applications
The Ports Collection offers a simple way for users and
administrators to install applications. Each
port
contains any patches necessary to make the original application source code
compile and run on BSD. Compiling an application is
as simple as typing make
build
in the port directory! The
Makefile automatically fetches the application
source code, either from a local disk or via FTP, unpacks it on your system,
applies the patches, and compiles it. If all goes well, simply type
make
install
to install the
application.
It is possible to download and use ports from the repository that are newer than the installed system; however it is important to install the appropriate “Upgrade Kit” from http://www.MidnightBSD.org/ports/ first!
For more information about using mports, see “Packages and Ports” in The FreeBSD Handbook, (file:/usr/share/doc/en_US.ISO8859-1/books/handbook/ports.html or http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/ports.html). For information about creating new ports, see The Porter's Handbook (file:/usr/share/doc/en_US.ISO8859-1/books/porters-handbook/index.html or http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/porters-handbook/).
Some of the targets work recursively through subdirectories. This
lets you, for example, install all of the
“biology
” ports. The targets that do
this are build
, checksum
,
clean
, configure
,
depends
, extract
,
fetch
, install
, and
package
.
The following targets will be run automatically by each proceeding
target in order. That is, build
will be run (if
necessary) by install
, and so on all the way to
fetch
. Usually, you will only use the
install
target.
config
config-recursive
fetch
checksum
depends
extract
or
fetch
targets, this is run in piecemeal as
fetch-depends
,
build-depends
, etc. Defining
NO_DEPENDS will skip this step.extract
patch
configure
build
all
target.install
The following targets are not run during the normal install process.
showconfig
showconfig-recursive
rmconfig
rmconfig-recursive
config-conditional
fetch-list
fetch-recursive
fetch-recursive-list
fetch-recursive
.pretty-print-run-depends-list
,
pretty-print-build-depends-list
clean
distclean
clean
target. The clean
portion recurses to dependencies
unless NOCLEANDEPENDS is defined, but the
distclean
portion never recurses (this is perhaps
a bug).reinstall
deinstall
.deinstall
deinstall-all
package
package-recursive
package
, but makes a package for each
depending port as well.readmes
search
cd /usr/mports && make
search name=query
to find all mports whose name matches
“query
”. Results include the
matching mports' path, comment, maintainer, build dependencies, and run
dependencies.
cd /usr/mports && make search name=pear- \ xbdeps=apache
To find all mports whose names contain
“pear-
” and which do not have
apache listed in build-time dependencies.
cd /usr/mports && make search name=pear- \ xname='ht(tp|ml)'
To find all mports whose names contain
“pear-
”, but not
“html
” or
“http
”.
make search key=apache display=name,path,info keylim=1
To find mports that contain
“apache
” in either of the name,
path, info fields, ignore the rest of the record.
describe
index
pretty-print-*
and search
targets. Running the index
target will ensure your
INDEX file is up to date with your mports
tree.fetchindex
You can change all of these.
package
target; the base
directory for the packages tree, normally
packages/ in PORTSDIR. If
this directory exists, the package tree will be (partially) constructed.
This directory does not have to exist; if it does not, packages will be
placed into the current directory, or you can define one of
fetchindex
target). Defaults to
http://www.MidnightBSD.org/ports/.fetchindex
target). Defaults to
“fetch
-am
”.clean
recurse to
dependencies.Build and install Emacs:
cd /usr/mports/editors/emacs make install
The following are part of the ports collection:
The FreeBSD Handbook.
http://www.FreeBSD.org/ports (searchable index of all ports)
The Ports Collection appeared in FreeBSD 1.0. It has since spread to NetBSD and OpenBSD with a major rewrite in
This manual page was originated by David O'Brien. It was rewritten for by Lucas Holt.
Ports documentation is split over five places — /usr/mports/Mk/bsd.mport.mk, The MidnightBSD website and wiki http://www.midnightbsd.org/wiki , The Porter's Handbook, the “Packages and Ports” chapter of The FreeBSD Handbook, and this manual page.
April 15, 2009 | midnightbsd-3.1 |