=================================================================== RCS file: /cvsrepo/anoncvs/cvs/www/Attic/ports.html,v retrieving revision 1.30 retrieving revision 1.31 diff -u -r1.30 -r1.31 --- www/Attic/ports.html 2000/05/27 14:51:26 1.30 +++ www/Attic/ports.html 2000/06/11 16:40:24 1.31 @@ -13,15 +13,11 @@ [OpenBSD] -

OpenBSD ports tree is currently tracking OpenBSD 2.7 -(release)

-
-

Ports and Packages

+

The Ports & Packages collection

-

History

+

Motivation

-

OpenBSD is a fairly complete system of its own, but still there is a lot of software that one might want see added. However there is the problem on where to draw the line as to what to include, as well as the occasional @@ -30,24 +26,16 @@ shipped with the system.

-We wanted to find a way for users to easily get software we don't provide -and started to look around. We didn't have to look far, as sibling project -FreeBSD already had an - excellent mechanism -for exactly this purpose called -"The ports collection". + +The ports & packages collection does NOT go through the thorough security audit that OpenBSD follows. +Although we strive to keep the quality of the packages collection high, we just do not have enough human +resources to ensure the same level of robustness and security. +

-At first we tried to use their collection as-is, but due to -incompatibility problems between FreeBSD and OpenBSD we decided to branch -out and create our very own OpenBSD Ports Project using FreeBSD's as a -starting point. This also allows us to tune the ports better to our -system. - -

Short description and setup

- -

-The ports idea is to have, for each piece of software, a Makefile that +The port collection, originally borrowed from +FreeBSD, fills this gap. +The concept is to have, for each third-party software, a Makefile that controls

-

This information is kept in a directory hierarchy under the /usr/ports directory. -

Getting the Ports tree

+

-You can ftp the release version from the pub/OpenBSD/[version] (where -[version] is the release number) directory on any of the -ftp mirror sites. -The release versions are the ones we ship on our CDROM, and have gone -through more testing than any snapshot. +Packages are the binary equivalent of ports. A compiled port becomes +a package that can be registered into the system using pkg_add(1). +

-Further information is available in the -ports(7) man page. + +Packages look like simple .tar.gz bundles, but they should always +be added using pkg_add(1), as there might be some extra information that only +pkg_add(1) knows how to handle. +Tip: you can distinguish between packages and .tar.gz bundles using pkg_info(1). -

Ports versus packages

+

Getting packages

-

-For common architectures, you don't necessarily have to compile anything -in the ports tree. With the advent of OpenBSD 2.7, a large set of -pre-compiled packages will be available: +A large collection of pre-compiled packages is available for most common +architectures.

-OpenBSD documentation includes more information on the proper use of -packages. -

Ports update for an OpenBSD release

+Adding a package is as easy as +pkg_add pkgname.tar.gz. +If you are grabbing packages off a single source (a package repository), +set PKG_PATH to that repository URL.

-The ports tree, like the rest of OpenBSD, is constantly changing. While -we try to maintain ports compatibility through the lifetime of a particular -release, sometimes issues beyond our control occur. For example, particular -versions of the ported package might no longer be available (But this -specific problem should be solved now). +For instance, to install the gimp package for the 2.7 release on an i386 +machine off the ftp site (including dependencies), do: +

+    # setenv PKG_PATH ftp://ftp.openbsd.org/pub/OpenBSD/2.7/packages/i386/
+    # pkg_add gimp-1.17.tar.gz
+
+ +

Managing installed packages

+ +The packages(7). +manual page holds useful information about ways to manage +installed packages, solve conflicts (files that already exist) and handle +dependencies.

+As of OpenBSD 2.7, to update a package you must: +

+This is slightly inconvenient, as packages may trigger dependencies, and +you may have to remove a large subset of packages for an update. + +

Using ports

+ +If a given package does not exist for your architecture, you may still +be able to compile the port. Besides, some users will want to compile +everything from source for various reasons. + +

+You can ftp the release version from the pub/OpenBSD/[version] (where +[version] is the release number) directory on any of the +ftp mirror sites. +The release versions are the ones we ship on our CDROM, and have gone +through more testing than any snapshot. +Further information is available in the +ports(7) man page. + +

Ports update for an OpenBSD release

+ +

+The ports tree, like the rest of OpenBSD, is constantly changing. The normal life cycle of the ports tree is as follows:

- -

The change of status will be widely publicized on the Mailing lists.

The ports tree works as a single entity. Updating a single directory is not guaranteed to work, as package dependencies may force you to update and recompile vast portions of the ports tree. - -

It is strongly suggested that people don't track ports-current unless +It is strongly suggested that people don't track ports-current unless they're prepared to deal with various problems. Mailing lists such as source-changes or tech will probably be invaluable. @@ -134,31 +153,41 @@ Let's say you managed to get a ports tree and you want to compile and install the archiving utility unzip. You should be able to do something like this: +

-% cd /usr/ports/archivers/unzip
-% su
-# make
-# make install
-# exit
+    % cd /usr/ports/archivers/unzip
+    % su
+    # make
+    # make install
+    # exit
 
-Easy, huh? - +In OpenBSD 2.7, a large proportion of the ports automatically build +packages when installing. +In OpenBSD current, almost all ports follow that standard. -

Creating new ports

+

+As ports get built, the /usr/ports/distfiles directory gets filled with +program sources, and /usr/ports/packages gets filled with binary packages. +Users with low connectivity may refer to mirror-distfiles(7) for +an efficient way to grab all distfiles at once. +Note that the OpenBSD CD only include the ports tree and selected packages. +If you wish to have the distfiles, you will have to get them through an +independent way. +

Creating new ports

If you are interested in helping to expand the OpenBSD ports tree you should first read porting.html. @@ -169,7 +198,8 @@

Problems and contacts

-If you have trouble with ports please send e-mail to the OpenBSD +If you have trouble with existing ports, or need information about creating new ports, +please send e-mail to the OpenBSD ports mailing list, ports@openbsd.org. Corrections are always welcome, but in any case do please provide: