diff --git a/en/handbook/contrib/chapter.sgml b/en/handbook/contrib/chapter.sgml
index 8b2d3c3c88..ccdb16f558 100644
--- a/en/handbook/contrib/chapter.sgml
+++ b/en/handbook/contrib/chapter.sgml
@@ -1,5715 +1,5715 @@
Contributing to FreeBSDContributed by &a.jkh;.So you want to contribute something to FreeBSD? That is great! We can
always use the help, and FreeBSD is one of those systems that
relies on the contributions of its user base in order
to survive. Your contributions are not only appreciated, they are vital
to FreeBSD's continued growth!Contrary to what some people might also have you believe, you do not
need to be a hot-shot programmer or a close personal friend of the FreeBSD
core team in order to have your contributions accepted. The FreeBSD
Project's development is done by a large and growing number of
international contributors whose ages and areas of technical expertise
vary greatly, and there is always more work to be done than there are
people available to do it.Since the FreeBSD project is responsible for an entire operating
system environment (and its installation) rather than just a kernel or a
few scattered utilities, our TODO list also spans a
very wide range of tasks, from documentation, beta testing and
presentation to highly specialized types of kernel development. No matter
what your skill level, there is almost certainly something you can do to
help the project!Commercial entities engaged in FreeBSD-related enterprises are also
encouraged to contact us. Need a special extension to make your product
work? You will find us receptive to your requests, given that they are not
too outlandish. Working on a value-added product? Please let us know! We
may be able to work cooperatively on some aspect of it. The free software
world is challenging a lot of existing assumptions about how software is
developed, sold, and maintained throughout its life cycle, and we urge you
to at least give it a second look.What Is NeededThe following list of tasks and sub-projects represents something of
an amalgam of the various core team TODO lists and
user requests we have collected over the last couple of months. Where
possible, tasks have been ranked by degree of urgency. If you are
interested in working on one of the tasks you see here, send mail to the
coordinator listed by clicking on their names. If no coordinator has
been appointed, maybe you would like to volunteer?High priority tasksThe following tasks are considered to be urgent, usually because
they represent something that is badly broken or sorely needed:3-stage boot issues. Overall coordination: &a.hackers;Do WinNT compatible drive tagging so that the 3rd stage
can provide an accurate mapping of BIOS geometries for
disks.Filesystem problems. Overall coordination: &a.fs;Fix the MSDOS file system.Clean up and document the nullfs filesystem code.
Coordinator: &a.eivind;Fix the union file system. Coordinator: &a.dg;Implement Int13 vm86 disk driver. Coordinator:
&a.hackers;New bus architecture. Coordinator: &a.newbus;Port existing ISA drivers to new architecture.Move all interrupt-management code to appropriate parts of
the bus drivers.Port PCI subsystem to new architecture. Coordinator:
&a.dfr;Figure out the right way to handle removable devices and
then use that as a substrate on which PC-Card and CardBus
support can be implemented.Resolve the probe/attach priority issue once and for
all.Move any remaining buses over to the new
architecture.Kernel issues. Overall coordination: &a.hackers;Add more pro-active security infrastructure. Overall
coordination: &a.security;Build something like Tripwire(TM) into the kernel, with a
remote and local part. There are a number of cryptographic
issues to getting this right; contact the coordinator for
details. Coordinator: &a.eivind;Make the entire kernel use suser()
instead of comparing to 0. It is presently using about half
of each. Coordinator: &a.eivind;Split securelevels into different parts, to allow an
administrator to throw away those privileges he can throw
away. Setting the overall securelevel needs to have the same
effect as now, obviously. Coordinator: &a.eivind;Make it possible to upload a list of “allowed
program” to BPF, and then block BPF from accepting other
programs. This would allow BPF to be used e.g. for DHCP,
without allowing an attacker to start snooping the local
network.Update the security checker script. We should at least
grab all the checks from the other BSD derivatives, and add
checks that a system with securelevel increased also have
reasonable flags on the relevant parts. Coordinator:
&a.eivind;Add authorization infrastructure to the kernel, to allow
different authorization policies. Part of this could be done
by modifying suser(). Coordinatory:
&a.eivind;
- Add code to teh NFS layer so that you cannot
+ Add code to the NFS layer so that you cannot
chdir("..") out of an NFS partition. E.g.,
/usr is a UFS partition with
/usr/src NFS exported. Now it is
possible to use the NFS filehandle for
/usr/src to get access to
/usr.Medium priority tasksThe following tasks need to be done, but not with any particular
urgency:Full KLD based driver support/Configuration Manager.Write a configuration manager (in the 3rd stage boot?)
that probes your hardware in a sane manner, keeps only the
KLDs required for your hardware, etc.PCMCIA/PCCARD. Coordinators: &a.msmith; and &a.phk;Documentation!Reliable operation of the pcic driver (needs
testing).Recognizer and handler for sio.c
(mostly done).Recognizer and handler for ed.c
(mostly done).Recognizer and handler for ep.c
(mostly done).User-mode recognizer and handler (partially done).Advanced Power Management. Coordinators: &a.msmith; and
&a.phk;APM sub-driver (mostly done).IDE/ATA disk sub-driver (partially done).syscons/pcvt sub-driver.Integration with the PCMCIA/PCCARD drivers
(suspend/resume).Low priority tasksThe following tasks are purely cosmetic or represent such an
investment of work that it is not likely that anyone will get them
done anytime soon:The first N items are from Terry Lambert
terry@lambert.orgNetWare Server (protected mode ODI driver) loader and
subservices to allow the use of ODI card drivers supplied with
network cards. The same thing for NDIS drivers and NetWare SCSI
drivers.An "upgrade system" option that works on Linux boxes instead
of just previous rev FreeBSD boxes.Symmetric Multiprocessing with kernel preemption (requires
kernel preemption).A concerted effort at support for portable computers. This is
somewhat handled by changing PCMCIA bridging rules and power
management event handling. But there are things like detecting
internal vs. external display and picking a different screen
resolution based on that fact, not spinning down the disk if the
machine is in dock, and allowing dock-based cards to disappear
without affecting the machines ability to boot (same issue for
PCMCIA).Smaller tasksMost of the tasks listed in the previous sections require either a
considerable investment of time or an in-depth knowledge of the
FreeBSD kernel (or both). However, there are also many useful tasks
which are suitable for "weekend hackers", or people without
programming skills.If you run FreeBSD-current and have a good Internet
connection, there is a machine current.freebsd.org which builds a full
release once a day — every now and again, try and install
the latest release from it and report any failures in the
process.Read the freebsd-bugs mailing list. There
might be a problem you can comment constructively on or with
patches you can test. Or you could even try to fix one of the
problems yourself.Read through the FAQ and Handbook periodically. If anything
is badly explained, out of date or even just completely wrong, let
us know. Even better, send us a fix (SGML is not difficult to
learn, but there is no objection to ASCII submissions).Help translate FreeBSD documentation into your native language
(if not already available) — just send an email to &a.doc;
asking if anyone is working on it. Note that you are not
committing yourself to translating every single FreeBSD document
by doing this — in fact, the documentation most in need of
translation is the installation instructions.Read the freebsd-questions mailing list and &ng.misc
occasionally (or even regularly). It can be very satisfying to
share your expertise and help people solve their problems;
sometimes you may even learn something new yourself! These forums
can also be a source of ideas for things to work on.If you know of any bugfixes which have been successfully
applied to -current but have not been merged into -stable after a
decent interval (normally a couple of weeks), send the committer a
polite reminder.Move contributed software to src/contrib
in the source tree.Make sure code in src/contrib is up to
date.Look for year 2000 bugs (and fix any you find!)Build the source tree (or just part of it) with extra warnings
enabled and clean up the warnings.Fix warnings for ports which do deprecated things like using
gets() or including malloc.h.If you have contributed any ports, send your patches back to
the original author (this will make your life easier when they
bring out the next version)Suggest further tasks for this list!How to ContributeContributions to the system generally fall into one or more of the
following 6 categories:Bug reports and general commentaryAn idea or suggestion of general technical
interest should be mailed to the &a.hackers;. Likewise, people with
an interest in such things (and a tolerance for a
high volume of mail!) may subscribe to the
hackers mailing list by sending mail to &a.majordomo;. See mailing lists for more information
about this and other mailing lists.If you find a bug or are submitting a specific change, please
report it using the &man.send-pr.1; program or its WEB-based
equivalent. Try to fill-in each field of the bug report.
Unless they exceed 65KB, include any patches directly in the report.
Consider compressing them and using &man.uuencode.1; if they exceed
20KB. Upload very large submissions to ftp.freebsd.org:/pub/FreeBSD/incoming/.After filing a report, you should receive confirmation along with
a tracking number. Keep this tracking number so that you can update
us with details about the problem by sending mail to
bug-followup@FreeBSD.ORG. Use the number as the
message subject, e.g. "Re: kern/3377". Additional
information for any bug report should be submitted this way.If you do not receive confirmation in a timely fashion (3 days to
a week, depending on your email connection) or are, for some reason,
unable to use the &man.send-pr.1; command, then you may ask
someone to file it for you by sending mail to the &a.bugs;.Changes to the documentationChanges to the documentation are overseen by the &a.doc;. Send
submissions and changes (even small ones are welcome!) using
send-pr as described in Bug Reports and General
Commentary.Changes to existing source codeAn addition or change to the existing source code is a somewhat
trickier affair and depends a lot on how far out of date you are with
the current state of the core FreeBSD development. There is a special
on-going release of FreeBSD known as “FreeBSD-current”
which is made available in a variety of ways for the convenience of
developers working actively on the system. See Staying current with FreeBSD for more
information about getting and using FreeBSD-current.Working from older sources unfortunately means that your changes
may sometimes be too obsolete or too divergent for easy re-integration
into FreeBSD. Chances of this can be minimized somewhat by
subscribing to the &a.announce; and the &a.current; lists, where
discussions on the current state of the system take place.Assuming that you can manage to secure fairly up-to-date sources
to base your changes on, the next step is to produce a set of diffs to
send to the FreeBSD maintainers. This is done with the &man.diff.1;
command, with the “context diff” form
being preferred. For example:&prompt.user; diff -c oldfile newfile
or
&prompt.user; diff -c -r olddir newdir
would generate such a set of context diffs for the given source file
or directory hierarchy. See the man page for &man.diff.1; for more
details.Once you have a set of diffs (which you may test with the
&man.patch.1; command), you should submit them for inclusion with
FreeBSD. Use the &man.send-pr.1; program as described in Bug Reports and General Commentary.
Do not just send the diffs to the &a.hackers; or
they will get lost! We greatly appreciate your submission (this is a
volunteer project!); because we are busy, we may not be able to
address it immediately, but it will remain in the pr database until we
do.If you feel it appropriate (e.g. you have added, deleted, or
renamed files), bundle your changes into a tar file
and run the &man.uuencode.1; program on it. Shar archives are also
welcome.If your change is of a potentially sensitive nature, e.g. you are
unsure of copyright issues governing its further distribution or you
are simply not ready to release it without a tighter review first,
then you should send it to &a.core; directly rather than submitting it
with &man.send-pr.1;. The core mailing list reaches a much smaller
group of people who do much of the day-to-day work on FreeBSD. Note
that this group is also very busy and so you
should only send mail to them where it is truly necessary.Please refer to man 9 intro and man 9
style for some information on coding style. We would
appreciate it if you were at least aware of this information before
submitting code.New code or major value-added packagesIn the rare case of a significant contribution of a large body
work, or the addition of an important new feature to FreeBSD, it
becomes almost always necessary to either send changes as uuencode'd
tar files or upload them to our ftp site ftp://ftp.FreeBSD.ORG/pub/FreeBSD/incoming.When working with large amounts of code, the touchy subject of
copyrights also invariably comes up. Acceptable copyrights for code
included in FreeBSD are:The BSD copyright. This copyright is most preferred due to
its “no strings attached” nature and general
attractiveness to commercial enterprises. Far from discouraging
such commercial use, the FreeBSD Project actively encourages such
participation by commercial interests who might eventually be
inclined to invest something of their own into FreeBSD.The GNU Public License, or “GPL”. This license is
not quite as popular with us due to the amount of extra effort
demanded of anyone using the code for commercial purposes, but
given the sheer quantity of GPL'd code we currently require
(compiler, assembler, text formatter, etc) it would be silly to
refuse additional contributions under this license. Code under
the GPL also goes into a different part of the tree, that being
/sys/gnu or
/usr/src/gnu, and is therefore easily
identifiable to anyone for whom the GPL presents a problem.Contributions coming under any other type of copyright must be
carefully reviewed before their inclusion into FreeBSD will be
considered. Contributions for which particularly restrictive
commercial copyrights apply are generally rejected, though the authors
are always encouraged to make such changes available through their own
channels.To place a “BSD-style” copyright on your work, include
the following text at the very beginning of every source code file you
wish to protect, replacing the text between the %%
with the appropriate information.
Copyright (c) %%proper_years_here%%
%%your_name_here%%, %%your_state%% %%your_zip%%.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer as
the first lines of this file unmodified.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY %%your_name_here%% ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL %%your_name_here%% BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
$Id$For your convenience, a copy of this text can be found in
/usr/share/examples/etc/bsd-style-copyright.Money, Hardware or Internet accessWe are always very happy to accept donations to further the cause
of the FreeBSD Project and, in a volunteer effort like ours, a little
can go a long way! Donations of hardware are also very important to
expanding our list of supported peripherals since we generally lack
the funds to buy such items ourselves.Donating fundsWhile the FreeBSD Project is not a 501(c)(3) (charitable)
corporation and hence cannot offer special tax incentives for any
donations made, any such donations will be gratefully accepted on
behalf of the project by FreeBSD, Inc.FreeBSD, Inc. was founded in early 1995 by &a.jkh; and &a.dg;
with the goal of furthering the aims of the FreeBSD Project and
giving it a minimal corporate presence. Any and all funds donated
(as well as any profits that may eventually be realized by FreeBSD,
Inc.) will be used exclusively to further the project's
goals.Please make any checks payable to FreeBSD, Inc., sent in care of
the following address:FreeBSD, Inc.c/o Jordan Hubbard4041 Pike Lane, Suite FConcordCA, 94520(currently using the Walnut Creek CDROM address until a PO box
can be opened)Wire transfers may also be sent directly to:Bank Of AmericaConcord Main OfficeP.O. Box 37176San FranciscoCA, 94137-5176Routing #: 121-000-358Account #: 01411-07441 (FreeBSD, Inc.)Any correspondence related to donations should be sent to Jordan
Hubbard jkh@FreeBSD.org, either via email or to the
FreeBSD, Inc. postal address given above.If you do not wish to be listed in our donors section, please specify this when
making your donation. Thanks!Donating hardwareDonations of hardware in any of the 3 following categories are
also gladly accepted by the FreeBSD Project:General purpose hardware such as disk drives, memory or
complete systems should be sent to the FreeBSD, Inc. address
listed in the donating funds
section.Hardware for which ongoing compliance testing is desired.
We are currently trying to put together a testing lab of all
components that FreeBSD supports so that proper regression
testing can be done with each new release. We are still lacking
many important pieces (network cards, motherboards, etc) and if
you would like to make such a donation, please contact &a.dg;
for information on which items are still required.Hardware currently unsupported by FreeBSD for which you
would like to see such support added. Please contact the
&a.core; before sending such items as we will need to find a
developer willing to take on the task before we can accept
delivery of new hardware.Donating Internet accessWe can always use new mirror sites for FTP, WWW or
cvsup. If you would like to be such a mirror,
please contact the FreeBSD project administrators
admin@FreeBSD.ORG for more information.Donors GalleryThe FreeBSD Project is indebted to the following donors and would
like to publically thank them here!Contributors to the central server
project:The following individuals and businesses made it possible for
the FreeBSD Project to build a new central server machine to
eventually replace freefall.freebsd.org
by donating the following items:Ade Barkah mbarkah@freebsd.org and his
employer, Hemisphere
Online, donated a Pentium Pro (P6) 200Mhz
CPUASA
Computers donated a Tyan 1662
motherboard.Joe McGuckin joe@via.net of ViaNet Communications donated
a Kingston ethernet controller.Jack O'Neill jack@diamond.xtalwind.net
donated an NCR 53C875 SCSI controller
card.Ulf Zimmermann ulf@Alameda.net of Alameda Networks donated
128MB of memory, a 4 Gb disk
drive and the case.Direct funding:The following individuals and businesses have generously
contributed direct funding to the project:Annelise Anderson
ANDRSN@HOOVER.STANFORD.EDUMatt Dillon dillon@best.netEpilogue Technology
CorporationSean Eric FaganDon Scott WildeGianmarco Giovannelli
gmarco@masternet.itJosef C. Grosch joeg@truenorth.orgRobert T. MorrisChuck Robey chuckr@freebsd.orgKenneth P. Stox ken@stox.sa.enteract.com of
Imaginary Landscape,
LLC.Dmitry S. Kohmanyuk dk@dog.farm.orgLaser5 of Japan
(a portion of the profits from sales of their various FreeBSD
CD-ROMs.Fuki Shuppan
Publishing Co. donated a portion of their profits from
Hajimete no FreeBSD (FreeBSD, Getting
started) to the FreeBSD and XFree86 projects.ASCII Corp.
donated a portion of their profits from several FreeBSD-related
books to the FreeBSD project.Yokogawa Electric
Corp has generously donated significant funding to the
FreeBSD project.BuffNETPacific
SolutionsSiemens AG
via Andre
AlbsmeierChris SilvaHardware contributors:The following individuals and businesses have generously
contributed hardware for testing and device driver
development/support:Walnut Creek CDROM for providing the Pentium P5-90 and
486/DX2-66 EISA/VL systems that are being used for our
development work, to say nothing of the network access and other
donations of hardware resources.TRW Financial Systems, Inc. provided 130 PCs, three 68 GB
fileservers, twelve Ethernets, two routers and an ATM switch for
debugging the diskless code.Dermot McDonnell donated the Toshiba XM3401B CDROM drive
currently used in freefall.&a.chuck; contributed his floppy tape streamer for
experimental work.Larry Altneu larry@ALR.COM, and &a.wilko;,
provided Wangtek and Archive QIC-02 tape drives in order to
improve the wt driver.Ernst Winter ewinter@lobo.muc.de contributed
a 2.88 MB floppy drive to the project. This will hopefully
increase the pressure for rewriting the floppy disk driver.
;-)Tekram
Technologies sent one each of their DC-390, DC-390U
and DC-390F FAST and ULTRA SCSI host adapter cards for
regression testing of the NCR and AMD drivers with their cards.
They are also to be applauded for making driver sources for free
operating systems available from their FTP server ftp://ftp.tekram.com/scsi/FreeBSD.Larry M. Augustin contributed not only a
Symbios Sym8751S SCSI card, but also a set of data books,
including one about the forthcoming Sym53c895 chip with Ultra-2
and LVD support, and the latest programming manual with
information on how to safely use the advanced features of the
latest Symbios SCSI chips. Thanks a lot!Christoph Kukulies kuku@freebsd.org donated
an FX120 12 speed Mitsumi CDROM drive for IDE CDROM driver
development.Special contributors:Walnut Creek CDROM
has donated almost more than we can say (see the history document for more details).
In particular, we would like to thank them for the original
hardware used for freefall.FreeBSD.ORG, our primary
development machine, and for thud.FreeBSD.ORG, a testing and build
box. We are also indebted to them for funding various
contributors over the years and providing us with unrestricted
use of their T1 connection to the Internet.The interface
business GmbH, Dresden has been patiently supporting
&a.joerg; who has often preferred FreeBSD work over paywork, and
used to fall back to their (quite expensive) EUnet Internet
connection whenever his private connection became too slow or
flakey to work with it...Berkeley Software Design,
Inc. has contributed their DOS emulator code to the
remaining BSD world, which is used in the
dosemu command.Core Team AlumnusThe following people were members of the FreeBSD core team during
the period indicated. We thank them for their past efforts in the
service of the FreeBSD project.In rough chronological order:Guido van Rooij (1995 - 1999)John Dyson (1993 - 1998)Nate Williams (1992 - 1996)Rod Grimes (1992 - 1995)Andreas Schulz (1992 - 1995)Geoff Rehmet (1993 - 1995)Paul Richards (1992 - 1995)Scott Mace (1993 - 1994)Andrew Moore (1993 - 1994)Christoph Robitschko (1993 - 1994)J. T. Conklin (1992 - 1993)Derived Software ContributorsThis software was originally derived from William F. Jolitz's 386BSD
release 0.1, though almost none of the original 386BSD specific code
remains. This software has been essentially re-implemented from the
4.4BSD-Lite release provided by the Computer Science Research Group
(CSRG) at the University of California, Berkeley and associated academic
contributors.There are also portions of NetBSD and OpenBSD that have been
integrated into FreeBSD as well, and we would therefore like to thank
all the contributors to NetBSD and OpenBSD for their work.Additional FreeBSD Contributors(in alphabetical order by first name):ABURAYA Ryushirou rewsirow@ff.iij4u.or.jpAMAGAI Yoshiji amagai@nue.orgAaron Bornstein aaronb@j51.comAaron Smith aaron@tau.veritas.comAchim Patzner ap@noses.comAda T Lim ada@bsd.orgAdam Baran badam@mw.mil.plAdam Glass glass@postgres.berkeley.eduAdam McDougall mcdouga9@egr.msu.eduAdrian Colley aecolley@ois.ieAdrian Hall adrian@ibmpcug.co.ukAdrian Mariano adrian@cam.cornell.eduAdrian Steinmann ast@marabu.chAdrian T. Filipi-Martin
atf3r@agate.cs.virginia.eduAjit Thyagarajan unknownAkio Morita
amorita@meadow.scphys.kyoto-u.ac.jpAkira SAWADA unknownAkira Watanabe
akira@myaw.ei.meisei-u.ac.jpAkito Fujita fujita@zoo.ncl.omron.co.jpAlain Kalker
A.C.P.M.Kalker@student.utwente.nlAlan Bawden alan@curry.epilogue.comAlan Cox alc@cs.rice.eduAlec Wolman wolman@cs.washington.eduAled Morris aledm@routers.co.ukAlex garbanzo@hooked.netAlex D. Chen
dhchen@Canvas.dorm7.nccu.edu.twAlex G. Bulushev bag@demos.suAlex Le Heux alexlh@funk.orgAlexander B. Povolotsky tarkhil@mgt.msk.ruAlexander Leidinger
netchild@wurzelausix.CS.Uni-SB.DEAlexandre Snarskii snar@paranoia.ruAlistair G. Crooks agc@uts.amdahl.comAllan Saddi asaddi@philosophysw.comAllen Campbell allenc@verinet.comAmakawa Shuhei amakawa@hoh.t.u-tokyo.ac.jpAmancio Hasty hasty@star-gate.comAmir Farah amir@comtrol.comAmy Baron amee@beer.orgAnatoly A. Orehovsky tolik@mpeks.tomsk.suAnatoly Vorobey mellon@pobox.comAnders Nordby nickerne@nome.noAnders Thulin Anders.X.Thulin@telia.seAndras Olah olah@cs.utwente.nlAndre Albsmeier
Andre.Albsmeier@mchp.siemens.deAndre Oppermann andre@pipeline.chAndreas Haakh ah@alman.robin.deAndreas Kohout shanee@rabbit.augusta.deAndreas Lohr andreas@marvin.RoBIN.deAndreas Schulz unknownAndreas Wetzel mickey@deadline.snafu.deAndreas Wrede andreas@planix.comAndres Vega Garcia unknownAndrew Atrens atreand@statcan.caAndrew Gillham gillham@andrews.eduAndrew Gordon andrew.gordon@net-tel.co.ukAndrew Herbert andrew@werple.apana.org.auAndrew J. Korty ajk@purdue.eduAndrew L. Moore alm@mclink.comAndrew McRae amcrae@cisco.comAndrew Stevenson andrew@ugh.net.auAndrew Timonin tim@pool1.convey.ruAndrew V. Stesin stesin@elvisti.kiev.uaAndrew Webster awebster@dataradio.comAndrey Zakhvatov andy@icc.surw.chel.suAndy Farkas andyf@speednet.com.auAndy Valencia ajv@csd.mot.comAndy Whitcroft andy@sarc.city.ac.ukAngelo Turetta ATuretta@stylo.itAnthony C. Chavez magus@xmission.comAnthony Yee-Hang Chan yeehang@netcom.comAnton Berezin tobez@plab.ku.dkAntti Kaipila anttik@iki.fiAre Bryne are.bryne@communique.noAri Suutari ari@suutari.iki.fiArjan de Vet devet@IAEhv.nlArne Henrik Juul arnej@Lise.Unit.NOAssar Westerlund assar@sics.seAtsushi Furuta furuta@sra.co.jpAtsushi Murai amurai@spec.co.jpBakul Shah bvs@bitblocks.comBarry Bierbauch pivrnec@vszbr.czBarry Lustig barry@ictv.comBen Hutchinson benhutch@xfiles.org.ukBen Jackson unknownBen Smithurst ben@scientia.demon.co.ukBen Walter bwalter@itachi.swcp.comBenjamin Lewis bhlewis@gte.netBernd Rosauer br@schiele-ct.deBill Kish kish@osf.orgBill Trost trost@cloud.rain.comBlaz Zupan blaz@amis.netBob Van Valzah Bob@whitebarn.comBob Willcox bob@luke.pmr.comBoris Staeblow balu@dva.in-berlin.deBoyd R. Faulkner faulkner@asgard.bga.comBrad Karp karp@eecs.harvard.eduBradley Dunn bradley@dunn.orgBrandon Gillespie brandon@roguetrader.com&a.wlloydBob Wilcox bob@obiwan.uucpBoyd Faulkner faulkner@mpd.tandem.comBrent J. Nordquist bjn@visi.comBrett Lymn blymn@mulga.awadi.com.AUBrett Taylor
brett@peloton.physics.montana.eduBrian Campbell brianc@pobox.comBrian Clapper bmc@willscreek.comBrian Cully shmit@kublai.comBrian F. Feldman green@unixhelp.orgBrian Handy
handy@lambic.space.lockheed.comBrian Litzinger brian@MediaCity.comBrian McGovern bmcgover@cisco.comBrian Moore ziff@houdini.eecs.umich.eduBrian R. Haug haug@conterra.comBrian Tao taob@risc.orgBrion Moss brion@queeg.comBruce A. Mah bmah@ca.sandia.govBruce Albrecht bruce@zuhause.mn.orgBruce Gingery bgingery@gtcs.comBruce J. Keeler loodvrij@gridpoint.comBruce Murphy packrat@iinet.net.auBruce Walter walter@fortean.comCarey Jones mcj@acquiesce.orgCarl Fongheiser cmf@netins.netCarl Mascott cmascott@world.std.comCasper casper@acc.amCastor Fu castor@geocast.comCejka Rudolf cejkar@dcse.fee.vutbr.czChain Lee chain@110.netCharles Hannum mycroft@ai.mit.eduCharles Henrich henrich@msu.eduCharles Mott cmott@srv.netCharles Owens owensc@enc.eduChet Ramey chet@odin.INS.CWRU.EduChia-liang Kao clkao@CirX.ORGChiharu Shibata chi@bd.mbn.or.jpChip Norkus unknownChoi Jun Ho junker@jazz.snu.ac.krChris Costello chris@holly.dyndns.orgChris Csanady cc@tarsier.ca.sandia.govChris Dabrowski chris@vader.orgChris Dillon cdillon@wolves.k12.mo.usChris Piazza cpiazza@home.netChris Shenton
cshenton@angst.it.hq.nasa.govChris Stenton jacs@gnome.co.ukChris Timmons skynyrd@opus.cts.cwu.eduChris Torek torek@ee.lbl.govChristian Gusenbauer
cg@fimp01.fim.uni-linz.ac.atChristian Haury Christian.Haury@sagem.frChristian Weisgerber
naddy@bigeye.rhein-neckar.deChristoph P. Kukulies kuku@FreeBSD.orgChristoph Robitschko
chmr@edvz.tu-graz.ac.atChristoph Weber-Fahr
wefa@callcenter.systemhaus.netChristopher G. Demetriou
cgd@postgres.berkeley.eduChristopher T. Johnson
cjohnson@neunacht.netgsi.comChrisy Luke chrisy@flix.netChuck Hein chein@cisco.comClive Lin clive@CiRX.ORGColman Reilly careilly@tcd.ieConrad Sabatier conrads@neosoft.comCoranth Gryphon gryphon@healer.comCornelis van der Laan
nils@guru.ims.uni-stuttgart.deCove Schneider cove@brazil.nbn.comCraig Leres leres@ee.lbl.govCraig Loomis unknownCraig Metz cmetz@inner.netCraig Spannring cts@internetcds.comCraig Struble cstruble@vt.eduCristian Ferretti cfs@riemann.mat.puc.clCurt Mayer curt@toad.comCy Schubert cschuber@uumail.gov.bc.caDI. Christian Gusenbauer
cg@scotty.edvz.uni-linz.ac.atDai Ishijima ishijima@tri.pref.osaka.jpDamian Hamill damian@cablenet.netDan Cross tenser@spitfire.ecsel.psu.eduDan Lukes dan@obluda.czDan Nelson dnelson@emsphone.comDan Walters hannibal@cyberstation.netDaniel Baker dbaker@crash.ops.neosoft.comDaniel M. Eischen
deischen@iworks.InterWorks.orgDaniel O'Connor doconnor@gsoft.com.auDaniel Poirot poirot@aio.jsc.nasa.govDaniel Rock rock@cs.uni-sb.deDanny Egen unknownDanny J. Zerkel dzerkel@phofarm.comDarren Reed avalon@coombs.anu.edu.auDave Adkins adkin003@tc.umn.eduDave Andersen angio@aros.netDave Blizzard dblizzar@sprynet.comDave Bodenstab imdave@synet.netDave Burgess burgess@hrd769.brooks.af.milDave Chapeskie dchapes@ddm.on.caDave Cornejo dave@dogwood.comDave Edmondson davided@sco.comDave Glowacki dglo@ssec.wisc.eduDave Marquardt marquard@austin.ibm.comDave Tweten tweten@FreeBSD.orgDavid A. Adkins adkin003@tc.umn.eduDavid A. Bader dbader@umiacs.umd.eduDavid Borman dab@bsdi.comDavid Dawes dawes@XFree86.orgDavid Filo filo@yahoo.comDavid Holland dholland@eecs.harvard.eduDavid Holloway daveh@gwythaint.tamis.comDavid Horwitt dhorwitt@ucsd.eduDavid Hovemeyer daveho@infocom.comDavid Jones dej@qpoint.torfree.netDavid Kelly dkelly@tomcat1.tbe.comDavid Kulp dkulp@neomorphic.comDavid L. Nugent davidn@blaze.net.auDavid Leonard d@scry.dstc.edu.auDavid Malone dwmalone@maths.tcd.ieDavid Muir Sharnoff muir@idiom.comDavid S. Miller davem@jenolan.rutgers.eduDavid Wolfskill dhw@whistle.comDean Gaudet dgaudet@arctic.orgDean Huxley dean@fsa.caDenis Fortin unknownDennis Glatting
dennis.glatting@software-munitions.comDenton Gentry denny1@home.comDerek Inksetter derek@saidev.comDima Sivachenko dima@Chg.RUDirk Keunecke dk@panda.rhein-main.deDirk Nehrling nerle@pdv.deDmitry Khrustalev dima@xyzzy.machaon.ruDmitry Kohmanyuk dk@farm.orgDom Mitchell dom@myrddin.demon.co.ukDon Croyle croyle@gelemna.ft-wayne.in.us&a.whiteside;Don Morrison dmorrisn@u.washington.eduDon Yuniskis dgy@rtd.comDonald Maddox dmaddox@conterra.comDoug Barton studded@dal.netDouglas Ambrisko ambrisko@whistle.comDouglas Carmichael dcarmich@mcs.comDouglas Crosher dtc@scrooge.ee.swin.oz.auDrew Derbyshire ahd@kew.comDuncan Barclay dmlb@ragnet.demon.co.ukDustin Sallings dustin@spy.netEckart "Isegrim" Hofmann
Isegrim@Wunder-Nett.orgEd Gold
vegold01@starbase.spd.louisville.eduEd Hudson elh@p5.spnet.comEdward Wang edward@edcom.comEdwin Groothus edwin@nwm.wan.philips.comEiji-usagi-MATSUmoto usagi@clave.gr.jpELISA Font ProjectElmar Bartel
bartel@informatik.tu-muenchen.deEric A. Griff eagriff@global2000.netEric Blood eblood@cs.unr.eduEric J. Haug ejh@slustl.slu.eduEric J. Schwertfeger eric@cybernut.comEric L. Hernes erich@lodgenet.comEric P. Scott eps@sirius.comEric Sprinkle eric@ennovatenetworks.comErich Stefan Boleyn erich@uruk.orgErik E. Rantapaa rantapaa@math.umn.eduErik H. Moe ehm@cris.comErnst Winter ewinter@lobo.muc.deEugene M. Kim astralblue@usa.netEugene Radchenko genie@qsar.chem.msu.suEvan Champion evanc@synapse.netFaried Nawaz fn@Hungry.COMFlemming Jacobsen fj@tfs.comFong-Ching Liaw fong@juniper.netFrancis M J Hsieh mjshieh@life.nthu.edu.twFrank Bartels knarf@camelot.deFrank Chen Hsiung Chan
frankch@waru.life.nthu.edu.twFrank Durda IV uhclem@nemesis.lonestar.orgFrank MacLachlan fpm@n2.netFrank Nobis fn@Radio-do.deFrank Volf volf@oasis.IAEhv.nlFrank ten Wolde franky@pinewood.nlFrank van der Linden frank@fwi.uva.nlFred Cawthorne fcawth@jjarray.umn.eduFred Gilham gilham@csl.sri.comFred Templin templin@erg.sri.comFrederick Earl Gray fgray@rice.eduFUJIMOTO Kensaku
fujimoto@oscar.elec.waseda.ac.jpFUJISHIMA Satsuki k5@respo.or.jpFURUSAWA Kazuhisa
furusawa@com.cs.osakafu-u.ac.jpGabor Kincses gabor@acm.orgGabor Zahemszky zgabor@CoDe.huGarance A Drosehn gad@eclipse.its.rpi.eduGareth McCaughan gjm11@dpmms.cam.ac.ukGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGary J. garyj@rks32.pcs.dec.comGary Kline kline@thought.orgGaspar Chilingarov nightmar@lemming.acc.amGea-Suan Lin gsl@tpts4.seed.net.twGeoff Rehmet csgr@alpha.ru.ac.zaGeorg Wagner georg.wagner@ubs.comGerard Roudier groudier@club-internet.frGianmarco Giovannelli
gmarco@giovannelli.itGil Kloepfer Jr. gil@limbic.ssdl.comGilad Rom rom_glsa@ein-hashofet.co.ilGinga Kawaguti
ginga@amalthea.phys.s.u-tokyo.ac.jpGiles Lean giles@nemeton.com.auGlen Foster gfoster@gfoster.comGlenn Johnson gljohns@bellsouth.netGodmar Back gback@facility.cs.utah.eduGoran Hammarback goran@astro.uu.seGord Matzigkeit gord@enci.ucalgary.caGordon Greeff gvg@uunet.co.zaGraham Wheeler gram@cdsec.comGreg A. Woods woods@zeus.leitch.comGreg Ansley gja@ansley.comGreg Troxel gdt@ir.bbn.comGreg Ungerer gerg@stallion.oz.auGregory Bond gnb@itga.com.auGregory D. Moncreaff
moncrg@bt340707.res.ray.comGuy Harris guy@netapp.comGuy Helmer ghelmer@cs.iastate.eduHAMADA Naoki hamada@astec.co.jpHONDA Yasuhiro
honda@kashio.info.mie-u.ac.jpHOSOBUCHI Noriyuki hoso@buchi.tama.or.jpHannu Savolainen hannu@voxware.pp.fiHans Huebner hans@artcom.deHans Petter Bieker zerium@webindex.noHans Zuidam hans@brandinnovators.comHarlan Stenn Harlan.Stenn@pfcs.comHarold Barker hbarker@dsms.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHeikki Suonsivu hsu@cs.hut.fiHeiko W. Rupp unknownHelmut F. Wirth hfwirth@ping.atHenrik Vestergaard Draboel
hvd@terry.ping.dkHerb Peyerl hpeyerl@NetBSD.orgHideaki Ohmon ohmon@tom.sfc.keio.ac.jpHidekazu Kuroki hidekazu@cs.titech.ac.jpHideki Yamamoto hyama@acm.orgHidetoshi Shimokawa
simokawa@sat.t.u-tokyo.ac.jpHideyuki Suzuki
hideyuki@sat.t.u-tokyo.ac.jpHirayama Issei iss@mail.wbs.ne.jpHiroaki Sakai sakai@miya.ee.kagu.sut.ac.jpHiroharu Tamaru tamaru@ap.t.u-tokyo.ac.jpHironori Ikura hikura@kaisei.orgHiroshi Nishikawa nis@pluto.dti.ne.jpHiroya Tsubakimoto unknownHiroyuki NAKAJI
nakaji@zeisei3.dpri.kyoto-u.ac.jpHolger Veit Holger.Veit@gmd.deHolm Tiffe holm@geophysik.tu-freiberg.deHorance Chou
horance@freedom.ie.cycu.edu.twHorihiro Kumagaio kuma@jp.freebsd.orgHr.Ladavac lada@ws2301.gud.siemens.co.atHubert Feyrer hubertf@NetBSD.ORGHugh F. Mahon hugh@nsmdserv.cnd.hp.comHugh Mahon h_mahon@fc.hp.comHung-Chi Chu hcchu@r350.ee.ntu.edu.twIMAI Takeshi take-i@ceres.dti.ne.jpIMAMURA Tomoaki
tomoak-i@is.aist-nara.ac.jpIan Dowse iedowse@maths.tcd.ieIan Holland ianh@tortuga.com.auIan Struble ian@broken.netIan Vaudrey i.vaudrey@bigfoot.comIgor Khasilev igor@jabber.paco.odessa.uaIgor Roshchin str@giganda.komkon.orgIgor Sviridov siac@ua.netIgor Vinokurov igor@zynaps.ruIkuo Nakagawa ikuo@isl.intec.co.jpIlya V. Komarov mur@lynx.ruIssei Suzuki issei@jp.FreeBSD.orgItsuro Saito saito@miv.t.u-tokyo.ac.jpJ. Bryant jbryant@argus.flash.netJ. David Lowe lowe@saturn5.comJ. Han hjh@best.comJ. Hawk jhawk@MIT.EDUJ.T. Conklin jtc@cygnus.comJ.T. Jang keith@email.gcn.net.twJack jack@zeus.xtalwind.netJacob Bohn Lorensen jacob@jblhome.ping.mkJagane D Sundar jagane@netcom.comJake Hamby jehamby@lightside.comJames Clark jjc@jclark.comJames D. Stewart jds@c4systm.comJames Jegers jimj@miller.cs.uwm.eduJames Raynard
fhackers@jraynard.demon.co.ukJames T. Liu jtliu@phlebas.rockefeller.eduJames da Silva jds@cs.umd.eduJan Conard
charly@fachschaften.tu-muenchen.deJan Koum jkb@FreeBSD.orgJanick Taillandier
Janick.Taillandier@ratp.frJanusz Kokot janek@gaja.ipan.lublin.plJarle Greipsland jarle@idt.unit.noJason Garman init@risen.orgJason Thorpe thorpej@NetBSD.orgJason Wright jason@OpenBSD.orgJason Young
doogie@forbidden-donut.anet-stl.comJavier Martin Rueda jmrueda@diatel.upm.esJay Fenlason hack@datacube.comJaye Mathisen mrcpu@cdsnet.netJeff Bartig jeffb@doit.wisc.eduJeff Forys jeff@forys.cranbury.nj.usJeff Kletsky Jeff@Wagsky.comJeffrey Evans evans@scnc.k12.mi.usJeffrey Wheat jeff@cetlink.netJens Schweikhardt schweikh@noc.dfn.dJeremy Allison jallison@whistle.comJeremy Chatfield jdc@xinside.comJeremy Lea reg@shale.csir.co.zaJeremy Prior unknownJeroen Ruigrok/Asmodai asmodai@wxs.nlJesse Rosenstock jmr@ugcs.caltech.eduJian-Da Li jdli@csie.nctu.edu.twJim Babb babb@FreeBSD.orgJim Binkley jrb@cs.pdx.eduJim Carroll jim@carroll.comJim Flowers jflowers@ezo.netJim Leppek jleppek@harris.comJim Lowe james@cs.uwm.eduJim Mattson jmattson@sonic.netJim Mercer jim@komodo.reptiles.orgJim Mock jim@phrantic.phear.netJim Wilson wilson@moria.cygnus.comJimbo Bahooli
griffin@blackhole.iceworld.orgJin Guojun jin@george.lbl.govJoachim Kuebart unknownJoao Carlos Mendes Luis jonny@jonny.eng.brJochen Pohl jpo.drs@sni.deJoe "Marcus" Clarke marcus@miami.eduJoe Abley jabley@clear.co.nzJoe Jih-Shian Lu jslu@dns.ntu.edu.twJoe Orthoefer j_orthoefer@tia.netJoe Traister traister@mojozone.orgJoel Faedi Joel.Faedi@esial.u-nancy.frJoel Ray Holveck joelh@gnu.orgJoel Sutton sutton@aardvark.apana.org.auJohan Granlund johan@granlund.nuJohan Karlsson k@numeri.campus.luth.seJohan Larsson johan@moon.campus.luth.seJohann Tonsing jtonsing@mikom.csir.co.zaJohannes Helander unknownJohannes Stille unknownJohn Baldwin jobaldwi@vt.eduJohn Beckett jbeckett@southern.eduJohn Beukema jbeukema@hk.super.netJohn Brezak unknownJohn Capo jc@irbs.comJohn F. Woods jfw@jfwhome.funhouse.comJohn Goerzen
jgoerzen@alexanderwohl.complete.orgJohn Hay jhay@mikom.csir.co.zaJohn Heidemann johnh@isi.eduJohn Hood cgull@owl.orgJohn Kohl unknownJohn Lind john@starfire.mn.orgJohn Mackin john@physiol.su.oz.auJohn P johnp@lodgenet.comJohn Perry perry@vishnu.alias.netJohn Preisler john@vapornet.comJohn Rochester jr@cs.mun.caJohn Sadler john_sadler@alum.mit.eduJohn Saunders john@pacer.nlc.net.auJohn W. DeBoskey jwd@unx.sas.comJohn Wehle john@feith.comJohn Woods jfw@eddie.mit.eduJon Morgan morgan@terminus.trailblazer.comJonathan H N Chin jc254@newton.cam.ac.ukJonathan Hanna
jh@pc-21490.bc.rogers.wave.caJorge Goncalves j@bug.fe.up.ptJorge M. Goncalves ee96199@tom.fe.up.ptJos Backus jbackus@plex.nlJose M. Alcaide jose@we.lc.ehu.esJosef Grosch
jgrosch@superior.mooseriver.comJosef Karthauser joe@uk.freebsd.orgJoseph Stein joes@wstein.comJosh Gilliam josh@quick.netJosh Tiefenbach josh@ican.netJuergen Lock nox@jelal.hb.north.deJuha Inkari inkari@cc.hut.fiJukka A. Ukkonen jua@iki.fiJulian Assange proff@suburbia.netJulian Coleman j.d.coleman@ncl.ac.ukJulian H. Stacey jhs@freebsd.orgJulian Jenkins kaveman@magna.com.auJunichi Satoh junichi@jp.freebsd.orgJunji SAKAI sakai@jp.freebsd.orgJunya WATANABE junya-w@remus.dti.ne.jpK.Higashino a00303@cc.hc.keio.ac.jpKUNISHIMA Takeo kunishi@c.oka-pu.ac.jpKai Vorma vode@snakemail.hut.fiKaleb S. Keithley kaleb@ics.comKaneda Hiloshi vanitas@ma3.seikyou.ne.jpKapil Chowksey kchowksey@hss.hns.comKarl Denninger karl@mcs.comKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comKato Takenori
kato@eclogite.eps.nagoya-u.ac.jpKawanobe Koh kawanobe@st.rim.or.jpKazuhiko Kiriyama kiri@kiri.toba-cmt.ac.jpKazuo Horikawa horikawa@jp.FreeBSD.orgKees Jan Koster kjk1@ukc.ac.ukKeith Bostic bostic@bostic.comKeith E. Walker unknownKeith Moore unknownKeith Sklower unknownKen Hornstein unknownKen Key key@cs.utk.eduKen Mayer kmayer@freegate.comKenji Saito marukun@mx2.nisiq.netKenji Tomita tommyk@da2.so-net.or.jpKenneth Furge kenneth.furge@us.endress.comKenneth Monville desmo@bandwidth.orgKenneth R. Westerback krw@tcn.netKenneth Stailey kstailey@gnu.ai.mit.eduKent Talarico kent@shipwreck.tsoft.netKent Vander Velden graphix@iastate.eduKentaro Inagaki JBD01226@niftyserve.ne.jpKevin Bracey kbracey@art.acorn.co.ukKevin Day toasty@dragondata.comKevin Lahey kml@nas.nasa.govKevin Street street@iname.comKevin Van Maren vanmaren@fast.cs.utah.eduKiroh HARADA kiroh@kh.rim.or.jpKlaus Klein kleink@layla.inka.deKlaus-J. Wolf Yanestra@t-online.deKoichi Sato copan@ppp.fastnet.or.jpKostya Lukin lukin@okbmei.msk.suKouichi Hirabayashi kh@mogami-wire.co.jpKurt D. Zeilenga Kurt@Boolean.NETKurt Olsen kurto@tiny.mcs.usu.eduL. Jonas Olsson
ljo@ljo-slip.DIALIN.CWRU.EduLars Köller
Lars.Koeller@Uni-Bielefeld.DELarry Altneu larry@ALR.COMLaurence Lopez lopez@mv.mv.comLee Cremeans lcremean@tidalwave.netLiang Tai-hwa
avatar@www.mmlab.cse.yzu.edu.twLon Willett lon%softt.uucp@math.utah.eduLouis A. Mamakos louie@TransSys.COMLouis Mamakos loiue@TransSys.comLucas James Lucas.James@ldjpc.apana.org.auLyndon Nerenberg lyndon@orthanc.comM.C. Wong unknownMANTANI Nobutaka nobutaka@nobutaka.comMIHIRA Sanpei Yoshiro sanpei@sanpei.orgMITA Yoshio mita@jp.FreeBSD.ORGMITSUNAGA Noriaki
mitchy@er.ams.eng.osaka-u.ac.jpMOROHOSHI Akihiko moro@race.u-tokyo.ac.jpMagnus Enbom dot@tinto.campus.luth.seMahesh Neelakanta mahesh@gcomm.comMakoto MATSUSHITA matusita@jp.freebsd.orgMakoto WATANABE
watanabe@zlab.phys.nagoya-u.ac.jpMalte Lance malte.lance@gmx.netManu Iyengar
iyengar@grunthos.pscwa.psca.comMarc Frajola marc@dev.comMarc Ramirez mrami@mramirez.sy.yale.eduMarc Slemko marcs@znep.comMarc van Kempen wmbfmk@urc.tue.nlMarcel Moolenaar marcel@scc.nlMario Sergio Fujikawa Ferreira
lioux@gns.com.brMark Andrews unknownMark Cammidge mark@gmtunx.ee.uct.ac.zaMark Diekhans markd@grizzly.comMark Huizer xaa@stack.nlMark J. Taylor mtaylor@cybernet.comMark Krentel krentel@rice.eduMark Mayo markm@vmunix.comMark Thompson thompson@tgsoft.comMark Tinguely tinguely@plains.nodak.eduMark Treacy unknownMark Valentine mark@linus.demon.co.ukMartin BirgmeierMartin Ibert mib@ppe.bb-data.deMartin Kammerhofer dada@sbox.tu-graz.ac.atMartin Renters martin@tdc.on.caMartti Kuparinen
martti.kuparinen@ericsson.comMasachika ISHIZUKA
ishizuka@isis.min.ntt.jpMas.TAKEMURA unknownMasafumi NAKANE max@wide.ad.jpMasahiro Sekiguchi
seki@sysrap.cs.fujitsu.co.jpMasanobu Saitoh msaitoh@spa.is.uec.ac.jpMasanori Kanaoka kana@saijo.mke.mei.co.jpMasanori Kiriake seiken@ARGV.ACMasatoshi TAMURA
tamrin@shinzan.kuee.kyoto-u.ac.jpMats Lofkvist mal@algonet.seMatt Bartley mbartley@lear35.cytex.comMatt Thomas matt@3am-software.comMatt White mwhite+@CMU.EDUMatthew C. Mead mmead@Glock.COMMatthew Cashdollar mattc@rfcnet.comMatthew Flatt mflatt@cs.rice.eduMatthew Fuller fullermd@futuresouth.comMatthew N. Dodd winter@jurai.netMatthew Stein matt@bdd.netMatthias Pfaller leo@dachau.marco.deMatthias Scheler tron@netbsd.orgMattias Gronlund
Mattias.Gronlund@sa.erisoft.seMattias Pantzare pantzer@ludd.luth.seMaurice Castro
maurice@planet.serc.rmit.edu.auMax Euston meuston@jmrodgers.comMax Khon fjoe@husky.iclub.nsu.ruMaxim Bolotin max@rsu.ruMicha Class
michael_class@hpbbse.bbn.hp.comMichael Butler imb@scgt.oz.auMichael Butschky butsch@computi.erols.comMichael Clay mclay@weareb.orgMichael Elbel me@FreeBSD.ORGMichael Galassi nerd@percival.rain.comMichael Hancock michaelh@cet.co.jpMichael Hohmuth hohmuth@inf.tu-dresden.deMichael Perlman canuck@caam.rice.eduMichael Petry petry@netwolf.NetMasters.comMichael Reifenberger root@totum.plaut.deMichael Searle searle@longacre.demon.co.ukMichal Listos mcl@Amnesiac.123.orgMichio Karl Jinbo
karl@marcer.nagaokaut.ac.jpMiguel Angel Sagreras
msagre@cactus.fi.uba.arMihoko Tanaka m_tonaka@pa.yokogawa.co.jpMika Nystrom mika@cs.caltech.eduMikael Hybsch micke@dynas.seMikael Karpberg
karpen@ocean.campus.luth.seMike Del repenting@hotmail.comMike Durian durian@plutotech.comMike Durkin mdurkin@tsoft.sf-bay.orgMike E. Matsnev mike@azog.cs.msu.suMike Evans mevans@candle.comMike Grupenhoff kashmir@umiacs.umd.eduMike Hibler mike@marker.cs.utah.eduMike Karels unknownMike McGaughey mmcg@cs.monash.edu.auMike Meyer mwm@shiva.the-park.comMike Mitchell mitchell@ref.tfs.comMike Murphy mrm@alpharel.comMike Peck mike@binghamton.eduMike Spengler mks@msc.eduMikhail A. Sokolov mishania@demos.suMikhail Teterin mi@aldan.ziplink.netMing-I Hseh PA@FreeBSD.ee.Ntu.edu.TWMitsuru IWASAKI iwasaki@pc.jaring.myMonte Mitzelfelt monte@gonefishing.orgMorgan Davis root@io.cts.comMostyn Lewis mostyn@mrl.comMotoyuki Kasahara m-kasahr@sra.co.jpMotoyuki Konno motoyuki@snipe.rim.or.jpMunechika Sumikawa sumikawa@kame.netMurray Stokely murray@cdrom.comN.G.Smith ngs@sesame.hensa.ac.ukNAGAO Tadaaki nagao@cs.titech.ac.jpNAKAJI Hiroyuki
nakaji@zeisei.dpri.kyoto-u.ac.jpNAKAMURA Kazushi nkazushi@highway.or.jpNAKAMURA Motonori
motonori@econ.kyoto-u.ac.jpNIIMI Satoshi sa2c@and.or.jpNOKUBI Hirotaka h-nokubi@yyy.or.jpNadav Eiron nadav@barcode.co.ilNanbor Wang nw1@cs.wustl.eduNaofumi Honda
honda@Kururu.math.sci.hokudai.ac.jpNaoki Hamada nao@tom-yam.or.jpNarvi narvi@haldjas.folklore.eeNathan Ahlstrom nrahlstr@winternet.comNathan Dorfman nathan@rtfm.netNeal Fachan kneel@ishiboo.comNeil Blakey-Milner nbm@rucus.ru.ac.zaNiall Smart rotel@indigo.ieNick Barnes Nick.Barnes@pobox.comNick Handel nhandel@NeoSoft.comNick Hilliard nick@foobar.org&a.nsayer;Nick Williams njw@cs.city.ac.ukNickolay N. Dudorov nnd@itfs.nsk.suNiklas Hallqvist niklas@filippa.appli.seNisha Talagala nisha@cs.berkeley.eduNo Name ZW6T-KND@j.asahi-net.or.jpNo Name adrian@virginia.eduNo Name alex@elvisti.kiev.uaNo Name anto@netscape.netNo Name bobson@egg.ics.nitch.ac.jpNo Name bovynf@awe.beNo Name burg@is.ge.comNo Name chris@gnome.co.ukNo Name colsen@usa.netNo Name coredump@nervosa.comNo Name dannyman@arh0300.urh.uiuc.eduNo Name davids@SECNET.COMNo Name derek@free.orgNo Name devet@adv.IAEhv.nlNo Name djv@bedford.netNo Name dvv@sprint.netNo Name enami@ba2.so-net.or.jpNo Name flash@eru.tubank.msk.suNo Name flash@hway.ruNo Name fn@pain.csrv.uidaho.eduNo Name gclarkii@netport.neosoft.comNo Name gordon@sheaky.lonestar.orgNo Name graaf@iae.nlNo Name greg@greg.rim.or.jpNo Name grossman@cygnus.comNo Name gusw@fub46.zedat.fu-berlin.deNo Name hfir@math.rochester.eduNo Name hnokubi@yyy.or.jpNo Name iaint@css.tuu.utas.edu.auNo Name invis@visi.comNo Name ishisone@sra.co.jpNo Name iverson@lionheart.comNo Name jpt@magic.netNo Name junker@jazz.snu.ac.krNo Name k-sugyou@ccs.mt.nec.co.jpNo Name kenji@reseau.toyonaka.osaka.jpNo Name kfurge@worldnet.att.netNo Name lh@aus.orgNo Name lhecking@nmrc.ucc.ieNo Name mrgreen@mame.mu.oz.auNo Name nakagawa@jp.freebsd.orgNo Name ohki@gssm.otsuka.tsukuba.ac.jpNo Name owaki@st.rim.or.jpNo Name pechter@shell.monmouth.comNo Name pete@pelican.pelican.comNo Name pritc003@maroon.tc.umn.eduNo Name risner@stdio.comNo Name roman@rpd.univ.kiev.uaNo Name root@ns2.redline.ruNo Name root@uglabgw.ug.cs.sunysb.eduNo Name stephen.ma@jtec.com.auNo Name sumii@is.s.u-tokyo.ac.jpNo Name takas-su@is.aist-nara.ac.jpNo Name tamone@eig.unige.chNo Name tjevans@raleigh.ibm.comNo Name tony-o@iij.ad.jp amurai@spec.co.jpNo Name torii@tcd.hitachi.co.jpNo Name uenami@imasy.or.jpNo Name uhlar@netlab.skNo Name vode@hut.fiNo Name wlloyd@mpd.caNo Name wlr@furball.wellsfargo.comNo Name wmbfmk@urc.tue.nlNo Name yamagata@nwgpc.kek.jpNo Name ziggy@ryan.orgNobuhiro Yasutomi nobu@psrc.isac.co.jpNobuyuki Koganemaru
kogane@koganemaru.co.jpNorio Suzuki nosuzuki@e-mail.ne.jpNoritaka Ishizumi graphite@jp.FreeBSD.ORGNoriyuki Soda soda@sra.co.jpOlaf Wagner wagner@luthien.in-berlin.deOleg Sharoiko os@rsu.ruOliver Breuninger ob@seicom.NETOliver Friedrichs oliver@secnet.comOliver Fromme
oliver.fromme@heim3.tu-clausthal.deOliver Laumann
net@informatik.uni-bremen.deOliver Oberdorf oly@world.std.comOlof Johansson offe@ludd.luth.seOsokin Sergey aka oZZ ozz@freebsd.org.ruPace Willisson pace@blitz.comPaco Rosich rosich@modico.eleinf.uv.esPalle Girgensohn girgen@partitur.seParag Patel parag@cgt.comPascal Pederiva pascal@zuo.dec.comPasvorn Boonmark boonmark@juniper.netPatrick Gardella patrick@cre8tivegroup.comPatrick Hausen unknownPaul Antonov apg@demos.suPaul F. Werkowski unknownPaul Fox pgf@foxharp.boston.ma.usPaul Koch koch@thehub.com.auPaul Kranenburg pk@NetBSD.orgPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPaul S. LaFollette, Jr. unknownPaul Saab paul@mu.orgPaul Sandys myj@nyct.netPaul T. Root proot@horton.iaces.comPaul Vixie paul@vix.comPaulo Menezes paulo@isr.uc.ptPaulo Menezes pm@dee.uc.ptPedro A M Vazquez vazquez@IQM.Unicamp.BRPedro Giffuni giffunip@asme.orgPete Bentley pete@demon.netPeter Childs pjchilds@imforei.apana.org.auPeter Cornelius pc@inr.fzk.dePeter Haight peterh@prognet.comPeter Jeremy perer.jeremy@alcatel.com.auPeter M. Chen pmchen@eecs.umich.eduPeter Much peter@citylink.dinoex.sub.orgPeter Olsson unknownPeter Philipp pjp@bsd-daemon.netPeter Stubbs PETERS@staidan.qld.edu.auPhil Maker pjm@cs.ntu.edu.auPhil Sutherland
philsuth@mycroft.dialix.oz.auPhil Taylor phil@zipmail.co.ukPhilip Musumeci philip@rmit.edu.auPierre Y. Dampure pierre.dampure@k2c.co.ukPius Fischer pius@ienet.comPomegranate daver@flag.blackened.netPowerdog Industries
kevin.ruddy@powerdog.comR. Kym HorsellRajesh Vaidheeswarran rv@fore.comRalf Friedl friedl@informatik.uni-kl.deRandal S. Masutani randal@comtest.comRandall Hopper rhh@ct.picker.comRandall W. Dean rwd@osf.orgRandy Bush rbush@bainbridge.verio.netReinier Bezuidenhout
rbezuide@mikom.csir.co.zaRemy Card Remy.Card@masi.ibp.frRicardas Cepas rch@richard.eu.orgRiccardo Veraldi veraldi@cs.unibo.itRichard Henderson richard@atheist.tamu.eduRichard Hwang rhwang@bigpanda.comRichard J Kuhns rjk@watson.grauel.comRichard M. Neswold
rneswold@drmemory.fnal.govRichard Seaman, Jr. dick@tar.comRichard Stallman rms@gnu.ai.mit.eduRichard Straka straka@user1.inficad.comRichard Tobin richard@cogsci.ed.ac.ukRichard Wackerbarth rkw@Dataplex.NETRichard Winkel rich@math.missouri.eduRichard Wiwatowski rjwiwat@adelaide.on.netRick Macklem rick@snowhite.cis.uoguelph.caRick Macklin unknownRob Austein sra@epilogue.comRob Mallory rmallory@qualcomm.comRob Snow rsnow@txdirect.netRobert Crowe bob@speakez.comRobert D. Thrush rd@phoenix.aii.comRobert Eckardt
roberte@MEP.Ruhr-Uni-Bochum.deRobert Sanders rsanders@mindspring.comRobert Sexton robert@kudra.comRobert Shady rls@id.netRobert Swindells swindellsr@genrad.co.ukRobert Watson robert@cyrus.watson.orgRobert Withrow witr@rwwa.comRobert Yoder unknownRobin Carey
robin@mailgate.dtc.rankxerox.co.ukRoger Hardiman roger@cs.strath.ac.ukRoland Jesse jesse@cs.uni-magdeburg.deRon Bickers rbickers@intercenter.netRon Lenk rlenk@widget.xmission.comRonald Kuehn kuehn@rz.tu-clausthal.deRudolf Cejka unknownRuslan Belkin rus@home2.UA.netRuslan Ermilov ru@ucb.crimea.uaRuslan Shevchenko rssh@cam.grad.kiev.uaRussell L. Carter rcarter@pinyon.orgRussell Vincent rv@groa.uct.ac.zaRyan Younce ryany@pobox.comSANETO Takanori sanewo@strg.sony.co.jpSAWADA Mizuki miz@qb3.so-net.ne.jpSUGIMURA Takashi sugimura@jp.FreeBSD.ORGSURANYI Peter
suranyip@jks.is.tsukuba.ac.jpSakari Jalovaara sja@tekla.fiSam Hartman hartmans@mit.eduSamuel Lam skl@ScalableNetwork.comSamuele Zannoli zannoli@cs.unibo.itSander Vesik sander@haldjas.folklore.eeSandro Sigala ssigala@globalnet.itSascha Blank blank@fox.uni-trier.deSascha Wildner swildner@channelz.GUN.deSatoh Junichi junichi@astec.co.jpScot Elliott scot@poptart.orgScot W. Hetzel hetzels@westbend.netScott A. Kenney saken@rmta.ml.orgScott Blachowicz
scott.blachowicz@seaslug.orgScott Burris scott@pita.cns.ucla.eduScott Hazen Mueller scott@zorch.sf-bay.orgScott Michel scottm@cs.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSebastian Strollo seb@erix.ericsson.seSeigou TANIMURA
tanimura@naklab.dnj.ynu.ac.jpSerge A. Babkin babkin@hq.icb.chel.suSerge V. Vakulenko vak@zebub.msk.suSergei Chechetkin
csl@whale.sunbay.crimea.uaSergei S. Laskavy laskavy@pc759.cs.msu.suSergey Gershtein sg@mplik.ruSergey Potapov sp@alkor.ruSergey Shkonda serg@bcs.zp.uaSergey V.Dorokhov svd@kbtelecom.nalnet.ruSergio Lenzi lenzi@bsi.com.brShaun Courtney shaun@emma.eng.uct.ac.zaShawn M. Carey smcarey@mailbox.syr.eduSheldon Hearn axl@iafrica.comShigio Yamaguchi shigio@wafu.netgate.netShinya Esu esu@yk.rim.or.jpShunsuke Akiyama akiyama@jp.freebsd.orgSimon simon@masi.ibp.frSimon Burge simonb@telstra.com.auSimon J Gerraty sjg@melb.bull.oz.auSimon Marlow simonm@dcs.gla.ac.ukSimon Shapiro shimon@simon-shapiro.orgSin'ichiro MIYATANI siu@phaseone.co.jpSlaven Rezic eserte@cs.tu-berlin.deSoochon Radee slr@mitre.orgSoren Dayton csdayton@midway.uchicago.eduSoren Dossing sauber@netcom.comSoren S. Jorvang soren@dt.dkStefan Bethke stb@hanse.deStefan Eggers seggers@semyam.dinoco.deStefan Moeding s.moeding@ndh.netStefan Petri unknownStefan `Sec` Zehl sec@42.orgSteinar Haug sthaug@nethelp.noStephane E. Potvin sepotvin@videotron.caStephane Legrand stephane@lituus.frStephen Clawson
sclawson@marker.cs.utah.eduStephen F. Combs combssf@salem.ge.comStephen Farrell stephen@farrell.orgStephen Hocking sysseh@devetir.qld.gov.auStephen J. Roznowski sjr@home.netStephen McKay syssgm@devetir.qld.gov.auStephen Melvin melvin@zytek.comSteve Bauer sbauer@rock.sdsmt.eduSteve Coltrin spcoltri@io.comSteve Deering unknownSteve Gerakines steve2@genesis.tiac.netSteve Gericke steveg@comtrol.comSteve Piette steve@simon.chi.il.USSteve Schwarz schwarz@alpharel.comSteven G. Kargl
kargl@troutmask.apl.washington.eduSteven H. Samorodin samorodi@NUXI.comSteven McCanne mccanne@cs.berkeley.eduSteven Plite splite@purdue.eduSteven Wallace unknownStuart Henderson
stuart@internationalschool.co.ukSue Blake sue@welearn.com.auSugimoto Sadahiro ixtl@komaba.utmc.or.jpSugiura Shiro ssugiura@duo.co.jpSujal Patel smpatel@wam.umd.eduSune Stjerneby stjerneby@usa.netSuzuki Yoshiaki
zensyo@ann.tama.kawasaki.jpTadashi Kumano kumano@strl.nhk.or.jpTaguchi Takeshi taguchi@tohoku.iij.ad.jpTakahashi Yoshihiro nyan@dd.catv.ne.jpTakahiro Yugawa yugawa@orleans.rim.or.jpTakanori Watanabe
takawata@shidahara1.planet.sci.kobe-u.ac.jpTakashi Mega mega@minz.orgTakashi Uozu j1594016@ed.kagu.sut.ac.jpTakayuki Ariga a00821@cc.hc.keio.ac.jpTakeru NAIKI naiki@bfd.es.hokudai.ac.jpTakeshi Amaike amaike@iri.co.jpTakeshi MUTOH mutoh@info.nara-k.ac.jpTakeshi Ohashi
ohashi@mickey.ai.kyutech.ac.jpTakeshi WATANABE
watanabe@crayon.earth.s.kobe-u.ac.jpTakuya SHIOZAKI
tshiozak@makino.ise.chuo-u.ac.jpTatoku Ogaito tacha@tera.fukui-med.ac.jpTatsumi HOSOKAWA hosokawa@jp.FreeBSD.orgTed Buswell tbuswell@mediaone.netTed Faber faber@isi.eduTed Lemon unknownTerry Lambert terry@lambert.orgTerry Lee terry@uivlsi.csl.uiuc.eduTetsuya Furukawa tetsuya@secom-sis.co.jpTheo de Raadt deraadt@OpenBSD.orgThomas thomas@mathematik.uni-Bremen.deThomas D. Dean tomdean@ix.netcom.comThomas David Rivers rivers@dignus.comThomas G. McWilliams tgm@netcom.comThomas Gellekum
thomas@ghpc8.ihf.rwth-aachen.deThomas Graichen
graichen@omega.physik.fu-berlin.deThomas König
Thomas.Koenig@ciw.uni-karlsruhe.deThomas Ptacek unknownThomas Stevens tas@stevens.orgThomas Stromberg tstrombe@rtci.comThomas Valentino Crimi
tcrimi+@andrew.cmu.eduThomas Wintergerst thomas@lemur.nord.deÞórður Ívarsson
totii@est.isTim Kientzle kientzle@netcom.comTim Singletary
tsingle@sunland.gsfc.nasa.govTim Wilkinson tim@sarc.city.ac.ukTimo J. Rinne tri@iki.fiTodd Miller millert@openbsd.orgTom root@majestix.cmr.noTom tom@sdf.comTom Gray - DCA dcasba@rain.orgTom Hukins tom@eborcom.comTom Jobbins tom@tom.tjTom Pusateri pusateri@juniper.netTom Rush tarush@mindspring.comTom Samplonius tom@misery.sdf.comTomohiko Kurahashi
kura@melchior.q.t.u-tokyo.ac.jpTony Kimball alk@Think.COMTony Li tli@jnx.comTony Lynn wing@cc.nsysu.edu.twTorbjorn Granlund tege@matematik.su.seToshihiko ARAI toshi@tenchi.ne.jpToshihiko SHIMOKAWA toshi@tea.forus.or.jpToshihiro Kanda candy@kgc.co.jpToshiomi Moriki
Toshiomi.Moriki@ma1.seikyou.ne.jpTrefor S. trefor@flevel.co.ukTrevor Blackwell tlb@viaweb.comURATA Shuichiro s-urata@nmit.tmg.nec.co.jpUdo Schweigert ust@cert.siemens.deUgo Paternostro paterno@dsi.unifi.itUlf Kieber kieber@sax.deUlli Linzen ulli@perceval.camelot.deUstimenko Semen semen@iclub.nsu.ruUwe Arndt arndt@mailhost.uni-koblenz.deVadim Chekan vadim@gc.lviv.uaVadim Kolontsov vadim@tversu.ac.ruVadim Mikhailov mvp@braz.ruVan Jacobson van@ee.lbl.govVasily V. Grechishnikov
bazilio@ns1.ied-vorstu.ac.ruVasim Valejev vasim@uddias.diaspro.comVernon J. Schryver vjs@mica.denver.sgi.comVic Abell abe@cc.purdue.eduVille Eerola ve@sci.fiVincent Poy vince@venus.gaianet.netVincenzo Capuano
VCAPUANO@vmprofs.esoc.esa.deVirgil Champlin champlin@pa.dec.comVladimir A. Jakovenko
vovik@ntu-kpi.kiev.uaVladimir Kushnir kushn@mail.kar.netVsevolod Lobko seva@alex-ua.comW. Gerald Hicks wghicks@bellsouth.netW. Richard Stevens rstevens@noao.eduWalt Howard howard@ee.utah.eduWarren Toomey wkt@csadfa.cs.adfa.oz.auWayne Scott wscott@ichips.intel.comWerner Griessl
werner@btp1da.phy.uni-bayreuth.deWes Santee wsantee@wsantee.oz.netWietse Venema wietse@wzv.win.tue.nlWilfredo Sanchez wsanchez@apple.comWiljo Heinen wiljo@freeside.ki.open.deWilko Bulte wilko@yedi.iaf.nlWillem Jan Withagen wjw@surf.IAE.nlWilliam Jolitz withheldWilliam Liao william@tale.netWojtek Pilorz
wpilorz@celebris.bdk.lublin.plWolfgang Helbig helbig@ba-stuttgart.deWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@FreeBSD.orgWu Ching-hong woju@FreeBSD.ee.Ntu.edu.TWYarema yds@ingress.comYaroslav Terletsky ts@polynet.lviv.uaYasuhito FUTATSUKI futatuki@fureai.or.jpYen-Shuo Su yssu@CCCA.NCTU.edu.twYing-Chieh Liao ijliao@csie.NCTU.edu.twYixin Jin yjin@rain.cs.ucla.eduYoshiaki Uchikawa yoshiaki@kt.rim.or.jpYoshihiko OHTA yohta@bres.tsukuba.ac.jpYoshihisa NAKAGAWA
y-nakaga@ccs.mt.nec.co.jpYoshikazu Goto gotoh@ae.anritsu.co.jpYoshimasa Ohnishi
ohnishi@isc.kyutech.ac.jpYoshishige Arai ryo2@on.rim.or.jpYuichi MATSUTAKA matutaka@osa.att.ne.jpYujiro MIYATA
miyata@bioele.nuee.nagoya-u.ac.jpYukihiro Nakai nacai@iname.comYusuke Nawano azuki@azkey.orgYuu Yashiki s974123@cc.matsuyama-u.ac.jpYuval Yarom yval@cs.huji.ac.ilYves Fonk yves@cpcoup5.tn.tudelft.nlYves Fonk yves@dutncp8.tn.tudelft.nlZach Heilig zach@gaffaneys.comZahemszhky Gabor zgabor@code.huZhong Ming-Xun zmx@mail.CDPA.nsysu.edu.twarci vega@sophia.inria.frder Mouse mouse@Collatz.McRCIM.McGill.EDUfrf frf@xocolatl.comEge Rekk aagero@aage.priv.no386BSD Patch Kit Patch Contributors(in alphabetical order by first name):Adam Glass glass@postgres.berkeley.eduAdrian Hall adrian@ibmpcug.co.ukAndrey A. Chernov ache@astral.msk.suAndrew Herbert andrew@werple.apana.org.auAndrew Moore alm@netcom.comAndy Valencia ajv@csd.mot.comjtk@netcom.comArne Henrik Juul arnej@Lise.Unit.NOBakul Shah bvs@bitblocks.comBarry Lustig barry@ictv.comBob Wilcox bob@obiwan.uucpBranko LankesterBrett Lymn blymn@mulga.awadi.com.AUCharles Hannum mycroft@ai.mit.eduChris G. Demetriou
cgd@postgres.berkeley.eduChris Torek torek@ee.lbl.govChristoph Robitschko
chmr@edvz.tu-graz.ac.atDaniel Poirot poirot@aio.jsc.nasa.govDave Burgess burgess@hrd769.brooks.af.milDave Rivers rivers@ponds.uucpDavid Dawes dawes@physics.su.OZ.AUDavid Greenman dg@Root.COMEric J. Haug ejh@slustl.slu.eduFelix Gaehtgens
felix@escape.vsse.in-berlin.deFrank Maclachlan fpm@crash.cts.comGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGeoff Rehmet csgr@alpha.ru.ac.zaGoran Hammarback goran@astro.uu.seGuido van Rooij guido@gvr.orgGuy Harris guy@auspex.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHerb Peyerl hpeyerl@novatel.cuc.ab.caHolger Veit Holger.Veit@gmd.deIshii Masahiro, R. Kym HorsellJ.T. Conklin jtc@cygnus.comJagane D Sundar jagane@netcom.comJames Clark jjc@jclark.comJames Jegers jimj@miller.cs.uwm.eduJames W. DolterJames da Silva jds@cs.umd.edu et alJay Fenlason hack@datacube.comJim Wilson wilson@moria.cygnus.comJörg Lohse
lohse@tech7.informatik.uni-hamburg.deJörg Wunsch
joerg_wunsch@uriah.heep.sax.deJohn DysonJohn Woods jfw@eddie.mit.eduJordan K. Hubbard jkh@whisker.hubbard.ieJulian Elischer julian@dialix.oz.auJulian Stacey jhs@freebsd.orgKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comkarl@one.neosoft.comKeith Bostic bostic@toe.CS.Berkeley.EDUKen HughesKent Talarico kent@shipwreck.tsoft.netKevin Lahey kml%rokkaku.UUCP@mathcs.emory.edukml@mosquito.cis.ufl.eduMarc Frajola marc@dev.comMark Tinguely tinguely@plains.nodak.edutinguely@hookie.cs.ndsu.NoDak.eduMartin Renters martin@tdc.on.caMichael Clay mclay@weareb.orgMichael Galassi nerd@percival.rain.comMike Durkin mdurkin@tsoft.sf-bay.orgNaoki Hamada nao@tom-yam.or.jpNate Williams nate@bsd.coe.montana.eduNick Handel nhandel@NeoSoft.comnick@madhouse.neosoft.comPace Willisson pace@blitz.comPaul Kranenburg pk@cs.few.eur.nlPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPeter da Silva peter@NeoSoft.comPhil Sutherland
philsuth@mycroft.dialix.oz.auPoul-Henning Kampphk@FreeBSD.ORGRalf Friedl friedl@informatik.uni-kl.deRick Macklem root@snowhite.cis.uoguelph.caRobert D. Thrush rd@phoenix.aii.comRodney W. Grimes rgrimes@cdrom.comSascha Wildner swildner@channelz.GUN.deScott Burris scott@pita.cns.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSean Eric Fagan sef@kithrup.comSimon J Gerraty sjg@melb.bull.oz.ausjg@zen.void.oz.auStephen McKay syssgm@devetir.qld.gov.auTerry Lambert terry@icarus.weber.eduTerry Lee terry@uivlsi.csl.uiuc.eduTor Egge Tor.Egge@idi.ntnu.noWarren Toomey wkt@csadfa.cs.adfa.oz.auWiljo Heinen wiljo@freeside.ki.open.deWilliam Jolitz withheldWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@dentaro.GUN.deYuval Yarom yval@cs.huji.ac.il
diff --git a/en/handbook/ports/chapter.sgml b/en/handbook/ports/chapter.sgml
index 23009b15fa..dc2cf404cc 100644
--- a/en/handbook/ports/chapter.sgml
+++ b/en/handbook/ports/chapter.sgml
@@ -1,4501 +1,4501 @@
Installing Applications: The Ports collectionContributed by &a.jraynard;.The FreeBSD Ports collection allows you to compile and install a very
wide range of applications with a minimum of effort.For all the hype about open standards, getting a program to work on
different versions of Unix in the real world can be a tedious and tricky
business, as anyone who has tried it will know. You may be lucky enough
to find that the program you want will compile cleanly on your system,
install itself in all the right places and run flawlessly “out of
the box”, but this is unfortunately rather rare. With most
programs, you will find yourself doing a fair bit of head-scratching, and
there are quite a few programs that will result in premature greying, or
even chronic alopecia...Some software distributions have attacked this problem by providing
configuration scripts. Some of these are very clever, but they have an
unfortunate tendency to triumphantly announce that your system is
something you have never heard of and then ask you lots of questions that
sound like a final exam in system-level Unix programming (Does
your system's gethitlist function return a const pointer to a fromboz or
a pointer to a const fromboz? Do you have Foonix style unacceptable
exception handling? And if not, why not?).Fortunately, with the Ports collection, all the hard work involved has
already been done, and you can just type make install
and get a working program.Why Have a Ports Collection?The base FreeBSD system comes with a very wide range of tools and
system utilities, but a lot of popular programs are not in the base
system, for good reasons:-Programs that some people cannot live without and other people
cannot stand, such as a certain Lisp-based editor.Programs which are too specialised to put in the base system
(CAD, databases).Programs which fall into the “I must have a look at that
when I get a spare minute” category, rather than
system-critical ones (some languages, perhaps).Programs that are far too much fun to be supplied with a serious
operating system like FreeBSD ;-)However many programs you put in the base system, people will
always want more, and a line has to be drawn somewhere (otherwise
FreeBSD distributions would become absolutely enormous).Obviously it would be unreasonable to expect everyone to port their
favourite programs by hand (not to mention a tremendous amount of
duplicated work), so the FreeBSD Project came up with an ingenious way
of using standard tools that would automate the process.Incidentally, this is an excellent illustration of how “the
Unix way” works in practice by combining a set of simple but very
flexible tools into something very powerful.How Does the Ports Collection Work?Programs are typically distributed on the Internet as a tarball consisting of a Makefile and
the source code for the program and usually some instructions (which are
unfortunately not always as instructive as they could be), with perhaps
a configuration script.The standard scenario is that you FTP down the tarball, extract it
somewhere, glance through the instructions, make any changes that seem
necessary, run the configure script to set things up and use the
standard make program to compile and install the
program from the source.FreeBSD ports still use the tarball mechanism, but use a skeleton to hold the
"knowledge" of how to get the program working on FreeBSD,
rather than expecting the user to be able to work it out. They also
supply their own customised Makefile, so that almost every port
can be built in the same way.If you look at a port skeleton (either on your FreeBSD
system or the
FTP site) and expect to find all sorts of pointy-headed rocket
science lurking there, you may be disappointed by the one or two rather
unexciting-looking files and directories you find there. (We will
discuss in a minute how to go about Getting a port).“How on earth can this do anything?” I hear you cry.
“There is no source code there!”Fear not, gentle reader, all will become clear (hopefully). Let's
see what happens if we try and install a port. I have chosen
ElectricFence, a useful tool for developers,
as the skeleton is more straightforward than most.If you are trying this at home, you will need to be root.&prompt.root; cd /usr/ports/devel/ElectricFence
&prompt.root; make install
>> Checksum OK for ElectricFence-2.0.5.tar.gz.
===> Extracting for ElectricFence-2.0.5
===> Patching for ElectricFence-2.0.5
===> Applying FreeBSD patches for ElectricFence-2.0.5
===> Configuring for ElectricFence-2.0.5
===> Building for ElectricFence-2.0.5
[lots of compiler output...]
===> Installing for ElectricFence-2.0.5
===> Warning: your umask is "0002". If this is not desired, set it to
an appropriate value and install this port again by ``make reinstall''.
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.a /usr/local/lib
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.3 /usr/local/man/man3
===> Compressing manual pages for ElectricFence-2.0.5
===> Registering installation for ElectricFence-2.0.5To avoid confusing the issue, I have completely removed the build
output.If you tried this yourself, you may well have got something like
this at the start:-&prompt.root; make install
>> ElectricFence-2.0.5.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://ftp.doc.ic.ac.uk/Mirrors/sunsite.unc.edu/pub/Linux/devel/lang/c/.The make program has noticed that you did not
have a local copy of the source code and tried to FTP it down so it
could get the job done. I already had the source handy in my example,
so it did not need to fetch it.Let's go through this and see what the make
program was doing.Locate the source code tarball. If it is not available
locally, try to grab it from an FTP site.Run a checksum test on the
tarball to make sure it has not been tampered with, accidentally
truncated, downloaded in ASCII mode, struck by neutrinos while in
transit, etc.Extract the tarball into a temporary work directory.Apply any patches needed to
get the source to compile and run under FreeBSD.Run any configuration script required by the build process and
correctly answer any questions it asks.(Finally!) Compile the code.Install the program executable and other supporting files, man
pages, etc. under the /usr/local hierarchy,
where they will not get mixed up with system programs. This also
makes sure that all the ports you install will go in the same place,
instead of being flung all over your system.Register the installation in a database. This means that, if
you do not like the program, you can cleanly remove all traces of it from your
system.Scroll up to the make output and see if you can
match these steps to it. And if you were not impressed before, you
should be by now!Getting a FreeBSD PortThere are two ways of getting hold of the FreeBSD port for a
program. One requires a FreeBSD CDROM,
the other involves using an Internet
Connection.Compiling ports from CDROMAssuming that your FreeBSD CDROM is in the drive and mounted on
/cdrom (and the mount point
must be /cdrom), you should
then be able to build ports just as you normally do and the port
collection's built in search path should find the tarballs in
/cdrom/ports/distfiles/ (if they exist there)
rather than downloading them over the net.Another way of doing this, if you want to just use the port
skeletons on the CDROM, is to set these variables in
/etc/make.conf:
PORTSDIR= /cdrom/ports
DISTDIR= /tmp/distfiles
WRKDIRPREFIX= /tmpSubstitute /tmp for any place you have enough
free space. Then, just cd to the appropriate
subdirectory under /cdrom/ports and type
make install as usual.
WRKDIRPREFIX will cause the port to be build under
/tmp/cdrom/ports; for instance,
games/oneko will be built under
/tmp/cdrom/ports/games/oneko.There are some ports for which we cannot provide the original
source in the CDROM due to licensing limitations. In that case, you
will need to look at the section on Compiling ports using an Internet
connection.Compiling ports from the InternetIf you do not have a CDROM, or you want to make sure you get the
very latest version of the port you want, you will need to download
the skeleton for the port. Now
this might sound like rather a fiddly job full of pitfalls, but it is
actually very easy.First, if you are running a release version of FreeBSD, make sure
you get the appropriate “upgrade kit” for your release
from the ports web
page. These packages include files that have been updated
since the release that you may need to compile new ports.The key to the skeletons is that the FreeBSD FTP server can create
on-the-fly tarballs for you.
Here is how it works, with the gnats program in the databases
directory as an example (the bits in square brackets are comments. Do
not type them in if you are trying this yourself!):-&prompt.root; cd /usr/ports
&prompt.root; mkdir databases
&prompt.root; cd databases
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports/databases>get gnats.tar
[tars up the gnats skeleton for us]
>quit
&prompt.root; tar xf gnats.tar
[extract the gnats skeleton]
&prompt.root; cd gnats
&prompt.root; make install
[build and install gnats]What happened here? We connected to the FTP server in the usual
way and went to its databases sub-directory.
When we gave it the command get gnats.tar, the FTP
server tarred up the gnats
directory for us.We then extracted the gnats skeleton and went into the gnats
directory to build the port. As we explained earlier, the make process noticed we
did not have a copy of the source locally, so it fetched one before
extracting, patching and building it.Let's try something more ambitious now. Instead of getting a
single port skeleton, let's get a whole sub-directory, for example all
the database skeletons in the ports collection. It looks almost the
same:-&prompt.root; cd /usr/ports
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports>get databases.tar
[tars up the databases directory for us]
>quit
&prompt.root; tar xf databases.tar
[extract all the database skeletons]
&prompt.root; cd databases
&prompt.root; make install
[build and install all the database ports]With half a dozen straightforward commands, we have now got a set
of database programs on our FreeBSD machine! All we did that was
different from getting a single port skeleton and building it was that
we got a whole directory at once, and compiled everything in it at
once. Pretty impressive, no?If you expect to be installing many ports, it is probably worth
downloading all the ports directories.SkeletonsA team of compulsive hackers who have forgotten to eat in a frantic
attempt to make a deadline? Something unpleasant lurking in the FreeBSD
attic? No, a skeleton here is a minimal framework that supplies
everything needed to make the ports magic work.MakefileThe most important component of a skeleton is the Makefile. This
contains various statements that specify how the port should be
compiled and installed. Here is the Makefile for
ElectricFence:-
# New ports collection makefile for: Electric Fence
# Version required: 2.0.5
# Date created: 13 November 1997
# Whom: jraynard
#
# $Id$
#
DISTNAME= ElectricFence-2.0.5
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= devel/lang/c
MAINTAINER= jraynard@freebsd.org
MAN3= libefence.3
do-install:
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
.include <bsd.port.mk>The lines beginning with a "#" sign are comments for the
benefit of human readers (as in most Unix script files).DISTNAME specifies the name of the tarball, but without the
extension.CATEGORIES states what kind of program this is.
In this case, a utility for developers. See the categories section of this
handbook for a complete list.MASTER_SITES is the URL(s) of the master FTP
site, which is used to retrieve the tarball if it is not available on the
local system. This is a site which is regarded as reputable, and is
normally the one from which the program is officially distributed (in
so far as any software is "officially" distributed on the
Internet).MAINTAINER is the email address of the person
who is responsible for updating the skeleton if, for example a new
version of the program comes out.Skipping over the next few lines for a minute, the line
.include <bsd.port.mk> says that the other
statements and commands needed for this port are in a standard file
called bsd.port.mk. As these are the same for
all ports, there is no point in duplicating them all over the place,
so they are kept in a single standard file.This is probably not the place to go into a detailed examination
of how Makefiles work; suffice it to say that the line starting with
MAN3 ensures that the ElectricFence man page is
compressed after installation, to help conserve your precious disk
space. The original port did not provide an
install target, so the three lines from
do-install ensure that the files produced by
this port are placed in the correct destination.The files directoryThe file containing the checksum for the port is called
md5, after the MD5 algorithm used for ports
checksums. It lives in a directory with the slightly confusing name
of files.This directory can also contain other miscellaneous files that are
required by the port and do not belong anywhere else.The patches directoryThis directory contains the patches needed to make everything work
properly under FreeBSD.The pkg directoryThis program contains three quite useful files:-COMMENT — a one-line description of
the program.DESCR — a more detailed
description.PLIST — a list of all the files
that will be created when the program is installed.What to do when a port does not work.Oh. You can do one of four (4) things :Fix it yourself. Technical details on how ports work can be
found in Porting applications.Gripe. This is done by e-mail only! Send
such e-mail to the &a.ports; and please include the name/version of
the port, where you got both the port source & distfile(s) from,
and what the text of the error was.Forget it. This is the easiest for most — very few of the
programs in ports can be classified as essential!Grab the pre-compiled package from a ftp server. The
“master” package collection is on FreeBSD's FTP server
in the packages
directory, though check your local mirror first, please!
These are more likely to work (on the whole) than trying to compile
from source and a lot faster besides! Use the &man.pkg.add.1;
program to install a package file on your
system.Some Questions and AnswersQ. I thought this was going to be a discussion about
modems??!A. Ah. You must be thinking of the serial ports on the back of
your computer. We are using “port” here to mean the
result of “porting” a program from one version of Unix
to another. (It is an unfortunate bad habit of computer people to
use the same word to refer to several completely different
things).Q. I thought you were supposed to use packages to install extra
programs?A. Yes, that is usually the quickest and easiest way of doing
it.Q. So why bother with ports then?A. Several reasons:-The licensing conditions on some software distributions
require that they be distributed as source code, not
binaries.Some people do not trust binary distributions. At least
with source code you can (in theory) read through it and look
for potential problems yourself.If you have some local patches, you will need the source to
add them yourself.You might have opinions on how a program should be compiled
that differ from the person who did the package — some
people have strong views on what optimisation setting should be
used, whether to build debug versions and then strip them or
not, etc. etc.Some people like having code around, so they can read it if
they get bored, hack around with it, borrow from it (licence
terms permitting, of course!) and so on.If you ain't got the source, it ain't software! ;-) Q. What is a patch?A. A patch is a small (usually) file that specifies how to go
from one version of a file to another. It contains text that says,
in effect, things like “delete line 23”, “add
these two lines after line 468” or “change line 197 to
this”. Also known as a “diff”, since it is
generated by a program of that name. Q. What is all this about
tarballs?A. It is a file ending in .tar or
.tar.gz (with variations like
.tar.Z, or even .tgz if
you are trying to squeeze the names into a DOS filesystem).Basically, it is a directory tree that has been archived into a
single file (.tar) and optionally compressed
(.gz). This technique was originally used for
Tape ARchives (hence the
name tar), but it is a widely used way of
distributing program source code around the Internet.You can see what files are in them, or even extract them
yourself, by using the standard Unix tar program, which comes with
the base FreeBSD system, like this:-&prompt.user; tar tvzf foobar.tar.gz
&prompt.user; tar xzvf foobar.tar.gz
&prompt.user; tar tvf foobar.tar
&prompt.user; tar xvf foobar.tar Q. And a checksum?A. It is a number generated by adding up all the data in the
file you want to check. If any of the characters change, the
checksum will no longer be equal to the total, so a simple
comparison will allow you to spot the difference. (In practice, it
is done in a more complicated way to spot problems like
position-swapping, which will not show up with a simplistic
addition).Q. I did what you said for compiling
ports from a CDROM and it worked great until I tried to
install the kermit port:-&prompt.root; make install
>> cku190.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://kermit.columbia.edu/kermit/archives/.Why can it not be found? Have I got a dud CDROM?A. The licensing terms for kermit do not allow us to put the
tarball for it on the CDROM, so you will have to fetch it by hand
— sorry! The reason why you got all those error messages was
because you were not connected to the Internet at the time. Once
you have downloaded it from any of the sites above, you can re-start
the process (try and choose the nearest site to you, though, to save
your time and the Internet's bandwidth).Q. I did that, but when I tried to put it into
/usr/ports/distfiles I got some error about not
having permission.A. The ports mechanism looks for the tarball in
/usr/ports/distfiles, but you will not be able
to copy anything there because it is sym-linked to the CDROM, which
is read-only. You can tell it to look somewhere else by
doing&prompt.root; make DISTDIR=/where/you/put/it installQ. Does the ports scheme only work if you have everything in
/usr/ports? My system administrator says I must
put everything under
/u/people/guests/wurzburger, but it does not
seem to work.A. You can use the PORTSDIR and
PREFIX variables to tell the ports mechanism to
use different directories. For instance,&prompt.root; make PORTSDIR=/u/people/guests/wurzburger/ports installwill compile the port in
/u/people/guests/wurzburger/ports and install
everything under /usr/local.&prompt.root; make PREFIX=/u/people/guests/wurzburger/local installwill compile it in /usr/ports and install
it in /u/people/guests/wurzburger/local.And of course&prompt.root; make PORTSDIR=.../ports PREFIX=.../local installwill combine the two (it is too long to fit on the page if I
write it in full, but I am sure you get the idea).If you do not fancy typing all that in every time you install a
port (and to be honest, who would?), it is a good idea to put these
variables into your environment.Q. I do not have a FreeBSD CDROM, but I would like to have all
the tarballs handy on my system so I do not have to wait for a
download every time I install a port. Is there an easy way to get
them all at once?A. To get every single tarball for the ports collection,
do&prompt.root; cd /usr/ports
&prompt.root; make fetchFor all the tarballs for a single ports directory, do&prompt.root; cd /usr/ports/directory
&prompt.root; make fetchand for just one port — well, I think you have guessed
already.Q. I know it is probably faster to fetch the tarballs from one
of the FreeBSD mirror sites close by. Is there any way to tell the
port to fetch them from servers other than ones listed in the
MASTER_SITES?A. Yes. If you know, for example, ftp.FreeBSD.ORG is much closer than sites
listed in MASTER_SITES, do as following
example.&prompt.root; cd /usr/ports/directory
&prompt.root; make MASTER_SITE_OVERRIDE=ftp://ftp.FreeBSD.ORG/pub/FreeBSD/ports/distfiles/ fetchQ. I want to know what files make is going to need before it
tries to pull them down.A. make fetch-list will display a list of
the files needed for a port.Q. Is there any way to stop the port from compiling? I want to
do some hacking on the source before I install it, but it is a bit
tiresome having to watch it and hit control-C every time.A. Doing make extract will stop it after it
has fetched and extracted the source code.Q. I am trying to make my own port and I want to be able to
stop it compiling until I have had a chance to see if my patches
worked properly. Is there something like make
extract, but for patches?A. Yep, make patch is what you want. You
will probably find the PATCH_DEBUG option useful
as well. And by the way, thank you for your efforts!Q. I have heard that some compiler options can cause bugs. Is
this true? How can I make sure that I compile ports with the right
settings?A. Yes, with version 2.6.3 of gcc (the
version shipped with FreeBSD 2.1.0 and 2.1.5), the
option could result in buggy code unless you
used the option as well.
(Most of the ports don't use ). You
should be able to specify the compiler options
used by something like&prompt.root; make CFLAGS='-O2 -fno-strength-reduce' installor by editing /etc/make.conf, but
unfortunately not all ports respect this. The surest way is to do
make configure, then go into the source directory
and inspect the Makefiles by hand, but this can get tedious if the
source has lots of sub-directories, each with their own
Makefiles.Q. There are so many ports it is hard to find the one I want.
Is there a list anywhere of what ports are available?A. Look in the INDEX file in
/usr/ports. If you would like to search the
ports collection for a keyword, you can do that too. For example,
you can find ports relevant to the LISP programming language
using:&prompt.user; cd /usr/ports
&prompt.user; make search key=lispQ. I went to install the foo port but the
system suddenly stopped compiling it and starting compiling the
bar port. What's going on?A. The foo port needs something that is
supplied with bar — for instance, if
foo uses graphics, bar might
have a library with useful graphics processing routines. Or
bar might be a tool that is needed to compile the
foo port. Q. I installed the
grizzle program from the ports and frankly it is
a complete waste of disk space. I want to delete it but I do not
know where it put all the files. Any clues?A. No problem, just do&prompt.root; pkg_delete grizzle-6.5
Q. Hang on a minute, you have to know the version number to use
that command. You do not seriously expect me to remember that, do
you??A. Not at all, you can find it out by doing&prompt.root; pkg_info -a | grep grizzle
Information for grizzle-6.5:
grizzle-6.5 - the combined piano tutorial, LOGO interpreter and shoot 'em up arcade game.Q. Talking of disk space, the ports directory seems to be
taking up an awful lot of room. Is it safe to go in there and
delete things?A. Yes, if you have installed the program and are fairly
certain you will not need the source again, there is no point in
keeping it hanging around. The best way to do this is&prompt.root; cd /usr/ports
&prompt.root; make cleanwhich will go through all the ports subdirectories and delete
everything except the skeletons for each port.Q. I tried that and it still left all those tarballs or
whatever you called them in the distfiles
directory. Can I delete those as well?A. Yes, if you are sure you have finished with them, those can
go as well.Q. I like having lots and lots of programs to play with. Is
there any way of installing all the ports in one go?A. Just do&prompt.root; cd /usr/ports
&prompt.root; make installQ. OK, I tried that, but I thought it would take a very long
time so I went to bed and left it to get on with it. When I looked
at the computer this morning, it had only done three and a half
ports. Did something go wrong?A. No, the problem is that some of the ports need to ask you
questions that we cannot answer for you (eg “Do you want to
print on A4 or US letter sized paper?”) and they need to have
someone on hand to answer them.Q. I really do not want to spend all day staring at the
monitor. Any better ideas?A. OK, do this before you go to bed/work/the local
park:-&prompt.root cd /usr/ports
&prompt.root; make -DBATCH installThis will install every port that does not
require user input. Then, when you come back, do&prompt.root; cd /usr/ports
&prompt.root; make -DIS_INTERACTIVE installto finish the job.Q. At work, we are using frobble, which is
in your ports collection, but we have altered it quite a bit to get
it to do what we need. Is there any way of making our own packages,
so we can distribute it more easily around our sites?A. No problem, assuming you know how to make patches for your
changes:-&prompt.root; cd /usr/ports/somewhere/frobble
&prompt.root; make extract
&prompt.root; cd work/frobble-2.8
[Apply your patches]
&prompt.root; cd ../..
&prompt.root; make packageQ. This ports stuff is really clever. I am desperate to find
out how you did it. What is the secret?A. Nothing secret about it at all, just look at the
bsd.ports.mk and
bsd.ports.subdir.mk files in your makefiles
directory.Readers with an aversion to intricate shell-scripts are
advised not to follow this link...)Making a port yourselfContributed by &a.jkh;, &a.gpalmer;, &a.asami; &a.obrien;
and &a.hoek;. 28 August 1996.So, now you are interested in making your own port? Great!What follows are some guidelines for creating a new port for
FreeBSD. The bulk of the work is done by
/usr/ports/Mk/bsd.port.mk, which all port Makefiles
include. Please refer to that file for more details on the inner
workings of the ports collection. Even if you don't hack Makefiles
daily, it is well commented, and you will still gain much knowledge from
it.Only a fraction of the overridable variables
(VAR) are mentioned in
this document. Most (if not all) are documented at the start of
bsd.port.mk. This file users a non-standard tab
setting. Emacs and
Vim should recognise the setting on loading
the file. vi or ex can be set
to use the correct value by typing :set tabstop=4
once the file has been loaded.Quick PortingThis section tells you how to do a quick port. In many cases, it
is not enough, but we will see.First, get the original tarball and put it into
DISTDIR, which defaults to
/usr/ports/distfiles.The following assumes that the software compiled out-of-the-box,
i.e., there was absolutely no change required for the port to work
on your FreeBSD box. If you needed to change something, you will
have to refer to the next section too.Writing the MakefileThe minimal Makefile would look something
like this:
# New ports collection makefile for: oneko
# Version required: 1.1b
# Date created: 5 December 1994
# Whom: asami
#
# $Id$
#
DISTNAME= oneko-1.1b
CATEGORIES= games
MASTER_SITES= ftp://ftp.cs.columbia.edu/archives/X11R5/contrib/
MAINTAINER= asami@FreeBSD.ORG
MAN1= oneko.1
MANCOMPRESSED= yes
USE_IMAKE= yes
.include <bsd.port.mk>See if you can figure it out. Do not worry about the contents
of the $Id$ line, it will be filled in
automatically by CVS when the port is imported to our main ports
tree. You can find a more detailed example in the sample Makefile section.Writing the description filesThere are three description files that are required for any
port, whether they actually package or not. They are
COMMENT, DESCR, and
PLIST, and reside in the
pkg subdirectory.COMMENTThis is the one-line description of the port.
Please do not include the package name (or
version number of the software) in the comment. Here is an
example:
A cat chasing a mouse all over the screen.DESCRThis is a longer description of the port. One to a few
paragraphs concisely explaining what the port does is
sufficient.This is not a manual or an in-depth
description on how to use or compile the port! Please
be careful if you are copying from the
README or manpage; too often
they are not a concise description of the port or are in an
awkward format (e.g., manpages have justified spacing). If the
ported software has an official WWW homepage, you should list it
here. Prefix one of the websites with
WWW: so that automated tools will work
correctly.It is recommended that you sign your name at the end of this
file, as in:
This is a port of oneko, in which a cat chases a poor mouse all over
the screen.
:
(etc.)
WWW: http://www.oneko.org/
- Satoshi
asami@cs.berkeley.eduPLISTThis file lists all the files installed by the port. It is
also called the “packing list” because the package is
generated by packing the files listed here. The pathnames are
relative to the installation prefix (usually
/usr/local or
/usr/X11R6). If you are using the
MANn variables (as
you should be), do not list any manpages here.Here is a small example:
bin/oneko
lib/X11/app-defaults/Oneko
lib/X11/oneko/cat1.xpm
lib/X11/oneko/cat2.xpm
lib/X11/oneko/mouse.xpm
@dirrm lib/X11/onekoRefer to the &man.pkg.create.1; man page for details on the
packing list.You should list all the files, but not the name directories,
in the list. Also, if the port creates directories for itself
during installtion, make sure to add @dirrm
lines as necessary to remove them when the port is
deleted.It is recommended that you keep all the filenames in this
file sorted alphabetically. It will make verifying the changes
when you upgrade the port much easier.Creating the checksum fileJust type make makesum. The ports make rules
will automatically generate the file
files/md5.Testing the portYou should make sure that the port rules do exactly what you
want it to do, including packaging up the port. These are the
important points you need to verify.PLIST does not contain anything not
installed by your portPLIST contains everything that is
installed by your portYour port can be installed multiple times using the
reinstall targetYour port cleans up
after itself upon deinstallRecommended test orderingmake installmake packagemake deinstallpkg_add `make package-name`make deinstallmake reinstallmake packageMake sure that there aren't any warnings issued in any of the
package and
deinstall stages, After step 3, check to
see if all the new directories are correctly deleted. Also, try
using the software after step 4, to ensure that is works correctly
when installed from a package.Checking your port with portlintPlease use portlint to see if your port
conforms to our guidelines. The portlint program
is part of the ports collection. In particular, your may want to
check if the Makefile is in
the right shape and the package is named
appropriately.Submitting the portFirst, make sure you have read the Do's and Dont's section.Now that you are happy with your port, the only thing remaining
is to put it in the main FreeBSD ports tree and make everybody else
happy about it too. We do not need your work
directory or the pkgname.tgz package, so delete
them now. Next, simply include the output of shar `find
port_dir` in a bug report and send it with the
&man.send-pr.1; program (see Bug
Reports and General Commentary for more information about
&man.send-pr.1;. If the uncompressed port is larger than 20KB,
you should compress it into a tarfile and use &man.uuencode.1;
before including it in the bug report (uuencoded tarfiles are
acceptable even if the bug report is smaller than 20KB but are not
preferred). Be sure to classify the bug report as category
ports and class
change-request. (Do not mark the report
confidential!)One more time, do not include the original source
distfile, the work directory, or the package
you built with make package.In the past, we asked you to upload new port submissions in
our ftp site (ftp.freebsd.org). This
is no longer recommended as read access is turned off on that
incoming/ directory of that site due to the
large amount of pirated software showing up there.We will look at your port, get back to you if necessary, and put
it in the tree. Your name will also appear in the list of
“Additional FreeBSD contributors” on the FreeBSD
Handbook and other files. Isn't that great?!? :)Slow PortingOk, so it was not that simple, and the port required some
modifications to get it to work. In this section, we will explain,
step by step, how to modify it to get it to work with the ports
paradigm.How things workFirst, this is the sequence of events which occurs when the user
first types make in your port's directory, and
you may find that having bsd.port.mk in another
window while you read this really helps to understand it.But do not worry if you do not really understand what
bsd.port.mk is doing, not many people do...
:>The fetch target is run. The
fetch target is responsible for making
sure that the tarball exists locally in
DISTDIR. If fetch
cannot find the required files in DISTDIR it
will look up the URL MASTER_SITES, which is
set in the Makefile, as well as our main ftp site at ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/,
where we put sanctioned distfiles as backup. It will then
attempt to fetch the named distribution file with
FETCH, assuming that the requesting site has
direct access to the Internet. If that succeeds, it will save
the file in DISTDIR for future use and
proceed.The extract target is run. It
looks for your port's distribution file (typically a gzip'd
tarball) in DISTDIR and unpacks it into a
temporary subdirectory specified by WRKDIR
(defaults to work).The patch target is run. First,
any patches defined in PATCHFILES are
applied. Second, if any patches are found in
PATCHDIR (defaults to the
patches subdirectory), they are applied at
this time in alphabetical order.The configure target is run. This
can do any one of many different things.If it exists, scripts/configure is
run.If HAS_CONFIGURE or
GNU_CONFIGURE is set,
WRKSRC/configure is
run.If USE_IMAKE is set,
XMKMF (default: xmkmf
-a) is run.The build target is run. This is
responsible for descending into the port's private working
directory (WRKSRC) and building it. If
USE_GMAKE is set, GNU make
will be used, otherwise the system make will
be used.The above are the default actions. In addition, you can define
targets
pre-something or
post-something,
or put scripts with those names, in the scripts
subdirectory, and they will be run before or after the default
actions are done.For example, if you have a post-extract
target defined in your Makefile, and a file
pre-build in the scripts
subdirectory, the post-extract target will
be called after the regular extraction actions, and the
pre-build script will be executed before the
default build rules are done. It is recommended that you use
Makefile targets if the actions are simple
enough, because it will be easier for someone to figure out what
kind of non-default action the port requires.The default actions are done by the
bsd.port.mk targets
do-something.
For example, the commands to extract a port are in the target
do-extract. If you are not happy with the
default target, you can fix it by redefining the
do-something
target in your Makefile.The “main” targets (e.g.,
extract,
configure, etc.) do nothing more than
make sure all the stages up to that one are completed and call
the real targets or scripts, and they are not intended to be
changed. If you want to fix the extraction, fix
do-extract, but never ever touch
extract!Now that you understand what goes on when the user types
make, let us go through the recommended steps to
create the perfect port.Getting the original sourcesGet the original sources (normally) as a compressed tarball
(foo.tar.gz or
foo.tar.Z) and copy
it into DISTDIR. Always use
mainstream sources when and where you
can.If you cannot find a ftp/http site that is well-connected to the
net, or can only find sites that have irritatingly non-standard
formats, you might want to put a copy on a reliable ftp or http
server that you control (e.g., your home page). Make sure you set
MASTER_SITES to reflect your choice.If you cannot find somewhere convenient and reliable to put the
distfile (if you are a FreeBSD committer, you can just put it in
your public_html/ directory on
freefall), we can “house” it ourselves
by putting it on
ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/LOCAL_PORTS/
as the last resort. Please refer to this location as
MASTER_SITE_LOCAL. Send mail to the &a.ports;if
you are not sure what to do.If your port's distfile changes all the time for no good reason,
consider putting the distfile in your home page and listing it as
the first MASTER_SITES. This will prevent users
from getting checksum mismatch errors, and
also reduce the workload of maintainers of our ftp site. Also, if
there isonly one master site for the port, it is recommended that
you house a backup at your site and list it as the second
MASTER_SITES.If your port requires some additional `patches' that are
available on the Internet, fetch them too and put them in
DISTDIR. Do not worry if they come from a site
other than where you got the main source tarball, we have a way to
handle these situations (see the description of PATCHFILES below).Modifying the portUnpack a copy of the tarball in a private directory and make
whatever changes are necessary to get the port to compile properly
under the current version of FreeBSD. Keep careful
track of everything you do, as you will be automating
the process shortly. Everything, including the deletion, addition
or modification of files should be doable using an automated script
or patch file when your port is finished.If your port requires significant user interaction/customization
to compile or install, you should take a look at one of Larry Wall's
classic Configure scripts and perhaps do
something similar yourself. The goal of the new ports collection is
to make each port as “plug-and-play” as possible for the
end-user while using a minimum of disk space.Unless explicitly stated, patch files, scripts, and other
files you have created and contributed to the FreeBSD ports
collection are assumed to be covered by the standard BSD copyright
conditions.PatchingIn the preparation of the port, files that have been added or
changed can be picked up with a recursive diff for later feeding to
patch. Each set of patches you wish to apply should be collected
into a file named
patch-xx where
xx denotes the sequence in which the
patches will be applied — these are done in
alphabetical order, thus aa
first, ab second and so on. These files should
be stored in PATCHDIR, from where they will be
automatically applied. All patches should be relative to
WRKSRC (generally the directory your port's
tarball unpacks itself into, that being where the build is done).
To make fixes and upgrades easier, you should avoid having more than
one patch fix the same file (e.g., patch-aa and
patch-ab both changing
WRKSRC/foobar.c).ConfiguringInclude any additional customization commands to your
configure script and save it in the
scripts subdirectory. As mentioned above, you
can also do this as Makefile targets and/or
scripts with the name pre-configure or
post-configure.Handling user inputIf your port requires user input to build, configure or install,
then set IS_INTERACTIVE in your Makefile. This
will allow “overnight builds” to skip your port if the
user sets the variable BATCH in his environment (and
if the user sets the variable INTERACTIVE, then
only those ports requiring interaction are
built).It is also recommended that if there are reasonable default
answers to the questions, you check the
PACKAGE_BUILDING variable and turn off the
interactive script when it is set. This will allow us to build the
packages for CD-ROMs and ftp.Configuring the MakefileConfiguring the Makefile is pretty simple, and again we suggest
that you look at existing examples before starting. Also, there is a
sample Makefile in this
handbook, so take a look and please follow the ordering of variables
and sections in that template to make your port easier for others to
read.Now, consider the following problems in sequence as you design
your new Makefile:The original sourceDoes it live in DISTDIR as a standard gzip'd
tarball? If so, you can go on to the next step. If not, you should
look at overriding any of the EXTRACT_CMD,
EXTRACT_BEFORE_ARGS,
EXTRACT_AFTER_ARGS,
EXTRACT_SUFX, or DISTFILES
variables, depending on how alien a format your port's distribution
file is. (The most common case is
EXTRACT_SUFX=.tar.Z, when the tarball is
condensed by regular compress, not gzip.)In the worst case, you can simply create your own
do-extract target to override the default,
though this should be rarely, if ever, necessary.DISTNAMEYou should set DISTNAME to be the base name
of your port. The default rules expect the distribution file list
(DISTFILES) to be named
DISTNAMEEXTRACT_SUFX which, if
it is a normal tarball, is going to be something like
foozolix-1.0.tar.gz for a setting of
DISTNAME=foozolix-1.0.The default rules also expect the tarball(s) to extract into a
subdirectory called
work/DISTNAME, e.g.
work/foozolix-1.0/.All this behavior can be overridden, of course; it simply
represents the most common time-saving defaults. For a port
requiring multiple distribution files, simply set
DISTFILES explicitly. If only a subset of
DISTFILES are actual extractable archives, then
set them up in EXTRACT_ONLY, which will override
the DISTFILES list when it comes to extraction,
and the rest will be just left in DISTDIR for
later use.PKGNAMEIf DISTNAME does not conform to our guidelines for a good package
name, you should set the PKGNAME
variable to something better. See the abovementioned guidelines for
more details.CATEGORIESWhen a package is created, it is put under
/usr/ports/packages/All and links are made from
one or more subdirectories of
/usr/ports/packages. The names of these
subdirectories are specified by the variable
CATEGORIES. It is intended to make life easier
for the user when he is wading through the pile of packages on the
ftp site or the CD-ROM. Please take a look at the existing categories and pick the ones
that are suitable for your port.This list also determines where in the ports tree the port is
imported. If you put more than one category here, it is assumed
that the port files will be put in the subdirectory with the name in
the first category. See the categories section for more
discussion about how to pick the right categories.If you port truly belongs to something that is different from
all the existing ones, you can even create a new category name. In
that case, please send mail to the &a.ports; to propose a new
category.There is no error checking for category names. make
package will happily create a new directory if you
mustype the category name, so be careful!MASTER_SITESRecord the directory part of the ftp/http-URL pointing at the
original tarball in MASTER_SITES. Do not forget
the trailing slash (/)!The make macros will try to use this
specification for grabbing the distribution file with
FETCH if they cannot find it already on the
system.It is recommended that you put multiple sites on this list,
preferably from different continents. This will safeguard against
wide-area network problems, and we are even planning to add support
for automatically determining the closest master site and fetching
from there!If the original tarball is part of one of the following popular
archives: X-contrib, GNU, Perl CPAN, TeX CTAN, or Linux Sunsite, you
refer to those sites in an easy compact form using
MASTER_SITE_XCONTRIB,
MASTER_SITE_GNU,
MASTER_SITE_PERL_CPAN,
MASTER_SITE_TEX_CTAN, and
MASTER_SITE_SUNSITE. Simply set
MASTER_SITE_SUBDIR to the path with in the
archive. Here is an example:
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applicationsThe user can also set the MASTER_SITE_*
variables in /etc/make.conf to override our
choices, and use their favorite mirrors of these popular archives
instead.PATCHFILESIf your port requires some additional patches that are available
by ftp or http, set PATCHFILES to the names of
the files and PATCH_SITES to the URL of the
directory that contains them (the format is the same as
MASTER_SITES).If the patch is not relative to the top of the source tree
(i.e., WKRSRC) because it contains some extra
pathnames, set PATCH_DIST_STRIP accordingly. For
instance, if all the pathnames in the patch have an extra
foozolix-1.0/ in front of the filenames, then set
PATCH_DIST_STRIP=-p1.Do not worry if the patches are compressed, they will be
decompressed automatically if the filenames end with
.gz or .Z.If the patch is distributed with some other files, such as
documentation, in a gzip'd tarball, you can't just use
PATCHFILES. If that is the case, add the name
and the location of the patch tarball to
DISTFILES and MASTER_SITES.
Then, from the pre-patch target, apply the
patch either by running the patch command from there, or copying the
patch file into the PATCHDIR directory and
calling it
patch-xx.Note the tarball will have been extracted alongside the
regular source by then, so there is no need to explicitly extract
it if it is a regular gzip'd or compress'd tarball. If you do the
latter, take extra care not to overwrite something that already
exists in that directory. Also do not forget to add a command to
remove the copied patch in the pre-clean
target.MAINTAINERSet your mail-address here. Please. :)For detailed description of the responsibility of maintainers,
refer to MAINTAINER on
Makefiles section.DependenciesMany ports depend on other ports. There are five variables that
you can use to ensure that all the required bits will be on the
user's machine. There are also some pre-supported dependency
variables for common cases, plus a few more to control the behaviour
of dependencies.LIB_DEPENDSThis variable specifies the shared libraries this port depends
on. It is a list of
lib:dir:target
tuples where lib is the name of the
shared library, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. For example, LIB_DEPENDS=
jpeg\\.9\\.:${PORTSDIR}/graphics/jpeg:install
will check for a shared jpeg library with major version 9, and
descend into the graphics/jpeg subdirectory
of your ports tree to build and install it if it is not found.
The target part can be omitted if it is
equal to DEPENDS_TARGET (which defaults to
install).The lib part is an argument given
to ldconfig -r | grep -wF. There shall be no
reqular expressions in this variable.The dependency is checked twice, once from within the
extract target and then from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system.RUN_DEPENDSThis variable specifies executables or files this port depends
on during run-time. It is a list of
path:dir:target
tuples where path is the name of the
executable or file, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. If path starts with a slash
(/), it is treated as a file and its existence
is tested with test -e; otherwise, it is
assumed to be an executable, and which -s is
used to determine if the program exists in the user's search
path.For example,
RUN_DEPENDS= ${PREFIX}/etc/innd:${PORTSDIR}/news/inn \
wish8.0:${PORTSDIR}/x11-toolkits/tk80will check if the file or directory
/usr/local/etc/innd exists, and build and
install it from the news/inn subdirectory of
the ports tree if it is not found. It will also see if an
executable called wish8.0 is in your search
path, and descend into the x11-toolkits/tk80
subdirectory of your ports tree to build and install it if it is
not found.In this case, innd is actually an
executable; if an executable is in a place that is not expected
to be in a normal user's search path, you should use the full
pathname.The dependency is checked from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system. The target
part can be omitted if it is the same
DEPENDS_TARGET.BUILD_DEPENDSThis variable specifies executables or files this port
requires to build. Like RUN_DEPENDS, it is a
list of
path:dir:target
tuples. For example, BUILD_DEPENDS=
unzip:${PORTSDIR}/archivers/unzip will check
for an executable called unzip, and descend
into the archivers/unzip subdirectory of your
ports tree to build and install it if it is not found.“build” here means everything from extracting to
compilation. The dependency is checked from within the
extract target. The
target part can be omitted if it is
the same as DEPENDS_TARGETFETCH_DEPENDSThis variable specifies executables or files this port
requires to fetch. Like the previous two, it is a list of
path:dir:target
tuples. For example, FETCH_DEPENDS=
ncftp2:${PORTSDIR}/net/ncftp2 will check for an
executable called ncftp2, and descend into the
net/ncftp2 subdirectory of your ports tree to
build and install it if it is not found.The dependency is checked from within the
fetch target. The
target part can be omitted if it is the
same as DEPENDS_TARGET.DEPENDSIf there is a dependency that does not fall into either of the
above four categories, or your port requires to have the source of
the other port extracted in addition to having them installed,
then use this variable. This is a list of
dir:target,
as there is nothing to check, unlike the previous four. The
target part can be omitted if it is the
same as DEPENDS_TARGET.Common dependency variablesDefine USE_XLIB=yes if your port requires
the X Window System to be installed (it is implied by
USE_IMAKE). Define
USE_GMAKE=yes if your port requires GNU
make instead of BSD make.
Define USE_AUTOCONF=yes if your port requires
GNU autoconf to be run. Define USE_QT=yes if
your port uses the latest qt toolkit. Use
USE_PERL5=yes if your port requires version 5
of the perl language. (The last is especially important since
some versions of FreeBSD has perl5 as part of the base system
while others don't.)Notes on dependenciesAs mentioned above, the default target to call when a
dependency is required is DEPENDS_TARGET.
It defaults to install. This is a user
variable; is is never defined in a port's
Makefile. If your port needs a special way
to handle a dependency, use the :target part of
the *_DEPENDS variables instead of redefining
DEPENDS_TARGET.When you type make clean, its dependencies
are automatically cleaned too. If you do not wish this to happen,
define the variable NOCLEANDEPENDS in your
environment.To depend on another port unconditionally, it is customary to
use the string nonexistent as the first field
of BUILD_DEPENDS or
RUN_DEPENDS. Use this only when you need to
the to get to the source of the other port. You can often save
compilation time by specifying the target too. For
instance
BUILD_DEPENDS= /nonexistent:${PORTSDIR}/graphics/jpeg:extract
will always descend to the JPEG port and extract it.Do not use DEPENDS unless there is no other
way the behaviour you want can be accomplished. It will cause the
other port to be always build (and installed, by default), and the
dependency will go into the packages as well. If this is really
what you need, I recommend you write it as
BUILD_DEPENDS and
RUN_DEPENDS instead—at least the
intention will be clear.Building mechanismsIf your package uses GNU make, set
USE_GMAKE=yes. If your package uses
configure, set
HAS_CONFIGURE=yes. If your package uses GNU
configure, set
GNU_CONFIGURE=yes (this implies
HAS_CONFIGURE). If you want to give some extra
arguments to configure (the default argument list
--prefix=${PREFIX} for GNU
configure and empty for non-GNU
configure), set those extra arguments in
CONFIGURE_ARGS. If your package uses GNU
autoconf, set
USE_AUTOCONF=yes. This implies
GNU_CONFIGURE, and will cause
autoconf to be run before
configure.If your package is an X application that creates
Makefiles from Imakefiles
using imake, then set
USE_IMAKE=yes. This will cause the configure
stage to automatically do an xmkmf -a. If the
flag is a problem for your port, set
XMKMF=xmkmf. If the port uses
imake but does not understand the
install.man target,
NO_INSTALL_MANPAGES=yes should be set. In
addition, the author of the original port should be shot. :>If your port's source Makefile has
something else than all as the main build
target, set ALL_TARGET accordingly. Same goes
for install and
INSTALL_TARGET.Special considerationsThere are some more things you have to take into account when you
create a port. This section explains the most common of those.ldconfigIf your port installs a shared library, add a
post-install target to your
Makefile that runs ${LDCONFIG}
-m on the directory where the new library is installed
(usually PREFIX/lib) to
register it into the shared library cache.Also, add a matching @exec /sbin/ldconfig -m
and @unexec /sbin/ldconfig -R pair to your
pkg/PLIST file so that a user who installed the
- package can start using teh shared libraru immediately and
+ package can start using the shared library immediately and
deinstallation will not cause the system to still believe the
library is there. These lines should immediately follow the line
for the shared library itself, as in:
lib/libtvl80.so.1
@exec /sbin/ldconfig -m %D/lib
@unexec /sbin/ldconfig -RNever, ever, ever add a line that says
ldconfig without any arguments to your
Makefile or pkg/PLIST.
- This will reset the shared libraru cache to the contents of
+ This will reset the shared library cache to the contents of
/usr/lib only, and will royally screw up the
user's machine ("Help, xinit does not run anymore after I install
this port!"). Anybody who does this will be shot and cut in 65,536
pieces by a rusty knife and have is liver chopped out by a bunch of
crows and will eternally rot to death in the deepest bowels of hell
(not necessarily in that order…)ELF supportSince FreeBSD is moving to ELF shortly after 3.0-RELEASE, we need
to convert many ports that build shared libraries to support ELF.
Complicating this task is that a 3.0 system can run as both ELF and
a.out, and we wish to unofficially support the 2.2 as long as
possible. Below are the guidelines on how to convert a.out only ports
to support both a.out and ELF compilation.Some part of this list is only applicable during the conversion,
but will be left here for awhile for reference in case you have come
across some old port you wish to upgrade.Moving a.out libraries out of the wayA.out libraries should be moved out of
/usr/local/lib and similar to an
aout subdirectory. (If you don't move them out
of the way, ELF ports will happily overwrite a.out libraries.) The
move-aout-libs target in the 3.0-CURRENT
src/Makefile (called from
aout-to-elf) will do this for you. It will
only move a.out libs so it is safe to call it on a system with both
ELF and a.out libs in the standard directories.FormatThe ports tree will build packages in the format the machine is
in. This means a.out for 2.2 and a.out or ELF for 3.0 depending on
what `objformat` returns. Also, once users move
a.out libraries to a subdirectory, building a.out libraries will be
unsupported. (I.e., it may still work if you know what you are
doing, but you are on your own.)If a port only works for a.out, set
BROKEN_ELF to a string describing the reason
why. Such ports will be skipped during a build on an ELF
system.PORTOBJFORMATbsd.port.mk will set
PORTOBJFORMAT to aout or
elf and export it in the environments
CONFIGURE_ENV, SCRIPTS_ENV and
MAKE_ENV. (It's always going to be
aout in 2.2-STABLE). It is also passed to
PLIST_SUB as
PORTOBJFORMAT=${PORTOBJFORMAT}. (See comment on
ldconfig lines below.)The variable is set using this line in
bsd.port.mk:
PORTOBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aoutPorts' make processes should use this variable to decide what to
do. However, if the port's configure script
already automatically detects an ELF system, it is not necessary to
refer to PORTOBJFORMAT.Building shared librariesThe following are differences in handling shared libraries for
a.out and ELF.Shared library versionsAn ELF shared library should be called
libfoo.so.M
where M is the single version number,
and an a.out library should be called
libfoo.so.M.N
where M is the major version and
N is the the minor version number.
Do not mix those; never install an ELF
shared library called
libfoo.so.N.M
or an a.out shared library (or symlink) called
libfoo.so.N.Linker command linesAssuming cc -shared is used rather than
ld directly, the only difference is that you
need to add
on the command line for ELF.You need to install a symlink from
libfoo.so to
libfoo.so.N to make
ELF linkers happy. Since it should be listed in
PLIST too, and it won't hurt in the a.out case
(some ports even require the link for dynamic loading), you should
just make this link regardless of the setting of
PORTOBJFORMAT.LIB_DEPENDSAll port Makefiles are edited to remove minor numbers from
LIB_DEPENDS, and also to have the regexp support
removed. (E.g., foo\\.1\\.\\(33|40\\) becomes
foo.2.) They will be matched using grep
-wF.PLISTPLIST should contain the short (ELF) shlib
names if the a.out minor number is zero, and the long (a.out) names
otherwise. bsd.port.mk will automatically add
.0 to the end of short shlib lines if
PORTOBJFORMAT equals aout, and
will delete the minor number from long shlib names if
PORTOBJFORMAT equals
elf.In cases where you really need to install shlibs with two
versions on an ELF system or those with one version on an a.out
system (for instance, ports that install compatibility libraries for
other operating systems), define the variable
NO_FILTER_SHLIBS. This will turn off the editing
of PLIST mentioned in the previous
paragraph.ldconfigThe ldconfig line in Makefiles should
read:
${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m ....In PLIST it should read;
@exec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -m ...
@unexec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -RThis is to ensure that the correct ldconfig
will be called depending on the format of the package, not the
default format of the system.MASTERDIRIf your port needs to build slightly different versions of
packages by having a variable (for instance, resolution, or paper
size) take different values, create one subdirectory per package to
make it easier forusers to see what to do, but try to share as many
files as possible between ports. Typically you only need a very short
Makefile in all but one of the directories if you
use variables cleverly. In the sole Makefiles,
you can use MASTERDIR to specify the directory
where the rest of the files are. Also, use a variable as part of
PKGNAME so
the packages will have different names.This will be best demonstrated by an example. This is part of
japanese/xdvi300/Makefile;
PKGNAME= ja-xdvi${RESOLUTION}-17
:
# default
RESOLUTION?= 300
.if ${RESOLUTION} != 118 && ${RESOLUTION} != 240 && \
${RESOLUTION} != 300 && ${RESOLUTION} != 400
@${ECHO} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
@${ECHO} "Possible values are: 118, 240, 300 (default) and 400."
@${FALSE}
.endifjapanese/xdvi300 also has all the regular
patches, package files, etc. If you type make
there, it will take the default value for the resolution (300) and
build the port normally.As for other resolutions, this is the entirexdvi118/Makefile;
RESOLUTION= 118
MASTERDIR= ${.CURDIR}/../xdvi300
.include ${MASTERDIR}/Makefile(xdvi240/Makefile and
xdvi400/Makefile are similar). The
MASTERDIR definition tells
bsd.port.mk that the refulat set of
subdirectories like PATCHDIR and
PKGDIR are to be found under
xdvi300. The RESOLUTION=118
line will override the RESOLUTION=300 line in
xdvi300/Makefile and the port will be built with
resolution set to 118.Shared library versionsFirst, please read our policy on
shared library versioning to understand what to do with
shared library versions in general. Do not blindly assume software
authors know what they are doing; many of them do not. It is very
important that these details are carefully considered, as we have
quite a unique situation where we are trying to have dozens of
potentially incompatible software pairs co-exist. Careless port
imports have caused great trouble regarding shared libraries in the
past (ever wondered why the port jpeg-6b has a
shared library version of 9.0?). If in doubt, send a message to the
&a.ports;. Most of the time, your job ends by determining the right
shared library version and making appropriate patches to implement
it.However, if there is a port which is a different version of the
same software already in the tree, the situation is much more complex.
In short, the FreeBSD implementation does not allow the user to
specify to the linker which version of shared library to link against
(the linker will always pick the highest numbered version). This
means, if there is a libfoo.so.3.2 and
libfoo.so.4.0 in the system, there is no way to
tell the linker to link a particular application to
libfoo.so.3.2. It is essentially completely
overshadowed in terms of compilation-time linkage. In this case, the
only solution is to rename the base part of the
shared library. For instance, change
libfoo.so.4.0 to
libfoo4.so.1.0 so both version 3.2 and 4.0 can be
linked from other ports.ManpagesThe MAN[1-9LN] variables will automatically add
any manpages to pkg/PLIST (this means you must
not list manpages in the
PLIST—see generating PLIST for more). It also
makes the install stage automatically compress or uncompress manpages
depending on the setting of NOMANCOMPRESS in
/etc/make.conf.To specify whether the manpages are compressed upon installation,
use the MANCOMPRESSED variable. This variable can
take three values, yes, no and
maybe. yes means manpages are
already installed compressed, no means they are
not, and maybe means the software already respects
the value of NOMANCOMPRESS so
bsd.port.mk does not have to do anything
special.MANCOMPRESSED is automatically set to
yes if USE_IMAKE is set and
NO_INSTALL_MANPAGES is not set, and to
no otherwise. You don't have to explicitly define
it unless the default is not suitable for your port.If your port anchors its man tree somewhere other than
PREFIX, you can use the
MANPREFIX to set it. Also, if only manpages in
certain sections go in a non-standard place, such as some Perl modules
ports, you can set individual man paths using
MANsectPREFIX (where
sect is one of 1-9,
L or N).If your manpages go to language-specific subdirectories, set the
name of the languages to MANLANG. The value of
this variable defaults to "" (i.e., English
only).Here is an example that puts it all together.
MAN1= foo.1
MAN3= bar.3
MAN4= baz.4
MANLANG= "" ja
MAN3PREFIX= ${PREFIX}/share/foobar
MANCOMPRESSED= yesThis states that six files are installed by this port;
${PREFIX}/man/man1/foo.1.gz
${PREFIX}/man/ja/man1/foo.1.gz
${PREFIX}/share/foobar/man/man3/bar.3.gz
${PREFIX}/share/foobar/man/ja/man3/bar.3.gz
${PREFIX}/man/man4/baz.4.gz
${PREFIX}/man/ja/man4/baz.4.gzPorts that require MotifThere are many programs that require a Motif library (available
from several commercial vendors, while there is a free clone reported
to be able to run many applications in
x11-toolkits/lesstif) to compile. Since it is a
popular toolkit and their licenses usually permit redistribution of
statically linked binaries, we have made special provisions for
handling ports that require Motif in a way that we can easily compile
binaries linked either dynamically (for people who are compiling from
the port) or statically (for people who distribute packages).REQUIRES_MOTIFIf your port requires Motif, define this variable in the
Makefile. This will prevent people who don't own a copy of Motif
from even attempting to build it.MOTIFLIBThis variable will be set by bsd.port.mk to
be the appropriate reference to the Motif library. Please patch the
source to use this wherever the Motif library is referenced in the
Makefile or
Imakefile.There are two common cases:If the port refers to the Motif library as
-lXm in its Makefile or
Imakefile, simply substitute
${MOTIFLIB} for it.If the port uses XmClientLibs in its
Imakefile, change it to
${MOTIFLIB} ${XTOOLLIB}
${XLIB}.Note that MOTIFLIB (usually) expands to
-L/usr/X11R6/lib -lXm or
/usr/X11R6/lib/libXm.a, so there is no need to
add -L or -l in front.X11 fontsIf your port installs fonts for the X Window system, put them in
X11BASE/lib/X11/fonts/local.
This directory is new to XFree86 release 3.3.3. If it does not exist,
please create it, and print out a message urging the user to update
their XFree86 to 3.3.3 or newer, or at least add this directory to the
font path in /etc/XF86Config.Info filesThe new version of texinfo (included in 2.2.2-RELEASE and onwards)
contains a utility called install-info to add and
delete entries to the dir file. If your port
installs any info documents, please follow this instructions so your
port/package will correctly update the user's
PREFIX/info/dir file. (Sorry
for the length of this section, but is it imperative to weave all the
info files together. If done correctly, it will produce a
beautiful listing, so please bear with me!First, this is what you (as a porter) need to know&prompt.user; install-info --help
install-info [OPTION]... [INFO-FILE [DIR-FILE]]
Install INFO-FILE in the Info directory file DIR-FILE.
Options:
--delete Delete existing entries in INFO-FILE;
don't insert any new entries.
:
--entry=TEXT Insert TEXT as an Info directory entry.
:
--section=SEC Put this file's entries in section SEC of the directory. :This program will not actually install info
files; it merely inserts or deletes entries in the
dir file.Here's a seven-step procedure to convert ports to use
install-info. I will use
editors/emacs as an example.Look at the texinfo sources and make a patch to insert
@dircategory and @direntry
statements to files that don't have them. This is part of my
patch:
--- ./man/vip.texi.org Fri Jun 16 15:31:11 1995
+++ ./man/vip.texi Tue May 20 01:28:33 1997
@@ -2,6 +2,10 @@
@setfilename ../info/vip
@settitle VIP
+@dircategory The Emacs editor and associated tools
+@direntry
+* VIP: (vip). A VI-emulation for Emacs.
+@end direntry
@iftex
@finalout
:The format should be self-explanatory. Many authors leave a
dir file in the source tree that contains all
the entries you need, so look around before you try to write your
own. Also, make sure you look into related ports and make the
section names and entry indentations consistent (we recommend that
all entry text start at the 4th tab stop).Note that you can put only one info entry per file because
of a bug in install-info --delete that
deletes only the first entry if you specify multiple entries in
the @direntry section.You can give the dir entries to
install-info as arguments
( and ) instead
of patching the texinfo sources. I do not think this is a good
idea for ports because you need to duplicate the same information
in three places
(Makefile and
@exec/@unexec of
PLIST; see below). However, if you have a
Japanese (or other multibyte encoding) info files, you will have
to use the extra arguments to install-info
because makeinfo can't handle those texinfo
sources. (See Makefile and
PLIST of japanese/skk
for examples on how to do this).Go back to the port directory and do a make clean;
make and verify that the info files are regenerated
from the texinfo sources. Since the texinfo sources are newer than
the info files, they should be rebuilt when you type
make; but many Makefiles
don't include correct dependencies for info files. In
emacs' case, I had to patch the main
Makefile.in so it will descend into the
man subdirectory to rebuild the info
pages.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Tue Apr 15 00:15:28 1997
@@ -184,7 +184,7 @@
# Subdirectories to make recursively. `lisp' is not included
# because the compiled lisp files are part of the distribution
# and you cannot remake them without installing Emacs first.
-SUBDIR = lib-src src
+SUBDIR = lib-src src man
# The makefiles of the directories in $SUBDIR.
SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile
--- ./man/Makefile.in.org Thu Jun 27 15:27:19 1996
+++ ./man/Makefile.in Tue Apr 15 00:29:52 1997
@@ -66,6 +66,7 @@
${srcdir}/gnu1.texi \
${srcdir}/glossary.texi
+all: info
info: $(INFO_TARGETS)
dvi: $(DVI_TARGETS)The second hunk was necessary because the default target in
the man subdir is called
info, while the main
Makefile wants to call
all. I also deleted the installation of
the info info file because we already have
one with the same name in /usr/share/info
(that patch is not shown here).If there is a place in the Makefile that
is installing the dir file, delete it. Your
port may not be doing it. Also, remove any commands that are
otherwise mucking around with the dir
file.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Mon Apr 14 23:38:07 1997
@@ -368,14 +368,8 @@
if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
then \
(cd ${infodir}; \
- if [ -f dir ]; then \
- if [ ! -f dir.old ]; then mv -f dir dir.old; \
- else mv -f dir dir.bak; fi; \
- fi; \
cd ${srcdir}/info ; \
- (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
- (cd $${thisdir}; chmod a+r ${infodir}/dir); \
for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
(cd $${thisdir}; \
${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
chmod a+r ${infodir}/$$f); \(This step is only necessary if you are modifying an existing
port.) Take a look at pkg/PLIST and delete
anything that is trying to patch up info/dir.
They may be in pkg/INSTALL or some other
file, so search extensively.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/04/15 06:32:12
@@ -15,9 +15,6 @@
man/man1/emacs.1.gz
man/man1/etags.1.gz
man/man1/ctags.1.gz
-@unexec cp %D/info/dir %D/info/dir.bak
-info/dir
-@unexec cp %D/info/dir.bak %D/info/dir
info/cl
info/cl-1
info/cl-2Add a post-install target to the
Makefile to create a dir
file if it is not there. Also, call
install-info with the installed info
files.
Index: Makefile
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 1996/11/19 13:14:40 1.26
+++ Makefile 1997/05/20 10:25:09 1.28
@@ -20,5 +20,11 @@
post-install:
.for file in emacs-19.34 emacsclient etags ctags b2m
strip ${PREFIX}/bin/${file}
.endfor
+ if [ ! -f ${PREFIX}/info/dir ]; then \
+ ${SED} -ne '1,/Menu:/p' /usr/share/info/dir > ${PREFIX}/info/dir; \
+ fi
+.for info in emacs vip viper forms gnus mh-e cl sc dired-x ediff ccmode
+ install-info ${PREFIX}/info/${info} ${PREFIX}/info/dir
+.endfor
.include <bsd.port.mk>Do not use anything other than
/usr/share/info/dir and the above command to
create a new info file. In fact, I'd add the first three lines of
the above patch to bsd.port.mk if you (the
porter) wouldn't have to do it in PLIST by
yourself anyway.Edit PLIST and add equivalent
@exec statements and also
@unexec for pkg_delete. You
do not need to delete info/dir with
@unexec.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/05/20 10:25:12 1.17
@@ -16,7 +14,15 @@
man/man1/etags.1.gz
man/man1/ctags.1.gz
+@unexec install-info --delete %D/info/emacs %D/info/dir
:
+@unexec install-info --delete %D/info/ccmode %D/info/dir
info/cl
info/cl-1
@@ -87,6 +94,18 @@
info/viper-3
info/viper-4
+@exec [ -f %D/info/dir ] || sed -ne '1,/Menu:/p' /usr/share/info/dir > %D/info/dir
+@exec install-info %D/info/emacs %D/info/dir
:
+@exec install-info %D/info/ccmode %D/info/dir
libexec/emacs/19.34/i386--freebsd/cvtmail
libexec/emacs/19.34/i386--freebsd/digest-docThe @unexec install-info --delete
commands have to be listed before the info files themselves so
they can read the files. Also, the @exec
install-info commands have to be after the info
files and the @exec command that creates the
the dir file.Test and admire your
work. :). Check the
dir file before and after each step.The pkg/ subdirectoryThere are some tricks we haven't mentioned yet about the
pkg/ subdirectory that come in handy
sometimes.MESSAGEIf you need to display a message to the installer, you may place
the message in pkg/MESSAGE. This capability is
often useful to display additional installation steps to be taken
after a pkg_add or to display licensing
information.The pkg/MESSAGE file does not need to be
added to pkg/PLIST. Also, it will not get
automatically printed if the user is using the port, not the
package, so you should probably display it from the
post-install target yourself.INSTALLIf your port needs to execute commands when the binary package
is installed with pkg_add you can do this via the
pkg/INSTALL script. This script will
automatically be added to the package, and will be run twice by
pkg_add. The first time will as INSTALL
${PKGNAME} PRE-INSTALL and the second time as
INSTALL ${PKGNAME} POST-INSTALL.
$2 can be tested to determine which mode
the script is being run in. The PKG_PREFIX
environmental variable will be set to the package installation
directory. See &man.pkg.add.1; for
additional information.This script is not run automatically if you install the port
with make install. If you are depending on it
being run, you will have to explicitly call it from your port's
Makefile.REQIf your port needs to determine if it should install or not, you
can create a pkg/REQ “requirements”
script. It will be invoked automatically at
installation/deinstallation time to determine whether or not
installation/deinstallation should proceed.Changing PLIST based on make
variablesSome ports, particularly the p5- ports, need to change their
PLIST depending on what options they are
configured with (or version of perl, in the case of p5- ports). To
make this easy, any instances in the PLIST of
%%OSREL%%, %%PERL_VER%%, and
%%PERL_VERSION%% will be substituted for
appropriately. The value of %%OSREL%% is the
numeric revision of the operating system (e.g.,
2.2.7). %%PERL_VERSION%% is
the full version number of perl (e.g., 5.00502)
and %%PERL_VER%% is the perl version number minus
the patchlevel (e.g., 5.005).If you need to make other substitutions, you can set the
PLIST_SUB variable with a list of
VAR=VALUE
pairs and instances of
%%VAR%%' will be
substituted with VALUE in the
PLIST.For instance, if you have a port that installs many files in a
version-specific subdirectory, you can put something like
OCTAVE_VERSION= 2.0.13
PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION}
in the Makefile and use
%%OCTAVE_VERSION%% wherever the version shows up
in PLIST. That way, when you upgrade the port,
you will not have to change dozens (or in some cases, hundreds) of
lines in the PLIST.This substitution (as well as addition of any man pages) will be done between
the do-install and
post-install targets, by reading from
PLIST and writing to TMPPLIST
(default:
WRKDIR/.PLIST.mktmp). So if
your port builds PLIST on the fly, do so in or
before do-install. Also, if your port
needs to edit the resulting file, do so in
post-install to a file named
TMPPLIST.Changing the names of files in the
pkg subdirectoryAll the filenames in the pkg subdirectory
are defined using variables so you can change them in your
Makefile if need be. This is especially useful
when you are sharing the same pkg subdirectory
among several ports or have to write to one of the above files (see
writing to places other than
WRKDIR for why it is a bad idea to write
directly in to the pkg subdirectory.Here is a list of variable names and their default
values.VariableDefault valueCOMMENT${PKGDIR}/DESCRDESCR${PKGDIR}/DESCRPLIST${PKGDIR}/PLISTPKGINSTALL${PKGDIR}/PKGINSTALLPKGDEINSTALL${PKGDIR}/PKGDEINSTALLPKGREQ${PKGDIR}/REQPKGMESSAGE${PKGDIR}/MESSAGEPlease change these variables rather than overriding
PKG_ARGS. If you change
PKG_ARGS, those files will not correctly be
installed in /var/db/pkg upon install from a
port.Licensing ProblemsSome software packages have restrictive licenses or can be in
violation to the law (PKP's patent on public key crypto, ITAR (export
of crypto software) to name just two of them). What we can do with
them varies a lot, depending on the exact wordings of the respective
licenses.It is your responsibility as a porter to read the licensing
terms of the software and make sure that the FreeBSD project will
not be held accountable of violating them by redistributing the
source or compiled binaries either via ftp or CD-ROM. If in doubt,
please contact the &a.ports;.There are two variables you can set in the Makefile to handle the
situations that arise frequently:If the port has a “do not sell for profit” type of
license, set the variable NO_CDROM to a string
describing the reason why. We will make sure such ports won't go
into the CD-ROM come release time. The distfile and package will
still be available via ftp.If the resulting package needs to be built uniquely for each
site, or the resulting binary package can't be distributed due to
licensing; set the variable NO_PACKAGE to a
string describing the reason why. We will make sure such packages
won't go on the ftp site, nor into the CD-ROM come release time.
The distfile will still be included on both however.If the port has legal restrictions on who can use it (e.g.,
crypto stuff) or has a “no commercial use” license,
set the variable RESTRICTED to be the string
describing the reason why. For such ports, the distfiles/packages
will not be available even from our ftp sites.The GNU General Public License (GPL), both version 1 and 2,
should not be a problem for ports.If you are a committer, make sure you update the
ports/LEGAL file too.UpgradingWhen you notice that a port is out of date compared to the latest
version from the original authors, first make sure you have the latest
port. You can find them in the
ports/ports-current directory of the ftp mirror
sites.The next step is to send a mail to the maintainer, if one is
listed in the port's Makefile. That person may
already be working on an upgrade, or have a reason to not upgrade the
port right now (because of, for example, stability problems of the new
version).If the maintainer asks you to do the upgrade or there isn't any
such person to begin with, please make the upgrade and send the
recursive diff (either unified or context diff is fine, but port
committers appear to prefer unified diff more) of the new and old
ports directories to us (e.g., if your modified port directory is
called superedit and the original as in our tree
is superedit.bak, then send us the result of
diff -ruN superedit.bak superedit). Please examine
the output to make sure all the changes make sense. The best way to
send us the diff is by including it to &man.send-pr.1; (category
ports). Please mention any added or deleted files
in the message, as they have to be explicitly specified to CVS when
doing a commit. If the diff is more than about 20KB, please compress
and uuencode it; otherwise, just include it in as is in the PR.Once again, please use &man.diff.1; and not &man.shar.1; to send
updates to ports.Do's and Dont'sHere is a list of common do's and dont's that you encounter during
the porting process.You should check your own port against this list,
but you can also check ports in the PR database that others have
submitted. Submit any comments on ports you check as described in
Bug Reports and General
Commentary. Checking ports in the PR database will both make
it faster for us to commit them, and prove that you know what you are
doing.Strip BinariesDo strip binaries. If the original source already strips the
binaries, fine; otherwise you should add a
post-install rule to to it yourself. Here is an
example;
post-install:
strip ${PREFIX}/bin/xdlUse the &man.file.1; command on the installed executable to
check whether the binary is stripped or not. If it does not say
not stripped, it is stripped.INSTALL_* macrosDo use the macros provided in bsd.port.mk
to ensure correct modes and ownership of files in your own
*-install targets. They are:INSTALL_PROGRAM is a command to install
binary executables.INSTALL_SCRIPT is a command to install
executable scripts.INSTALL_DATA is a command to install
sharable data.INSTALL_MAN is a command to install
manpages and other documentation (it doesn't compress
anything).These are basically the install command with
all the appropriate flags. See below for an example on how to use
them.WRKDIRDo not write anything to files outside
WRKDIR. WRKDIR is the only
place that is guaranteed to be writable during the port build (see
compiling ports from CDROM for an
example of building ports from a read-only tree). If you need to
modigy some file in PKGDIR, do so by redefining a variable, not by
writing over it.WRKDIRPREFIXMake sure your port honors WRKDIRPREFIX.
Most ports don't have to worry about this. In particular, if you
are referring to a WRKDIR of another port, note
that the correct location is
WRKDIRPREFIXPORTSDIR/subdir/name/work not PORTSDIR/subdir/name/work or .CURDIR/../../subdir/name/work or some such.Also, if you are defining WRKDIR yourself,
make sure you prepend
${WKRDIRPREFIX}${.CURDIR} in the
front.Differentiating operating systems and OS versionsYou may come across code that needs modifications or conditional
compilation based upon what version of UNIX it is running under. If
you need to make such changes to the code for conditional
compilation, make sure you make the changes as general as possible
so that we can back-port code to FreeBSD 1.x systems and cross-port
to other BSD systems such as 4.4BSD from CSRG, BSD/386, 386BSD,
NetBSD, and OpenBSD.The preferred way to tell 4.3BSD/Reno (1990) and newer versions
of the BSD code apart is by using the BSD macro
defined in <sys/param.h>. Hopefully that
file is already included; if not, add the code:
#if (defined(__unix__) || defined(unix)) && !defined(USG)
#include <sys/param.h>
#endifto the proper place in the .c file. We
believe that every system that defines these two symbols has
sys/param.h. If you find a system that
doesn't, we would like to know. Please send mail to the
&a.ports;.Another way is to use the GNU Autoconf style of doing
this:
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h>
#endifDon't forget to add -DHAVE_SYS_PARAM_H to the
CFLAGS in the Makefile for
this method.Once you have sys/param.h included, you may
use:
#if (defined(BSD) && (BSD >= 199103))to detect if the code is being compiled on a 4.3 Net2 code base
or newer (e.g. FreeBSD 1.x, 4.3/Reno, NetBSD 0.9, 386BSD, BSD/386
1.1 and below).Use:
#if (defined(BSD) && (BSD >= 199306))to detect if the code is being compiled on a 4.4 code base or
newer (e.g. FreeBSD 2.x, 4.4, NetBSD 1.0, BSD/386 2.0 or
above).The value of the BSD macro is
199506 for the 4.4BSD-Lite2 code base. This is
stated for informational purposes only. It should not be used to
distinguish between versions of FreeBSD based only on 4.4-Lite vs.
versions that have merged in changes from 4.4-Lite2. The
__FreeBSD__ macro should be used instead.Use sparingly:__FreeBSD__ is defined in all versions of
FreeBSD. Use it if the change you are making
only affects FreeBSD. Porting gotchas like
the use of sys_errlist[] vs
strerror() are Berkeleyisms, not FreeBSD
changes.In FreeBSD 2.x, __FreeBSD__ is defined to
be 2. In earlier versions, it is
1. Later versions will bump it to match
their major version number.If you need to tell the difference between a FreeBSD 1.x
system and a FreeBSD 2.x or 3.x system, usually the right answer
is to use the BSD macros described above. If
there actually is a FreeBSD specific change (such as special
shared library options when using ld) then it
is OK to use __FreeBSD__ and #if
__FreeBSD__ > 1 to detect a FreeBSD 2.x and later
system. If you need more granularity in detecting FreeBSD
systems since 2.0-RELEASE you can use the following:
#if __FreeBSD__ >= 2
#include <osreldate.h>
# if __FreeBSD_version >= 199504
/* 2.0.5+ release specific code here */
# endif
#endifRelease__FreeBSD_version2.0-RELEASE1194112.1-CURRENTs199501, 1995032.0.5-RELEASE1995042.2-CURRENT before 2.11995082.1.0-RELEASE1995112.2-CURRENT before 2.1.51995122.1.5-RELEASE1996072.2-CURRENT before 2.1.61996082.1.6-RELEASE1996122.1.7-RELEASE1996122.2-RELEASE2200002.2.1-RELEASE220000 (no change)2.2-STABLE after 2.2.1-RELEASE220000 (no change)2.2-STABLE after texinfo-3.92210012.2-STABLE after top2210022.2.2-RELEASE2220002.2-STABLE after 2.2.2-RELEASE2220012.2.5-RELEASE2250002.2-STABLE after 2.2.5-RELEASE2250012.2-STABLE after ldconfig -R merge2250022.2.6-RELEASE2260002.2.7-RELEASE2270002.2-STABLE after 2.2.7-RELEASE2270012.2-STABLE after semctl(2) change2270022.2.8-RELEASE2280002.2-STABLE after 2.2.8-RELEASE2280013.0-CURRENT before mount(2) change3000003.0-CURRENT after mount(2) change3000013.0-CURRENT after semctl(2) change3000023.0-CURRENT after ioctl arg changes3000033.0-CURRENT after ELF conversion3000043.0-RELEASE3000053.0-CURRENT after 3.0-RELEASE3000063.0-STABLE after 3/4 branch3000073.1-RELEASE3100003.1-STABLE after 3.1-RELEASE3100014.0-CURRENT after 3/4 branch400000Note that 2.2-STABLE sometimes identifies itself as
“2.2.5-STABLE” after the 2.2.5-RELEASE. The pattern
used to be year followed by the month, but we decided to change it
to a more straightforward major/minor system starting from 2.2.
This is because the parallel development on several branches made
it infeasible to classify the releases simply by their real
release dates. If you are making a port now, you don't have to
worry about old -CURRENTs; they are listed here just for your
reference.In the hundreds of ports that have been done, there have only
been one or two cases where __FreeBSD__ should
have been used. Just because an earlier port screwed up and used it
in the wrong place does not mean you should do so too.Writing something after
bsd.port.mkDo not write anything after the .include
<bsd.port.mk> line. it usually can be avoided by
including bsd.port.pre.mk somewhere in the
middle of your Makefile and
bsd.port.post.mk at the end.You need to include either the
pre.mk/post.mk pair or
bsd.port.mk only; don't mix these two.bsd.port.pre.mk only defines a few
variables, which can be used in tests in the
Makefile, bsd.port.post.mk
defines the rest.Here are some important variables defined in
bsd.port.pre.mk (this is not the complete list,
please read bsd.port.mk for the complete
list).VariableDescriptionARCHThe architecture as returned by uname
-m (e.g., i386)OPSYSThe operating system type, as returned by
uname -s (e.g.,
FreeBSD)OSRELThe release version of the operating system (e.g.,
2.1.5 or
2.2.7)OSVERSIONThe numeric version of the operating system, same as
__FreeBSD_version.PORTOBJFORMATThe object format of the system
(aout or elfLOCALBASEThe base of the “local” tree (e.g.,
/usr/local/)X11BASEThe base of the “X11” tree (e.g.,
/usr/X11R6)PREFIXWhere the port installs itself (see more on
PREFIX).If you have to define the variables
USE_IMAKE, USE_X_PREFIX, or
MASTERDIR, do so before including
bsd.port.pre.mk.Here are some examples of things you can write after
bsd.port.pre.mk;
# no need to compile lang/perl5 if perl5 is already in system
.if ${OSVERSION} > 300003
BROKEN= perl is in system
.endif
# only one shlib version number for ELF
.if ${PORTOBJFORMAT} == "elf"
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}
.else
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}.${SHLIB_MINOR}
.endif
# software already makes link for ELF, but not for a.out
post-install:
.if ${PORTOBJFORMAT} == "aout"
${LN} -sf liblinpack.so.1.0 ${PREFIX}/lib/liblinpack.so
.endifInstall additional documentationIf your software has some documentation other than the standard
man and info pages that you think is useful for the user, install it
under PREFIX/share/doc.
This can be done, like the previous item, in the
post-install target.Create a new directory for your port. The directory name should
reflect what the port is. This usually means
PKGNAME minus the version part. However, if you
think the user might want different versions of the port to be
installed at the same time, you can use the whole
PKGNAME.Make the installation dependent to the variable
NOPORTDOCS so that users can disable it in
/etc/make.conf, like this:
post-install:
.if !defined(NOPORTDOCS)
${MKDIR}${PREFIX}/share/doc/xv
${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${PREFIX}/share/doc/xv
.endifDo not forget to add them to pkg/PLIST too!
(Do not worry about NOPORTDOCS here; there is
currently no way for the packages to read variables from
/etc/make.conf.)Also you can use the pkg/MESSAGE file to
display messages upon installation. See the using
pkg/MESSAGE section for
details.MESSAGE does not need to be added to
pkg/PLIST).DIST_SUBDIRDo not let your port clutter
/usr/ports/distfiles. If your port requires a
lot of files to be fetched, or contains a file that has a name that
might conflict with other ports (e.g.,
Makefile), set DIST_SUBDIR
to the name of the port (PKGNAME without the
version part should work fine). This will change
DISTDIR from the default
/usr/ports/distfiles to
/usr/ports/distfiles/DIST_SUBDIR,
and in effect puts everything that is required for your port into
that subdirectory.It will also look at the subdirectory with the same name on the
backup master site at ftp.freebsd.org.
(Setting DISTDIR explicitly in your
Makefile will not accomplish this, so please use
DIST_SUBDIR.)This does not affect the MASTER_SITES you
define in your Makefile.Package informationDo include package information, i.e.
COMMENT, DESCR, and
PLIST, in pkg.Note that these files are not used only for packaging anymore,
and are mandatory now, even if
NO_PACKAGE is set.RCS stringsDo not put RCS strings in patches. CVS will mangle them when we
put the files into the ports tree, and when we check them out again,
they will come out different and the patch will fail. RCS strings
are surrounded by dollar ($) signs, and
typically start with $Id or
$RCS.Recursive diffUsing the recurse () option to
diff to generate patches is fine, but please take
a look at the resulting patches to make sure you don't have any
unnecessary junk in there. In particular, diffs between two backup
files, Makefiles when the port uses
Imake or GNU configure, etc.,
are unnecessary and should be deleted. If you had to edit
configure.in and run
autoconf to regenerate
configure, do not take the diffs of
configure (it often grows to a few thousand
lines!); define USE_AUTOCONF=yes and take the
diffsof configure.in.Also, if you had to delete a file, then you can do it in the
post-extract target rather than as part of
the patch. Once you are happy with the resulting diff, please split
it up into one source file per patch file.PREFIXDo try to make your port install relative to
PREFIX. (The value of this variable will be set
to LOCALBASE (default
/usr/local), unless
USE_X_PREFIX or USE_IMAKE is
set, in which case it will be X11BASE (default
/usr/X11R6).)Not hard-coding /usr/local or
/usr/X11R6 anywhere in the source will make the
port much more flexible and able to cater to the needs of other
sites. For X ports that use imake, this is
automatic; otherwise, this can often be done by simply replacing the
occurrences of /usr/local (or
/usr/X11R6 for X ports that do not use imake)
in the various scripts/Makefiles in the port to read
PREFIX, as this variable is automatically passed
down to every stage of the build and install processes.Do not set USE_X_PREFIX unless your port
truly require it (i.e., it links against X libs or it needs to
reference files in X11BASE).The variable PREFIX can be reassigned in your
Makefile or in the user's environment.
However, it is strongly discouraged for individual ports to set this
variable explicitly in the Makefiles.Also, refer to programs/files from other ports with the
variables mentioned above, not explicit pathnames. For instance, if
your port requires a macro PAGER to be the full
pathname of less, use the compiler flag:
-DPAGER=\"${PREFIX}/bin/less\"
or
-DPAGER=\"${LOCALBASE}/bin/less\"
if this is an X port, instead of
-DPAGER=\"/usr/local/bin/less\". This way it will
have a better chance of working if the system administrator has
moved the whole `/usr/local' tree somewhere else.SubdirectoriesTry to let the port put things in the right subdirectories of
PREFIX. Some ports lump everything and put it in
the subdirectory with the port's name, which is incorrect. Also,
many ports put everything except binaries, header files and manual
pages in the a subdirectory of lib, which does
not bode well with the BSD paradigm. Many of the files should be
moved to one of the following: etc
(setup/configuration files), libexec
(executables started internally), sbin
(executables for superusers/managers), info
(documentation for info browser) or share
(architecture independent files). See man &man.hier.7; for details,
the rules governing
/usr pretty much apply to
/usr/local too. The exception are ports
dealing with USENET “news”. They may use
PREFIX/news as a destination
for their files.Cleaning up empty directoriesDo make your ports clean up after themselves when they are
deinstalled. This is usually accomplished by adding
@dirrm lines for all directories that are
specifically created by the port. You need to delete subdirectories
before you can delete parent directories.
:
lib/X11/oneko/pixmaps/cat.xpm
lib/X11/oneko/sounds/cat.au
:
@dirrm lib/X11/oneko/pixmals
@dirrm lib/X11/oneko/sounds
@dirrm lib/X11/onekoHowever, sometimes @dirrm will give you
errors because other ports also share the same subdirectory. You
can call rmdir from @unexec to
remove only empty directories without warning.
@unexec rmdir %D/share/doc/gimp 2>/dev/null || trueThis will neither print any error messages nor cause
pkg_delete to exit abnormally even if
PREFIX/share/doc/gimp is not
empty due to other ports installing some files in there.UIDsIf your port requires a certain user to be on the installed
system, let the pkg/INSTALL script call
pw to create it automatically. Look at
net/cvsup-mirror for an example.If your port must use the same user/group ID number when it is
installed a binarypackage as when it was compiled, then you mus
choose a free UID from 50 to 99 and register it below. Look at
japanese/Wnn for an example.Make sure you don't use a UID already used by the system or
other ports. This is the current list of UIDs between 50 and
99.
majordom:*:54:54:Majordomo Pseudo User:/usr/local/majordomo:/nonexistent
cyrus:*:60:60:the cyrus mail server:/nonexistent:/nonexistent
gnats:*:61:1:GNATS database owner:/usr/local/share/gnats/gnats-db:/bin/sh
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/nonexistent
pop:*:68:6:Post Office Owner (popper):/nonexistent:/nonexistent
wnn:*:69:7:Wnn:/nonexistent:/nonexistent
ifmail:*:70:66:Ifmail user:/nonexistent:/nonexistent
pgsql:*:70:70:PostgreSQL pseudo-user:/usr/local/pgsql:/bin/sh
ircd:*:72:72:IRCd hybrid:/nonexistent:/nonexistent
alias:*:81:81:QMail user:/var/qmail/alias:/nonexistent
qmaill:*:83:81:QMail user:/var/qmail:/nonexistent
qmaild:*:82:81:QMail user:/var/qmail:/nonexistent
qmailq:*:85:82:QMail user:/var/qmail:/nonexistent
qmails:*:87:82:QMail user:/var/qmail:/nonexistent
qmailp:*:84:81:QMail user:/var/qmail:/nonexistent
qmailr:*:86:82:QMail user:/var/qmail:/nonexistent
msql:*:87:87:mSQL-2 pseudo-user:/var/db/msqldb:/bin/shPlease include a notice when you submit a port (or an upgrade)
that reserves a new UID or GID in this range. This allows us to
keep the list of reserved IDs up to date.Do things rationallyThe Makefile should do things simply and
reasonably. If you can make it a couple of lines shorter or more
readable, then do so. Examples include using a make
.if construct instead of a shell
if construct, not redefining
do-extract if you can redefine
EXTRACT* instead, and using
GNU_CONFIGURE instead of CONFIGURE_ARGS
+= --prefix=${PREFIX}.Respect CFLAGSThe port should respect the CFLAGS variable.
If it doesn't, please add NO_PACKAGE=ignores
cflags to the Makefile.Configuration filesIf your port requires some configuration files in
PREFIX/etc, do
not just install them and list them in
pkg/PLIST. That will cause
pkg_delete to delete files carefully edited by
the user and a new installation to wipe them out.Instead, install sample files with a suffix
(filename.sample
will work well) and print out a message pointing out that the
user has to copy and edit the file before the software can be made
to work.PortlintDo check your work with portlint
before you submit or commit it.FeedbackDo send applicable changes/patches to the original
author/maintainer for inclusion in next release of the code. This
will only make your job that much easier for the next
release.MiscellaneaThe files pkg/DESCR,
pkg/COMMENT, and pkg/PLIST
should each be double-checked. If you are reviewing a port and feel
they can be worded better, do so.Don't copy more copies of the GNU General Public License into
our system, please.Please be careful to note any legal issues! Don't let us
illegally distribute software!If you are stuck…Do look at existing examples and the
bsd.port.mk file before asking us questions!
;)Do ask us questions if you have any trouble! Do not just beat
your head against a wall! :)A Sample MakefileHere is a sample Makefile that you can use to
create a new port. Make sure you remove all the extra comments (ones
between brackets)!It is recommended that you follow this format (ordering of
variables, empty lines between sections, etc.). This format is
designed so that the most important information is easy to locate. We
recommend that you use portlint to check the
Makefile.
[the header...just to make it easier for us to identify the ports.]
# New ports collection makefile for: xdvi
[the version required header should updated when upgrading a port.]
# Version required: pl18 [things like "1.5alpha" are fine here too]
[this is the date when the first version of this Makefile was created.
Never change this when doing an update of the port.]
# Date created: 26 May 1995
[this is the person who did the original port to FreeBSD, in particular, the
person who wrote the first version of this Makefile. Remember, this should
not be changed when upgrading the port later.]
# Whom: Satoshi Asami <asami@FreeBSD.ORG>
#
# $Id$
[ ^^^^ This will be automatically replaced with RCS ID string by CVS
when it is committed to our repository.]
#
[section to describe the port itself and the master site - DISTNAME
is always first, followed by PKGNAME (if necessary), CATEGORIES,
and then MASTER_SITES, which can be followed by MASTER_SITE_SUBDIR.
After those, one of EXTRACT_SUFX or DISTFILES can be specified too.]
DISTNAME= xdvi
PKGNAME= xdvi-pl18
CATEGORIES= print
[do not forget the trailing slash ("/")!
if you aren't using MASTER_SITE_* macros]
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applications
[set this if the source is not in the standard ".tar.gz" form]
EXTRACT_SUFX= .tar.Z
[section for distributed patches -- can be empty]
PATCH_SITES= ftp://ftp.sra.co.jp/pub/X11/japanese/
PATCHFILES= xdvi-18.patch1.gz xdvi-18.patch2.gz
[maintainer; *mandatory*! This is the person (preferably with commit
privileges) who a user can contact for questions and bug reports - this
person should be the porter or someone who can forward questions to the
original porter reasonably promptly. If you really do not want to have
your address here, set it to "ports@FreeBSD.ORG".]
MAINTAINER= asami@FreeBSD.ORG
[dependencies -- can be empty]
RUN_DEPENDS= gs:${PORTSDIR}/print/ghostscript
LIB_DEPENDS= Xpm.5:${PORTSDIR}/graphics/xpm
[this section is for other standard bsd.port.mk variables that do not
belong to any of the above]
[If it asks questions during configure, build, install...]
IS_INTERACTIVE= yes
[If it extracts to a directory other than ${DISTNAME}...]
WRKSRC= ${WRKDIR}/xdvi-new
[If the distributed patches were not made relative to ${WRKSRC}, you
may need to tweak this]
PATCH_DIST_STRIP= -p1
[If it requires a "configure" script generated by GNU autoconf to be run]
GNU_CONFIGURE= yes
[If it requires GNU make, not /usr/bin/make, to build...]
USE_GMAKE= yes
[If it is an X application and requires "xmkmf -a" to be run...]
USE_IMAKE= yes
[et cetera.]
[non-standard variables to be used in the rules below]
MY_FAVORITE_RESPONSE= "yeah, right"
[then the special rules, in the order they are called]
pre-fetch:
i go fetch something, yeah
post-patch:
i need to do something after patch, great
pre-install:
and then some more stuff before installing, wow
[and then the epilogue]
.include <bsd.port.mk>Package NamesThe following are the conventions you should follow in naming your
packages. This is to have our package directory easy to scan, as
there are already lots and lots of packages and users are going to
turn away if they hurt their eyes!The package name should look like
language-name-compiled.specifics-version.numbers.If your DISTNAME doesn't look like that, set
PKGNAME to something in that format.FreeBSD strives to support the native language of its users.
The language- part should be a two
letter abbreviation of the natural language defined by ISO-639 if
the port is specific to a certain language. Examples are
ja for Japanese, ru for
Russian, vi for Vietnamese,
zh for Chinese, ko for
Korean and de for German.The name part should be all lowercases,
except for a really large package (with lots of programs in it).
Things like XFree86 (yes there really is a port of it, check it
out) and ImageMagick fall into this category. Otherwise, convert
the name (or at least the first letter) to lowercase. If the
capital letters are important to the name (for example, with
one-letter names like R or
V) you may use capital letters at your
discretion. There is a tradition of naming Perl 5 modules by
prepending p5- and converting the double-colon
separator to a hyphen; for example, the
Data::Dumper module becomes
p5-Data-Dumper. If the software in question
has numbers, hyphens, or underscores in its name, you may include
them as well (like kinput2).If the port can be built with different hardcoded defaults (usually
part of the directory name in a family of ports), the
-compiled.specifics part should state
the compiled-in defaults (the hyphen is optional). Examples are
papersize and font units.The version string should be a period-separated list of
integers and single lowercase alphabetics. The only exception is
the string pl (meaning `patchlevel'), which can
be used only when there are no major and
minor version numbers in the software.Here are some (real) examples on how to convert a
DISTNAME into a suitable
PKGNAME:Distribution NamePackage NameReasonmule-2.2.2.mule-2.2.2No changes requiredXFree86-3.1.2XFree86-3.1.2No changes requiredEmiClock-1.0.2emiclock-1.0.2No uppercase names for single programsgmod1.4gmod-1.4Need a hyphen before version numbersxmris.4.0.2xmris-4.0.2Need a hyphen before version numbersrdist-1.3alphardist-1.3aNo strings like alpha
allowedes-0.9-beta1es-0.9b1No strings like beta
allowedv3.3beta021.srctiff-3.3What the heck was that anyway?tvtwmtvtwm-pl11Version string always requiredpiewmpiewm-1.0Version string always requiredxvgr-2.10pl1xvgr-2.10.1pl allowed only when no
major/minor version numbersgawk-2.15.6ja-gawk-2.15.6Japanese language versionpsutils-1.13psutils-letter-1.13Papersize hardcoded at package build timepkfontspkfonts300-1.0Package for 300dpi fontsIf there is absolutely no trace of version information in the
original source and it is unlikely that the original author will ever
release another version, just set the version string to
1.0 (like the piewm example above). Otherwise, ask
the original author or use the date string
(yy.mm.dd) as the version.CategoriesAs you already know, ports are classified in several categories.
But for this to wor, it is important that porters and users understand
what each category and how we deicde what to put in each
category.Current list of categoriesFirst, this is the current list of port categories. Those
marked with an asterisk (*) are
virtual categories—those that do not have
a corresponding subdirectory in the ports tree.For non-virtual categories, you will find a one-line
description in the pkg/COMMENT file in that
subdirectory (e.g.,
archivers/pkg/COMMENT).CategoryDescriptionafterstep*Ports to support AfterStep window managerarchiversArchiving tools.astroAstronomical ports.audioSound support.benchmarksBenchmarking utilities.biologyBiology-related software.cadComputer aided design tools.chineseChinese language support.commsCommunication software. Mostly software to talk to
your serial port.convertersCharacter code converters.databasesDatabases.deskutilsThings that used to be on the desktop before
computers were invented.develDevelopment utilities. Do not put libraries here just
because they are libraries—unless they truly don't
belong to anywhere else, they shouldn't be in this
category.editorsGeneral editors. Specialized editors go in the section
for those tools (e.g., a mathematical-formula editor will go
in math).elispEmacs-lisp ports.emulatorsEmulators for other operating systems. Terminal
emulators do not belong
here—X-based ones should go to
x11 and text-based ones to either
comms or misc,
depending on the exact functionality.gamesGames.germanGerman language support.graphicsGraphics utilities.japaneseJapanese language support.kde*Ports that form the K Desktop Environment
(kde).koreanKorean language support.langProgramming languages.mailMail software.mathNumerical computation software and other utilities
for mathematics.mboneMBone applications.miscMiscellaneous utilities—basically things that
doesn't belong to anywhere else. This is the only category
that should not appear with any other non-virtual category.
If you have misc with something else in
your CATEGORIES line, that means you can
safely delete misc and just put the port
in that other subdirectory!netMiscellaneous networking software.newsUSENET news software.offix*Ports from the OffiX suite.palmSoftware support for the 3Com Palm(tm) series.perl5*Ports that require perl version 5 to run.plan9*Various programs from Plan9.printPrinting software. Desktop publishing tools
(previewers, etc.) belong here too.python*Software written in python.russianRussian language support.securitySecurity utilities.shellsCommand line shells.sysutilsSystem utilities.tcl75*Ports that use tcl version 7.5 to run.tcl76*Ports that use tcl version 7.6 to run.tcl80*Ports that use tcl version 8.0 to run.tcl81*Ports that use tcl version 8.1 to run.textprocText processing utilities. It does not include
desktop publishing tools, which go to print/.tk41*Ports that use tk version 4.1 to run.tk42*Ports that use tk version 4.2 to run.tk80*Ports that use tk version 8.0 to run.tk81*Ports that use tk version 8.1 to run.vietnameseVietnamese language support.windowmaker*Ports to support the WindowMaker window
managerwwwSoftware related to the World Wide Web. HTML language
support belong here too.x11The X window system and friends. This category is only
for software that directly support the window system. Do not
put regular X applications here. If your port is an X
application, define USE_XLIB (implied by
USE_IMAKE) and put it in appropriate
categories. Also, many of them go into other
x11-* categories (see below).x11-clocksX11 clocks.x11-fmX11 file managers.x11-fontsX11 fonts and font utilities.x11-toolkitsX11 toolkits.x11-wmX11 window managers.Choosing the right categoryAs many of the categories overlap, you often have to choose
which of the categories should be the primary category of your port.
There are several rules that govern this usse. Here is the list of
priorities, in decreasing order of precedence.Language specific categories alwasys come first. For
example, if your port installs Japanese X11 fonts, then your
CATEGORIES line would read japanese
x11.Specific categories win over less-specific ones. For
instance, an HTML editor should be listed as www
editors, not the other way around. Also, you don't
need to list net when the port belongs to
either of mail, mbone,
news, security, or
www.x11 is used as a secondary category only
when the primary category is a natural language. In particular,
you should not put x11 in the category line
for X applications.If your port truly does not belong anywhere else, put it in
misc.If you are not sure about the category, please put a comment to
that effect in your send-pr submission so we can
discuss it before import it. (If you are a committer, send a note
&a.ports; so we can discuss it first—too often new ports are
imported to a wrong category only to be moved right away.)Changes to this document and the ports systemIf you maintain a lot of ports, you should consider following the
&a.ports;. Important changes to the way ports work will be announced
there. You can always find more detailed information on the latest
changes by looking at the
bsd.port.mk CVS log.That is It, Folks!Boy, this sure was a long tutorial, wasn't it? Thanks for
following us to here, really.Well, now that you know how to do a port, let us go at it and
convert everything in the world into ports! That is the easiest way to
start contributing to the FreeBSD Project! :)
diff --git a/en/handbook/ppp-and-slip/chapter.sgml b/en/handbook/ppp-and-slip/chapter.sgml
index a6b0d462da..2db526fa62 100644
--- a/en/handbook/ppp-and-slip/chapter.sgml
+++ b/en/handbook/ppp-and-slip/chapter.sgml
@@ -1,2487 +1,2488 @@
PPP and SLIPIf your connection to the Internet is through a modem, or you wish to
provide other people with dialup connections to the Internet using
FreeBSD, you have the option of using PPP or SLIP. Furthermore, two
varieties of PPP are provided: user (sometimes
referred to as iijppp) and
kernel. The procedures for configuring both types of
PPP, and for setting up SLIP are described in this chapter.Setting up User PPPUser PPP was introduced to FreeBSD in release 2.0.5 as an addition
to the existing kernel implementation of PPP. So, what is different
about this new PPP that warrants its addition? To quote from the manual
page:
This is a user process PPP software package. Normally, PPP is
implemented as a part of the kernel (e.g. as managed by
pppd) and it is thus somewhat hard to debug and/or
modify its behavior. However, in this implementation PPP is done as a
- user process with the help of the tunnel device driver (tun).
+ user process with the help of the tunnel device driver
+ (tun).
In essence, this means that rather than running a PPP daemon, the
ppp program can be run as and when desired. No PPP interface needs to
be compiled into the kernel, as the program can use the generic tunnel
device to get data into and out of the kernel.From here on out, user ppp will be referred to simply as ppp unless
a distinction needs to be made between it and any other PPP
client/server software such as pppd. Unless
otherwise stated, all commands in this section should be executed as
root.There are a large number of enhancements in version 2 of ppp. You
can discover what version you have by running ppp with no arguments and
typing show version at the prompt. It is a simple
matter to upgrade to the latest version of ppp (under any version of
FreeBSD) by downloading the latest archive via www.Awfulhak.org.Before you startThis document assumes you are in roughly this position:You have an account with an Internet Service Provider (ISP) which
lets you use PPP. Further, you have a modem (or other device)
connected and configured correctly which allows you to connect to your
ISP.You are going to need the following information to hand:Your ISPs phone number(s).Your login name and password. This can be either a regular
unix style login/password pair, or a PPP PAP or CHAP
login/password pair.The IP addresses of one or more nameservers. Normally, you
will be given two IP numbers. You must have
this information for PPP version 1.x
unless you run your own nameserver. From version 2 onwards,
PPP supports nameserver address
negotiation. If your ISP supports this, then using the command
enable dns in your config file will tell
PPP to set the nameservers for
you.The following information may have been supplied by your ISP, but
is not strictly necessary:The IP address of your ISP's gateway. The gateway is the
machine to which you will connect and will be set up as your
default route. If your ISP hasn't given you
this number, we can make one up and your ISP's PPP server will
tell us the correct value when we connect.This IP number is referred to as HISADDR
by ppp.Your ISP's netmask. If your ISP hasn't given you this
information, you can safely use a netmask of 255.255.255.0.If your ISP allocates you a static IP address and hostname
then you can enter this information. Otherwise, we simply let the
peer assign whatever IP number it sees fit.If you do not have any of the required information, contact your
ISP and make sure they provide it to you.Building a ppp ready kernelAs the description states, ppp uses the kernel
tun device. It is necessary to make sure
that your kernel has support for this device compiled in.To check this, go to your kernel compile directory
(/sys/i386/conf or
/sys/pc98/conf) and examine your kernel
configuration file. It needs to have the line
pseudo-device tun 1
in it somewhere. The stock GENERIC kernel has
this as standard, so if you have not installed a custom kernel or you
do not have a /sys directory, you do not have to
change anything.If your kernel configuration file does not have this line in it,
- or you need to configure more than one tun device (for example, if you
+ or you need to configure more than one tun device (for example, if you
are setting up a server and could have 16 dialup ppp connections at
any one time then you will need to use 16 instead
of 1), then you should add the line, re-compile,
re-install and boot the new kernel. Please refer to the Configuring the FreeBSD Kernel section
for more information on kernel configuration.You can check how many tunnel devices your current kernel has by
typing the following:&prompt.root; ifconfig -a
tun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 200.10.100.1 --> 203.10.100.24 netmask 0xffffffff
tun1: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 576
tun2: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 203.10.100.1 --> 203.10.100.20 netmask 0xffffffff
tun3: flags=8010<POINTOPOINT,MULTICAST> mtu 1500This case shows four tunnel devices, two of which are currently
configured and being used. It should be noted that the
RUNNING flag above indicates that the interface has
been used at some point—it is not an error if your interface
does not show up as RUNNING.
- If you have a kernel without the tun device, and you can not
+ If you have a kernel without the tun device, and you can not
rebuild it for some reason, all is not lost. You should be able to
dynamically load the code. Refer to the appropriate
&man.modload.8; and &man.lkm.4; pages for further details.You may also wish to take this opportunity to configure a
firewall. Details can be found in the Firewalls section.Check the tun deviceMost users will only require one tun
device (/dev/tun0). If you have used more (i.e.,
a number other than 1 in the
pseudo-device line in the kernel configuration
file) then alter all references to tun0 below
to reflect whichever device number you are using.The easiest way to make sure that the
tun0 device is configured correctly is to
re-make it. To do this, execute the following commands:&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun0If you require 16 tunnel devices in your kernel, you will need to
- create more than just tun0:
+ create more than just tun0:
&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun15Also, to confirm that the kernel is configured correctly, the
following command should give the indicated output:&prompt.root; ifconfig tun0
tun0: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 1500The RUNNING flag may not yet be set, in which
case you will see:&prompt.root; ifconfig tun0
tun0: flags=8010<POINTOPOINT,MULTICAST> mtu 1500Name Resolution ConfigurationThe resolver is the part of the system that turns IP addresses
into hostnames and vice versa. It can be configured to look for maps
that describe IP to hostname mappings in one of two places. The first
is a file called /etc/hosts (man 5
hosts). The second is the Internet Domain Name Service
(DNS), a distributed data base, the discussion of which is beyond the
scope of this document.This section describes briefly how to configure your
resolver.The resolver is a set of system calls that do the name mappings,
but you have to tell them where to find their information. You do
this by first editing the file /etc/host.conf.
Do not call this file
/etc/hosts.conf (note the extra
s) as the results can be confusing.Edit the /etc/host.conf fileThis file should contain the following two lines (in this
order):
hosts
bindThese instructs the resolver to first look in the file
/etc/hosts, and then to consult the DNS if the
name was not found.Edit the /etc/hosts(5) fileThis file should contain the IP addresses and names of machines
on your network. At a bare minimum it should contain entries for
the machine which will be running ppp. Assuming that your machine
is called foo.bar.com with the IP
address 10.0.0.1,
/etc/hosts should contain:
127.0.0.1 localhost
10.0.0.1 foo.bar.com fooThe first line defines the alias localhost as a
synonym for the current machine. Regardless of your own IP address,
the IP address for this line should always be 127.0.0.1. The second line maps the name
foo.bar.com (and the shorthand
foo) to the IP address 10.0.0.1.If your provider allocates you a static IP address and name,
then use these in place of the 10.0.0.1 entry.Edit the /etc/resolv.conf file/etc/resolv.conf tells the resolver how to
behave. If you are running your own DNS, you may leave this file
empty. Normally, you will need to enter the following
line(s):
nameserver x.x.x.x
nameserver y.y.y.y
domain bar.comThe x.x.x.x and
y.y.y.y
addresses are those given to you by your ISP. Add as many
nameserver lines as your ISP provides. The
domain line defaults to your hostname's domain,
and is probably unnecessary. Refer to the
resolv.conf manual page for details of other
possible entries in this file.If you are running PPP version 2 or greater, the enable
dns command will tell PPP to request that your ISP
confirms the nameserver values. If your ISP supplies different
addresses (or if there are no nameserver lines in
/etc/resolv.conf), PPP will rewrite the file
with the ISP-supplied values.ppp ConfigurationBoth user ppp and pppd (the kernel level
implementation of PPP) use configuration files located in the
/etc/ppp directory. The sample configuration
files provided are a good reference for user ppp, so don't delete
them.Configuring ppp requires that you edit a number
of files, depending on your requirements. What you put in them
depends to some extent on whether your ISP allocates IP addresses
statically (i.e., you get given one IP address, and always use that
one) or dynamically (i.e., your IP address can be different for each
PPP session).PPP and Static IP addressesYou will need to create a configuration file called
/etc/ppp/ppp.conf. It should look similar to
the example below.Lines that end in a : start in the first
column, all other lines should be indented as shown using spaces
or tabs.
1 default:
2 set device /dev/cuaa0
3 set speed 115200
4 set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \"\" ATE1Q0 OK-AT-OK \\dATDT\\TTIMEOUT 40 CONNECT"
5 provider:
6 set phone "(0123) 456 7890"
7 set login "TIMEOUT 10 \"\" \"\" gin:--gin: foo word: bar col: ppp"
8 set timeout 300
9 set ifaddr x.x.x.xy.y.y.y 255.255.255.0 0.0.0.0
10 add default HISADDR
11 enable dnsDo not include the line numbers, they are just for reference in
this discussion.Line 1:Identifies the default entry. Commands in this entry are
executed automatically when ppp is run.Line 2:Identifies the device to which the modem is connected.
COM1: is
/dev/cuaa0 and
COM2: is
/dev/cuaa1.Line 3:Sets the speed you want to connect at. If 115200 doesn't
work (it should with any reasonably new modem), try 38400
instead.Line 4:The dial string. User PPP uses an expect-send syntax
similar to the &man.chat.8; program. Refer to the
manual page for information on the features of this
language.Line 5:Identifies an entry for a provider called
“provider”.Line 6:Sets the phone number for this provider. Multiple phone
numbers may be specified using the : or
| character as a separator. The difference
- between these spearators is described in the ppp manual page.
+ between these separators is described in &man.ppp.8;.
To summarize, if you want to rotate through the numbers, use
the :. If you want to always attempt to
dial the first number first and only use the other numbers if
the first number fails, use the |. Always
quote the entire set of phone numbers as shown.Line 7:The login string is of the same chat-like syntax as the
dial string. In this example, the string works for a service
whose login session looks like this:J. Random Provider
login: foo
password: bar
protocol: pppYou will need to alter this script to suit your own needs.
When you write this script for the first time, you should
enable “chat” logging to ensure that the
conversation is going as expected.If you're using PAP or CHAP, there will be no login at
this point, so your login string can be left blank. See PAP and CHAP
authentication for further details.Line 8:Sets the default timeout (in seconds) for the connection.
Here, the connection will be closed automatically after 300
seconds of inactivity. If you never want to timeout, set this
value to zero.Line 9:Sets the interface addresses. The string
x.x.x.x should be replaced by the
IP address that your provider has allocated to you. The
string y.y.y.y should be replaced
by the IP address that your ISP indicated for their gateway
(the machine to which you connect). If your ISP hasn't given
you a gateway address, use 10.0.0.2/0. If you need to use a
“guessed” address, make sure that you create an
entry in /etc/ppp/ppp.linkup as per the
instructions for PPP and
Dynamic IP addresses. If this line is omitted,
ppp cannot run in or
mode.Line 10:Adds a default route to your ISPs gateway. The special
word HISADDR is replaced with the gateway
address specified on line 9. It is important that this line
appears after line 9, otherwise HISADDR
will not yet be initialized.Line 11:This line tells PPP to ask your ISP to confirm that your
nameserver addresses are correct. If your ISP supports this
facility, PPP can then update
/etc/resolv.conf with the correct
nameserver entries.It is not necessary to add an entry to
ppp.linkup when you have a static IP address as
your routing table entries are already correct before you connect.
You may however wish to create an entry to invoke programs after
connection. This is explained later with the sendmail
example.Example configuration files can be found in the
/etc/ppp directory.PPP and Dynamic IP addressesIf your service provider does not assign static IP numbers,
ppp can be configured to negotiate the local and
remote addresses. This is done by “guessing” an IP
number and allowing ppp to set it up correctly
using the IP Configuration Protocol (IPCP) after connecting. The
ppp.conf configuration is the same as PPP and Static IP addresses,
with the following change:
9 set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0Again, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 9:The number after the / character is the
number of bits of the address that ppp will insist on. You
may wish to use IP numbers more appropriate to your
circumstances, but the above example will always work.The last argument (0.0.0.0) tells PPP
to negotiate using address 0.0.0.0 rather than 10.0.0.1. Do not use
0.0.0.0 as the first argument to
set ifaddr as it prevents PPP from setting
up an intial route in mode.If you are running version 1.x of PPP, uou will also need to
create an entry in /etc/ppp/ppp.linkup.
ppp.linkup is used after a connection has been
established. At this point, ppp will know what
IP addresses should really be used. The
following entry will delete the existing bogus routes, and create
correct ones:
1 provider:
2 delete ALL
3 add 0 0 HISADDRLine 1:On establishing a connection, ppp will
look for an entry in ppp.linkup according
to the following rules: First, try to match the same label as
we used in ppp.conf. If that fails, look
for an entry for the IP number of our gateway. This entry is
a four-octet IP style label. If we still haven't found an
entry, look for the MYADDR entry.Line 2:This line tells ppp to delete all
existing routes for the acquired tun interface (except the
direct route entry).Line 3:This line tells ppp to add a default
route that points to HISADDR.
HISADDR will be replaced with the IP number
of the gateway as negotiated in the IPCP.See the pmdemand entry in the files
/etc/ppp/ppp.conf.sample and
/etc/ppp/ppp.linkup.sample for a detailed
example.Version 2 of PPP introduces “sticky routes”. Any
add or delete lines that
contain MYADDR or HISADDR will
be remembered, and any time the actual values of
MYADDR or HISADDR change, the
routes will be re-applied. This removes the necessity of repeating
these lines in ppp.linkup.Receiving incoming calls with pppThis section describes setting up ppp in a
server role.When you configure ppp to receive incoming
calls on a machine connected to a LAN, you must decide if you wish
to forward packets to the LAN. If you do, you should allocate the
peer an IP number from your LAN's subet, and use the command
enable proxy
in your ppp.conf file. You should also confirm
that the /etc/rc.conf file (this file used to
be called /etc/sysconfig) contains the
following:
gateway=YESWhich getty?Configuring FreeBSD for Dialup
Services provides a good description on enabling dialup
services using getty.An alternative to getty is mgetty,
a smarter version of getty designed with dialup
lines in mind.The advantages of using mgetty is that it
actively talks to modems, meaning if port is
turned off in /etc/ttys then your modem won't
answer the phone.Later versions of mgetty (from 0.99beta
onwards) also support the automatic detection of PPP streams,
allowing your clients script-less access to your server.Refer to Mgetty and
AutoPPP for more information on
mgetty.PPP permissionsppp must normally be run as user id 0. If
however you wish to allow ppp to run in server
mode as a normal user by executing ppp as
described below, that user must be given permission to run
ppp by adding them to the
network group in
/etc/group.You will also need to give them access to one or more sections
of the configuration file using the allow
command:
allow users fred maryIf this command is used in the default
section, it gives the specified users access to everything.Setting up a PPP shell for dynamic-IP usersCreate a file called /etc/ppp/ppp-shell
containing the following:
#!/bin/sh
IDENT=`echo $0 | sed -e 's/^.*-\(.*\)$/\1/'`
CALLEDAS="$IDENT"
TTY=`tty`
if [ x$IDENT = xdialup ]; then
IDENT=`basename $TTY`
fi
echo "PPP for $CALLEDAS on $TTY"
echo "Starting PPP for $IDENT"
exec /usr/sbin/ppp -direct $IDENTThis script should be executable. Now make a symbolic link
called ppp-dialup to this script using the
following commands:&prompt.root; ln -s ppp-shell /etc/ppp/ppp-dialupYou should use this script as the shell
for all your dialup ppp users. This is an example from
/etc/password for a dialup PPP user with
username pchilds. (remember don't directly
edit the password file, use vipw)
pchilds:*:1011:300:Peter Childs PPP:/home/ppp:/etc/ppp/ppp-dialupCreate a /home/ppp directory that is
world readable containing the following 0 byte files
-r--r--r-- 1 root wheel 0 May 27 02:23 .hushlogin
-r--r--r-- 1 root wheel 0 May 27 02:22 .rhosts
which prevents /etc/motd from being
displayed.Setting up a PPP shell for static-IP usersCreate the ppp-shell file as above and
for each account with statically assigned IPs create a symbolic
link to ppp-shell.For example, if you have three dialup customers
fred, sam, and
mary, that you route class C networks for,
you would type the following:&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-fred
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-sam
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-maryEach of these users dialup accounts should have their shell
set to the symbolic link created above. (ie.
mary's shell should be
/etc/ppp/ppp-mary).Setting up ppp.conf for dynamic-IP usersThe /etc/ppp/ppp.conf file should contain
something along the lines of
default:
set debug phase lcp chat
set timeout 0
ttyd0:
set ifaddr 203.14.100.1 203.14.100.20 255.255.255.255
enable proxy
ttyd1:
set ifaddr 203.14.100.1 203.14.100.21 255.255.255.255
enable proxyThe indenting is important.The default: section is loaded for each
session. For each dialup line enabled in
/etc/ttys create an entry similar to the one
for ttyd0: above. Each line should get a
unique IP address from your pool of IP addresses for dynamic
users.Setting up ppp.conf for static-IP
usersAlong with the contents of the sample
/etc/ppp/ppp.conf above you should add a
section for each of the statically assigned dialup users. We will
continue with our fred,
sam, and mary
example.
fred:
set ifaddr 203.14.100.1 203.14.101.1 255.255.255.255
sam:
set ifaddr 203.14.100.1 203.14.102.1 255.255.255.255
mary:
set ifaddr 203.14.100.1 203.14.103.1 255.255.255.255The file /etc/ppp/ppp.linkup should also
contain routing information for each static IP user if required.
The line below would add a route for the 203.14.101.0 class C via the client's
ppp link.
fred:
add 203.14.101.0 netmask 255.255.255.0 HISADDR
sam:
add 203.14.102.0 netmask 255.255.255.0 HISADDR
mary:
add 203.14.103.0 netmask 255.255.255.0 HISADDRMore on mgetty, AutoPPP, and MS
extensionsmgetty and AutoPPPConfiguring and compiling mgetty with the
AUTO_PPP option enabled allows
mgetty to detect the LCP phase of PPP
connections and automatically spawn off a ppp shell. However,
since the default login/password sequence does not occur it is
necessary to authenticate users using either PAP or CHAP.This section assumes the user has successfully configured,
compiled, and installed a version of mgetty
with the AUTO_PPP option (v0.99beta or
later)Make sure your
/usr/local/etc/mgetty+sendfax/login.config
file has the following in it:
/AutoPPP/ - - /etc/ppp/ppp-pap-dialupThis will tell mgetty to run the
ppp-pap-dialup script for detected PPP
connections.Create a file called
/etc/ppp/ppp-pap-dialup containing the
following (the file should be executable):
#!/bin/sh
exec /usr/sbin/ppp -direct pap$IDENTFor each dialup line enabled in
/etc/ttys create a corresponding entry in
/etc/ppp/ppp.conf. This will happily
co-exist with the definitions we created above.
pap:
enable pap
set ifaddr 203.14.100.1 203.14.100.20-203.14.100.40
enable proxyEach user logging in with this method will need to have a
username/password in /etc/ppp/ppp.secret
file, or alternatively add the
enable passwdauthoption to authenticate users via pap from the
/etc/password file.If you wish to assign some users a static IP number, you can
specify the number as the third argument in
/etc/ppp/ppp.secret. See
/etc/ppp/ppp.secret.sample for
examples.MS extentionsIt is possible to configure PPP to supply DNS and NetBIOS
nameserver addresses on demand.To enable these extensions with PPP version 1.x, the
following lines might be added to the relevant section of
/etc/ppp/ppp.conf.
enable msext
set ns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5And for PPP version 2 and above:
accept dns
set dns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5This will tell the clients the primary and secondary name
server addresses, and a netbios nameserver host.In version 2 and above, if the set dns
line is ommitted, PPP will use the values found in
/etc/resolv.conf.PAP and CHAP authenticationSome ISPs set their system up so that the authentication part of
your connection is done using either of the PAP or CHAP
authentication mechanisms. If this is the case, your ISP will not
give a login: prompt when you connect, but will
start talking PPP immediately.PAP is less secure than CHAP, but security is not normally an
issue here as passwords, although being sent as plain text with PAP,
are being transmitted down a serial line only. There's not much room
for crackers to “eavesdrop”.Referring back to the PPP and
Static IP addresses or PPP and Dynamic IP addresses
sections, the following alterations must be made:
7 set login
…
12 set authname MyUserName
13 set authkey MyPasswordAs always, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 7:Your ISP will not normally require that you log into the
server if you're using PAP or CHAP. You must therefore
disable your "set login" string.Line 12:This line specifies your PAP/CHAP user name. You will
need to insert the correct value for
MyUserName.Line 13:This line specifies your PAP/CHAP password. You will need
to insert the correct value for
MyPassword. You may want to add an
additional line
15 accept PAP
or
15 accept CHAP
to make it obvious that this is the intention, but PAP and
CHAP are both accepted by default.Changing your ppp configuration on the
flyIt is possible to talk to the ppp program
while it is running in the background, but only if a suitable
diagnostic port has been set up. To do this, add the following line
to your configuration:
set server /var/run/ppp-tun%d DiagnosticPassword 0177This will tell PPP to listen to the specified unix-domain
socket, asking clients for the specified password before allowing
- access. The %d in the name is replaced with teh
- tun device number that is in use.
+ access. The %d in the name is replaced with the
+ tun device number that is in use.
Once a socket has been set up, the
&man.pppctl.8; program may be used in scripts that wish to
manipulate the running program.Final system configurationYou now have ppp configured, but there are a
few more things to do before it is ready to work. They all involve
editing the /etc/rc.conf file (was
/etc/sysconfig).Working from the top down in this file, make sure the
hostname= line is set, e.g.:
hostname=foo.bar.comIf your ISP has supplied you with a static IP address and name,
it's probably best that you use this name as your host name.Look for the network_interfaces variable. If
you want to configure your system to dial your ISP on demand, make
sure the tun0 device is added to the list,
otherwise remove it.
network_interfaces="lo0 tun0" ifconfig_tun0=The ifconfig_tun0 variable should be empty,
and a file called /etc/start_if.tun0 should be
created. This file should contain the line
ppp -auto mysystemThis script is executed at network configuration time, starting
your ppp daemon in automatic mode. If you have a LAN for which this
machine is a gateway, you may also wish to use the
switch. Refer to the manual page for
further details.Set the router program to NO with the
line
router_enable=NO (/etc/rc.conf)
router=NO (/etc/sysconfig)It is important that the routed daemon is not
started (it's started by default) as routed tends
to delete the default routing table entries created by
ppp.It is probably worth your while ensuring that the
sendmail_flags line does not include the
option, otherwise sendmail will
attempt to do a network lookup every now and then, possibly causing
your machine to dial out. You may try:
sendmail_flags="-bd"The upshot of this is that you must force
sendmail to re-examine the mail queue whenever the
ppp link is up by typing:&prompt.root; /usr/sbin/sendmail -qYou may wish to use the !bg command in
ppp.linkup to do this automatically:
1 provider:
2 delete ALL
3 add 0 0 HISADDR
4 !bg sendmail -bd -q30mIf you don't like this, it is possible to set up a
“dfilter” to block SMTP traffic. Refer to the sample
files for further details.All that is left is to reboot the machine.After rebooting, you can now either type&prompt.root; pppand then dial provider to start the PPP
session, or, if you want ppp to establish sessions
automatically when there is outbound traffic (and you haven't created
the start_if.tun0 script), type&prompt.root; ppp -auto providerSummaryTo recap, the following steps are necessary when setting up ppp
for the first time:Client side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/ppp/ppp.conf.
The pmdemand example should suffice for most
ISPs.If you have a dynamic IP address, create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.Create a start_if.tun0 script if you
require demand dialing.Server side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/passwd (using the
&man.vipw.8; program).Create a profile in this users home directory that runs
ppp -direct direct-server or similar.Create an entry in /etc/ppp/ppp.conf.
The direct-server example should
suffice.Create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.AcknowledgmentsThis section of the handbook was last updated on Monday Aug 10,
1998 by &a.brian;Thanks to the following for their input, comments &
suggestions:&a.nik;&a.dirkvangulik;&a.pjc;Setting up Kernel PPPContributed by &a.gena;.Before you start setting up PPP on your machine make sure that
pppd is located in /usr/sbin and
directory /etc/ppp exists.pppd can work in two modes:as a “client”, i.e. you want to connect your machine
to outside world via PPP serial connection or modem line.as a “server”, i.e. your machine is located on the
network and used to connect other computers using PPP.In both cases you will need to set up an options file
(/etc/ppp/options or ~/.ppprc
if you have more then one user on your machine that uses PPP).You also will need some modem/serial software (preferably kermit) so
you can dial and establish connection with remote host.Working as a PPP clientI used the following /etc/ppp/options to
connect to CISCO terminal server PPP line.
crtscts # enable hardware flow control
modem # modem control line
noipdefault # remote PPP server must supply your IP address.
# if the remote host doesn't send your IP during IPCP
# negotiation , remove this option
passive # wait for LCP packets
domain ppp.foo.com # put your domain name here
:<remote_ip> # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be your
# default routerTo connect:Dial to the remote host using kermit (or other modem program)
enter your user name and password (or whatever is needed to enable
PPP on the remote host)Exit kermit (without hanging up the line).enter:&prompt.root; /usr/src/usr.sbin/pppd.new/pppd /dev/tty0119200Use the appropriate speed and device name.Now your computer is connected with PPP. If the connection fails
for some reasons you can add the option to the
/etc/ppp/options file and check messages on the
console to track the problemFollowing /etc/ppp/pppup script will make all
3 stages automatically:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.dial
pppd /dev/tty01 19200/etc/ppp/kermit.dial is kermit script that
dials and makes all necessary authorization on the remote host.
(Example of such script is attached to the end of this
document)Use the following /etc/ppp/pppdown script to
disconnect the PPP line:
#!/bin/sh
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill -TERM ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
/sbin/ifconfig ppp0 down
/sbin/ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.hup
/etc/ppp/ppptestCheck if PPP is still running
(/usr/etc/ppp/ppptest):
#!/bin/sh
pid=`ps ax| grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'pppd running: PID=' ${pid-NONE}
else
echo 'No pppd running.'
fi
set -x
netstat -n -I ppp0
ifconfig ppp0Hangs up modem line
(/etc/ppp/kermit.hup):
set line /dev/tty01 ; put your modem device here
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
echo \13
exitHere is an alternate method using chat instead
of kermit.Contributed by &a.rhuff;.The following two files are sufficient to accomplish a pppd
connection./etc/ppp/options:
/dev/cuaa1 115200
crtscts # enable hardware flow control
modem # modem control line
connect "/usr/bin/chat -f /etc/ppp/login.chat.script"
noipdefault # remote PPP serve must supply your IP address.
# if the remote host doesn't send your IP during
# IPCP negotiation, remove this option
passive # wait for LCP packets
domain <your.domain> # put your domain name here
: # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be
# your default router/etc/ppp/login.chat.script:(This should actually go into a single line.)
ABORT BUSY ABORT 'NO CARRIER' "" AT OK ATDT<phone.number>
CONNECT "" TIMEOUT 10 ogin:-\\r-ogin: <login-id>
TIMEOUT 5 sword: <password>Once these are installed and modified correctly, all you need to
do is&prompt.root; pppdThis sample based primarily on information provided by: Trev
Roydhouse <Trev.Roydhouse@f401.n711.z3.fidonet.org> and used by
permission.Working as a PPP server/etc/ppp/options:
crtscts # Hardware flow control
netmask 255.255.255.0 # netmask ( not required )
192.114.208.20:192.114.208.165 # ip's of local and remote hosts
# local ip must be different from one
# you assigned to the ethernet ( or other )
# interface on your machine.
# remote IP is ip address that will be
# assigned to the remote machine
domain ppp.foo.com # your domain
passive # wait for LCP
modem # modem lineFollowing /etc/ppp/pppserv script will enable
ppp server on your machine:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
# reset ppp interface
ifconfig ppp0 down
ifconfig ppp0 delete
# enable autoanswer mode
kermit -y /etc/ppp/kermit.ans
# run ppp
pppd /dev/tty01 19200Use this /etc/ppp/pppservdown script to stop
ppp server:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.noansFollowing kermit script will enable/disable autoanswer mode on
your modem (/etc/ppp/kermit.ans):
set line /dev/tty01
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
inp 5 OK
echo \13
out ATS0=1\13 ; change this to out ATS0=0\13 if you want to disable
; autoanswer mod
inp 5 OK
echo \13
exitThis /etc/ppp/kermit.dial script is used for
dialing and authorizing on remote host. You will need to customize it
for your needs. Put your login and password in this script, also you
will need to change input statement depending on responses from your
modem and remote host.
;
; put the com line attached to the modem here:
;
set line /dev/tty01
;
; put the modem speed here:
;
set speed 19200
set file type binary ; full 8 bit file xfer
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
set modem hayes
set dial hangup off
set carrier auto ; Then SET CARRIER if necessary,
set dial display on ; Then SET DIAL if necessary,
set input echo on
set input timeout proceed
set input case ignore
def \%x 0 ; login prompt counter
goto slhup
:slcmd ; put the modem in command mode
echo Put the modem in command mode.
clear ; Clear unread characters from input buffer
pause 1
output +++ ; hayes escape sequence
input 1 OK\13\10 ; wait for OK
if success goto slhup
output \13
pause 1
output at\13
input 1 OK\13\10
if fail goto slcmd ; if modem doesn't answer OK, try again
:slhup ; hang up the phone
clear ; Clear unread characters from input buffer
pause 1
echo Hanging up the phone.
output ath0\13 ; hayes command for on hook
input 2 OK\13\10
if fail goto slcmd ; if no OK answer, put modem in command mode
:sldial ; dial the number
pause 1
echo Dialing.
output atdt9,550311\13\10 ; put phone number here
assign \%x 0 ; zero the time counter
:look
clear ; Clear unread characters from input buffer
increment \%x ; Count the seconds
input 1 {CONNECT }
if success goto sllogin
reinput 1 {NO CARRIER\13\10}
if success goto sldial
reinput 1 {NO DIALTONE\13\10}
if success goto slnodial
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 60 goto look
else goto slhup
:sllogin ; login
assign \%x 0 ; zero the time counter
pause 1
echo Looking for login prompt.
:slloop
increment \%x ; Count the seconds
clear ; Clear unread characters from input buffer
output \13
;
; put your expected login prompt here:
;
input 1 {Username: }
if success goto sluid
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 10 goto slloop ; try 10 times to get a login prompt
else goto slhup ; hang up and start again if 10 failures
:sluid
;
; put your userid here:
;
output ppp-login\13
input 1 {Password: }
;
; put your password here:
;
output ppp-password\13
input 1 {Entering SLIP mode.}
echo
quit
:slnodial
echo \7No dialtone. Check the telephone line!\7
exit 1
; local variables:
; mode: csh
; comment-start: "; "
; comment-start-skip: "; "
; end:Setting up a SLIP ClientContributed by &a.asami; 8 Aug 1995.The following is one way to set up a FreeBSD machine for SLIP on a
static host network. For dynamic hostname assignments (i.e., your
address changes each time you dial up), you probably need to do
something much fancier.First, determine which serial port your modem is connected to. I
have a symbolic link to /dev/modem from
/dev/cuaa1, and only use the modem name in my
configuration files. It can become quite cumbersome when you need to
fix a bunch of files in /etc and
.kermrc's all over the system!/dev/cuaa0 is COM1,
cuaa1 is COM2,
etc.Make sure you have
pseudo-device sl 1
in your kernel's config file. It is included in the
GENERIC kernel, so this will not be a problem
unless you deleted it.Things you have to do only onceAdd your home machine, the gateway and nameservers to your
/etc/hosts file. Mine looks like
this:
127.0.0.1 localhost loghost
136.152.64.181 silvia.HIP.Berkeley.EDU silvia.HIP silvia
136.152.64.1 inr-3.Berkeley.EDU inr-3 slip-gateway
128.32.136.9 ns1.Berkeley.edu ns1
128.32.136.12 ns2.Berkeley.edu ns2By the way, silvia is the name of the car that I had when I
was back in Japan (it is called 2?0SX here in U.S.).Make sure you have before
in your /etc/host.conf.
Otherwise, funny things may happen.Edit the file /etc/rc.conf. Note that
you should edit the file /etc/sysconfig
instead if you are running FreeBSD previous to version
2.2.2.Set your hostname by editing the line that says:
hostname=myname.my.domainYou should give it your full Internet hostname.Add sl0 to the list of network interfaces by changing the
line that says:
network_interfaces="lo0"to:
network_interfaces="lo0 sl0"Set the startup flags of sl0 by adding a line:
ifconfig_sl0="inet ${hostname} slip-gateway netmask 0xffffff00 up"Designate the default router by changing the line:
defaultrouter=NOto:
defaultrouter=slip-gatewayMake a file /etc/resolv.conf which
contains:
domain HIP.Berkeley.EDU
nameserver 128.32.136.9
nameserver 128.32.136.12As you can see, these set up the nameserver hosts. Of course,
the actual domain names and addresses depend on your
environment.Set the password for root and toor (and any other accounts
that does not have a password). Use passwd, do not edit the
/etc/passwd or
/etc/master.passwd files!Reboot your machine and make sure it comes up with the correct
hostname.Making a SLIP connectionDial up, type slip at the prompt, enter
your machine name and password. The things you need to enter
depends on your environment. I use kermit, with a script like
this:
# kermit setup
set modem hayes
set line /dev/modem
set speed 115200
set parity none
set flow rts/cts
set terminal bytesize 8
set file type binary
# The next macro will dial up and login
define slip dial 643-9600, input 10 =>, if failure stop, -
output slip\x0d, input 10 Username:, if failure stop, -
output silvia\x0d, input 10 Password:, if failure stop, -
output ***\x0d, echo \x0aCONNECTED\x0a(of course, you have to change the hostname and password to
fit yours). Then you can just type slip from
the kermit prompt to get connected.Leaving your password in plain text anywhere in the
filesystem is generally a BAD idea. Do it at your own risk. I
am just too lazy.Leave the kermit there (you can suspend it by
z) and as root, type:&prompt.root; slattach -h -c -s 115200 /dev/modemIf you are able to ping hosts on the other
side of the router, you are connected! If it does not work, you
might want to try instead of
as an argument to slattach.How to shutdown the connectionType
&prompt.root; kill -INT `cat /var/run/slattach.modem.pid`
(as root) to kill slattach. Then go back to kermit
(fg if you suspended it) and exit from it
(q).The slattach man page says you have to use ifconfig sl0
down to mark the interface down, but this does not seem to
make any difference for me. (ifconfig sl0 reports
the same thing.)Some times, your modem might refuse to drop the carrier (mine
often does). In that case, simply start kermit and quit it again. It
usually goes out on the second try.TroubleshootingIf it does not work, feel free to ask me. The things that people
tripped over so far:Not using or in
slattach (I have no idea why this can be fatal, but adding this
flag solved the problem for at least one person)Using instead of
(might be hard to see the difference on some fonts).Try ifconfig sl0 to see your interface
status. I get:&prompt.root; ifconfig sl0
sl0: flags=10<POINTOPOINT>
inet 136.152.64.181 --> 136.152.64.1 netmask ffffff00Also, netstat -r will give the routing
table, in case you get the "no route to host" messages from ping.
Mine looks like:&prompt.root; netstat -r
Routing tables
Destination Gateway Flags Refs Use IfaceMTU Rtt Netmasks:
(root node)
(root node)
Route Tree for Protocol Family inet:
(root node) =>
default inr-3.Berkeley.EDU UG 8 224515 sl0 - -
localhost.Berkel localhost.Berkeley UH 5 42127 lo0 - 0.438
inr-3.Berkeley.E silvia.HIP.Berkele UH 1 0 sl0 - -
silvia.HIP.Berke localhost.Berkeley UGH 34 47641234 lo0 - 0.438
(root node)(this is after transferring a bunch of files, your numbers
should be smaller).Setting up a SLIP ServerContributed by &a.ghelmer;. v1.0, 15 May
1995.This document provides suggestions for setting up SLIP Server
services on a FreeBSD system, which typically means configuring your
system to automatically startup connections upon login for remote SLIP
clients. The author has written this document based on his experience;
however, as your system and needs may be different, this document may
not answer all of your questions, and the author cannot be responsible
if you damage your system or lose data due to attempting to follow the
suggestions here.This guide was originally written for SLIP Server services on a
FreeBSD 1.x system. It has been modified to reflect changes in the
pathnames and the removal of the SLIP interface compression flags in
early versions of FreeBSD 2.X, which appear to be the only major changes
between FreeBSD versions. If you do encounter mistakes in this
document, please email the author with enough information to help
correct the problem.PrerequisitesThis document is very technical in nature, so background knowledge
is required. It is assumed that you are familiar with the TCP/IP
network protocol, and in particular, network and node addressing,
network address masks, subnetting, routing, and routing protocols,
such as RIP. Configuring SLIP services on a dial-up server requires a
knowledge of these concepts, and if you are not familiar with them,
please read a copy of either Craig Hunt's TCP/IP Network
Administration published by O'Reilly & Associates,
Inc. (ISBN Number 0-937175-82-X), or Douglas Comer's books on the
TCP/IP protocol.It is further assumed that you have already setup your modem(s)
and configured the appropriate system files to allow logins through
your modems. If you have not prepared your system for this yet,
please see the tutorial for configuring dialup services; if you have a
World-Wide Web browser available, browse the list of tutorials at
http://www.freebsd.org/;
otherwise, check the place where you found this document for a
document named dialup.txt or something similar.
You may also want to check the manual pages for
&man.sio.4; for information on the serial port device driver and
&man.ttys.5;, &man.gettytab.5;, &man.getty.8;, & &man.init.8;
for information relevant to configuring the system to accept logins on
modems, and perhaps &man.stty.1; for information on setting serial
port parameters (such as clocal for
directly-connected serial interfaces).Quick OverviewIn its typical configuration, using FreeBSD as a SLIP server works
as follows: a SLIP user dials up your FreeBSD SLIP Server system and
logs in with a special SLIP login ID that uses
/usr/sbin/sliplogin as the special user's shell.
The sliplogin program browses the file
/etc/sliphome/slip.hosts to find a matching line
for the special user, and if it finds a match, connects the serial
line to an available SLIP interface and then runs the shell script
/etc/sliphome/slip.login to configure the SLIP
interface.An Example of a SLIP Server LoginFor example, if a SLIP user ID were
Shelmerg, Shelmerg's entry
in /etc/master.passwd would look something like
this (except it would be all on one line):
Shelmerg:password:1964:89::0:0:Guy Helmer - SLIP:/usr/users/Shelmerg:/usr/sbin/sliploginWhen Shelmerg logs in,
sliplogin will search
/etc/sliphome/slip.hosts for a line that had a
matching user ID; for example, there may be a line in
/etc/sliphome/slip.hosts that reads:
Shelmerg dc-slip sl-helmer 0xfffffc00 autocompsliplogin will find that matching line, hook
the serial line into the next available SLIP interface, and then
execute /etc/sliphome/slip.login like
this:
/etc/sliphome/slip.login 0 19200 Shelmerg dc-slip sl-helmer 0xfffffc00 autocompIf all goes well, /etc/sliphome/slip.login
will issue an ifconfig for the SLIP interface to
which sliplogin attached itself (slip interface
0, in the above example, which was the first parameter in the list
given to slip.login) to set the local IP
address (dc-slip), remote IP address
(sl-helmer), network mask for the SLIP interface
(0xfffffc00), and any additional
flags (autocomp). If something goes wrong,
sliplogin usually logs good informational
messages via the daemon syslog facility, which
usually goes into /var/log/messages (see the
manual pages for &man.syslogd.8; and
&man.syslog.conf.5, and perhaps check
/etc/syslog.conf to see to which files
syslogd is logging).OK, enough of the examples — let us dive into setting up
the system.Kernel ConfigurationFreeBSD's default kernels usually come with two SLIP interfaces
defined (sl0 and
sl1); you can use netstat
-i to see whether these interfaces are defined in your
kernel.Sample output from netstat -i:Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll
ed0 1500 <Link>0.0.c0.2c.5f.4a 291311 0 174209 0 133
ed0 1500 138.247.224 ivory 291311 0 174209 0 133
lo0 65535 <Link> 79 0 79 0 0
lo0 65535 loop localhost 79 0 79 0 0
sl0* 296 <Link> 0 0 0 0 0
sl1* 296 <Link> 0 0 0 0 0The sl0 and sl1
interfaces shown in netstat -i's output indicate
that there are two SLIP interfaces built into the kernel. (The
asterisks after the sl0 and sl1
indicate that the interfaces are “down”.)However, FreeBSD's default kernels do not come configured to
forward packets (ie, your FreeBSD machine will not act as a router)
due to Internet RFC requirements for Internet hosts (see RFC's 1009
[Requirements for Internet Gateways], 1122 [Requirements for Internet
Hosts — Communication Layers], and perhaps 1127 [A Perspective
on the Host Requirements RFCs]), so if you want your FreeBSD SLIP
Server to act as a router, you will have to edit the
/etc/rc.conf file (called
/etc/sysconfig in FreeBSD releases prior to
2.2.2) and change the setting of the gateway
variable to . If you have an older system which
predates even the /etc/sysconfig file, then add
the following command:
sysctl -w net.inet.ip.forwarding = 1
to your /etc/rc.local file.You will then need to reboot for the new settings to take
effect.You will notice that near the end of the default kernel
configuration file (/sys/i386/conf/GENERIC) is a
line that reads:
pseudo-device sl 2This is the line that defines the number of SLIP devices available
in the kernel; the number at the end of the line is the maximum number
of SLIP connections that may be operating simultaneously.Please refer to Configuring the
FreeBSD Kernel for help in reconfiguring your kernel.Sliplogin ConfigurationAs mentioned earlier, there are three files in the
/etc/sliphome directory that are part of the
configuration for /usr/sbin/sliplogin (see
&man.sliplogin.8; for the actual manual page for
sliplogin): slip.hosts, which
defines the SLIP users & their associated IP addresses;
slip.login, which usually just configures the
SLIP interface; and (optionally) slip.logout,
which undoes slip.login's effects when the serial
connection is terminated.slip.hosts Configuration/etc/sliphome/slip.hosts contains lines
which have at least four items, separated by whitespace:SLIP user's login IDLocal address (local to the SLIP server) of the SLIP
linkRemote address of the SLIP linkNetwork maskThe local and remote addresses may be host names (resolved to IP
addresses by /etc/hosts or by the domain name
service, depending on your specifications in
/etc/host.conf), and I believe the network mask
may be a name that can be resolved by a lookup into
/etc/networks. On a sample system,
/etc/sliphome/slip.hosts looks like
this:
#
# login local-addr remote-addr mask opt1 opt2
# (normal,compress,noicmp)
#
Shelmerg dc-slip sl-helmerg 0xfffffc00 autocompAt the end of the line is one or more of the options. — no header compression — compress headers — compress headers if the
remote end allows it — disable ICMP packets (so any
“ping” packets will be dropped instead of using up
your bandwidth)Note that sliplogin under early releases of
FreeBSD 2 ignored the options that FreeBSD 1.x recognized, so the
options , ,
, and had no effect
until support was added in FreeBSD 2.2 (unless your
slip.login script included code to make use of
the flags).Your choice of local and remote addresses for your SLIP links
depends on whether you are going to dedicate a TCP/IP subnet or if
you are going to use “proxy ARP” on your SLIP server (it
is not “true” proxy ARP, but that is the terminology
used in this document to describe it). If you are not sure which
method to select or how to assign IP addresses, please refer to the
TCP/IP books referenced in the slips-prereqs section and/or
consult your IP network manager.If you are going to use a separate subnet for your SLIP clients,
you will need to allocate the subnet number out of your assigned IP
network number and assign each of your SLIP client's IP numbers out
of that subnet. Then, you will probably either need to configure a
static route to the SLIP subnet via your SLIP server on your nearest
IP router, or install gated on your FreeBSD SLIP
server and configure it to talk the appropriate routing protocols to
your other routers to inform them about your SLIP server's route to
the SLIP subnet.Otherwise, if you will use the “proxy ARP” method,
you will need to assign your SLIP client's IP addresses out of your
SLIP server's Ethernet subnet, and you will also need to adjust your
/etc/sliphome/slip.login and
/etc/sliphome/slip.logout scripts to use
&man.arp.8; to manage the proxy-ARP entries in the SLIP server's
ARP table.slip.login ConfigurationThe typical /etc/sliphome/slip.login file
looks like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6This slip.login file merely
ifconfig's the appropriate SLIP interface with
the local and remote addresses and network mask of the SLIP
interface.If you have decided to use the “proxy ARP” method
(instead of using a separate subnet for your SLIP clients), your
/etc/sliphome/slip.login file will need to look
something like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6
# Answer ARP requests for the SLIP client with our Ethernet addr
/usr/sbin/arp -s $5 00:11:22:33:44:55 pubThe additional line in this slip.login,
arp -s $5 00:11:22:33:44:55 pub, creates an
ARP entry in the SLIP server's ARP table. This ARP entry causes the
SLIP server to respond with the SLIP server's Ethernet MAC address
whenever a another IP node on the Ethernet asks to speak to the SLIP
client's IP address.When using the example above, be sure to replace the Ethernet
MAC address (00:11:22:33:44:55) with the
MAC address of your system's Ethernet card, or your “proxy
ARP” will definitely not work! You can discover your SLIP
server's Ethernet MAC address by looking at the results of running
netstat -i; the second line of the output should
look something like:ed0 1500 <Link>0.2.c1.28.5f.4a 191923 0 129457 0 116This indicates that this particular system's Ethernet MAC
address is 00:02:c1:28:5f:4a — the
periods in the Ethernet MAC address given by netstat
-i must be changed to colons and leading zeros should be
added to each single-digit hexadecimal number to convert the address
into the form that
&man.arp.8; desires; see the manual page on &man.arp.8; for
complete information on usage.When you create /etc/sliphome/slip.login
and /etc/sliphome/slip.logout, the
“execute” bit (ie, chmod 755
/etc/sliphome/slip.login /etc/sliphome/slip.logout)
must be set, or sliplogin will be unable to
execute it.slip.logout Configuration/etc/sliphome/slip.logout is not strictly
needed (unless you are implementing “proxy ARP”), but if
you decide to create it, this is an example of a basic
slip.logout script:
#!/bin/sh -
#
# slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 downIf you are using “proxy ARP”, you will want to have
/etc/sliphome/slip.logout remove the ARP entry
for the SLIP client:
#!/bin/sh -
#
# @(#)slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 down
# Quit answering ARP requests for the SLIP client
/usr/sbin/arp -d $5The arp -d $5 removes the ARP entry that
the “proxy ARP” slip.login added
when the SLIP client logged in.It bears repeating: make sure
/etc/sliphome/slip.logout has the execute
bit set for after you create it (ie, chmod
755 /etc/sliphome/slip.logout).Routing ConsiderationsIf you are not using the “proxy ARP” method for
routing packets between your SLIP clients and the rest of your network
(and perhaps the Internet), you will probably either have to add
static routes to your closest default router(s) to route your SLIP
client subnet via your SLIP server, or you will probably need to
install and configure gated on your FreeBSD SLIP
server so that it will tell your routers via appropriate routing
protocols about your SLIP subnet.Static RoutesAdding static routes to your nearest default routers can be
troublesome (or impossible, if you do not have authority to do
so...). If you have a multiple-router network in your organization,
some routers, such as Cisco and Proteon, may not only need to be
configured with the static route to the SLIP subnet, but also need
to be told which static routes to tell other routers about, so some
expertise and troubleshooting/tweaking may be necessary to get
static-route-based routing to work.Running gatedAn alternative to the headaches of static routes is to install
gated on your FreeBSD SLIP server and configure
it to use the appropriate routing protocols (RIP/OSPF/BGP/EGP) to
tell other routers about your SLIP subnet. You can use
gated from the ports
collection or retrieve and build it yourself from the
GateD anonymous ftp site; I believe the current version as
of this writing is gated-R3_5Alpha_8.tar.Z,
which includes support for FreeBSD “out-of-the-box”.
Complete information and documentation on gated
is available on the Web starting at the Merit GateD
Consortium. Compile and install it, and then write a
/etc/gated.conf file to configure your gated;
here is a sample, similar to what the author used on a FreeBSD SLIP
server:
#
# gated configuration file for dc.dsu.edu; for gated version 3.5alpha5
# Only broadcast RIP information for xxx.xxx.yy out the ed Ethernet interface
#
#
# tracing options
#
traceoptions "/var/tmp/gated.output" replace size 100k files 2 general ;
rip yes {
interface sl noripout noripin ;
interface ed ripin ripout version 1 ;
traceoptions route ;
} ;
#
# Turn on a bunch of tracing info for the interface to the kernel:
kernel {
traceoptions remnants request routes info interface ;
} ;
#
# Propagate the route to xxx.xxx.yy out the Ethernet interface via RIP
#
export proto rip interface ed {
proto direct {
xxx.xxx.yy mask 255.255.252.0 metric 1; # SLIP connections
} ;
} ;
#
# Accept routes from RIP via ed Ethernet interfaces
import proto rip interface ed {
all ;
} ;The above sample gated.conf file broadcasts
routing information regarding the SLIP subnet
xxx.xxx.yy via RIP onto the Ethernet; if
you are using a different Ethernet driver than the
ed driver, you will need to change the
references to the ed interface
appropriately. This sample file also sets up tracing to
/var/tmp/gated.output for debugging
gated's activity; you can certainly turn off the
tracing options if gated works OK for you. You
will need to change the xxx.xxx.yy's into
the network address of your own SLIP subnet (be sure to change the
net mask in the proto direct clause as
well).When you get gated built and installed and
create a configuration file for it, you will need to run
gated in place of routed on
your FreeBSD system; change the routed/gated
startup parameters in /etc/netstart as
appropriate for your system. Please see the manual page for
gated for information on
gated's command-line parameters.AcknowledgmentsThanks to these people for comments and advice regarding this
tutorial:&a.wilko;Piero SeriniPiero@Strider.Inet.IT
diff --git a/en_US.ISO8859-1/articles/contributing/article.sgml b/en_US.ISO8859-1/articles/contributing/article.sgml
index 6b2a95d1dd..0b06b77f22 100644
--- a/en_US.ISO8859-1/articles/contributing/article.sgml
+++ b/en_US.ISO8859-1/articles/contributing/article.sgml
@@ -1,5715 +1,5715 @@
Contributing to FreeBSDContributed by &a.jkh;.So you want to contribute something to FreeBSD? That is great! We can
always use the help, and FreeBSD is one of those systems that
relies on the contributions of its user base in order
to survive. Your contributions are not only appreciated, they are vital
to FreeBSD's continued growth!Contrary to what some people might also have you believe, you do not
need to be a hot-shot programmer or a close personal friend of the FreeBSD
core team in order to have your contributions accepted. The FreeBSD
Project's development is done by a large and growing number of
international contributors whose ages and areas of technical expertise
vary greatly, and there is always more work to be done than there are
people available to do it.Since the FreeBSD project is responsible for an entire operating
system environment (and its installation) rather than just a kernel or a
few scattered utilities, our TODO list also spans a
very wide range of tasks, from documentation, beta testing and
presentation to highly specialized types of kernel development. No matter
what your skill level, there is almost certainly something you can do to
help the project!Commercial entities engaged in FreeBSD-related enterprises are also
encouraged to contact us. Need a special extension to make your product
work? You will find us receptive to your requests, given that they are not
too outlandish. Working on a value-added product? Please let us know! We
may be able to work cooperatively on some aspect of it. The free software
world is challenging a lot of existing assumptions about how software is
developed, sold, and maintained throughout its life cycle, and we urge you
to at least give it a second look.What Is NeededThe following list of tasks and sub-projects represents something of
an amalgam of the various core team TODO lists and
user requests we have collected over the last couple of months. Where
possible, tasks have been ranked by degree of urgency. If you are
interested in working on one of the tasks you see here, send mail to the
coordinator listed by clicking on their names. If no coordinator has
been appointed, maybe you would like to volunteer?High priority tasksThe following tasks are considered to be urgent, usually because
they represent something that is badly broken or sorely needed:3-stage boot issues. Overall coordination: &a.hackers;Do WinNT compatible drive tagging so that the 3rd stage
can provide an accurate mapping of BIOS geometries for
disks.Filesystem problems. Overall coordination: &a.fs;Fix the MSDOS file system.Clean up and document the nullfs filesystem code.
Coordinator: &a.eivind;Fix the union file system. Coordinator: &a.dg;Implement Int13 vm86 disk driver. Coordinator:
&a.hackers;New bus architecture. Coordinator: &a.newbus;Port existing ISA drivers to new architecture.Move all interrupt-management code to appropriate parts of
the bus drivers.Port PCI subsystem to new architecture. Coordinator:
&a.dfr;Figure out the right way to handle removable devices and
then use that as a substrate on which PC-Card and CardBus
support can be implemented.Resolve the probe/attach priority issue once and for
all.Move any remaining buses over to the new
architecture.Kernel issues. Overall coordination: &a.hackers;Add more pro-active security infrastructure. Overall
coordination: &a.security;Build something like Tripwire(TM) into the kernel, with a
remote and local part. There are a number of cryptographic
issues to getting this right; contact the coordinator for
details. Coordinator: &a.eivind;Make the entire kernel use suser()
instead of comparing to 0. It is presently using about half
of each. Coordinator: &a.eivind;Split securelevels into different parts, to allow an
administrator to throw away those privileges he can throw
away. Setting the overall securelevel needs to have the same
effect as now, obviously. Coordinator: &a.eivind;Make it possible to upload a list of “allowed
program” to BPF, and then block BPF from accepting other
programs. This would allow BPF to be used e.g. for DHCP,
without allowing an attacker to start snooping the local
network.Update the security checker script. We should at least
grab all the checks from the other BSD derivatives, and add
checks that a system with securelevel increased also have
reasonable flags on the relevant parts. Coordinator:
&a.eivind;Add authorization infrastructure to the kernel, to allow
different authorization policies. Part of this could be done
by modifying suser(). Coordinatory:
&a.eivind;
- Add code to teh NFS layer so that you cannot
+ Add code to the NFS layer so that you cannot
chdir("..") out of an NFS partition. E.g.,
/usr is a UFS partition with
/usr/src NFS exported. Now it is
possible to use the NFS filehandle for
/usr/src to get access to
/usr.Medium priority tasksThe following tasks need to be done, but not with any particular
urgency:Full KLD based driver support/Configuration Manager.Write a configuration manager (in the 3rd stage boot?)
that probes your hardware in a sane manner, keeps only the
KLDs required for your hardware, etc.PCMCIA/PCCARD. Coordinators: &a.msmith; and &a.phk;Documentation!Reliable operation of the pcic driver (needs
testing).Recognizer and handler for sio.c
(mostly done).Recognizer and handler for ed.c
(mostly done).Recognizer and handler for ep.c
(mostly done).User-mode recognizer and handler (partially done).Advanced Power Management. Coordinators: &a.msmith; and
&a.phk;APM sub-driver (mostly done).IDE/ATA disk sub-driver (partially done).syscons/pcvt sub-driver.Integration with the PCMCIA/PCCARD drivers
(suspend/resume).Low priority tasksThe following tasks are purely cosmetic or represent such an
investment of work that it is not likely that anyone will get them
done anytime soon:The first N items are from Terry Lambert
terry@lambert.orgNetWare Server (protected mode ODI driver) loader and
subservices to allow the use of ODI card drivers supplied with
network cards. The same thing for NDIS drivers and NetWare SCSI
drivers.An "upgrade system" option that works on Linux boxes instead
of just previous rev FreeBSD boxes.Symmetric Multiprocessing with kernel preemption (requires
kernel preemption).A concerted effort at support for portable computers. This is
somewhat handled by changing PCMCIA bridging rules and power
management event handling. But there are things like detecting
internal vs. external display and picking a different screen
resolution based on that fact, not spinning down the disk if the
machine is in dock, and allowing dock-based cards to disappear
without affecting the machines ability to boot (same issue for
PCMCIA).Smaller tasksMost of the tasks listed in the previous sections require either a
considerable investment of time or an in-depth knowledge of the
FreeBSD kernel (or both). However, there are also many useful tasks
which are suitable for "weekend hackers", or people without
programming skills.If you run FreeBSD-current and have a good Internet
connection, there is a machine current.freebsd.org which builds a full
release once a day — every now and again, try and install
the latest release from it and report any failures in the
process.Read the freebsd-bugs mailing list. There
might be a problem you can comment constructively on or with
patches you can test. Or you could even try to fix one of the
problems yourself.Read through the FAQ and Handbook periodically. If anything
is badly explained, out of date or even just completely wrong, let
us know. Even better, send us a fix (SGML is not difficult to
learn, but there is no objection to ASCII submissions).Help translate FreeBSD documentation into your native language
(if not already available) — just send an email to &a.doc;
asking if anyone is working on it. Note that you are not
committing yourself to translating every single FreeBSD document
by doing this — in fact, the documentation most in need of
translation is the installation instructions.Read the freebsd-questions mailing list and &ng.misc
occasionally (or even regularly). It can be very satisfying to
share your expertise and help people solve their problems;
sometimes you may even learn something new yourself! These forums
can also be a source of ideas for things to work on.If you know of any bugfixes which have been successfully
applied to -current but have not been merged into -stable after a
decent interval (normally a couple of weeks), send the committer a
polite reminder.Move contributed software to src/contrib
in the source tree.Make sure code in src/contrib is up to
date.Look for year 2000 bugs (and fix any you find!)Build the source tree (or just part of it) with extra warnings
enabled and clean up the warnings.Fix warnings for ports which do deprecated things like using
gets() or including malloc.h.If you have contributed any ports, send your patches back to
the original author (this will make your life easier when they
bring out the next version)Suggest further tasks for this list!How to ContributeContributions to the system generally fall into one or more of the
following 6 categories:Bug reports and general commentaryAn idea or suggestion of general technical
interest should be mailed to the &a.hackers;. Likewise, people with
an interest in such things (and a tolerance for a
high volume of mail!) may subscribe to the
hackers mailing list by sending mail to &a.majordomo;. See mailing lists for more information
about this and other mailing lists.If you find a bug or are submitting a specific change, please
report it using the &man.send-pr.1; program or its WEB-based
equivalent. Try to fill-in each field of the bug report.
Unless they exceed 65KB, include any patches directly in the report.
Consider compressing them and using &man.uuencode.1; if they exceed
20KB. Upload very large submissions to ftp.freebsd.org:/pub/FreeBSD/incoming/.After filing a report, you should receive confirmation along with
a tracking number. Keep this tracking number so that you can update
us with details about the problem by sending mail to
bug-followup@FreeBSD.ORG. Use the number as the
message subject, e.g. "Re: kern/3377". Additional
information for any bug report should be submitted this way.If you do not receive confirmation in a timely fashion (3 days to
a week, depending on your email connection) or are, for some reason,
unable to use the &man.send-pr.1; command, then you may ask
someone to file it for you by sending mail to the &a.bugs;.Changes to the documentationChanges to the documentation are overseen by the &a.doc;. Send
submissions and changes (even small ones are welcome!) using
send-pr as described in Bug Reports and General
Commentary.Changes to existing source codeAn addition or change to the existing source code is a somewhat
trickier affair and depends a lot on how far out of date you are with
the current state of the core FreeBSD development. There is a special
on-going release of FreeBSD known as “FreeBSD-current”
which is made available in a variety of ways for the convenience of
developers working actively on the system. See Staying current with FreeBSD for more
information about getting and using FreeBSD-current.Working from older sources unfortunately means that your changes
may sometimes be too obsolete or too divergent for easy re-integration
into FreeBSD. Chances of this can be minimized somewhat by
subscribing to the &a.announce; and the &a.current; lists, where
discussions on the current state of the system take place.Assuming that you can manage to secure fairly up-to-date sources
to base your changes on, the next step is to produce a set of diffs to
send to the FreeBSD maintainers. This is done with the &man.diff.1;
command, with the “context diff” form
being preferred. For example:&prompt.user; diff -c oldfile newfile
or
&prompt.user; diff -c -r olddir newdir
would generate such a set of context diffs for the given source file
or directory hierarchy. See the man page for &man.diff.1; for more
details.Once you have a set of diffs (which you may test with the
&man.patch.1; command), you should submit them for inclusion with
FreeBSD. Use the &man.send-pr.1; program as described in Bug Reports and General Commentary.
Do not just send the diffs to the &a.hackers; or
they will get lost! We greatly appreciate your submission (this is a
volunteer project!); because we are busy, we may not be able to
address it immediately, but it will remain in the pr database until we
do.If you feel it appropriate (e.g. you have added, deleted, or
renamed files), bundle your changes into a tar file
and run the &man.uuencode.1; program on it. Shar archives are also
welcome.If your change is of a potentially sensitive nature, e.g. you are
unsure of copyright issues governing its further distribution or you
are simply not ready to release it without a tighter review first,
then you should send it to &a.core; directly rather than submitting it
with &man.send-pr.1;. The core mailing list reaches a much smaller
group of people who do much of the day-to-day work on FreeBSD. Note
that this group is also very busy and so you
should only send mail to them where it is truly necessary.Please refer to man 9 intro and man 9
style for some information on coding style. We would
appreciate it if you were at least aware of this information before
submitting code.New code or major value-added packagesIn the rare case of a significant contribution of a large body
work, or the addition of an important new feature to FreeBSD, it
becomes almost always necessary to either send changes as uuencode'd
tar files or upload them to our ftp site ftp://ftp.FreeBSD.ORG/pub/FreeBSD/incoming.When working with large amounts of code, the touchy subject of
copyrights also invariably comes up. Acceptable copyrights for code
included in FreeBSD are:The BSD copyright. This copyright is most preferred due to
its “no strings attached” nature and general
attractiveness to commercial enterprises. Far from discouraging
such commercial use, the FreeBSD Project actively encourages such
participation by commercial interests who might eventually be
inclined to invest something of their own into FreeBSD.The GNU Public License, or “GPL”. This license is
not quite as popular with us due to the amount of extra effort
demanded of anyone using the code for commercial purposes, but
given the sheer quantity of GPL'd code we currently require
(compiler, assembler, text formatter, etc) it would be silly to
refuse additional contributions under this license. Code under
the GPL also goes into a different part of the tree, that being
/sys/gnu or
/usr/src/gnu, and is therefore easily
identifiable to anyone for whom the GPL presents a problem.Contributions coming under any other type of copyright must be
carefully reviewed before their inclusion into FreeBSD will be
considered. Contributions for which particularly restrictive
commercial copyrights apply are generally rejected, though the authors
are always encouraged to make such changes available through their own
channels.To place a “BSD-style” copyright on your work, include
the following text at the very beginning of every source code file you
wish to protect, replacing the text between the %%
with the appropriate information.
Copyright (c) %%proper_years_here%%
%%your_name_here%%, %%your_state%% %%your_zip%%.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer as
the first lines of this file unmodified.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY %%your_name_here%% ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL %%your_name_here%% BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
$Id$For your convenience, a copy of this text can be found in
/usr/share/examples/etc/bsd-style-copyright.Money, Hardware or Internet accessWe are always very happy to accept donations to further the cause
of the FreeBSD Project and, in a volunteer effort like ours, a little
can go a long way! Donations of hardware are also very important to
expanding our list of supported peripherals since we generally lack
the funds to buy such items ourselves.Donating fundsWhile the FreeBSD Project is not a 501(c)(3) (charitable)
corporation and hence cannot offer special tax incentives for any
donations made, any such donations will be gratefully accepted on
behalf of the project by FreeBSD, Inc.FreeBSD, Inc. was founded in early 1995 by &a.jkh; and &a.dg;
with the goal of furthering the aims of the FreeBSD Project and
giving it a minimal corporate presence. Any and all funds donated
(as well as any profits that may eventually be realized by FreeBSD,
Inc.) will be used exclusively to further the project's
goals.Please make any checks payable to FreeBSD, Inc., sent in care of
the following address:FreeBSD, Inc.c/o Jordan Hubbard4041 Pike Lane, Suite FConcordCA, 94520(currently using the Walnut Creek CDROM address until a PO box
can be opened)Wire transfers may also be sent directly to:Bank Of AmericaConcord Main OfficeP.O. Box 37176San FranciscoCA, 94137-5176Routing #: 121-000-358Account #: 01411-07441 (FreeBSD, Inc.)Any correspondence related to donations should be sent to Jordan
Hubbard jkh@FreeBSD.org, either via email or to the
FreeBSD, Inc. postal address given above.If you do not wish to be listed in our donors section, please specify this when
making your donation. Thanks!Donating hardwareDonations of hardware in any of the 3 following categories are
also gladly accepted by the FreeBSD Project:General purpose hardware such as disk drives, memory or
complete systems should be sent to the FreeBSD, Inc. address
listed in the donating funds
section.Hardware for which ongoing compliance testing is desired.
We are currently trying to put together a testing lab of all
components that FreeBSD supports so that proper regression
testing can be done with each new release. We are still lacking
many important pieces (network cards, motherboards, etc) and if
you would like to make such a donation, please contact &a.dg;
for information on which items are still required.Hardware currently unsupported by FreeBSD for which you
would like to see such support added. Please contact the
&a.core; before sending such items as we will need to find a
developer willing to take on the task before we can accept
delivery of new hardware.Donating Internet accessWe can always use new mirror sites for FTP, WWW or
cvsup. If you would like to be such a mirror,
please contact the FreeBSD project administrators
admin@FreeBSD.ORG for more information.Donors GalleryThe FreeBSD Project is indebted to the following donors and would
like to publically thank them here!Contributors to the central server
project:The following individuals and businesses made it possible for
the FreeBSD Project to build a new central server machine to
eventually replace freefall.freebsd.org
by donating the following items:Ade Barkah mbarkah@freebsd.org and his
employer, Hemisphere
Online, donated a Pentium Pro (P6) 200Mhz
CPUASA
Computers donated a Tyan 1662
motherboard.Joe McGuckin joe@via.net of ViaNet Communications donated
a Kingston ethernet controller.Jack O'Neill jack@diamond.xtalwind.net
donated an NCR 53C875 SCSI controller
card.Ulf Zimmermann ulf@Alameda.net of Alameda Networks donated
128MB of memory, a 4 Gb disk
drive and the case.Direct funding:The following individuals and businesses have generously
contributed direct funding to the project:Annelise Anderson
ANDRSN@HOOVER.STANFORD.EDUMatt Dillon dillon@best.netEpilogue Technology
CorporationSean Eric FaganDon Scott WildeGianmarco Giovannelli
gmarco@masternet.itJosef C. Grosch joeg@truenorth.orgRobert T. MorrisChuck Robey chuckr@freebsd.orgKenneth P. Stox ken@stox.sa.enteract.com of
Imaginary Landscape,
LLC.Dmitry S. Kohmanyuk dk@dog.farm.orgLaser5 of Japan
(a portion of the profits from sales of their various FreeBSD
CD-ROMs.Fuki Shuppan
Publishing Co. donated a portion of their profits from
Hajimete no FreeBSD (FreeBSD, Getting
started) to the FreeBSD and XFree86 projects.ASCII Corp.
donated a portion of their profits from several FreeBSD-related
books to the FreeBSD project.Yokogawa Electric
Corp has generously donated significant funding to the
FreeBSD project.BuffNETPacific
SolutionsSiemens AG
via Andre
AlbsmeierChris SilvaHardware contributors:The following individuals and businesses have generously
contributed hardware for testing and device driver
development/support:Walnut Creek CDROM for providing the Pentium P5-90 and
486/DX2-66 EISA/VL systems that are being used for our
development work, to say nothing of the network access and other
donations of hardware resources.TRW Financial Systems, Inc. provided 130 PCs, three 68 GB
fileservers, twelve Ethernets, two routers and an ATM switch for
debugging the diskless code.Dermot McDonnell donated the Toshiba XM3401B CDROM drive
currently used in freefall.&a.chuck; contributed his floppy tape streamer for
experimental work.Larry Altneu larry@ALR.COM, and &a.wilko;,
provided Wangtek and Archive QIC-02 tape drives in order to
improve the wt driver.Ernst Winter ewinter@lobo.muc.de contributed
a 2.88 MB floppy drive to the project. This will hopefully
increase the pressure for rewriting the floppy disk driver.
;-)Tekram
Technologies sent one each of their DC-390, DC-390U
and DC-390F FAST and ULTRA SCSI host adapter cards for
regression testing of the NCR and AMD drivers with their cards.
They are also to be applauded for making driver sources for free
operating systems available from their FTP server ftp://ftp.tekram.com/scsi/FreeBSD.Larry M. Augustin contributed not only a
Symbios Sym8751S SCSI card, but also a set of data books,
including one about the forthcoming Sym53c895 chip with Ultra-2
and LVD support, and the latest programming manual with
information on how to safely use the advanced features of the
latest Symbios SCSI chips. Thanks a lot!Christoph Kukulies kuku@freebsd.org donated
an FX120 12 speed Mitsumi CDROM drive for IDE CDROM driver
development.Special contributors:Walnut Creek CDROM
has donated almost more than we can say (see the history document for more details).
In particular, we would like to thank them for the original
hardware used for freefall.FreeBSD.ORG, our primary
development machine, and for thud.FreeBSD.ORG, a testing and build
box. We are also indebted to them for funding various
contributors over the years and providing us with unrestricted
use of their T1 connection to the Internet.The interface
business GmbH, Dresden has been patiently supporting
&a.joerg; who has often preferred FreeBSD work over paywork, and
used to fall back to their (quite expensive) EUnet Internet
connection whenever his private connection became too slow or
flakey to work with it...Berkeley Software Design,
Inc. has contributed their DOS emulator code to the
remaining BSD world, which is used in the
dosemu command.Core Team AlumnusThe following people were members of the FreeBSD core team during
the period indicated. We thank them for their past efforts in the
service of the FreeBSD project.In rough chronological order:Guido van Rooij (1995 - 1999)John Dyson (1993 - 1998)Nate Williams (1992 - 1996)Rod Grimes (1992 - 1995)Andreas Schulz (1992 - 1995)Geoff Rehmet (1993 - 1995)Paul Richards (1992 - 1995)Scott Mace (1993 - 1994)Andrew Moore (1993 - 1994)Christoph Robitschko (1993 - 1994)J. T. Conklin (1992 - 1993)Derived Software ContributorsThis software was originally derived from William F. Jolitz's 386BSD
release 0.1, though almost none of the original 386BSD specific code
remains. This software has been essentially re-implemented from the
4.4BSD-Lite release provided by the Computer Science Research Group
(CSRG) at the University of California, Berkeley and associated academic
contributors.There are also portions of NetBSD and OpenBSD that have been
integrated into FreeBSD as well, and we would therefore like to thank
all the contributors to NetBSD and OpenBSD for their work.Additional FreeBSD Contributors(in alphabetical order by first name):ABURAYA Ryushirou rewsirow@ff.iij4u.or.jpAMAGAI Yoshiji amagai@nue.orgAaron Bornstein aaronb@j51.comAaron Smith aaron@tau.veritas.comAchim Patzner ap@noses.comAda T Lim ada@bsd.orgAdam Baran badam@mw.mil.plAdam Glass glass@postgres.berkeley.eduAdam McDougall mcdouga9@egr.msu.eduAdrian Colley aecolley@ois.ieAdrian Hall adrian@ibmpcug.co.ukAdrian Mariano adrian@cam.cornell.eduAdrian Steinmann ast@marabu.chAdrian T. Filipi-Martin
atf3r@agate.cs.virginia.eduAjit Thyagarajan unknownAkio Morita
amorita@meadow.scphys.kyoto-u.ac.jpAkira SAWADA unknownAkira Watanabe
akira@myaw.ei.meisei-u.ac.jpAkito Fujita fujita@zoo.ncl.omron.co.jpAlain Kalker
A.C.P.M.Kalker@student.utwente.nlAlan Bawden alan@curry.epilogue.comAlan Cox alc@cs.rice.eduAlec Wolman wolman@cs.washington.eduAled Morris aledm@routers.co.ukAlex garbanzo@hooked.netAlex D. Chen
dhchen@Canvas.dorm7.nccu.edu.twAlex G. Bulushev bag@demos.suAlex Le Heux alexlh@funk.orgAlexander B. Povolotsky tarkhil@mgt.msk.ruAlexander Leidinger
netchild@wurzelausix.CS.Uni-SB.DEAlexandre Snarskii snar@paranoia.ruAlistair G. Crooks agc@uts.amdahl.comAllan Saddi asaddi@philosophysw.comAllen Campbell allenc@verinet.comAmakawa Shuhei amakawa@hoh.t.u-tokyo.ac.jpAmancio Hasty hasty@star-gate.comAmir Farah amir@comtrol.comAmy Baron amee@beer.orgAnatoly A. Orehovsky tolik@mpeks.tomsk.suAnatoly Vorobey mellon@pobox.comAnders Nordby nickerne@nome.noAnders Thulin Anders.X.Thulin@telia.seAndras Olah olah@cs.utwente.nlAndre Albsmeier
Andre.Albsmeier@mchp.siemens.deAndre Oppermann andre@pipeline.chAndreas Haakh ah@alman.robin.deAndreas Kohout shanee@rabbit.augusta.deAndreas Lohr andreas@marvin.RoBIN.deAndreas Schulz unknownAndreas Wetzel mickey@deadline.snafu.deAndreas Wrede andreas@planix.comAndres Vega Garcia unknownAndrew Atrens atreand@statcan.caAndrew Gillham gillham@andrews.eduAndrew Gordon andrew.gordon@net-tel.co.ukAndrew Herbert andrew@werple.apana.org.auAndrew J. Korty ajk@purdue.eduAndrew L. Moore alm@mclink.comAndrew McRae amcrae@cisco.comAndrew Stevenson andrew@ugh.net.auAndrew Timonin tim@pool1.convey.ruAndrew V. Stesin stesin@elvisti.kiev.uaAndrew Webster awebster@dataradio.comAndrey Zakhvatov andy@icc.surw.chel.suAndy Farkas andyf@speednet.com.auAndy Valencia ajv@csd.mot.comAndy Whitcroft andy@sarc.city.ac.ukAngelo Turetta ATuretta@stylo.itAnthony C. Chavez magus@xmission.comAnthony Yee-Hang Chan yeehang@netcom.comAnton Berezin tobez@plab.ku.dkAntti Kaipila anttik@iki.fiAre Bryne are.bryne@communique.noAri Suutari ari@suutari.iki.fiArjan de Vet devet@IAEhv.nlArne Henrik Juul arnej@Lise.Unit.NOAssar Westerlund assar@sics.seAtsushi Furuta furuta@sra.co.jpAtsushi Murai amurai@spec.co.jpBakul Shah bvs@bitblocks.comBarry Bierbauch pivrnec@vszbr.czBarry Lustig barry@ictv.comBen Hutchinson benhutch@xfiles.org.ukBen Jackson unknownBen Smithurst ben@scientia.demon.co.ukBen Walter bwalter@itachi.swcp.comBenjamin Lewis bhlewis@gte.netBernd Rosauer br@schiele-ct.deBill Kish kish@osf.orgBill Trost trost@cloud.rain.comBlaz Zupan blaz@amis.netBob Van Valzah Bob@whitebarn.comBob Willcox bob@luke.pmr.comBoris Staeblow balu@dva.in-berlin.deBoyd R. Faulkner faulkner@asgard.bga.comBrad Karp karp@eecs.harvard.eduBradley Dunn bradley@dunn.orgBrandon Gillespie brandon@roguetrader.com&a.wlloydBob Wilcox bob@obiwan.uucpBoyd Faulkner faulkner@mpd.tandem.comBrent J. Nordquist bjn@visi.comBrett Lymn blymn@mulga.awadi.com.AUBrett Taylor
brett@peloton.physics.montana.eduBrian Campbell brianc@pobox.comBrian Clapper bmc@willscreek.comBrian Cully shmit@kublai.comBrian F. Feldman green@unixhelp.orgBrian Handy
handy@lambic.space.lockheed.comBrian Litzinger brian@MediaCity.comBrian McGovern bmcgover@cisco.comBrian Moore ziff@houdini.eecs.umich.eduBrian R. Haug haug@conterra.comBrian Tao taob@risc.orgBrion Moss brion@queeg.comBruce A. Mah bmah@ca.sandia.govBruce Albrecht bruce@zuhause.mn.orgBruce Gingery bgingery@gtcs.comBruce J. Keeler loodvrij@gridpoint.comBruce Murphy packrat@iinet.net.auBruce Walter walter@fortean.comCarey Jones mcj@acquiesce.orgCarl Fongheiser cmf@netins.netCarl Mascott cmascott@world.std.comCasper casper@acc.amCastor Fu castor@geocast.comCejka Rudolf cejkar@dcse.fee.vutbr.czChain Lee chain@110.netCharles Hannum mycroft@ai.mit.eduCharles Henrich henrich@msu.eduCharles Mott cmott@srv.netCharles Owens owensc@enc.eduChet Ramey chet@odin.INS.CWRU.EduChia-liang Kao clkao@CirX.ORGChiharu Shibata chi@bd.mbn.or.jpChip Norkus unknownChoi Jun Ho junker@jazz.snu.ac.krChris Costello chris@holly.dyndns.orgChris Csanady cc@tarsier.ca.sandia.govChris Dabrowski chris@vader.orgChris Dillon cdillon@wolves.k12.mo.usChris Piazza cpiazza@home.netChris Shenton
cshenton@angst.it.hq.nasa.govChris Stenton jacs@gnome.co.ukChris Timmons skynyrd@opus.cts.cwu.eduChris Torek torek@ee.lbl.govChristian Gusenbauer
cg@fimp01.fim.uni-linz.ac.atChristian Haury Christian.Haury@sagem.frChristian Weisgerber
naddy@bigeye.rhein-neckar.deChristoph P. Kukulies kuku@FreeBSD.orgChristoph Robitschko
chmr@edvz.tu-graz.ac.atChristoph Weber-Fahr
wefa@callcenter.systemhaus.netChristopher G. Demetriou
cgd@postgres.berkeley.eduChristopher T. Johnson
cjohnson@neunacht.netgsi.comChrisy Luke chrisy@flix.netChuck Hein chein@cisco.comClive Lin clive@CiRX.ORGColman Reilly careilly@tcd.ieConrad Sabatier conrads@neosoft.comCoranth Gryphon gryphon@healer.comCornelis van der Laan
nils@guru.ims.uni-stuttgart.deCove Schneider cove@brazil.nbn.comCraig Leres leres@ee.lbl.govCraig Loomis unknownCraig Metz cmetz@inner.netCraig Spannring cts@internetcds.comCraig Struble cstruble@vt.eduCristian Ferretti cfs@riemann.mat.puc.clCurt Mayer curt@toad.comCy Schubert cschuber@uumail.gov.bc.caDI. Christian Gusenbauer
cg@scotty.edvz.uni-linz.ac.atDai Ishijima ishijima@tri.pref.osaka.jpDamian Hamill damian@cablenet.netDan Cross tenser@spitfire.ecsel.psu.eduDan Lukes dan@obluda.czDan Nelson dnelson@emsphone.comDan Walters hannibal@cyberstation.netDaniel Baker dbaker@crash.ops.neosoft.comDaniel M. Eischen
deischen@iworks.InterWorks.orgDaniel O'Connor doconnor@gsoft.com.auDaniel Poirot poirot@aio.jsc.nasa.govDaniel Rock rock@cs.uni-sb.deDanny Egen unknownDanny J. Zerkel dzerkel@phofarm.comDarren Reed avalon@coombs.anu.edu.auDave Adkins adkin003@tc.umn.eduDave Andersen angio@aros.netDave Blizzard dblizzar@sprynet.comDave Bodenstab imdave@synet.netDave Burgess burgess@hrd769.brooks.af.milDave Chapeskie dchapes@ddm.on.caDave Cornejo dave@dogwood.comDave Edmondson davided@sco.comDave Glowacki dglo@ssec.wisc.eduDave Marquardt marquard@austin.ibm.comDave Tweten tweten@FreeBSD.orgDavid A. Adkins adkin003@tc.umn.eduDavid A. Bader dbader@umiacs.umd.eduDavid Borman dab@bsdi.comDavid Dawes dawes@XFree86.orgDavid Filo filo@yahoo.comDavid Holland dholland@eecs.harvard.eduDavid Holloway daveh@gwythaint.tamis.comDavid Horwitt dhorwitt@ucsd.eduDavid Hovemeyer daveho@infocom.comDavid Jones dej@qpoint.torfree.netDavid Kelly dkelly@tomcat1.tbe.comDavid Kulp dkulp@neomorphic.comDavid L. Nugent davidn@blaze.net.auDavid Leonard d@scry.dstc.edu.auDavid Malone dwmalone@maths.tcd.ieDavid Muir Sharnoff muir@idiom.comDavid S. Miller davem@jenolan.rutgers.eduDavid Wolfskill dhw@whistle.comDean Gaudet dgaudet@arctic.orgDean Huxley dean@fsa.caDenis Fortin unknownDennis Glatting
dennis.glatting@software-munitions.comDenton Gentry denny1@home.comDerek Inksetter derek@saidev.comDima Sivachenko dima@Chg.RUDirk Keunecke dk@panda.rhein-main.deDirk Nehrling nerle@pdv.deDmitry Khrustalev dima@xyzzy.machaon.ruDmitry Kohmanyuk dk@farm.orgDom Mitchell dom@myrddin.demon.co.ukDon Croyle croyle@gelemna.ft-wayne.in.us&a.whiteside;Don Morrison dmorrisn@u.washington.eduDon Yuniskis dgy@rtd.comDonald Maddox dmaddox@conterra.comDoug Barton studded@dal.netDouglas Ambrisko ambrisko@whistle.comDouglas Carmichael dcarmich@mcs.comDouglas Crosher dtc@scrooge.ee.swin.oz.auDrew Derbyshire ahd@kew.comDuncan Barclay dmlb@ragnet.demon.co.ukDustin Sallings dustin@spy.netEckart "Isegrim" Hofmann
Isegrim@Wunder-Nett.orgEd Gold
vegold01@starbase.spd.louisville.eduEd Hudson elh@p5.spnet.comEdward Wang edward@edcom.comEdwin Groothus edwin@nwm.wan.philips.comEiji-usagi-MATSUmoto usagi@clave.gr.jpELISA Font ProjectElmar Bartel
bartel@informatik.tu-muenchen.deEric A. Griff eagriff@global2000.netEric Blood eblood@cs.unr.eduEric J. Haug ejh@slustl.slu.eduEric J. Schwertfeger eric@cybernut.comEric L. Hernes erich@lodgenet.comEric P. Scott eps@sirius.comEric Sprinkle eric@ennovatenetworks.comErich Stefan Boleyn erich@uruk.orgErik E. Rantapaa rantapaa@math.umn.eduErik H. Moe ehm@cris.comErnst Winter ewinter@lobo.muc.deEugene M. Kim astralblue@usa.netEugene Radchenko genie@qsar.chem.msu.suEvan Champion evanc@synapse.netFaried Nawaz fn@Hungry.COMFlemming Jacobsen fj@tfs.comFong-Ching Liaw fong@juniper.netFrancis M J Hsieh mjshieh@life.nthu.edu.twFrank Bartels knarf@camelot.deFrank Chen Hsiung Chan
frankch@waru.life.nthu.edu.twFrank Durda IV uhclem@nemesis.lonestar.orgFrank MacLachlan fpm@n2.netFrank Nobis fn@Radio-do.deFrank Volf volf@oasis.IAEhv.nlFrank ten Wolde franky@pinewood.nlFrank van der Linden frank@fwi.uva.nlFred Cawthorne fcawth@jjarray.umn.eduFred Gilham gilham@csl.sri.comFred Templin templin@erg.sri.comFrederick Earl Gray fgray@rice.eduFUJIMOTO Kensaku
fujimoto@oscar.elec.waseda.ac.jpFUJISHIMA Satsuki k5@respo.or.jpFURUSAWA Kazuhisa
furusawa@com.cs.osakafu-u.ac.jpGabor Kincses gabor@acm.orgGabor Zahemszky zgabor@CoDe.huGarance A Drosehn gad@eclipse.its.rpi.eduGareth McCaughan gjm11@dpmms.cam.ac.ukGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGary J. garyj@rks32.pcs.dec.comGary Kline kline@thought.orgGaspar Chilingarov nightmar@lemming.acc.amGea-Suan Lin gsl@tpts4.seed.net.twGeoff Rehmet csgr@alpha.ru.ac.zaGeorg Wagner georg.wagner@ubs.comGerard Roudier groudier@club-internet.frGianmarco Giovannelli
gmarco@giovannelli.itGil Kloepfer Jr. gil@limbic.ssdl.comGilad Rom rom_glsa@ein-hashofet.co.ilGinga Kawaguti
ginga@amalthea.phys.s.u-tokyo.ac.jpGiles Lean giles@nemeton.com.auGlen Foster gfoster@gfoster.comGlenn Johnson gljohns@bellsouth.netGodmar Back gback@facility.cs.utah.eduGoran Hammarback goran@astro.uu.seGord Matzigkeit gord@enci.ucalgary.caGordon Greeff gvg@uunet.co.zaGraham Wheeler gram@cdsec.comGreg A. Woods woods@zeus.leitch.comGreg Ansley gja@ansley.comGreg Troxel gdt@ir.bbn.comGreg Ungerer gerg@stallion.oz.auGregory Bond gnb@itga.com.auGregory D. Moncreaff
moncrg@bt340707.res.ray.comGuy Harris guy@netapp.comGuy Helmer ghelmer@cs.iastate.eduHAMADA Naoki hamada@astec.co.jpHONDA Yasuhiro
honda@kashio.info.mie-u.ac.jpHOSOBUCHI Noriyuki hoso@buchi.tama.or.jpHannu Savolainen hannu@voxware.pp.fiHans Huebner hans@artcom.deHans Petter Bieker zerium@webindex.noHans Zuidam hans@brandinnovators.comHarlan Stenn Harlan.Stenn@pfcs.comHarold Barker hbarker@dsms.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHeikki Suonsivu hsu@cs.hut.fiHeiko W. Rupp unknownHelmut F. Wirth hfwirth@ping.atHenrik Vestergaard Draboel
hvd@terry.ping.dkHerb Peyerl hpeyerl@NetBSD.orgHideaki Ohmon ohmon@tom.sfc.keio.ac.jpHidekazu Kuroki hidekazu@cs.titech.ac.jpHideki Yamamoto hyama@acm.orgHidetoshi Shimokawa
simokawa@sat.t.u-tokyo.ac.jpHideyuki Suzuki
hideyuki@sat.t.u-tokyo.ac.jpHirayama Issei iss@mail.wbs.ne.jpHiroaki Sakai sakai@miya.ee.kagu.sut.ac.jpHiroharu Tamaru tamaru@ap.t.u-tokyo.ac.jpHironori Ikura hikura@kaisei.orgHiroshi Nishikawa nis@pluto.dti.ne.jpHiroya Tsubakimoto unknownHiroyuki NAKAJI
nakaji@zeisei3.dpri.kyoto-u.ac.jpHolger Veit Holger.Veit@gmd.deHolm Tiffe holm@geophysik.tu-freiberg.deHorance Chou
horance@freedom.ie.cycu.edu.twHorihiro Kumagaio kuma@jp.freebsd.orgHr.Ladavac lada@ws2301.gud.siemens.co.atHubert Feyrer hubertf@NetBSD.ORGHugh F. Mahon hugh@nsmdserv.cnd.hp.comHugh Mahon h_mahon@fc.hp.comHung-Chi Chu hcchu@r350.ee.ntu.edu.twIMAI Takeshi take-i@ceres.dti.ne.jpIMAMURA Tomoaki
tomoak-i@is.aist-nara.ac.jpIan Dowse iedowse@maths.tcd.ieIan Holland ianh@tortuga.com.auIan Struble ian@broken.netIan Vaudrey i.vaudrey@bigfoot.comIgor Khasilev igor@jabber.paco.odessa.uaIgor Roshchin str@giganda.komkon.orgIgor Sviridov siac@ua.netIgor Vinokurov igor@zynaps.ruIkuo Nakagawa ikuo@isl.intec.co.jpIlya V. Komarov mur@lynx.ruIssei Suzuki issei@jp.FreeBSD.orgItsuro Saito saito@miv.t.u-tokyo.ac.jpJ. Bryant jbryant@argus.flash.netJ. David Lowe lowe@saturn5.comJ. Han hjh@best.comJ. Hawk jhawk@MIT.EDUJ.T. Conklin jtc@cygnus.comJ.T. Jang keith@email.gcn.net.twJack jack@zeus.xtalwind.netJacob Bohn Lorensen jacob@jblhome.ping.mkJagane D Sundar jagane@netcom.comJake Hamby jehamby@lightside.comJames Clark jjc@jclark.comJames D. Stewart jds@c4systm.comJames Jegers jimj@miller.cs.uwm.eduJames Raynard
fhackers@jraynard.demon.co.ukJames T. Liu jtliu@phlebas.rockefeller.eduJames da Silva jds@cs.umd.eduJan Conard
charly@fachschaften.tu-muenchen.deJan Koum jkb@FreeBSD.orgJanick Taillandier
Janick.Taillandier@ratp.frJanusz Kokot janek@gaja.ipan.lublin.plJarle Greipsland jarle@idt.unit.noJason Garman init@risen.orgJason Thorpe thorpej@NetBSD.orgJason Wright jason@OpenBSD.orgJason Young
doogie@forbidden-donut.anet-stl.comJavier Martin Rueda jmrueda@diatel.upm.esJay Fenlason hack@datacube.comJaye Mathisen mrcpu@cdsnet.netJeff Bartig jeffb@doit.wisc.eduJeff Forys jeff@forys.cranbury.nj.usJeff Kletsky Jeff@Wagsky.comJeffrey Evans evans@scnc.k12.mi.usJeffrey Wheat jeff@cetlink.netJens Schweikhardt schweikh@noc.dfn.dJeremy Allison jallison@whistle.comJeremy Chatfield jdc@xinside.comJeremy Lea reg@shale.csir.co.zaJeremy Prior unknownJeroen Ruigrok/Asmodai asmodai@wxs.nlJesse Rosenstock jmr@ugcs.caltech.eduJian-Da Li jdli@csie.nctu.edu.twJim Babb babb@FreeBSD.orgJim Binkley jrb@cs.pdx.eduJim Carroll jim@carroll.comJim Flowers jflowers@ezo.netJim Leppek jleppek@harris.comJim Lowe james@cs.uwm.eduJim Mattson jmattson@sonic.netJim Mercer jim@komodo.reptiles.orgJim Mock jim@phrantic.phear.netJim Wilson wilson@moria.cygnus.comJimbo Bahooli
griffin@blackhole.iceworld.orgJin Guojun jin@george.lbl.govJoachim Kuebart unknownJoao Carlos Mendes Luis jonny@jonny.eng.brJochen Pohl jpo.drs@sni.deJoe "Marcus" Clarke marcus@miami.eduJoe Abley jabley@clear.co.nzJoe Jih-Shian Lu jslu@dns.ntu.edu.twJoe Orthoefer j_orthoefer@tia.netJoe Traister traister@mojozone.orgJoel Faedi Joel.Faedi@esial.u-nancy.frJoel Ray Holveck joelh@gnu.orgJoel Sutton sutton@aardvark.apana.org.auJohan Granlund johan@granlund.nuJohan Karlsson k@numeri.campus.luth.seJohan Larsson johan@moon.campus.luth.seJohann Tonsing jtonsing@mikom.csir.co.zaJohannes Helander unknownJohannes Stille unknownJohn Baldwin jobaldwi@vt.eduJohn Beckett jbeckett@southern.eduJohn Beukema jbeukema@hk.super.netJohn Brezak unknownJohn Capo jc@irbs.comJohn F. Woods jfw@jfwhome.funhouse.comJohn Goerzen
jgoerzen@alexanderwohl.complete.orgJohn Hay jhay@mikom.csir.co.zaJohn Heidemann johnh@isi.eduJohn Hood cgull@owl.orgJohn Kohl unknownJohn Lind john@starfire.mn.orgJohn Mackin john@physiol.su.oz.auJohn P johnp@lodgenet.comJohn Perry perry@vishnu.alias.netJohn Preisler john@vapornet.comJohn Rochester jr@cs.mun.caJohn Sadler john_sadler@alum.mit.eduJohn Saunders john@pacer.nlc.net.auJohn W. DeBoskey jwd@unx.sas.comJohn Wehle john@feith.comJohn Woods jfw@eddie.mit.eduJon Morgan morgan@terminus.trailblazer.comJonathan H N Chin jc254@newton.cam.ac.ukJonathan Hanna
jh@pc-21490.bc.rogers.wave.caJorge Goncalves j@bug.fe.up.ptJorge M. Goncalves ee96199@tom.fe.up.ptJos Backus jbackus@plex.nlJose M. Alcaide jose@we.lc.ehu.esJosef Grosch
jgrosch@superior.mooseriver.comJosef Karthauser joe@uk.freebsd.orgJoseph Stein joes@wstein.comJosh Gilliam josh@quick.netJosh Tiefenbach josh@ican.netJuergen Lock nox@jelal.hb.north.deJuha Inkari inkari@cc.hut.fiJukka A. Ukkonen jua@iki.fiJulian Assange proff@suburbia.netJulian Coleman j.d.coleman@ncl.ac.ukJulian H. Stacey jhs@freebsd.orgJulian Jenkins kaveman@magna.com.auJunichi Satoh junichi@jp.freebsd.orgJunji SAKAI sakai@jp.freebsd.orgJunya WATANABE junya-w@remus.dti.ne.jpK.Higashino a00303@cc.hc.keio.ac.jpKUNISHIMA Takeo kunishi@c.oka-pu.ac.jpKai Vorma vode@snakemail.hut.fiKaleb S. Keithley kaleb@ics.comKaneda Hiloshi vanitas@ma3.seikyou.ne.jpKapil Chowksey kchowksey@hss.hns.comKarl Denninger karl@mcs.comKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comKato Takenori
kato@eclogite.eps.nagoya-u.ac.jpKawanobe Koh kawanobe@st.rim.or.jpKazuhiko Kiriyama kiri@kiri.toba-cmt.ac.jpKazuo Horikawa horikawa@jp.FreeBSD.orgKees Jan Koster kjk1@ukc.ac.ukKeith Bostic bostic@bostic.comKeith E. Walker unknownKeith Moore unknownKeith Sklower unknownKen Hornstein unknownKen Key key@cs.utk.eduKen Mayer kmayer@freegate.comKenji Saito marukun@mx2.nisiq.netKenji Tomita tommyk@da2.so-net.or.jpKenneth Furge kenneth.furge@us.endress.comKenneth Monville desmo@bandwidth.orgKenneth R. Westerback krw@tcn.netKenneth Stailey kstailey@gnu.ai.mit.eduKent Talarico kent@shipwreck.tsoft.netKent Vander Velden graphix@iastate.eduKentaro Inagaki JBD01226@niftyserve.ne.jpKevin Bracey kbracey@art.acorn.co.ukKevin Day toasty@dragondata.comKevin Lahey kml@nas.nasa.govKevin Street street@iname.comKevin Van Maren vanmaren@fast.cs.utah.eduKiroh HARADA kiroh@kh.rim.or.jpKlaus Klein kleink@layla.inka.deKlaus-J. Wolf Yanestra@t-online.deKoichi Sato copan@ppp.fastnet.or.jpKostya Lukin lukin@okbmei.msk.suKouichi Hirabayashi kh@mogami-wire.co.jpKurt D. Zeilenga Kurt@Boolean.NETKurt Olsen kurto@tiny.mcs.usu.eduL. Jonas Olsson
ljo@ljo-slip.DIALIN.CWRU.EduLars Köller
Lars.Koeller@Uni-Bielefeld.DELarry Altneu larry@ALR.COMLaurence Lopez lopez@mv.mv.comLee Cremeans lcremean@tidalwave.netLiang Tai-hwa
avatar@www.mmlab.cse.yzu.edu.twLon Willett lon%softt.uucp@math.utah.eduLouis A. Mamakos louie@TransSys.COMLouis Mamakos loiue@TransSys.comLucas James Lucas.James@ldjpc.apana.org.auLyndon Nerenberg lyndon@orthanc.comM.C. Wong unknownMANTANI Nobutaka nobutaka@nobutaka.comMIHIRA Sanpei Yoshiro sanpei@sanpei.orgMITA Yoshio mita@jp.FreeBSD.ORGMITSUNAGA Noriaki
mitchy@er.ams.eng.osaka-u.ac.jpMOROHOSHI Akihiko moro@race.u-tokyo.ac.jpMagnus Enbom dot@tinto.campus.luth.seMahesh Neelakanta mahesh@gcomm.comMakoto MATSUSHITA matusita@jp.freebsd.orgMakoto WATANABE
watanabe@zlab.phys.nagoya-u.ac.jpMalte Lance malte.lance@gmx.netManu Iyengar
iyengar@grunthos.pscwa.psca.comMarc Frajola marc@dev.comMarc Ramirez mrami@mramirez.sy.yale.eduMarc Slemko marcs@znep.comMarc van Kempen wmbfmk@urc.tue.nlMarcel Moolenaar marcel@scc.nlMario Sergio Fujikawa Ferreira
lioux@gns.com.brMark Andrews unknownMark Cammidge mark@gmtunx.ee.uct.ac.zaMark Diekhans markd@grizzly.comMark Huizer xaa@stack.nlMark J. Taylor mtaylor@cybernet.comMark Krentel krentel@rice.eduMark Mayo markm@vmunix.comMark Thompson thompson@tgsoft.comMark Tinguely tinguely@plains.nodak.eduMark Treacy unknownMark Valentine mark@linus.demon.co.ukMartin BirgmeierMartin Ibert mib@ppe.bb-data.deMartin Kammerhofer dada@sbox.tu-graz.ac.atMartin Renters martin@tdc.on.caMartti Kuparinen
martti.kuparinen@ericsson.comMasachika ISHIZUKA
ishizuka@isis.min.ntt.jpMas.TAKEMURA unknownMasafumi NAKANE max@wide.ad.jpMasahiro Sekiguchi
seki@sysrap.cs.fujitsu.co.jpMasanobu Saitoh msaitoh@spa.is.uec.ac.jpMasanori Kanaoka kana@saijo.mke.mei.co.jpMasanori Kiriake seiken@ARGV.ACMasatoshi TAMURA
tamrin@shinzan.kuee.kyoto-u.ac.jpMats Lofkvist mal@algonet.seMatt Bartley mbartley@lear35.cytex.comMatt Thomas matt@3am-software.comMatt White mwhite+@CMU.EDUMatthew C. Mead mmead@Glock.COMMatthew Cashdollar mattc@rfcnet.comMatthew Flatt mflatt@cs.rice.eduMatthew Fuller fullermd@futuresouth.comMatthew N. Dodd winter@jurai.netMatthew Stein matt@bdd.netMatthias Pfaller leo@dachau.marco.deMatthias Scheler tron@netbsd.orgMattias Gronlund
Mattias.Gronlund@sa.erisoft.seMattias Pantzare pantzer@ludd.luth.seMaurice Castro
maurice@planet.serc.rmit.edu.auMax Euston meuston@jmrodgers.comMax Khon fjoe@husky.iclub.nsu.ruMaxim Bolotin max@rsu.ruMicha Class
michael_class@hpbbse.bbn.hp.comMichael Butler imb@scgt.oz.auMichael Butschky butsch@computi.erols.comMichael Clay mclay@weareb.orgMichael Elbel me@FreeBSD.ORGMichael Galassi nerd@percival.rain.comMichael Hancock michaelh@cet.co.jpMichael Hohmuth hohmuth@inf.tu-dresden.deMichael Perlman canuck@caam.rice.eduMichael Petry petry@netwolf.NetMasters.comMichael Reifenberger root@totum.plaut.deMichael Searle searle@longacre.demon.co.ukMichal Listos mcl@Amnesiac.123.orgMichio Karl Jinbo
karl@marcer.nagaokaut.ac.jpMiguel Angel Sagreras
msagre@cactus.fi.uba.arMihoko Tanaka m_tonaka@pa.yokogawa.co.jpMika Nystrom mika@cs.caltech.eduMikael Hybsch micke@dynas.seMikael Karpberg
karpen@ocean.campus.luth.seMike Del repenting@hotmail.comMike Durian durian@plutotech.comMike Durkin mdurkin@tsoft.sf-bay.orgMike E. Matsnev mike@azog.cs.msu.suMike Evans mevans@candle.comMike Grupenhoff kashmir@umiacs.umd.eduMike Hibler mike@marker.cs.utah.eduMike Karels unknownMike McGaughey mmcg@cs.monash.edu.auMike Meyer mwm@shiva.the-park.comMike Mitchell mitchell@ref.tfs.comMike Murphy mrm@alpharel.comMike Peck mike@binghamton.eduMike Spengler mks@msc.eduMikhail A. Sokolov mishania@demos.suMikhail Teterin mi@aldan.ziplink.netMing-I Hseh PA@FreeBSD.ee.Ntu.edu.TWMitsuru IWASAKI iwasaki@pc.jaring.myMonte Mitzelfelt monte@gonefishing.orgMorgan Davis root@io.cts.comMostyn Lewis mostyn@mrl.comMotoyuki Kasahara m-kasahr@sra.co.jpMotoyuki Konno motoyuki@snipe.rim.or.jpMunechika Sumikawa sumikawa@kame.netMurray Stokely murray@cdrom.comN.G.Smith ngs@sesame.hensa.ac.ukNAGAO Tadaaki nagao@cs.titech.ac.jpNAKAJI Hiroyuki
nakaji@zeisei.dpri.kyoto-u.ac.jpNAKAMURA Kazushi nkazushi@highway.or.jpNAKAMURA Motonori
motonori@econ.kyoto-u.ac.jpNIIMI Satoshi sa2c@and.or.jpNOKUBI Hirotaka h-nokubi@yyy.or.jpNadav Eiron nadav@barcode.co.ilNanbor Wang nw1@cs.wustl.eduNaofumi Honda
honda@Kururu.math.sci.hokudai.ac.jpNaoki Hamada nao@tom-yam.or.jpNarvi narvi@haldjas.folklore.eeNathan Ahlstrom nrahlstr@winternet.comNathan Dorfman nathan@rtfm.netNeal Fachan kneel@ishiboo.comNeil Blakey-Milner nbm@rucus.ru.ac.zaNiall Smart rotel@indigo.ieNick Barnes Nick.Barnes@pobox.comNick Handel nhandel@NeoSoft.comNick Hilliard nick@foobar.org&a.nsayer;Nick Williams njw@cs.city.ac.ukNickolay N. Dudorov nnd@itfs.nsk.suNiklas Hallqvist niklas@filippa.appli.seNisha Talagala nisha@cs.berkeley.eduNo Name ZW6T-KND@j.asahi-net.or.jpNo Name adrian@virginia.eduNo Name alex@elvisti.kiev.uaNo Name anto@netscape.netNo Name bobson@egg.ics.nitch.ac.jpNo Name bovynf@awe.beNo Name burg@is.ge.comNo Name chris@gnome.co.ukNo Name colsen@usa.netNo Name coredump@nervosa.comNo Name dannyman@arh0300.urh.uiuc.eduNo Name davids@SECNET.COMNo Name derek@free.orgNo Name devet@adv.IAEhv.nlNo Name djv@bedford.netNo Name dvv@sprint.netNo Name enami@ba2.so-net.or.jpNo Name flash@eru.tubank.msk.suNo Name flash@hway.ruNo Name fn@pain.csrv.uidaho.eduNo Name gclarkii@netport.neosoft.comNo Name gordon@sheaky.lonestar.orgNo Name graaf@iae.nlNo Name greg@greg.rim.or.jpNo Name grossman@cygnus.comNo Name gusw@fub46.zedat.fu-berlin.deNo Name hfir@math.rochester.eduNo Name hnokubi@yyy.or.jpNo Name iaint@css.tuu.utas.edu.auNo Name invis@visi.comNo Name ishisone@sra.co.jpNo Name iverson@lionheart.comNo Name jpt@magic.netNo Name junker@jazz.snu.ac.krNo Name k-sugyou@ccs.mt.nec.co.jpNo Name kenji@reseau.toyonaka.osaka.jpNo Name kfurge@worldnet.att.netNo Name lh@aus.orgNo Name lhecking@nmrc.ucc.ieNo Name mrgreen@mame.mu.oz.auNo Name nakagawa@jp.freebsd.orgNo Name ohki@gssm.otsuka.tsukuba.ac.jpNo Name owaki@st.rim.or.jpNo Name pechter@shell.monmouth.comNo Name pete@pelican.pelican.comNo Name pritc003@maroon.tc.umn.eduNo Name risner@stdio.comNo Name roman@rpd.univ.kiev.uaNo Name root@ns2.redline.ruNo Name root@uglabgw.ug.cs.sunysb.eduNo Name stephen.ma@jtec.com.auNo Name sumii@is.s.u-tokyo.ac.jpNo Name takas-su@is.aist-nara.ac.jpNo Name tamone@eig.unige.chNo Name tjevans@raleigh.ibm.comNo Name tony-o@iij.ad.jp amurai@spec.co.jpNo Name torii@tcd.hitachi.co.jpNo Name uenami@imasy.or.jpNo Name uhlar@netlab.skNo Name vode@hut.fiNo Name wlloyd@mpd.caNo Name wlr@furball.wellsfargo.comNo Name wmbfmk@urc.tue.nlNo Name yamagata@nwgpc.kek.jpNo Name ziggy@ryan.orgNobuhiro Yasutomi nobu@psrc.isac.co.jpNobuyuki Koganemaru
kogane@koganemaru.co.jpNorio Suzuki nosuzuki@e-mail.ne.jpNoritaka Ishizumi graphite@jp.FreeBSD.ORGNoriyuki Soda soda@sra.co.jpOlaf Wagner wagner@luthien.in-berlin.deOleg Sharoiko os@rsu.ruOliver Breuninger ob@seicom.NETOliver Friedrichs oliver@secnet.comOliver Fromme
oliver.fromme@heim3.tu-clausthal.deOliver Laumann
net@informatik.uni-bremen.deOliver Oberdorf oly@world.std.comOlof Johansson offe@ludd.luth.seOsokin Sergey aka oZZ ozz@freebsd.org.ruPace Willisson pace@blitz.comPaco Rosich rosich@modico.eleinf.uv.esPalle Girgensohn girgen@partitur.seParag Patel parag@cgt.comPascal Pederiva pascal@zuo.dec.comPasvorn Boonmark boonmark@juniper.netPatrick Gardella patrick@cre8tivegroup.comPatrick Hausen unknownPaul Antonov apg@demos.suPaul F. Werkowski unknownPaul Fox pgf@foxharp.boston.ma.usPaul Koch koch@thehub.com.auPaul Kranenburg pk@NetBSD.orgPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPaul S. LaFollette, Jr. unknownPaul Saab paul@mu.orgPaul Sandys myj@nyct.netPaul T. Root proot@horton.iaces.comPaul Vixie paul@vix.comPaulo Menezes paulo@isr.uc.ptPaulo Menezes pm@dee.uc.ptPedro A M Vazquez vazquez@IQM.Unicamp.BRPedro Giffuni giffunip@asme.orgPete Bentley pete@demon.netPeter Childs pjchilds@imforei.apana.org.auPeter Cornelius pc@inr.fzk.dePeter Haight peterh@prognet.comPeter Jeremy perer.jeremy@alcatel.com.auPeter M. Chen pmchen@eecs.umich.eduPeter Much peter@citylink.dinoex.sub.orgPeter Olsson unknownPeter Philipp pjp@bsd-daemon.netPeter Stubbs PETERS@staidan.qld.edu.auPhil Maker pjm@cs.ntu.edu.auPhil Sutherland
philsuth@mycroft.dialix.oz.auPhil Taylor phil@zipmail.co.ukPhilip Musumeci philip@rmit.edu.auPierre Y. Dampure pierre.dampure@k2c.co.ukPius Fischer pius@ienet.comPomegranate daver@flag.blackened.netPowerdog Industries
kevin.ruddy@powerdog.comR. Kym HorsellRajesh Vaidheeswarran rv@fore.comRalf Friedl friedl@informatik.uni-kl.deRandal S. Masutani randal@comtest.comRandall Hopper rhh@ct.picker.comRandall W. Dean rwd@osf.orgRandy Bush rbush@bainbridge.verio.netReinier Bezuidenhout
rbezuide@mikom.csir.co.zaRemy Card Remy.Card@masi.ibp.frRicardas Cepas rch@richard.eu.orgRiccardo Veraldi veraldi@cs.unibo.itRichard Henderson richard@atheist.tamu.eduRichard Hwang rhwang@bigpanda.comRichard J Kuhns rjk@watson.grauel.comRichard M. Neswold
rneswold@drmemory.fnal.govRichard Seaman, Jr. dick@tar.comRichard Stallman rms@gnu.ai.mit.eduRichard Straka straka@user1.inficad.comRichard Tobin richard@cogsci.ed.ac.ukRichard Wackerbarth rkw@Dataplex.NETRichard Winkel rich@math.missouri.eduRichard Wiwatowski rjwiwat@adelaide.on.netRick Macklem rick@snowhite.cis.uoguelph.caRick Macklin unknownRob Austein sra@epilogue.comRob Mallory rmallory@qualcomm.comRob Snow rsnow@txdirect.netRobert Crowe bob@speakez.comRobert D. Thrush rd@phoenix.aii.comRobert Eckardt
roberte@MEP.Ruhr-Uni-Bochum.deRobert Sanders rsanders@mindspring.comRobert Sexton robert@kudra.comRobert Shady rls@id.netRobert Swindells swindellsr@genrad.co.ukRobert Watson robert@cyrus.watson.orgRobert Withrow witr@rwwa.comRobert Yoder unknownRobin Carey
robin@mailgate.dtc.rankxerox.co.ukRoger Hardiman roger@cs.strath.ac.ukRoland Jesse jesse@cs.uni-magdeburg.deRon Bickers rbickers@intercenter.netRon Lenk rlenk@widget.xmission.comRonald Kuehn kuehn@rz.tu-clausthal.deRudolf Cejka unknownRuslan Belkin rus@home2.UA.netRuslan Ermilov ru@ucb.crimea.uaRuslan Shevchenko rssh@cam.grad.kiev.uaRussell L. Carter rcarter@pinyon.orgRussell Vincent rv@groa.uct.ac.zaRyan Younce ryany@pobox.comSANETO Takanori sanewo@strg.sony.co.jpSAWADA Mizuki miz@qb3.so-net.ne.jpSUGIMURA Takashi sugimura@jp.FreeBSD.ORGSURANYI Peter
suranyip@jks.is.tsukuba.ac.jpSakari Jalovaara sja@tekla.fiSam Hartman hartmans@mit.eduSamuel Lam skl@ScalableNetwork.comSamuele Zannoli zannoli@cs.unibo.itSander Vesik sander@haldjas.folklore.eeSandro Sigala ssigala@globalnet.itSascha Blank blank@fox.uni-trier.deSascha Wildner swildner@channelz.GUN.deSatoh Junichi junichi@astec.co.jpScot Elliott scot@poptart.orgScot W. Hetzel hetzels@westbend.netScott A. Kenney saken@rmta.ml.orgScott Blachowicz
scott.blachowicz@seaslug.orgScott Burris scott@pita.cns.ucla.eduScott Hazen Mueller scott@zorch.sf-bay.orgScott Michel scottm@cs.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSebastian Strollo seb@erix.ericsson.seSeigou TANIMURA
tanimura@naklab.dnj.ynu.ac.jpSerge A. Babkin babkin@hq.icb.chel.suSerge V. Vakulenko vak@zebub.msk.suSergei Chechetkin
csl@whale.sunbay.crimea.uaSergei S. Laskavy laskavy@pc759.cs.msu.suSergey Gershtein sg@mplik.ruSergey Potapov sp@alkor.ruSergey Shkonda serg@bcs.zp.uaSergey V.Dorokhov svd@kbtelecom.nalnet.ruSergio Lenzi lenzi@bsi.com.brShaun Courtney shaun@emma.eng.uct.ac.zaShawn M. Carey smcarey@mailbox.syr.eduSheldon Hearn axl@iafrica.comShigio Yamaguchi shigio@wafu.netgate.netShinya Esu esu@yk.rim.or.jpShunsuke Akiyama akiyama@jp.freebsd.orgSimon simon@masi.ibp.frSimon Burge simonb@telstra.com.auSimon J Gerraty sjg@melb.bull.oz.auSimon Marlow simonm@dcs.gla.ac.ukSimon Shapiro shimon@simon-shapiro.orgSin'ichiro MIYATANI siu@phaseone.co.jpSlaven Rezic eserte@cs.tu-berlin.deSoochon Radee slr@mitre.orgSoren Dayton csdayton@midway.uchicago.eduSoren Dossing sauber@netcom.comSoren S. Jorvang soren@dt.dkStefan Bethke stb@hanse.deStefan Eggers seggers@semyam.dinoco.deStefan Moeding s.moeding@ndh.netStefan Petri unknownStefan `Sec` Zehl sec@42.orgSteinar Haug sthaug@nethelp.noStephane E. Potvin sepotvin@videotron.caStephane Legrand stephane@lituus.frStephen Clawson
sclawson@marker.cs.utah.eduStephen F. Combs combssf@salem.ge.comStephen Farrell stephen@farrell.orgStephen Hocking sysseh@devetir.qld.gov.auStephen J. Roznowski sjr@home.netStephen McKay syssgm@devetir.qld.gov.auStephen Melvin melvin@zytek.comSteve Bauer sbauer@rock.sdsmt.eduSteve Coltrin spcoltri@io.comSteve Deering unknownSteve Gerakines steve2@genesis.tiac.netSteve Gericke steveg@comtrol.comSteve Piette steve@simon.chi.il.USSteve Schwarz schwarz@alpharel.comSteven G. Kargl
kargl@troutmask.apl.washington.eduSteven H. Samorodin samorodi@NUXI.comSteven McCanne mccanne@cs.berkeley.eduSteven Plite splite@purdue.eduSteven Wallace unknownStuart Henderson
stuart@internationalschool.co.ukSue Blake sue@welearn.com.auSugimoto Sadahiro ixtl@komaba.utmc.or.jpSugiura Shiro ssugiura@duo.co.jpSujal Patel smpatel@wam.umd.eduSune Stjerneby stjerneby@usa.netSuzuki Yoshiaki
zensyo@ann.tama.kawasaki.jpTadashi Kumano kumano@strl.nhk.or.jpTaguchi Takeshi taguchi@tohoku.iij.ad.jpTakahashi Yoshihiro nyan@dd.catv.ne.jpTakahiro Yugawa yugawa@orleans.rim.or.jpTakanori Watanabe
takawata@shidahara1.planet.sci.kobe-u.ac.jpTakashi Mega mega@minz.orgTakashi Uozu j1594016@ed.kagu.sut.ac.jpTakayuki Ariga a00821@cc.hc.keio.ac.jpTakeru NAIKI naiki@bfd.es.hokudai.ac.jpTakeshi Amaike amaike@iri.co.jpTakeshi MUTOH mutoh@info.nara-k.ac.jpTakeshi Ohashi
ohashi@mickey.ai.kyutech.ac.jpTakeshi WATANABE
watanabe@crayon.earth.s.kobe-u.ac.jpTakuya SHIOZAKI
tshiozak@makino.ise.chuo-u.ac.jpTatoku Ogaito tacha@tera.fukui-med.ac.jpTatsumi HOSOKAWA hosokawa@jp.FreeBSD.orgTed Buswell tbuswell@mediaone.netTed Faber faber@isi.eduTed Lemon unknownTerry Lambert terry@lambert.orgTerry Lee terry@uivlsi.csl.uiuc.eduTetsuya Furukawa tetsuya@secom-sis.co.jpTheo de Raadt deraadt@OpenBSD.orgThomas thomas@mathematik.uni-Bremen.deThomas D. Dean tomdean@ix.netcom.comThomas David Rivers rivers@dignus.comThomas G. McWilliams tgm@netcom.comThomas Gellekum
thomas@ghpc8.ihf.rwth-aachen.deThomas Graichen
graichen@omega.physik.fu-berlin.deThomas König
Thomas.Koenig@ciw.uni-karlsruhe.deThomas Ptacek unknownThomas Stevens tas@stevens.orgThomas Stromberg tstrombe@rtci.comThomas Valentino Crimi
tcrimi+@andrew.cmu.eduThomas Wintergerst thomas@lemur.nord.deÞórður Ívarsson
totii@est.isTim Kientzle kientzle@netcom.comTim Singletary
tsingle@sunland.gsfc.nasa.govTim Wilkinson tim@sarc.city.ac.ukTimo J. Rinne tri@iki.fiTodd Miller millert@openbsd.orgTom root@majestix.cmr.noTom tom@sdf.comTom Gray - DCA dcasba@rain.orgTom Hukins tom@eborcom.comTom Jobbins tom@tom.tjTom Pusateri pusateri@juniper.netTom Rush tarush@mindspring.comTom Samplonius tom@misery.sdf.comTomohiko Kurahashi
kura@melchior.q.t.u-tokyo.ac.jpTony Kimball alk@Think.COMTony Li tli@jnx.comTony Lynn wing@cc.nsysu.edu.twTorbjorn Granlund tege@matematik.su.seToshihiko ARAI toshi@tenchi.ne.jpToshihiko SHIMOKAWA toshi@tea.forus.or.jpToshihiro Kanda candy@kgc.co.jpToshiomi Moriki
Toshiomi.Moriki@ma1.seikyou.ne.jpTrefor S. trefor@flevel.co.ukTrevor Blackwell tlb@viaweb.comURATA Shuichiro s-urata@nmit.tmg.nec.co.jpUdo Schweigert ust@cert.siemens.deUgo Paternostro paterno@dsi.unifi.itUlf Kieber kieber@sax.deUlli Linzen ulli@perceval.camelot.deUstimenko Semen semen@iclub.nsu.ruUwe Arndt arndt@mailhost.uni-koblenz.deVadim Chekan vadim@gc.lviv.uaVadim Kolontsov vadim@tversu.ac.ruVadim Mikhailov mvp@braz.ruVan Jacobson van@ee.lbl.govVasily V. Grechishnikov
bazilio@ns1.ied-vorstu.ac.ruVasim Valejev vasim@uddias.diaspro.comVernon J. Schryver vjs@mica.denver.sgi.comVic Abell abe@cc.purdue.eduVille Eerola ve@sci.fiVincent Poy vince@venus.gaianet.netVincenzo Capuano
VCAPUANO@vmprofs.esoc.esa.deVirgil Champlin champlin@pa.dec.comVladimir A. Jakovenko
vovik@ntu-kpi.kiev.uaVladimir Kushnir kushn@mail.kar.netVsevolod Lobko seva@alex-ua.comW. Gerald Hicks wghicks@bellsouth.netW. Richard Stevens rstevens@noao.eduWalt Howard howard@ee.utah.eduWarren Toomey wkt@csadfa.cs.adfa.oz.auWayne Scott wscott@ichips.intel.comWerner Griessl
werner@btp1da.phy.uni-bayreuth.deWes Santee wsantee@wsantee.oz.netWietse Venema wietse@wzv.win.tue.nlWilfredo Sanchez wsanchez@apple.comWiljo Heinen wiljo@freeside.ki.open.deWilko Bulte wilko@yedi.iaf.nlWillem Jan Withagen wjw@surf.IAE.nlWilliam Jolitz withheldWilliam Liao william@tale.netWojtek Pilorz
wpilorz@celebris.bdk.lublin.plWolfgang Helbig helbig@ba-stuttgart.deWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@FreeBSD.orgWu Ching-hong woju@FreeBSD.ee.Ntu.edu.TWYarema yds@ingress.comYaroslav Terletsky ts@polynet.lviv.uaYasuhito FUTATSUKI futatuki@fureai.or.jpYen-Shuo Su yssu@CCCA.NCTU.edu.twYing-Chieh Liao ijliao@csie.NCTU.edu.twYixin Jin yjin@rain.cs.ucla.eduYoshiaki Uchikawa yoshiaki@kt.rim.or.jpYoshihiko OHTA yohta@bres.tsukuba.ac.jpYoshihisa NAKAGAWA
y-nakaga@ccs.mt.nec.co.jpYoshikazu Goto gotoh@ae.anritsu.co.jpYoshimasa Ohnishi
ohnishi@isc.kyutech.ac.jpYoshishige Arai ryo2@on.rim.or.jpYuichi MATSUTAKA matutaka@osa.att.ne.jpYujiro MIYATA
miyata@bioele.nuee.nagoya-u.ac.jpYukihiro Nakai nacai@iname.comYusuke Nawano azuki@azkey.orgYuu Yashiki s974123@cc.matsuyama-u.ac.jpYuval Yarom yval@cs.huji.ac.ilYves Fonk yves@cpcoup5.tn.tudelft.nlYves Fonk yves@dutncp8.tn.tudelft.nlZach Heilig zach@gaffaneys.comZahemszhky Gabor zgabor@code.huZhong Ming-Xun zmx@mail.CDPA.nsysu.edu.twarci vega@sophia.inria.frder Mouse mouse@Collatz.McRCIM.McGill.EDUfrf frf@xocolatl.comEge Rekk aagero@aage.priv.no386BSD Patch Kit Patch Contributors(in alphabetical order by first name):Adam Glass glass@postgres.berkeley.eduAdrian Hall adrian@ibmpcug.co.ukAndrey A. Chernov ache@astral.msk.suAndrew Herbert andrew@werple.apana.org.auAndrew Moore alm@netcom.comAndy Valencia ajv@csd.mot.comjtk@netcom.comArne Henrik Juul arnej@Lise.Unit.NOBakul Shah bvs@bitblocks.comBarry Lustig barry@ictv.comBob Wilcox bob@obiwan.uucpBranko LankesterBrett Lymn blymn@mulga.awadi.com.AUCharles Hannum mycroft@ai.mit.eduChris G. Demetriou
cgd@postgres.berkeley.eduChris Torek torek@ee.lbl.govChristoph Robitschko
chmr@edvz.tu-graz.ac.atDaniel Poirot poirot@aio.jsc.nasa.govDave Burgess burgess@hrd769.brooks.af.milDave Rivers rivers@ponds.uucpDavid Dawes dawes@physics.su.OZ.AUDavid Greenman dg@Root.COMEric J. Haug ejh@slustl.slu.eduFelix Gaehtgens
felix@escape.vsse.in-berlin.deFrank Maclachlan fpm@crash.cts.comGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGeoff Rehmet csgr@alpha.ru.ac.zaGoran Hammarback goran@astro.uu.seGuido van Rooij guido@gvr.orgGuy Harris guy@auspex.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHerb Peyerl hpeyerl@novatel.cuc.ab.caHolger Veit Holger.Veit@gmd.deIshii Masahiro, R. Kym HorsellJ.T. Conklin jtc@cygnus.comJagane D Sundar jagane@netcom.comJames Clark jjc@jclark.comJames Jegers jimj@miller.cs.uwm.eduJames W. DolterJames da Silva jds@cs.umd.edu et alJay Fenlason hack@datacube.comJim Wilson wilson@moria.cygnus.comJörg Lohse
lohse@tech7.informatik.uni-hamburg.deJörg Wunsch
joerg_wunsch@uriah.heep.sax.deJohn DysonJohn Woods jfw@eddie.mit.eduJordan K. Hubbard jkh@whisker.hubbard.ieJulian Elischer julian@dialix.oz.auJulian Stacey jhs@freebsd.orgKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comkarl@one.neosoft.comKeith Bostic bostic@toe.CS.Berkeley.EDUKen HughesKent Talarico kent@shipwreck.tsoft.netKevin Lahey kml%rokkaku.UUCP@mathcs.emory.edukml@mosquito.cis.ufl.eduMarc Frajola marc@dev.comMark Tinguely tinguely@plains.nodak.edutinguely@hookie.cs.ndsu.NoDak.eduMartin Renters martin@tdc.on.caMichael Clay mclay@weareb.orgMichael Galassi nerd@percival.rain.comMike Durkin mdurkin@tsoft.sf-bay.orgNaoki Hamada nao@tom-yam.or.jpNate Williams nate@bsd.coe.montana.eduNick Handel nhandel@NeoSoft.comnick@madhouse.neosoft.comPace Willisson pace@blitz.comPaul Kranenburg pk@cs.few.eur.nlPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPeter da Silva peter@NeoSoft.comPhil Sutherland
philsuth@mycroft.dialix.oz.auPoul-Henning Kampphk@FreeBSD.ORGRalf Friedl friedl@informatik.uni-kl.deRick Macklem root@snowhite.cis.uoguelph.caRobert D. Thrush rd@phoenix.aii.comRodney W. Grimes rgrimes@cdrom.comSascha Wildner swildner@channelz.GUN.deScott Burris scott@pita.cns.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSean Eric Fagan sef@kithrup.comSimon J Gerraty sjg@melb.bull.oz.ausjg@zen.void.oz.auStephen McKay syssgm@devetir.qld.gov.auTerry Lambert terry@icarus.weber.eduTerry Lee terry@uivlsi.csl.uiuc.eduTor Egge Tor.Egge@idi.ntnu.noWarren Toomey wkt@csadfa.cs.adfa.oz.auWiljo Heinen wiljo@freeside.ki.open.deWilliam Jolitz withheldWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@dentaro.GUN.deYuval Yarom yval@cs.huji.ac.il
diff --git a/en_US.ISO8859-1/books/handbook/contrib/chapter.sgml b/en_US.ISO8859-1/books/handbook/contrib/chapter.sgml
index 8b2d3c3c88..ccdb16f558 100644
--- a/en_US.ISO8859-1/books/handbook/contrib/chapter.sgml
+++ b/en_US.ISO8859-1/books/handbook/contrib/chapter.sgml
@@ -1,5715 +1,5715 @@
Contributing to FreeBSDContributed by &a.jkh;.So you want to contribute something to FreeBSD? That is great! We can
always use the help, and FreeBSD is one of those systems that
relies on the contributions of its user base in order
to survive. Your contributions are not only appreciated, they are vital
to FreeBSD's continued growth!Contrary to what some people might also have you believe, you do not
need to be a hot-shot programmer or a close personal friend of the FreeBSD
core team in order to have your contributions accepted. The FreeBSD
Project's development is done by a large and growing number of
international contributors whose ages and areas of technical expertise
vary greatly, and there is always more work to be done than there are
people available to do it.Since the FreeBSD project is responsible for an entire operating
system environment (and its installation) rather than just a kernel or a
few scattered utilities, our TODO list also spans a
very wide range of tasks, from documentation, beta testing and
presentation to highly specialized types of kernel development. No matter
what your skill level, there is almost certainly something you can do to
help the project!Commercial entities engaged in FreeBSD-related enterprises are also
encouraged to contact us. Need a special extension to make your product
work? You will find us receptive to your requests, given that they are not
too outlandish. Working on a value-added product? Please let us know! We
may be able to work cooperatively on some aspect of it. The free software
world is challenging a lot of existing assumptions about how software is
developed, sold, and maintained throughout its life cycle, and we urge you
to at least give it a second look.What Is NeededThe following list of tasks and sub-projects represents something of
an amalgam of the various core team TODO lists and
user requests we have collected over the last couple of months. Where
possible, tasks have been ranked by degree of urgency. If you are
interested in working on one of the tasks you see here, send mail to the
coordinator listed by clicking on their names. If no coordinator has
been appointed, maybe you would like to volunteer?High priority tasksThe following tasks are considered to be urgent, usually because
they represent something that is badly broken or sorely needed:3-stage boot issues. Overall coordination: &a.hackers;Do WinNT compatible drive tagging so that the 3rd stage
can provide an accurate mapping of BIOS geometries for
disks.Filesystem problems. Overall coordination: &a.fs;Fix the MSDOS file system.Clean up and document the nullfs filesystem code.
Coordinator: &a.eivind;Fix the union file system. Coordinator: &a.dg;Implement Int13 vm86 disk driver. Coordinator:
&a.hackers;New bus architecture. Coordinator: &a.newbus;Port existing ISA drivers to new architecture.Move all interrupt-management code to appropriate parts of
the bus drivers.Port PCI subsystem to new architecture. Coordinator:
&a.dfr;Figure out the right way to handle removable devices and
then use that as a substrate on which PC-Card and CardBus
support can be implemented.Resolve the probe/attach priority issue once and for
all.Move any remaining buses over to the new
architecture.Kernel issues. Overall coordination: &a.hackers;Add more pro-active security infrastructure. Overall
coordination: &a.security;Build something like Tripwire(TM) into the kernel, with a
remote and local part. There are a number of cryptographic
issues to getting this right; contact the coordinator for
details. Coordinator: &a.eivind;Make the entire kernel use suser()
instead of comparing to 0. It is presently using about half
of each. Coordinator: &a.eivind;Split securelevels into different parts, to allow an
administrator to throw away those privileges he can throw
away. Setting the overall securelevel needs to have the same
effect as now, obviously. Coordinator: &a.eivind;Make it possible to upload a list of “allowed
program” to BPF, and then block BPF from accepting other
programs. This would allow BPF to be used e.g. for DHCP,
without allowing an attacker to start snooping the local
network.Update the security checker script. We should at least
grab all the checks from the other BSD derivatives, and add
checks that a system with securelevel increased also have
reasonable flags on the relevant parts. Coordinator:
&a.eivind;Add authorization infrastructure to the kernel, to allow
different authorization policies. Part of this could be done
by modifying suser(). Coordinatory:
&a.eivind;
- Add code to teh NFS layer so that you cannot
+ Add code to the NFS layer so that you cannot
chdir("..") out of an NFS partition. E.g.,
/usr is a UFS partition with
/usr/src NFS exported. Now it is
possible to use the NFS filehandle for
/usr/src to get access to
/usr.Medium priority tasksThe following tasks need to be done, but not with any particular
urgency:Full KLD based driver support/Configuration Manager.Write a configuration manager (in the 3rd stage boot?)
that probes your hardware in a sane manner, keeps only the
KLDs required for your hardware, etc.PCMCIA/PCCARD. Coordinators: &a.msmith; and &a.phk;Documentation!Reliable operation of the pcic driver (needs
testing).Recognizer and handler for sio.c
(mostly done).Recognizer and handler for ed.c
(mostly done).Recognizer and handler for ep.c
(mostly done).User-mode recognizer and handler (partially done).Advanced Power Management. Coordinators: &a.msmith; and
&a.phk;APM sub-driver (mostly done).IDE/ATA disk sub-driver (partially done).syscons/pcvt sub-driver.Integration with the PCMCIA/PCCARD drivers
(suspend/resume).Low priority tasksThe following tasks are purely cosmetic or represent such an
investment of work that it is not likely that anyone will get them
done anytime soon:The first N items are from Terry Lambert
terry@lambert.orgNetWare Server (protected mode ODI driver) loader and
subservices to allow the use of ODI card drivers supplied with
network cards. The same thing for NDIS drivers and NetWare SCSI
drivers.An "upgrade system" option that works on Linux boxes instead
of just previous rev FreeBSD boxes.Symmetric Multiprocessing with kernel preemption (requires
kernel preemption).A concerted effort at support for portable computers. This is
somewhat handled by changing PCMCIA bridging rules and power
management event handling. But there are things like detecting
internal vs. external display and picking a different screen
resolution based on that fact, not spinning down the disk if the
machine is in dock, and allowing dock-based cards to disappear
without affecting the machines ability to boot (same issue for
PCMCIA).Smaller tasksMost of the tasks listed in the previous sections require either a
considerable investment of time or an in-depth knowledge of the
FreeBSD kernel (or both). However, there are also many useful tasks
which are suitable for "weekend hackers", or people without
programming skills.If you run FreeBSD-current and have a good Internet
connection, there is a machine current.freebsd.org which builds a full
release once a day — every now and again, try and install
the latest release from it and report any failures in the
process.Read the freebsd-bugs mailing list. There
might be a problem you can comment constructively on or with
patches you can test. Or you could even try to fix one of the
problems yourself.Read through the FAQ and Handbook periodically. If anything
is badly explained, out of date or even just completely wrong, let
us know. Even better, send us a fix (SGML is not difficult to
learn, but there is no objection to ASCII submissions).Help translate FreeBSD documentation into your native language
(if not already available) — just send an email to &a.doc;
asking if anyone is working on it. Note that you are not
committing yourself to translating every single FreeBSD document
by doing this — in fact, the documentation most in need of
translation is the installation instructions.Read the freebsd-questions mailing list and &ng.misc
occasionally (or even regularly). It can be very satisfying to
share your expertise and help people solve their problems;
sometimes you may even learn something new yourself! These forums
can also be a source of ideas for things to work on.If you know of any bugfixes which have been successfully
applied to -current but have not been merged into -stable after a
decent interval (normally a couple of weeks), send the committer a
polite reminder.Move contributed software to src/contrib
in the source tree.Make sure code in src/contrib is up to
date.Look for year 2000 bugs (and fix any you find!)Build the source tree (or just part of it) with extra warnings
enabled and clean up the warnings.Fix warnings for ports which do deprecated things like using
gets() or including malloc.h.If you have contributed any ports, send your patches back to
the original author (this will make your life easier when they
bring out the next version)Suggest further tasks for this list!How to ContributeContributions to the system generally fall into one or more of the
following 6 categories:Bug reports and general commentaryAn idea or suggestion of general technical
interest should be mailed to the &a.hackers;. Likewise, people with
an interest in such things (and a tolerance for a
high volume of mail!) may subscribe to the
hackers mailing list by sending mail to &a.majordomo;. See mailing lists for more information
about this and other mailing lists.If you find a bug or are submitting a specific change, please
report it using the &man.send-pr.1; program or its WEB-based
equivalent. Try to fill-in each field of the bug report.
Unless they exceed 65KB, include any patches directly in the report.
Consider compressing them and using &man.uuencode.1; if they exceed
20KB. Upload very large submissions to ftp.freebsd.org:/pub/FreeBSD/incoming/.After filing a report, you should receive confirmation along with
a tracking number. Keep this tracking number so that you can update
us with details about the problem by sending mail to
bug-followup@FreeBSD.ORG. Use the number as the
message subject, e.g. "Re: kern/3377". Additional
information for any bug report should be submitted this way.If you do not receive confirmation in a timely fashion (3 days to
a week, depending on your email connection) or are, for some reason,
unable to use the &man.send-pr.1; command, then you may ask
someone to file it for you by sending mail to the &a.bugs;.Changes to the documentationChanges to the documentation are overseen by the &a.doc;. Send
submissions and changes (even small ones are welcome!) using
send-pr as described in Bug Reports and General
Commentary.Changes to existing source codeAn addition or change to the existing source code is a somewhat
trickier affair and depends a lot on how far out of date you are with
the current state of the core FreeBSD development. There is a special
on-going release of FreeBSD known as “FreeBSD-current”
which is made available in a variety of ways for the convenience of
developers working actively on the system. See Staying current with FreeBSD for more
information about getting and using FreeBSD-current.Working from older sources unfortunately means that your changes
may sometimes be too obsolete or too divergent for easy re-integration
into FreeBSD. Chances of this can be minimized somewhat by
subscribing to the &a.announce; and the &a.current; lists, where
discussions on the current state of the system take place.Assuming that you can manage to secure fairly up-to-date sources
to base your changes on, the next step is to produce a set of diffs to
send to the FreeBSD maintainers. This is done with the &man.diff.1;
command, with the “context diff” form
being preferred. For example:&prompt.user; diff -c oldfile newfile
or
&prompt.user; diff -c -r olddir newdir
would generate such a set of context diffs for the given source file
or directory hierarchy. See the man page for &man.diff.1; for more
details.Once you have a set of diffs (which you may test with the
&man.patch.1; command), you should submit them for inclusion with
FreeBSD. Use the &man.send-pr.1; program as described in Bug Reports and General Commentary.
Do not just send the diffs to the &a.hackers; or
they will get lost! We greatly appreciate your submission (this is a
volunteer project!); because we are busy, we may not be able to
address it immediately, but it will remain in the pr database until we
do.If you feel it appropriate (e.g. you have added, deleted, or
renamed files), bundle your changes into a tar file
and run the &man.uuencode.1; program on it. Shar archives are also
welcome.If your change is of a potentially sensitive nature, e.g. you are
unsure of copyright issues governing its further distribution or you
are simply not ready to release it without a tighter review first,
then you should send it to &a.core; directly rather than submitting it
with &man.send-pr.1;. The core mailing list reaches a much smaller
group of people who do much of the day-to-day work on FreeBSD. Note
that this group is also very busy and so you
should only send mail to them where it is truly necessary.Please refer to man 9 intro and man 9
style for some information on coding style. We would
appreciate it if you were at least aware of this information before
submitting code.New code or major value-added packagesIn the rare case of a significant contribution of a large body
work, or the addition of an important new feature to FreeBSD, it
becomes almost always necessary to either send changes as uuencode'd
tar files or upload them to our ftp site ftp://ftp.FreeBSD.ORG/pub/FreeBSD/incoming.When working with large amounts of code, the touchy subject of
copyrights also invariably comes up. Acceptable copyrights for code
included in FreeBSD are:The BSD copyright. This copyright is most preferred due to
its “no strings attached” nature and general
attractiveness to commercial enterprises. Far from discouraging
such commercial use, the FreeBSD Project actively encourages such
participation by commercial interests who might eventually be
inclined to invest something of their own into FreeBSD.The GNU Public License, or “GPL”. This license is
not quite as popular with us due to the amount of extra effort
demanded of anyone using the code for commercial purposes, but
given the sheer quantity of GPL'd code we currently require
(compiler, assembler, text formatter, etc) it would be silly to
refuse additional contributions under this license. Code under
the GPL also goes into a different part of the tree, that being
/sys/gnu or
/usr/src/gnu, and is therefore easily
identifiable to anyone for whom the GPL presents a problem.Contributions coming under any other type of copyright must be
carefully reviewed before their inclusion into FreeBSD will be
considered. Contributions for which particularly restrictive
commercial copyrights apply are generally rejected, though the authors
are always encouraged to make such changes available through their own
channels.To place a “BSD-style” copyright on your work, include
the following text at the very beginning of every source code file you
wish to protect, replacing the text between the %%
with the appropriate information.
Copyright (c) %%proper_years_here%%
%%your_name_here%%, %%your_state%% %%your_zip%%.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer as
the first lines of this file unmodified.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY %%your_name_here%% ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL %%your_name_here%% BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
$Id$For your convenience, a copy of this text can be found in
/usr/share/examples/etc/bsd-style-copyright.Money, Hardware or Internet accessWe are always very happy to accept donations to further the cause
of the FreeBSD Project and, in a volunteer effort like ours, a little
can go a long way! Donations of hardware are also very important to
expanding our list of supported peripherals since we generally lack
the funds to buy such items ourselves.Donating fundsWhile the FreeBSD Project is not a 501(c)(3) (charitable)
corporation and hence cannot offer special tax incentives for any
donations made, any such donations will be gratefully accepted on
behalf of the project by FreeBSD, Inc.FreeBSD, Inc. was founded in early 1995 by &a.jkh; and &a.dg;
with the goal of furthering the aims of the FreeBSD Project and
giving it a minimal corporate presence. Any and all funds donated
(as well as any profits that may eventually be realized by FreeBSD,
Inc.) will be used exclusively to further the project's
goals.Please make any checks payable to FreeBSD, Inc., sent in care of
the following address:FreeBSD, Inc.c/o Jordan Hubbard4041 Pike Lane, Suite FConcordCA, 94520(currently using the Walnut Creek CDROM address until a PO box
can be opened)Wire transfers may also be sent directly to:Bank Of AmericaConcord Main OfficeP.O. Box 37176San FranciscoCA, 94137-5176Routing #: 121-000-358Account #: 01411-07441 (FreeBSD, Inc.)Any correspondence related to donations should be sent to Jordan
Hubbard jkh@FreeBSD.org, either via email or to the
FreeBSD, Inc. postal address given above.If you do not wish to be listed in our donors section, please specify this when
making your donation. Thanks!Donating hardwareDonations of hardware in any of the 3 following categories are
also gladly accepted by the FreeBSD Project:General purpose hardware such as disk drives, memory or
complete systems should be sent to the FreeBSD, Inc. address
listed in the donating funds
section.Hardware for which ongoing compliance testing is desired.
We are currently trying to put together a testing lab of all
components that FreeBSD supports so that proper regression
testing can be done with each new release. We are still lacking
many important pieces (network cards, motherboards, etc) and if
you would like to make such a donation, please contact &a.dg;
for information on which items are still required.Hardware currently unsupported by FreeBSD for which you
would like to see such support added. Please contact the
&a.core; before sending such items as we will need to find a
developer willing to take on the task before we can accept
delivery of new hardware.Donating Internet accessWe can always use new mirror sites for FTP, WWW or
cvsup. If you would like to be such a mirror,
please contact the FreeBSD project administrators
admin@FreeBSD.ORG for more information.Donors GalleryThe FreeBSD Project is indebted to the following donors and would
like to publically thank them here!Contributors to the central server
project:The following individuals and businesses made it possible for
the FreeBSD Project to build a new central server machine to
eventually replace freefall.freebsd.org
by donating the following items:Ade Barkah mbarkah@freebsd.org and his
employer, Hemisphere
Online, donated a Pentium Pro (P6) 200Mhz
CPUASA
Computers donated a Tyan 1662
motherboard.Joe McGuckin joe@via.net of ViaNet Communications donated
a Kingston ethernet controller.Jack O'Neill jack@diamond.xtalwind.net
donated an NCR 53C875 SCSI controller
card.Ulf Zimmermann ulf@Alameda.net of Alameda Networks donated
128MB of memory, a 4 Gb disk
drive and the case.Direct funding:The following individuals and businesses have generously
contributed direct funding to the project:Annelise Anderson
ANDRSN@HOOVER.STANFORD.EDUMatt Dillon dillon@best.netEpilogue Technology
CorporationSean Eric FaganDon Scott WildeGianmarco Giovannelli
gmarco@masternet.itJosef C. Grosch joeg@truenorth.orgRobert T. MorrisChuck Robey chuckr@freebsd.orgKenneth P. Stox ken@stox.sa.enteract.com of
Imaginary Landscape,
LLC.Dmitry S. Kohmanyuk dk@dog.farm.orgLaser5 of Japan
(a portion of the profits from sales of their various FreeBSD
CD-ROMs.Fuki Shuppan
Publishing Co. donated a portion of their profits from
Hajimete no FreeBSD (FreeBSD, Getting
started) to the FreeBSD and XFree86 projects.ASCII Corp.
donated a portion of their profits from several FreeBSD-related
books to the FreeBSD project.Yokogawa Electric
Corp has generously donated significant funding to the
FreeBSD project.BuffNETPacific
SolutionsSiemens AG
via Andre
AlbsmeierChris SilvaHardware contributors:The following individuals and businesses have generously
contributed hardware for testing and device driver
development/support:Walnut Creek CDROM for providing the Pentium P5-90 and
486/DX2-66 EISA/VL systems that are being used for our
development work, to say nothing of the network access and other
donations of hardware resources.TRW Financial Systems, Inc. provided 130 PCs, three 68 GB
fileservers, twelve Ethernets, two routers and an ATM switch for
debugging the diskless code.Dermot McDonnell donated the Toshiba XM3401B CDROM drive
currently used in freefall.&a.chuck; contributed his floppy tape streamer for
experimental work.Larry Altneu larry@ALR.COM, and &a.wilko;,
provided Wangtek and Archive QIC-02 tape drives in order to
improve the wt driver.Ernst Winter ewinter@lobo.muc.de contributed
a 2.88 MB floppy drive to the project. This will hopefully
increase the pressure for rewriting the floppy disk driver.
;-)Tekram
Technologies sent one each of their DC-390, DC-390U
and DC-390F FAST and ULTRA SCSI host adapter cards for
regression testing of the NCR and AMD drivers with their cards.
They are also to be applauded for making driver sources for free
operating systems available from their FTP server ftp://ftp.tekram.com/scsi/FreeBSD.Larry M. Augustin contributed not only a
Symbios Sym8751S SCSI card, but also a set of data books,
including one about the forthcoming Sym53c895 chip with Ultra-2
and LVD support, and the latest programming manual with
information on how to safely use the advanced features of the
latest Symbios SCSI chips. Thanks a lot!Christoph Kukulies kuku@freebsd.org donated
an FX120 12 speed Mitsumi CDROM drive for IDE CDROM driver
development.Special contributors:Walnut Creek CDROM
has donated almost more than we can say (see the history document for more details).
In particular, we would like to thank them for the original
hardware used for freefall.FreeBSD.ORG, our primary
development machine, and for thud.FreeBSD.ORG, a testing and build
box. We are also indebted to them for funding various
contributors over the years and providing us with unrestricted
use of their T1 connection to the Internet.The interface
business GmbH, Dresden has been patiently supporting
&a.joerg; who has often preferred FreeBSD work over paywork, and
used to fall back to their (quite expensive) EUnet Internet
connection whenever his private connection became too slow or
flakey to work with it...Berkeley Software Design,
Inc. has contributed their DOS emulator code to the
remaining BSD world, which is used in the
dosemu command.Core Team AlumnusThe following people were members of the FreeBSD core team during
the period indicated. We thank them for their past efforts in the
service of the FreeBSD project.In rough chronological order:Guido van Rooij (1995 - 1999)John Dyson (1993 - 1998)Nate Williams (1992 - 1996)Rod Grimes (1992 - 1995)Andreas Schulz (1992 - 1995)Geoff Rehmet (1993 - 1995)Paul Richards (1992 - 1995)Scott Mace (1993 - 1994)Andrew Moore (1993 - 1994)Christoph Robitschko (1993 - 1994)J. T. Conklin (1992 - 1993)Derived Software ContributorsThis software was originally derived from William F. Jolitz's 386BSD
release 0.1, though almost none of the original 386BSD specific code
remains. This software has been essentially re-implemented from the
4.4BSD-Lite release provided by the Computer Science Research Group
(CSRG) at the University of California, Berkeley and associated academic
contributors.There are also portions of NetBSD and OpenBSD that have been
integrated into FreeBSD as well, and we would therefore like to thank
all the contributors to NetBSD and OpenBSD for their work.Additional FreeBSD Contributors(in alphabetical order by first name):ABURAYA Ryushirou rewsirow@ff.iij4u.or.jpAMAGAI Yoshiji amagai@nue.orgAaron Bornstein aaronb@j51.comAaron Smith aaron@tau.veritas.comAchim Patzner ap@noses.comAda T Lim ada@bsd.orgAdam Baran badam@mw.mil.plAdam Glass glass@postgres.berkeley.eduAdam McDougall mcdouga9@egr.msu.eduAdrian Colley aecolley@ois.ieAdrian Hall adrian@ibmpcug.co.ukAdrian Mariano adrian@cam.cornell.eduAdrian Steinmann ast@marabu.chAdrian T. Filipi-Martin
atf3r@agate.cs.virginia.eduAjit Thyagarajan unknownAkio Morita
amorita@meadow.scphys.kyoto-u.ac.jpAkira SAWADA unknownAkira Watanabe
akira@myaw.ei.meisei-u.ac.jpAkito Fujita fujita@zoo.ncl.omron.co.jpAlain Kalker
A.C.P.M.Kalker@student.utwente.nlAlan Bawden alan@curry.epilogue.comAlan Cox alc@cs.rice.eduAlec Wolman wolman@cs.washington.eduAled Morris aledm@routers.co.ukAlex garbanzo@hooked.netAlex D. Chen
dhchen@Canvas.dorm7.nccu.edu.twAlex G. Bulushev bag@demos.suAlex Le Heux alexlh@funk.orgAlexander B. Povolotsky tarkhil@mgt.msk.ruAlexander Leidinger
netchild@wurzelausix.CS.Uni-SB.DEAlexandre Snarskii snar@paranoia.ruAlistair G. Crooks agc@uts.amdahl.comAllan Saddi asaddi@philosophysw.comAllen Campbell allenc@verinet.comAmakawa Shuhei amakawa@hoh.t.u-tokyo.ac.jpAmancio Hasty hasty@star-gate.comAmir Farah amir@comtrol.comAmy Baron amee@beer.orgAnatoly A. Orehovsky tolik@mpeks.tomsk.suAnatoly Vorobey mellon@pobox.comAnders Nordby nickerne@nome.noAnders Thulin Anders.X.Thulin@telia.seAndras Olah olah@cs.utwente.nlAndre Albsmeier
Andre.Albsmeier@mchp.siemens.deAndre Oppermann andre@pipeline.chAndreas Haakh ah@alman.robin.deAndreas Kohout shanee@rabbit.augusta.deAndreas Lohr andreas@marvin.RoBIN.deAndreas Schulz unknownAndreas Wetzel mickey@deadline.snafu.deAndreas Wrede andreas@planix.comAndres Vega Garcia unknownAndrew Atrens atreand@statcan.caAndrew Gillham gillham@andrews.eduAndrew Gordon andrew.gordon@net-tel.co.ukAndrew Herbert andrew@werple.apana.org.auAndrew J. Korty ajk@purdue.eduAndrew L. Moore alm@mclink.comAndrew McRae amcrae@cisco.comAndrew Stevenson andrew@ugh.net.auAndrew Timonin tim@pool1.convey.ruAndrew V. Stesin stesin@elvisti.kiev.uaAndrew Webster awebster@dataradio.comAndrey Zakhvatov andy@icc.surw.chel.suAndy Farkas andyf@speednet.com.auAndy Valencia ajv@csd.mot.comAndy Whitcroft andy@sarc.city.ac.ukAngelo Turetta ATuretta@stylo.itAnthony C. Chavez magus@xmission.comAnthony Yee-Hang Chan yeehang@netcom.comAnton Berezin tobez@plab.ku.dkAntti Kaipila anttik@iki.fiAre Bryne are.bryne@communique.noAri Suutari ari@suutari.iki.fiArjan de Vet devet@IAEhv.nlArne Henrik Juul arnej@Lise.Unit.NOAssar Westerlund assar@sics.seAtsushi Furuta furuta@sra.co.jpAtsushi Murai amurai@spec.co.jpBakul Shah bvs@bitblocks.comBarry Bierbauch pivrnec@vszbr.czBarry Lustig barry@ictv.comBen Hutchinson benhutch@xfiles.org.ukBen Jackson unknownBen Smithurst ben@scientia.demon.co.ukBen Walter bwalter@itachi.swcp.comBenjamin Lewis bhlewis@gte.netBernd Rosauer br@schiele-ct.deBill Kish kish@osf.orgBill Trost trost@cloud.rain.comBlaz Zupan blaz@amis.netBob Van Valzah Bob@whitebarn.comBob Willcox bob@luke.pmr.comBoris Staeblow balu@dva.in-berlin.deBoyd R. Faulkner faulkner@asgard.bga.comBrad Karp karp@eecs.harvard.eduBradley Dunn bradley@dunn.orgBrandon Gillespie brandon@roguetrader.com&a.wlloydBob Wilcox bob@obiwan.uucpBoyd Faulkner faulkner@mpd.tandem.comBrent J. Nordquist bjn@visi.comBrett Lymn blymn@mulga.awadi.com.AUBrett Taylor
brett@peloton.physics.montana.eduBrian Campbell brianc@pobox.comBrian Clapper bmc@willscreek.comBrian Cully shmit@kublai.comBrian F. Feldman green@unixhelp.orgBrian Handy
handy@lambic.space.lockheed.comBrian Litzinger brian@MediaCity.comBrian McGovern bmcgover@cisco.comBrian Moore ziff@houdini.eecs.umich.eduBrian R. Haug haug@conterra.comBrian Tao taob@risc.orgBrion Moss brion@queeg.comBruce A. Mah bmah@ca.sandia.govBruce Albrecht bruce@zuhause.mn.orgBruce Gingery bgingery@gtcs.comBruce J. Keeler loodvrij@gridpoint.comBruce Murphy packrat@iinet.net.auBruce Walter walter@fortean.comCarey Jones mcj@acquiesce.orgCarl Fongheiser cmf@netins.netCarl Mascott cmascott@world.std.comCasper casper@acc.amCastor Fu castor@geocast.comCejka Rudolf cejkar@dcse.fee.vutbr.czChain Lee chain@110.netCharles Hannum mycroft@ai.mit.eduCharles Henrich henrich@msu.eduCharles Mott cmott@srv.netCharles Owens owensc@enc.eduChet Ramey chet@odin.INS.CWRU.EduChia-liang Kao clkao@CirX.ORGChiharu Shibata chi@bd.mbn.or.jpChip Norkus unknownChoi Jun Ho junker@jazz.snu.ac.krChris Costello chris@holly.dyndns.orgChris Csanady cc@tarsier.ca.sandia.govChris Dabrowski chris@vader.orgChris Dillon cdillon@wolves.k12.mo.usChris Piazza cpiazza@home.netChris Shenton
cshenton@angst.it.hq.nasa.govChris Stenton jacs@gnome.co.ukChris Timmons skynyrd@opus.cts.cwu.eduChris Torek torek@ee.lbl.govChristian Gusenbauer
cg@fimp01.fim.uni-linz.ac.atChristian Haury Christian.Haury@sagem.frChristian Weisgerber
naddy@bigeye.rhein-neckar.deChristoph P. Kukulies kuku@FreeBSD.orgChristoph Robitschko
chmr@edvz.tu-graz.ac.atChristoph Weber-Fahr
wefa@callcenter.systemhaus.netChristopher G. Demetriou
cgd@postgres.berkeley.eduChristopher T. Johnson
cjohnson@neunacht.netgsi.comChrisy Luke chrisy@flix.netChuck Hein chein@cisco.comClive Lin clive@CiRX.ORGColman Reilly careilly@tcd.ieConrad Sabatier conrads@neosoft.comCoranth Gryphon gryphon@healer.comCornelis van der Laan
nils@guru.ims.uni-stuttgart.deCove Schneider cove@brazil.nbn.comCraig Leres leres@ee.lbl.govCraig Loomis unknownCraig Metz cmetz@inner.netCraig Spannring cts@internetcds.comCraig Struble cstruble@vt.eduCristian Ferretti cfs@riemann.mat.puc.clCurt Mayer curt@toad.comCy Schubert cschuber@uumail.gov.bc.caDI. Christian Gusenbauer
cg@scotty.edvz.uni-linz.ac.atDai Ishijima ishijima@tri.pref.osaka.jpDamian Hamill damian@cablenet.netDan Cross tenser@spitfire.ecsel.psu.eduDan Lukes dan@obluda.czDan Nelson dnelson@emsphone.comDan Walters hannibal@cyberstation.netDaniel Baker dbaker@crash.ops.neosoft.comDaniel M. Eischen
deischen@iworks.InterWorks.orgDaniel O'Connor doconnor@gsoft.com.auDaniel Poirot poirot@aio.jsc.nasa.govDaniel Rock rock@cs.uni-sb.deDanny Egen unknownDanny J. Zerkel dzerkel@phofarm.comDarren Reed avalon@coombs.anu.edu.auDave Adkins adkin003@tc.umn.eduDave Andersen angio@aros.netDave Blizzard dblizzar@sprynet.comDave Bodenstab imdave@synet.netDave Burgess burgess@hrd769.brooks.af.milDave Chapeskie dchapes@ddm.on.caDave Cornejo dave@dogwood.comDave Edmondson davided@sco.comDave Glowacki dglo@ssec.wisc.eduDave Marquardt marquard@austin.ibm.comDave Tweten tweten@FreeBSD.orgDavid A. Adkins adkin003@tc.umn.eduDavid A. Bader dbader@umiacs.umd.eduDavid Borman dab@bsdi.comDavid Dawes dawes@XFree86.orgDavid Filo filo@yahoo.comDavid Holland dholland@eecs.harvard.eduDavid Holloway daveh@gwythaint.tamis.comDavid Horwitt dhorwitt@ucsd.eduDavid Hovemeyer daveho@infocom.comDavid Jones dej@qpoint.torfree.netDavid Kelly dkelly@tomcat1.tbe.comDavid Kulp dkulp@neomorphic.comDavid L. Nugent davidn@blaze.net.auDavid Leonard d@scry.dstc.edu.auDavid Malone dwmalone@maths.tcd.ieDavid Muir Sharnoff muir@idiom.comDavid S. Miller davem@jenolan.rutgers.eduDavid Wolfskill dhw@whistle.comDean Gaudet dgaudet@arctic.orgDean Huxley dean@fsa.caDenis Fortin unknownDennis Glatting
dennis.glatting@software-munitions.comDenton Gentry denny1@home.comDerek Inksetter derek@saidev.comDima Sivachenko dima@Chg.RUDirk Keunecke dk@panda.rhein-main.deDirk Nehrling nerle@pdv.deDmitry Khrustalev dima@xyzzy.machaon.ruDmitry Kohmanyuk dk@farm.orgDom Mitchell dom@myrddin.demon.co.ukDon Croyle croyle@gelemna.ft-wayne.in.us&a.whiteside;Don Morrison dmorrisn@u.washington.eduDon Yuniskis dgy@rtd.comDonald Maddox dmaddox@conterra.comDoug Barton studded@dal.netDouglas Ambrisko ambrisko@whistle.comDouglas Carmichael dcarmich@mcs.comDouglas Crosher dtc@scrooge.ee.swin.oz.auDrew Derbyshire ahd@kew.comDuncan Barclay dmlb@ragnet.demon.co.ukDustin Sallings dustin@spy.netEckart "Isegrim" Hofmann
Isegrim@Wunder-Nett.orgEd Gold
vegold01@starbase.spd.louisville.eduEd Hudson elh@p5.spnet.comEdward Wang edward@edcom.comEdwin Groothus edwin@nwm.wan.philips.comEiji-usagi-MATSUmoto usagi@clave.gr.jpELISA Font ProjectElmar Bartel
bartel@informatik.tu-muenchen.deEric A. Griff eagriff@global2000.netEric Blood eblood@cs.unr.eduEric J. Haug ejh@slustl.slu.eduEric J. Schwertfeger eric@cybernut.comEric L. Hernes erich@lodgenet.comEric P. Scott eps@sirius.comEric Sprinkle eric@ennovatenetworks.comErich Stefan Boleyn erich@uruk.orgErik E. Rantapaa rantapaa@math.umn.eduErik H. Moe ehm@cris.comErnst Winter ewinter@lobo.muc.deEugene M. Kim astralblue@usa.netEugene Radchenko genie@qsar.chem.msu.suEvan Champion evanc@synapse.netFaried Nawaz fn@Hungry.COMFlemming Jacobsen fj@tfs.comFong-Ching Liaw fong@juniper.netFrancis M J Hsieh mjshieh@life.nthu.edu.twFrank Bartels knarf@camelot.deFrank Chen Hsiung Chan
frankch@waru.life.nthu.edu.twFrank Durda IV uhclem@nemesis.lonestar.orgFrank MacLachlan fpm@n2.netFrank Nobis fn@Radio-do.deFrank Volf volf@oasis.IAEhv.nlFrank ten Wolde franky@pinewood.nlFrank van der Linden frank@fwi.uva.nlFred Cawthorne fcawth@jjarray.umn.eduFred Gilham gilham@csl.sri.comFred Templin templin@erg.sri.comFrederick Earl Gray fgray@rice.eduFUJIMOTO Kensaku
fujimoto@oscar.elec.waseda.ac.jpFUJISHIMA Satsuki k5@respo.or.jpFURUSAWA Kazuhisa
furusawa@com.cs.osakafu-u.ac.jpGabor Kincses gabor@acm.orgGabor Zahemszky zgabor@CoDe.huGarance A Drosehn gad@eclipse.its.rpi.eduGareth McCaughan gjm11@dpmms.cam.ac.ukGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGary J. garyj@rks32.pcs.dec.comGary Kline kline@thought.orgGaspar Chilingarov nightmar@lemming.acc.amGea-Suan Lin gsl@tpts4.seed.net.twGeoff Rehmet csgr@alpha.ru.ac.zaGeorg Wagner georg.wagner@ubs.comGerard Roudier groudier@club-internet.frGianmarco Giovannelli
gmarco@giovannelli.itGil Kloepfer Jr. gil@limbic.ssdl.comGilad Rom rom_glsa@ein-hashofet.co.ilGinga Kawaguti
ginga@amalthea.phys.s.u-tokyo.ac.jpGiles Lean giles@nemeton.com.auGlen Foster gfoster@gfoster.comGlenn Johnson gljohns@bellsouth.netGodmar Back gback@facility.cs.utah.eduGoran Hammarback goran@astro.uu.seGord Matzigkeit gord@enci.ucalgary.caGordon Greeff gvg@uunet.co.zaGraham Wheeler gram@cdsec.comGreg A. Woods woods@zeus.leitch.comGreg Ansley gja@ansley.comGreg Troxel gdt@ir.bbn.comGreg Ungerer gerg@stallion.oz.auGregory Bond gnb@itga.com.auGregory D. Moncreaff
moncrg@bt340707.res.ray.comGuy Harris guy@netapp.comGuy Helmer ghelmer@cs.iastate.eduHAMADA Naoki hamada@astec.co.jpHONDA Yasuhiro
honda@kashio.info.mie-u.ac.jpHOSOBUCHI Noriyuki hoso@buchi.tama.or.jpHannu Savolainen hannu@voxware.pp.fiHans Huebner hans@artcom.deHans Petter Bieker zerium@webindex.noHans Zuidam hans@brandinnovators.comHarlan Stenn Harlan.Stenn@pfcs.comHarold Barker hbarker@dsms.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHeikki Suonsivu hsu@cs.hut.fiHeiko W. Rupp unknownHelmut F. Wirth hfwirth@ping.atHenrik Vestergaard Draboel
hvd@terry.ping.dkHerb Peyerl hpeyerl@NetBSD.orgHideaki Ohmon ohmon@tom.sfc.keio.ac.jpHidekazu Kuroki hidekazu@cs.titech.ac.jpHideki Yamamoto hyama@acm.orgHidetoshi Shimokawa
simokawa@sat.t.u-tokyo.ac.jpHideyuki Suzuki
hideyuki@sat.t.u-tokyo.ac.jpHirayama Issei iss@mail.wbs.ne.jpHiroaki Sakai sakai@miya.ee.kagu.sut.ac.jpHiroharu Tamaru tamaru@ap.t.u-tokyo.ac.jpHironori Ikura hikura@kaisei.orgHiroshi Nishikawa nis@pluto.dti.ne.jpHiroya Tsubakimoto unknownHiroyuki NAKAJI
nakaji@zeisei3.dpri.kyoto-u.ac.jpHolger Veit Holger.Veit@gmd.deHolm Tiffe holm@geophysik.tu-freiberg.deHorance Chou
horance@freedom.ie.cycu.edu.twHorihiro Kumagaio kuma@jp.freebsd.orgHr.Ladavac lada@ws2301.gud.siemens.co.atHubert Feyrer hubertf@NetBSD.ORGHugh F. Mahon hugh@nsmdserv.cnd.hp.comHugh Mahon h_mahon@fc.hp.comHung-Chi Chu hcchu@r350.ee.ntu.edu.twIMAI Takeshi take-i@ceres.dti.ne.jpIMAMURA Tomoaki
tomoak-i@is.aist-nara.ac.jpIan Dowse iedowse@maths.tcd.ieIan Holland ianh@tortuga.com.auIan Struble ian@broken.netIan Vaudrey i.vaudrey@bigfoot.comIgor Khasilev igor@jabber.paco.odessa.uaIgor Roshchin str@giganda.komkon.orgIgor Sviridov siac@ua.netIgor Vinokurov igor@zynaps.ruIkuo Nakagawa ikuo@isl.intec.co.jpIlya V. Komarov mur@lynx.ruIssei Suzuki issei@jp.FreeBSD.orgItsuro Saito saito@miv.t.u-tokyo.ac.jpJ. Bryant jbryant@argus.flash.netJ. David Lowe lowe@saturn5.comJ. Han hjh@best.comJ. Hawk jhawk@MIT.EDUJ.T. Conklin jtc@cygnus.comJ.T. Jang keith@email.gcn.net.twJack jack@zeus.xtalwind.netJacob Bohn Lorensen jacob@jblhome.ping.mkJagane D Sundar jagane@netcom.comJake Hamby jehamby@lightside.comJames Clark jjc@jclark.comJames D. Stewart jds@c4systm.comJames Jegers jimj@miller.cs.uwm.eduJames Raynard
fhackers@jraynard.demon.co.ukJames T. Liu jtliu@phlebas.rockefeller.eduJames da Silva jds@cs.umd.eduJan Conard
charly@fachschaften.tu-muenchen.deJan Koum jkb@FreeBSD.orgJanick Taillandier
Janick.Taillandier@ratp.frJanusz Kokot janek@gaja.ipan.lublin.plJarle Greipsland jarle@idt.unit.noJason Garman init@risen.orgJason Thorpe thorpej@NetBSD.orgJason Wright jason@OpenBSD.orgJason Young
doogie@forbidden-donut.anet-stl.comJavier Martin Rueda jmrueda@diatel.upm.esJay Fenlason hack@datacube.comJaye Mathisen mrcpu@cdsnet.netJeff Bartig jeffb@doit.wisc.eduJeff Forys jeff@forys.cranbury.nj.usJeff Kletsky Jeff@Wagsky.comJeffrey Evans evans@scnc.k12.mi.usJeffrey Wheat jeff@cetlink.netJens Schweikhardt schweikh@noc.dfn.dJeremy Allison jallison@whistle.comJeremy Chatfield jdc@xinside.comJeremy Lea reg@shale.csir.co.zaJeremy Prior unknownJeroen Ruigrok/Asmodai asmodai@wxs.nlJesse Rosenstock jmr@ugcs.caltech.eduJian-Da Li jdli@csie.nctu.edu.twJim Babb babb@FreeBSD.orgJim Binkley jrb@cs.pdx.eduJim Carroll jim@carroll.comJim Flowers jflowers@ezo.netJim Leppek jleppek@harris.comJim Lowe james@cs.uwm.eduJim Mattson jmattson@sonic.netJim Mercer jim@komodo.reptiles.orgJim Mock jim@phrantic.phear.netJim Wilson wilson@moria.cygnus.comJimbo Bahooli
griffin@blackhole.iceworld.orgJin Guojun jin@george.lbl.govJoachim Kuebart unknownJoao Carlos Mendes Luis jonny@jonny.eng.brJochen Pohl jpo.drs@sni.deJoe "Marcus" Clarke marcus@miami.eduJoe Abley jabley@clear.co.nzJoe Jih-Shian Lu jslu@dns.ntu.edu.twJoe Orthoefer j_orthoefer@tia.netJoe Traister traister@mojozone.orgJoel Faedi Joel.Faedi@esial.u-nancy.frJoel Ray Holveck joelh@gnu.orgJoel Sutton sutton@aardvark.apana.org.auJohan Granlund johan@granlund.nuJohan Karlsson k@numeri.campus.luth.seJohan Larsson johan@moon.campus.luth.seJohann Tonsing jtonsing@mikom.csir.co.zaJohannes Helander unknownJohannes Stille unknownJohn Baldwin jobaldwi@vt.eduJohn Beckett jbeckett@southern.eduJohn Beukema jbeukema@hk.super.netJohn Brezak unknownJohn Capo jc@irbs.comJohn F. Woods jfw@jfwhome.funhouse.comJohn Goerzen
jgoerzen@alexanderwohl.complete.orgJohn Hay jhay@mikom.csir.co.zaJohn Heidemann johnh@isi.eduJohn Hood cgull@owl.orgJohn Kohl unknownJohn Lind john@starfire.mn.orgJohn Mackin john@physiol.su.oz.auJohn P johnp@lodgenet.comJohn Perry perry@vishnu.alias.netJohn Preisler john@vapornet.comJohn Rochester jr@cs.mun.caJohn Sadler john_sadler@alum.mit.eduJohn Saunders john@pacer.nlc.net.auJohn W. DeBoskey jwd@unx.sas.comJohn Wehle john@feith.comJohn Woods jfw@eddie.mit.eduJon Morgan morgan@terminus.trailblazer.comJonathan H N Chin jc254@newton.cam.ac.ukJonathan Hanna
jh@pc-21490.bc.rogers.wave.caJorge Goncalves j@bug.fe.up.ptJorge M. Goncalves ee96199@tom.fe.up.ptJos Backus jbackus@plex.nlJose M. Alcaide jose@we.lc.ehu.esJosef Grosch
jgrosch@superior.mooseriver.comJosef Karthauser joe@uk.freebsd.orgJoseph Stein joes@wstein.comJosh Gilliam josh@quick.netJosh Tiefenbach josh@ican.netJuergen Lock nox@jelal.hb.north.deJuha Inkari inkari@cc.hut.fiJukka A. Ukkonen jua@iki.fiJulian Assange proff@suburbia.netJulian Coleman j.d.coleman@ncl.ac.ukJulian H. Stacey jhs@freebsd.orgJulian Jenkins kaveman@magna.com.auJunichi Satoh junichi@jp.freebsd.orgJunji SAKAI sakai@jp.freebsd.orgJunya WATANABE junya-w@remus.dti.ne.jpK.Higashino a00303@cc.hc.keio.ac.jpKUNISHIMA Takeo kunishi@c.oka-pu.ac.jpKai Vorma vode@snakemail.hut.fiKaleb S. Keithley kaleb@ics.comKaneda Hiloshi vanitas@ma3.seikyou.ne.jpKapil Chowksey kchowksey@hss.hns.comKarl Denninger karl@mcs.comKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comKato Takenori
kato@eclogite.eps.nagoya-u.ac.jpKawanobe Koh kawanobe@st.rim.or.jpKazuhiko Kiriyama kiri@kiri.toba-cmt.ac.jpKazuo Horikawa horikawa@jp.FreeBSD.orgKees Jan Koster kjk1@ukc.ac.ukKeith Bostic bostic@bostic.comKeith E. Walker unknownKeith Moore unknownKeith Sklower unknownKen Hornstein unknownKen Key key@cs.utk.eduKen Mayer kmayer@freegate.comKenji Saito marukun@mx2.nisiq.netKenji Tomita tommyk@da2.so-net.or.jpKenneth Furge kenneth.furge@us.endress.comKenneth Monville desmo@bandwidth.orgKenneth R. Westerback krw@tcn.netKenneth Stailey kstailey@gnu.ai.mit.eduKent Talarico kent@shipwreck.tsoft.netKent Vander Velden graphix@iastate.eduKentaro Inagaki JBD01226@niftyserve.ne.jpKevin Bracey kbracey@art.acorn.co.ukKevin Day toasty@dragondata.comKevin Lahey kml@nas.nasa.govKevin Street street@iname.comKevin Van Maren vanmaren@fast.cs.utah.eduKiroh HARADA kiroh@kh.rim.or.jpKlaus Klein kleink@layla.inka.deKlaus-J. Wolf Yanestra@t-online.deKoichi Sato copan@ppp.fastnet.or.jpKostya Lukin lukin@okbmei.msk.suKouichi Hirabayashi kh@mogami-wire.co.jpKurt D. Zeilenga Kurt@Boolean.NETKurt Olsen kurto@tiny.mcs.usu.eduL. Jonas Olsson
ljo@ljo-slip.DIALIN.CWRU.EduLars Köller
Lars.Koeller@Uni-Bielefeld.DELarry Altneu larry@ALR.COMLaurence Lopez lopez@mv.mv.comLee Cremeans lcremean@tidalwave.netLiang Tai-hwa
avatar@www.mmlab.cse.yzu.edu.twLon Willett lon%softt.uucp@math.utah.eduLouis A. Mamakos louie@TransSys.COMLouis Mamakos loiue@TransSys.comLucas James Lucas.James@ldjpc.apana.org.auLyndon Nerenberg lyndon@orthanc.comM.C. Wong unknownMANTANI Nobutaka nobutaka@nobutaka.comMIHIRA Sanpei Yoshiro sanpei@sanpei.orgMITA Yoshio mita@jp.FreeBSD.ORGMITSUNAGA Noriaki
mitchy@er.ams.eng.osaka-u.ac.jpMOROHOSHI Akihiko moro@race.u-tokyo.ac.jpMagnus Enbom dot@tinto.campus.luth.seMahesh Neelakanta mahesh@gcomm.comMakoto MATSUSHITA matusita@jp.freebsd.orgMakoto WATANABE
watanabe@zlab.phys.nagoya-u.ac.jpMalte Lance malte.lance@gmx.netManu Iyengar
iyengar@grunthos.pscwa.psca.comMarc Frajola marc@dev.comMarc Ramirez mrami@mramirez.sy.yale.eduMarc Slemko marcs@znep.comMarc van Kempen wmbfmk@urc.tue.nlMarcel Moolenaar marcel@scc.nlMario Sergio Fujikawa Ferreira
lioux@gns.com.brMark Andrews unknownMark Cammidge mark@gmtunx.ee.uct.ac.zaMark Diekhans markd@grizzly.comMark Huizer xaa@stack.nlMark J. Taylor mtaylor@cybernet.comMark Krentel krentel@rice.eduMark Mayo markm@vmunix.comMark Thompson thompson@tgsoft.comMark Tinguely tinguely@plains.nodak.eduMark Treacy unknownMark Valentine mark@linus.demon.co.ukMartin BirgmeierMartin Ibert mib@ppe.bb-data.deMartin Kammerhofer dada@sbox.tu-graz.ac.atMartin Renters martin@tdc.on.caMartti Kuparinen
martti.kuparinen@ericsson.comMasachika ISHIZUKA
ishizuka@isis.min.ntt.jpMas.TAKEMURA unknownMasafumi NAKANE max@wide.ad.jpMasahiro Sekiguchi
seki@sysrap.cs.fujitsu.co.jpMasanobu Saitoh msaitoh@spa.is.uec.ac.jpMasanori Kanaoka kana@saijo.mke.mei.co.jpMasanori Kiriake seiken@ARGV.ACMasatoshi TAMURA
tamrin@shinzan.kuee.kyoto-u.ac.jpMats Lofkvist mal@algonet.seMatt Bartley mbartley@lear35.cytex.comMatt Thomas matt@3am-software.comMatt White mwhite+@CMU.EDUMatthew C. Mead mmead@Glock.COMMatthew Cashdollar mattc@rfcnet.comMatthew Flatt mflatt@cs.rice.eduMatthew Fuller fullermd@futuresouth.comMatthew N. Dodd winter@jurai.netMatthew Stein matt@bdd.netMatthias Pfaller leo@dachau.marco.deMatthias Scheler tron@netbsd.orgMattias Gronlund
Mattias.Gronlund@sa.erisoft.seMattias Pantzare pantzer@ludd.luth.seMaurice Castro
maurice@planet.serc.rmit.edu.auMax Euston meuston@jmrodgers.comMax Khon fjoe@husky.iclub.nsu.ruMaxim Bolotin max@rsu.ruMicha Class
michael_class@hpbbse.bbn.hp.comMichael Butler imb@scgt.oz.auMichael Butschky butsch@computi.erols.comMichael Clay mclay@weareb.orgMichael Elbel me@FreeBSD.ORGMichael Galassi nerd@percival.rain.comMichael Hancock michaelh@cet.co.jpMichael Hohmuth hohmuth@inf.tu-dresden.deMichael Perlman canuck@caam.rice.eduMichael Petry petry@netwolf.NetMasters.comMichael Reifenberger root@totum.plaut.deMichael Searle searle@longacre.demon.co.ukMichal Listos mcl@Amnesiac.123.orgMichio Karl Jinbo
karl@marcer.nagaokaut.ac.jpMiguel Angel Sagreras
msagre@cactus.fi.uba.arMihoko Tanaka m_tonaka@pa.yokogawa.co.jpMika Nystrom mika@cs.caltech.eduMikael Hybsch micke@dynas.seMikael Karpberg
karpen@ocean.campus.luth.seMike Del repenting@hotmail.comMike Durian durian@plutotech.comMike Durkin mdurkin@tsoft.sf-bay.orgMike E. Matsnev mike@azog.cs.msu.suMike Evans mevans@candle.comMike Grupenhoff kashmir@umiacs.umd.eduMike Hibler mike@marker.cs.utah.eduMike Karels unknownMike McGaughey mmcg@cs.monash.edu.auMike Meyer mwm@shiva.the-park.comMike Mitchell mitchell@ref.tfs.comMike Murphy mrm@alpharel.comMike Peck mike@binghamton.eduMike Spengler mks@msc.eduMikhail A. Sokolov mishania@demos.suMikhail Teterin mi@aldan.ziplink.netMing-I Hseh PA@FreeBSD.ee.Ntu.edu.TWMitsuru IWASAKI iwasaki@pc.jaring.myMonte Mitzelfelt monte@gonefishing.orgMorgan Davis root@io.cts.comMostyn Lewis mostyn@mrl.comMotoyuki Kasahara m-kasahr@sra.co.jpMotoyuki Konno motoyuki@snipe.rim.or.jpMunechika Sumikawa sumikawa@kame.netMurray Stokely murray@cdrom.comN.G.Smith ngs@sesame.hensa.ac.ukNAGAO Tadaaki nagao@cs.titech.ac.jpNAKAJI Hiroyuki
nakaji@zeisei.dpri.kyoto-u.ac.jpNAKAMURA Kazushi nkazushi@highway.or.jpNAKAMURA Motonori
motonori@econ.kyoto-u.ac.jpNIIMI Satoshi sa2c@and.or.jpNOKUBI Hirotaka h-nokubi@yyy.or.jpNadav Eiron nadav@barcode.co.ilNanbor Wang nw1@cs.wustl.eduNaofumi Honda
honda@Kururu.math.sci.hokudai.ac.jpNaoki Hamada nao@tom-yam.or.jpNarvi narvi@haldjas.folklore.eeNathan Ahlstrom nrahlstr@winternet.comNathan Dorfman nathan@rtfm.netNeal Fachan kneel@ishiboo.comNeil Blakey-Milner nbm@rucus.ru.ac.zaNiall Smart rotel@indigo.ieNick Barnes Nick.Barnes@pobox.comNick Handel nhandel@NeoSoft.comNick Hilliard nick@foobar.org&a.nsayer;Nick Williams njw@cs.city.ac.ukNickolay N. Dudorov nnd@itfs.nsk.suNiklas Hallqvist niklas@filippa.appli.seNisha Talagala nisha@cs.berkeley.eduNo Name ZW6T-KND@j.asahi-net.or.jpNo Name adrian@virginia.eduNo Name alex@elvisti.kiev.uaNo Name anto@netscape.netNo Name bobson@egg.ics.nitch.ac.jpNo Name bovynf@awe.beNo Name burg@is.ge.comNo Name chris@gnome.co.ukNo Name colsen@usa.netNo Name coredump@nervosa.comNo Name dannyman@arh0300.urh.uiuc.eduNo Name davids@SECNET.COMNo Name derek@free.orgNo Name devet@adv.IAEhv.nlNo Name djv@bedford.netNo Name dvv@sprint.netNo Name enami@ba2.so-net.or.jpNo Name flash@eru.tubank.msk.suNo Name flash@hway.ruNo Name fn@pain.csrv.uidaho.eduNo Name gclarkii@netport.neosoft.comNo Name gordon@sheaky.lonestar.orgNo Name graaf@iae.nlNo Name greg@greg.rim.or.jpNo Name grossman@cygnus.comNo Name gusw@fub46.zedat.fu-berlin.deNo Name hfir@math.rochester.eduNo Name hnokubi@yyy.or.jpNo Name iaint@css.tuu.utas.edu.auNo Name invis@visi.comNo Name ishisone@sra.co.jpNo Name iverson@lionheart.comNo Name jpt@magic.netNo Name junker@jazz.snu.ac.krNo Name k-sugyou@ccs.mt.nec.co.jpNo Name kenji@reseau.toyonaka.osaka.jpNo Name kfurge@worldnet.att.netNo Name lh@aus.orgNo Name lhecking@nmrc.ucc.ieNo Name mrgreen@mame.mu.oz.auNo Name nakagawa@jp.freebsd.orgNo Name ohki@gssm.otsuka.tsukuba.ac.jpNo Name owaki@st.rim.or.jpNo Name pechter@shell.monmouth.comNo Name pete@pelican.pelican.comNo Name pritc003@maroon.tc.umn.eduNo Name risner@stdio.comNo Name roman@rpd.univ.kiev.uaNo Name root@ns2.redline.ruNo Name root@uglabgw.ug.cs.sunysb.eduNo Name stephen.ma@jtec.com.auNo Name sumii@is.s.u-tokyo.ac.jpNo Name takas-su@is.aist-nara.ac.jpNo Name tamone@eig.unige.chNo Name tjevans@raleigh.ibm.comNo Name tony-o@iij.ad.jp amurai@spec.co.jpNo Name torii@tcd.hitachi.co.jpNo Name uenami@imasy.or.jpNo Name uhlar@netlab.skNo Name vode@hut.fiNo Name wlloyd@mpd.caNo Name wlr@furball.wellsfargo.comNo Name wmbfmk@urc.tue.nlNo Name yamagata@nwgpc.kek.jpNo Name ziggy@ryan.orgNobuhiro Yasutomi nobu@psrc.isac.co.jpNobuyuki Koganemaru
kogane@koganemaru.co.jpNorio Suzuki nosuzuki@e-mail.ne.jpNoritaka Ishizumi graphite@jp.FreeBSD.ORGNoriyuki Soda soda@sra.co.jpOlaf Wagner wagner@luthien.in-berlin.deOleg Sharoiko os@rsu.ruOliver Breuninger ob@seicom.NETOliver Friedrichs oliver@secnet.comOliver Fromme
oliver.fromme@heim3.tu-clausthal.deOliver Laumann
net@informatik.uni-bremen.deOliver Oberdorf oly@world.std.comOlof Johansson offe@ludd.luth.seOsokin Sergey aka oZZ ozz@freebsd.org.ruPace Willisson pace@blitz.comPaco Rosich rosich@modico.eleinf.uv.esPalle Girgensohn girgen@partitur.seParag Patel parag@cgt.comPascal Pederiva pascal@zuo.dec.comPasvorn Boonmark boonmark@juniper.netPatrick Gardella patrick@cre8tivegroup.comPatrick Hausen unknownPaul Antonov apg@demos.suPaul F. Werkowski unknownPaul Fox pgf@foxharp.boston.ma.usPaul Koch koch@thehub.com.auPaul Kranenburg pk@NetBSD.orgPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPaul S. LaFollette, Jr. unknownPaul Saab paul@mu.orgPaul Sandys myj@nyct.netPaul T. Root proot@horton.iaces.comPaul Vixie paul@vix.comPaulo Menezes paulo@isr.uc.ptPaulo Menezes pm@dee.uc.ptPedro A M Vazquez vazquez@IQM.Unicamp.BRPedro Giffuni giffunip@asme.orgPete Bentley pete@demon.netPeter Childs pjchilds@imforei.apana.org.auPeter Cornelius pc@inr.fzk.dePeter Haight peterh@prognet.comPeter Jeremy perer.jeremy@alcatel.com.auPeter M. Chen pmchen@eecs.umich.eduPeter Much peter@citylink.dinoex.sub.orgPeter Olsson unknownPeter Philipp pjp@bsd-daemon.netPeter Stubbs PETERS@staidan.qld.edu.auPhil Maker pjm@cs.ntu.edu.auPhil Sutherland
philsuth@mycroft.dialix.oz.auPhil Taylor phil@zipmail.co.ukPhilip Musumeci philip@rmit.edu.auPierre Y. Dampure pierre.dampure@k2c.co.ukPius Fischer pius@ienet.comPomegranate daver@flag.blackened.netPowerdog Industries
kevin.ruddy@powerdog.comR. Kym HorsellRajesh Vaidheeswarran rv@fore.comRalf Friedl friedl@informatik.uni-kl.deRandal S. Masutani randal@comtest.comRandall Hopper rhh@ct.picker.comRandall W. Dean rwd@osf.orgRandy Bush rbush@bainbridge.verio.netReinier Bezuidenhout
rbezuide@mikom.csir.co.zaRemy Card Remy.Card@masi.ibp.frRicardas Cepas rch@richard.eu.orgRiccardo Veraldi veraldi@cs.unibo.itRichard Henderson richard@atheist.tamu.eduRichard Hwang rhwang@bigpanda.comRichard J Kuhns rjk@watson.grauel.comRichard M. Neswold
rneswold@drmemory.fnal.govRichard Seaman, Jr. dick@tar.comRichard Stallman rms@gnu.ai.mit.eduRichard Straka straka@user1.inficad.comRichard Tobin richard@cogsci.ed.ac.ukRichard Wackerbarth rkw@Dataplex.NETRichard Winkel rich@math.missouri.eduRichard Wiwatowski rjwiwat@adelaide.on.netRick Macklem rick@snowhite.cis.uoguelph.caRick Macklin unknownRob Austein sra@epilogue.comRob Mallory rmallory@qualcomm.comRob Snow rsnow@txdirect.netRobert Crowe bob@speakez.comRobert D. Thrush rd@phoenix.aii.comRobert Eckardt
roberte@MEP.Ruhr-Uni-Bochum.deRobert Sanders rsanders@mindspring.comRobert Sexton robert@kudra.comRobert Shady rls@id.netRobert Swindells swindellsr@genrad.co.ukRobert Watson robert@cyrus.watson.orgRobert Withrow witr@rwwa.comRobert Yoder unknownRobin Carey
robin@mailgate.dtc.rankxerox.co.ukRoger Hardiman roger@cs.strath.ac.ukRoland Jesse jesse@cs.uni-magdeburg.deRon Bickers rbickers@intercenter.netRon Lenk rlenk@widget.xmission.comRonald Kuehn kuehn@rz.tu-clausthal.deRudolf Cejka unknownRuslan Belkin rus@home2.UA.netRuslan Ermilov ru@ucb.crimea.uaRuslan Shevchenko rssh@cam.grad.kiev.uaRussell L. Carter rcarter@pinyon.orgRussell Vincent rv@groa.uct.ac.zaRyan Younce ryany@pobox.comSANETO Takanori sanewo@strg.sony.co.jpSAWADA Mizuki miz@qb3.so-net.ne.jpSUGIMURA Takashi sugimura@jp.FreeBSD.ORGSURANYI Peter
suranyip@jks.is.tsukuba.ac.jpSakari Jalovaara sja@tekla.fiSam Hartman hartmans@mit.eduSamuel Lam skl@ScalableNetwork.comSamuele Zannoli zannoli@cs.unibo.itSander Vesik sander@haldjas.folklore.eeSandro Sigala ssigala@globalnet.itSascha Blank blank@fox.uni-trier.deSascha Wildner swildner@channelz.GUN.deSatoh Junichi junichi@astec.co.jpScot Elliott scot@poptart.orgScot W. Hetzel hetzels@westbend.netScott A. Kenney saken@rmta.ml.orgScott Blachowicz
scott.blachowicz@seaslug.orgScott Burris scott@pita.cns.ucla.eduScott Hazen Mueller scott@zorch.sf-bay.orgScott Michel scottm@cs.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSebastian Strollo seb@erix.ericsson.seSeigou TANIMURA
tanimura@naklab.dnj.ynu.ac.jpSerge A. Babkin babkin@hq.icb.chel.suSerge V. Vakulenko vak@zebub.msk.suSergei Chechetkin
csl@whale.sunbay.crimea.uaSergei S. Laskavy laskavy@pc759.cs.msu.suSergey Gershtein sg@mplik.ruSergey Potapov sp@alkor.ruSergey Shkonda serg@bcs.zp.uaSergey V.Dorokhov svd@kbtelecom.nalnet.ruSergio Lenzi lenzi@bsi.com.brShaun Courtney shaun@emma.eng.uct.ac.zaShawn M. Carey smcarey@mailbox.syr.eduSheldon Hearn axl@iafrica.comShigio Yamaguchi shigio@wafu.netgate.netShinya Esu esu@yk.rim.or.jpShunsuke Akiyama akiyama@jp.freebsd.orgSimon simon@masi.ibp.frSimon Burge simonb@telstra.com.auSimon J Gerraty sjg@melb.bull.oz.auSimon Marlow simonm@dcs.gla.ac.ukSimon Shapiro shimon@simon-shapiro.orgSin'ichiro MIYATANI siu@phaseone.co.jpSlaven Rezic eserte@cs.tu-berlin.deSoochon Radee slr@mitre.orgSoren Dayton csdayton@midway.uchicago.eduSoren Dossing sauber@netcom.comSoren S. Jorvang soren@dt.dkStefan Bethke stb@hanse.deStefan Eggers seggers@semyam.dinoco.deStefan Moeding s.moeding@ndh.netStefan Petri unknownStefan `Sec` Zehl sec@42.orgSteinar Haug sthaug@nethelp.noStephane E. Potvin sepotvin@videotron.caStephane Legrand stephane@lituus.frStephen Clawson
sclawson@marker.cs.utah.eduStephen F. Combs combssf@salem.ge.comStephen Farrell stephen@farrell.orgStephen Hocking sysseh@devetir.qld.gov.auStephen J. Roznowski sjr@home.netStephen McKay syssgm@devetir.qld.gov.auStephen Melvin melvin@zytek.comSteve Bauer sbauer@rock.sdsmt.eduSteve Coltrin spcoltri@io.comSteve Deering unknownSteve Gerakines steve2@genesis.tiac.netSteve Gericke steveg@comtrol.comSteve Piette steve@simon.chi.il.USSteve Schwarz schwarz@alpharel.comSteven G. Kargl
kargl@troutmask.apl.washington.eduSteven H. Samorodin samorodi@NUXI.comSteven McCanne mccanne@cs.berkeley.eduSteven Plite splite@purdue.eduSteven Wallace unknownStuart Henderson
stuart@internationalschool.co.ukSue Blake sue@welearn.com.auSugimoto Sadahiro ixtl@komaba.utmc.or.jpSugiura Shiro ssugiura@duo.co.jpSujal Patel smpatel@wam.umd.eduSune Stjerneby stjerneby@usa.netSuzuki Yoshiaki
zensyo@ann.tama.kawasaki.jpTadashi Kumano kumano@strl.nhk.or.jpTaguchi Takeshi taguchi@tohoku.iij.ad.jpTakahashi Yoshihiro nyan@dd.catv.ne.jpTakahiro Yugawa yugawa@orleans.rim.or.jpTakanori Watanabe
takawata@shidahara1.planet.sci.kobe-u.ac.jpTakashi Mega mega@minz.orgTakashi Uozu j1594016@ed.kagu.sut.ac.jpTakayuki Ariga a00821@cc.hc.keio.ac.jpTakeru NAIKI naiki@bfd.es.hokudai.ac.jpTakeshi Amaike amaike@iri.co.jpTakeshi MUTOH mutoh@info.nara-k.ac.jpTakeshi Ohashi
ohashi@mickey.ai.kyutech.ac.jpTakeshi WATANABE
watanabe@crayon.earth.s.kobe-u.ac.jpTakuya SHIOZAKI
tshiozak@makino.ise.chuo-u.ac.jpTatoku Ogaito tacha@tera.fukui-med.ac.jpTatsumi HOSOKAWA hosokawa@jp.FreeBSD.orgTed Buswell tbuswell@mediaone.netTed Faber faber@isi.eduTed Lemon unknownTerry Lambert terry@lambert.orgTerry Lee terry@uivlsi.csl.uiuc.eduTetsuya Furukawa tetsuya@secom-sis.co.jpTheo de Raadt deraadt@OpenBSD.orgThomas thomas@mathematik.uni-Bremen.deThomas D. Dean tomdean@ix.netcom.comThomas David Rivers rivers@dignus.comThomas G. McWilliams tgm@netcom.comThomas Gellekum
thomas@ghpc8.ihf.rwth-aachen.deThomas Graichen
graichen@omega.physik.fu-berlin.deThomas König
Thomas.Koenig@ciw.uni-karlsruhe.deThomas Ptacek unknownThomas Stevens tas@stevens.orgThomas Stromberg tstrombe@rtci.comThomas Valentino Crimi
tcrimi+@andrew.cmu.eduThomas Wintergerst thomas@lemur.nord.deÞórður Ívarsson
totii@est.isTim Kientzle kientzle@netcom.comTim Singletary
tsingle@sunland.gsfc.nasa.govTim Wilkinson tim@sarc.city.ac.ukTimo J. Rinne tri@iki.fiTodd Miller millert@openbsd.orgTom root@majestix.cmr.noTom tom@sdf.comTom Gray - DCA dcasba@rain.orgTom Hukins tom@eborcom.comTom Jobbins tom@tom.tjTom Pusateri pusateri@juniper.netTom Rush tarush@mindspring.comTom Samplonius tom@misery.sdf.comTomohiko Kurahashi
kura@melchior.q.t.u-tokyo.ac.jpTony Kimball alk@Think.COMTony Li tli@jnx.comTony Lynn wing@cc.nsysu.edu.twTorbjorn Granlund tege@matematik.su.seToshihiko ARAI toshi@tenchi.ne.jpToshihiko SHIMOKAWA toshi@tea.forus.or.jpToshihiro Kanda candy@kgc.co.jpToshiomi Moriki
Toshiomi.Moriki@ma1.seikyou.ne.jpTrefor S. trefor@flevel.co.ukTrevor Blackwell tlb@viaweb.comURATA Shuichiro s-urata@nmit.tmg.nec.co.jpUdo Schweigert ust@cert.siemens.deUgo Paternostro paterno@dsi.unifi.itUlf Kieber kieber@sax.deUlli Linzen ulli@perceval.camelot.deUstimenko Semen semen@iclub.nsu.ruUwe Arndt arndt@mailhost.uni-koblenz.deVadim Chekan vadim@gc.lviv.uaVadim Kolontsov vadim@tversu.ac.ruVadim Mikhailov mvp@braz.ruVan Jacobson van@ee.lbl.govVasily V. Grechishnikov
bazilio@ns1.ied-vorstu.ac.ruVasim Valejev vasim@uddias.diaspro.comVernon J. Schryver vjs@mica.denver.sgi.comVic Abell abe@cc.purdue.eduVille Eerola ve@sci.fiVincent Poy vince@venus.gaianet.netVincenzo Capuano
VCAPUANO@vmprofs.esoc.esa.deVirgil Champlin champlin@pa.dec.comVladimir A. Jakovenko
vovik@ntu-kpi.kiev.uaVladimir Kushnir kushn@mail.kar.netVsevolod Lobko seva@alex-ua.comW. Gerald Hicks wghicks@bellsouth.netW. Richard Stevens rstevens@noao.eduWalt Howard howard@ee.utah.eduWarren Toomey wkt@csadfa.cs.adfa.oz.auWayne Scott wscott@ichips.intel.comWerner Griessl
werner@btp1da.phy.uni-bayreuth.deWes Santee wsantee@wsantee.oz.netWietse Venema wietse@wzv.win.tue.nlWilfredo Sanchez wsanchez@apple.comWiljo Heinen wiljo@freeside.ki.open.deWilko Bulte wilko@yedi.iaf.nlWillem Jan Withagen wjw@surf.IAE.nlWilliam Jolitz withheldWilliam Liao william@tale.netWojtek Pilorz
wpilorz@celebris.bdk.lublin.plWolfgang Helbig helbig@ba-stuttgart.deWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@FreeBSD.orgWu Ching-hong woju@FreeBSD.ee.Ntu.edu.TWYarema yds@ingress.comYaroslav Terletsky ts@polynet.lviv.uaYasuhito FUTATSUKI futatuki@fureai.or.jpYen-Shuo Su yssu@CCCA.NCTU.edu.twYing-Chieh Liao ijliao@csie.NCTU.edu.twYixin Jin yjin@rain.cs.ucla.eduYoshiaki Uchikawa yoshiaki@kt.rim.or.jpYoshihiko OHTA yohta@bres.tsukuba.ac.jpYoshihisa NAKAGAWA
y-nakaga@ccs.mt.nec.co.jpYoshikazu Goto gotoh@ae.anritsu.co.jpYoshimasa Ohnishi
ohnishi@isc.kyutech.ac.jpYoshishige Arai ryo2@on.rim.or.jpYuichi MATSUTAKA matutaka@osa.att.ne.jpYujiro MIYATA
miyata@bioele.nuee.nagoya-u.ac.jpYukihiro Nakai nacai@iname.comYusuke Nawano azuki@azkey.orgYuu Yashiki s974123@cc.matsuyama-u.ac.jpYuval Yarom yval@cs.huji.ac.ilYves Fonk yves@cpcoup5.tn.tudelft.nlYves Fonk yves@dutncp8.tn.tudelft.nlZach Heilig zach@gaffaneys.comZahemszhky Gabor zgabor@code.huZhong Ming-Xun zmx@mail.CDPA.nsysu.edu.twarci vega@sophia.inria.frder Mouse mouse@Collatz.McRCIM.McGill.EDUfrf frf@xocolatl.comEge Rekk aagero@aage.priv.no386BSD Patch Kit Patch Contributors(in alphabetical order by first name):Adam Glass glass@postgres.berkeley.eduAdrian Hall adrian@ibmpcug.co.ukAndrey A. Chernov ache@astral.msk.suAndrew Herbert andrew@werple.apana.org.auAndrew Moore alm@netcom.comAndy Valencia ajv@csd.mot.comjtk@netcom.comArne Henrik Juul arnej@Lise.Unit.NOBakul Shah bvs@bitblocks.comBarry Lustig barry@ictv.comBob Wilcox bob@obiwan.uucpBranko LankesterBrett Lymn blymn@mulga.awadi.com.AUCharles Hannum mycroft@ai.mit.eduChris G. Demetriou
cgd@postgres.berkeley.eduChris Torek torek@ee.lbl.govChristoph Robitschko
chmr@edvz.tu-graz.ac.atDaniel Poirot poirot@aio.jsc.nasa.govDave Burgess burgess@hrd769.brooks.af.milDave Rivers rivers@ponds.uucpDavid Dawes dawes@physics.su.OZ.AUDavid Greenman dg@Root.COMEric J. Haug ejh@slustl.slu.eduFelix Gaehtgens
felix@escape.vsse.in-berlin.deFrank Maclachlan fpm@crash.cts.comGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGeoff Rehmet csgr@alpha.ru.ac.zaGoran Hammarback goran@astro.uu.seGuido van Rooij guido@gvr.orgGuy Harris guy@auspex.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHerb Peyerl hpeyerl@novatel.cuc.ab.caHolger Veit Holger.Veit@gmd.deIshii Masahiro, R. Kym HorsellJ.T. Conklin jtc@cygnus.comJagane D Sundar jagane@netcom.comJames Clark jjc@jclark.comJames Jegers jimj@miller.cs.uwm.eduJames W. DolterJames da Silva jds@cs.umd.edu et alJay Fenlason hack@datacube.comJim Wilson wilson@moria.cygnus.comJörg Lohse
lohse@tech7.informatik.uni-hamburg.deJörg Wunsch
joerg_wunsch@uriah.heep.sax.deJohn DysonJohn Woods jfw@eddie.mit.eduJordan K. Hubbard jkh@whisker.hubbard.ieJulian Elischer julian@dialix.oz.auJulian Stacey jhs@freebsd.orgKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comkarl@one.neosoft.comKeith Bostic bostic@toe.CS.Berkeley.EDUKen HughesKent Talarico kent@shipwreck.tsoft.netKevin Lahey kml%rokkaku.UUCP@mathcs.emory.edukml@mosquito.cis.ufl.eduMarc Frajola marc@dev.comMark Tinguely tinguely@plains.nodak.edutinguely@hookie.cs.ndsu.NoDak.eduMartin Renters martin@tdc.on.caMichael Clay mclay@weareb.orgMichael Galassi nerd@percival.rain.comMike Durkin mdurkin@tsoft.sf-bay.orgNaoki Hamada nao@tom-yam.or.jpNate Williams nate@bsd.coe.montana.eduNick Handel nhandel@NeoSoft.comnick@madhouse.neosoft.comPace Willisson pace@blitz.comPaul Kranenburg pk@cs.few.eur.nlPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPeter da Silva peter@NeoSoft.comPhil Sutherland
philsuth@mycroft.dialix.oz.auPoul-Henning Kampphk@FreeBSD.ORGRalf Friedl friedl@informatik.uni-kl.deRick Macklem root@snowhite.cis.uoguelph.caRobert D. Thrush rd@phoenix.aii.comRodney W. Grimes rgrimes@cdrom.comSascha Wildner swildner@channelz.GUN.deScott Burris scott@pita.cns.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSean Eric Fagan sef@kithrup.comSimon J Gerraty sjg@melb.bull.oz.ausjg@zen.void.oz.auStephen McKay syssgm@devetir.qld.gov.auTerry Lambert terry@icarus.weber.eduTerry Lee terry@uivlsi.csl.uiuc.eduTor Egge Tor.Egge@idi.ntnu.noWarren Toomey wkt@csadfa.cs.adfa.oz.auWiljo Heinen wiljo@freeside.ki.open.deWilliam Jolitz withheldWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@dentaro.GUN.deYuval Yarom yval@cs.huji.ac.il
diff --git a/en_US.ISO8859-1/books/handbook/ports/chapter.sgml b/en_US.ISO8859-1/books/handbook/ports/chapter.sgml
index 23009b15fa..dc2cf404cc 100644
--- a/en_US.ISO8859-1/books/handbook/ports/chapter.sgml
+++ b/en_US.ISO8859-1/books/handbook/ports/chapter.sgml
@@ -1,4501 +1,4501 @@
Installing Applications: The Ports collectionContributed by &a.jraynard;.The FreeBSD Ports collection allows you to compile and install a very
wide range of applications with a minimum of effort.For all the hype about open standards, getting a program to work on
different versions of Unix in the real world can be a tedious and tricky
business, as anyone who has tried it will know. You may be lucky enough
to find that the program you want will compile cleanly on your system,
install itself in all the right places and run flawlessly “out of
the box”, but this is unfortunately rather rare. With most
programs, you will find yourself doing a fair bit of head-scratching, and
there are quite a few programs that will result in premature greying, or
even chronic alopecia...Some software distributions have attacked this problem by providing
configuration scripts. Some of these are very clever, but they have an
unfortunate tendency to triumphantly announce that your system is
something you have never heard of and then ask you lots of questions that
sound like a final exam in system-level Unix programming (Does
your system's gethitlist function return a const pointer to a fromboz or
a pointer to a const fromboz? Do you have Foonix style unacceptable
exception handling? And if not, why not?).Fortunately, with the Ports collection, all the hard work involved has
already been done, and you can just type make install
and get a working program.Why Have a Ports Collection?The base FreeBSD system comes with a very wide range of tools and
system utilities, but a lot of popular programs are not in the base
system, for good reasons:-Programs that some people cannot live without and other people
cannot stand, such as a certain Lisp-based editor.Programs which are too specialised to put in the base system
(CAD, databases).Programs which fall into the “I must have a look at that
when I get a spare minute” category, rather than
system-critical ones (some languages, perhaps).Programs that are far too much fun to be supplied with a serious
operating system like FreeBSD ;-)However many programs you put in the base system, people will
always want more, and a line has to be drawn somewhere (otherwise
FreeBSD distributions would become absolutely enormous).Obviously it would be unreasonable to expect everyone to port their
favourite programs by hand (not to mention a tremendous amount of
duplicated work), so the FreeBSD Project came up with an ingenious way
of using standard tools that would automate the process.Incidentally, this is an excellent illustration of how “the
Unix way” works in practice by combining a set of simple but very
flexible tools into something very powerful.How Does the Ports Collection Work?Programs are typically distributed on the Internet as a tarball consisting of a Makefile and
the source code for the program and usually some instructions (which are
unfortunately not always as instructive as they could be), with perhaps
a configuration script.The standard scenario is that you FTP down the tarball, extract it
somewhere, glance through the instructions, make any changes that seem
necessary, run the configure script to set things up and use the
standard make program to compile and install the
program from the source.FreeBSD ports still use the tarball mechanism, but use a skeleton to hold the
"knowledge" of how to get the program working on FreeBSD,
rather than expecting the user to be able to work it out. They also
supply their own customised Makefile, so that almost every port
can be built in the same way.If you look at a port skeleton (either on your FreeBSD
system or the
FTP site) and expect to find all sorts of pointy-headed rocket
science lurking there, you may be disappointed by the one or two rather
unexciting-looking files and directories you find there. (We will
discuss in a minute how to go about Getting a port).“How on earth can this do anything?” I hear you cry.
“There is no source code there!”Fear not, gentle reader, all will become clear (hopefully). Let's
see what happens if we try and install a port. I have chosen
ElectricFence, a useful tool for developers,
as the skeleton is more straightforward than most.If you are trying this at home, you will need to be root.&prompt.root; cd /usr/ports/devel/ElectricFence
&prompt.root; make install
>> Checksum OK for ElectricFence-2.0.5.tar.gz.
===> Extracting for ElectricFence-2.0.5
===> Patching for ElectricFence-2.0.5
===> Applying FreeBSD patches for ElectricFence-2.0.5
===> Configuring for ElectricFence-2.0.5
===> Building for ElectricFence-2.0.5
[lots of compiler output...]
===> Installing for ElectricFence-2.0.5
===> Warning: your umask is "0002". If this is not desired, set it to
an appropriate value and install this port again by ``make reinstall''.
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.a /usr/local/lib
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.3 /usr/local/man/man3
===> Compressing manual pages for ElectricFence-2.0.5
===> Registering installation for ElectricFence-2.0.5To avoid confusing the issue, I have completely removed the build
output.If you tried this yourself, you may well have got something like
this at the start:-&prompt.root; make install
>> ElectricFence-2.0.5.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://ftp.doc.ic.ac.uk/Mirrors/sunsite.unc.edu/pub/Linux/devel/lang/c/.The make program has noticed that you did not
have a local copy of the source code and tried to FTP it down so it
could get the job done. I already had the source handy in my example,
so it did not need to fetch it.Let's go through this and see what the make
program was doing.Locate the source code tarball. If it is not available
locally, try to grab it from an FTP site.Run a checksum test on the
tarball to make sure it has not been tampered with, accidentally
truncated, downloaded in ASCII mode, struck by neutrinos while in
transit, etc.Extract the tarball into a temporary work directory.Apply any patches needed to
get the source to compile and run under FreeBSD.Run any configuration script required by the build process and
correctly answer any questions it asks.(Finally!) Compile the code.Install the program executable and other supporting files, man
pages, etc. under the /usr/local hierarchy,
where they will not get mixed up with system programs. This also
makes sure that all the ports you install will go in the same place,
instead of being flung all over your system.Register the installation in a database. This means that, if
you do not like the program, you can cleanly remove all traces of it from your
system.Scroll up to the make output and see if you can
match these steps to it. And if you were not impressed before, you
should be by now!Getting a FreeBSD PortThere are two ways of getting hold of the FreeBSD port for a
program. One requires a FreeBSD CDROM,
the other involves using an Internet
Connection.Compiling ports from CDROMAssuming that your FreeBSD CDROM is in the drive and mounted on
/cdrom (and the mount point
must be /cdrom), you should
then be able to build ports just as you normally do and the port
collection's built in search path should find the tarballs in
/cdrom/ports/distfiles/ (if they exist there)
rather than downloading them over the net.Another way of doing this, if you want to just use the port
skeletons on the CDROM, is to set these variables in
/etc/make.conf:
PORTSDIR= /cdrom/ports
DISTDIR= /tmp/distfiles
WRKDIRPREFIX= /tmpSubstitute /tmp for any place you have enough
free space. Then, just cd to the appropriate
subdirectory under /cdrom/ports and type
make install as usual.
WRKDIRPREFIX will cause the port to be build under
/tmp/cdrom/ports; for instance,
games/oneko will be built under
/tmp/cdrom/ports/games/oneko.There are some ports for which we cannot provide the original
source in the CDROM due to licensing limitations. In that case, you
will need to look at the section on Compiling ports using an Internet
connection.Compiling ports from the InternetIf you do not have a CDROM, or you want to make sure you get the
very latest version of the port you want, you will need to download
the skeleton for the port. Now
this might sound like rather a fiddly job full of pitfalls, but it is
actually very easy.First, if you are running a release version of FreeBSD, make sure
you get the appropriate “upgrade kit” for your release
from the ports web
page. These packages include files that have been updated
since the release that you may need to compile new ports.The key to the skeletons is that the FreeBSD FTP server can create
on-the-fly tarballs for you.
Here is how it works, with the gnats program in the databases
directory as an example (the bits in square brackets are comments. Do
not type them in if you are trying this yourself!):-&prompt.root; cd /usr/ports
&prompt.root; mkdir databases
&prompt.root; cd databases
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports/databases>get gnats.tar
[tars up the gnats skeleton for us]
>quit
&prompt.root; tar xf gnats.tar
[extract the gnats skeleton]
&prompt.root; cd gnats
&prompt.root; make install
[build and install gnats]What happened here? We connected to the FTP server in the usual
way and went to its databases sub-directory.
When we gave it the command get gnats.tar, the FTP
server tarred up the gnats
directory for us.We then extracted the gnats skeleton and went into the gnats
directory to build the port. As we explained earlier, the make process noticed we
did not have a copy of the source locally, so it fetched one before
extracting, patching and building it.Let's try something more ambitious now. Instead of getting a
single port skeleton, let's get a whole sub-directory, for example all
the database skeletons in the ports collection. It looks almost the
same:-&prompt.root; cd /usr/ports
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports>get databases.tar
[tars up the databases directory for us]
>quit
&prompt.root; tar xf databases.tar
[extract all the database skeletons]
&prompt.root; cd databases
&prompt.root; make install
[build and install all the database ports]With half a dozen straightforward commands, we have now got a set
of database programs on our FreeBSD machine! All we did that was
different from getting a single port skeleton and building it was that
we got a whole directory at once, and compiled everything in it at
once. Pretty impressive, no?If you expect to be installing many ports, it is probably worth
downloading all the ports directories.SkeletonsA team of compulsive hackers who have forgotten to eat in a frantic
attempt to make a deadline? Something unpleasant lurking in the FreeBSD
attic? No, a skeleton here is a minimal framework that supplies
everything needed to make the ports magic work.MakefileThe most important component of a skeleton is the Makefile. This
contains various statements that specify how the port should be
compiled and installed. Here is the Makefile for
ElectricFence:-
# New ports collection makefile for: Electric Fence
# Version required: 2.0.5
# Date created: 13 November 1997
# Whom: jraynard
#
# $Id$
#
DISTNAME= ElectricFence-2.0.5
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= devel/lang/c
MAINTAINER= jraynard@freebsd.org
MAN3= libefence.3
do-install:
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
.include <bsd.port.mk>The lines beginning with a "#" sign are comments for the
benefit of human readers (as in most Unix script files).DISTNAME specifies the name of the tarball, but without the
extension.CATEGORIES states what kind of program this is.
In this case, a utility for developers. See the categories section of this
handbook for a complete list.MASTER_SITES is the URL(s) of the master FTP
site, which is used to retrieve the tarball if it is not available on the
local system. This is a site which is regarded as reputable, and is
normally the one from which the program is officially distributed (in
so far as any software is "officially" distributed on the
Internet).MAINTAINER is the email address of the person
who is responsible for updating the skeleton if, for example a new
version of the program comes out.Skipping over the next few lines for a minute, the line
.include <bsd.port.mk> says that the other
statements and commands needed for this port are in a standard file
called bsd.port.mk. As these are the same for
all ports, there is no point in duplicating them all over the place,
so they are kept in a single standard file.This is probably not the place to go into a detailed examination
of how Makefiles work; suffice it to say that the line starting with
MAN3 ensures that the ElectricFence man page is
compressed after installation, to help conserve your precious disk
space. The original port did not provide an
install target, so the three lines from
do-install ensure that the files produced by
this port are placed in the correct destination.The files directoryThe file containing the checksum for the port is called
md5, after the MD5 algorithm used for ports
checksums. It lives in a directory with the slightly confusing name
of files.This directory can also contain other miscellaneous files that are
required by the port and do not belong anywhere else.The patches directoryThis directory contains the patches needed to make everything work
properly under FreeBSD.The pkg directoryThis program contains three quite useful files:-COMMENT — a one-line description of
the program.DESCR — a more detailed
description.PLIST — a list of all the files
that will be created when the program is installed.What to do when a port does not work.Oh. You can do one of four (4) things :Fix it yourself. Technical details on how ports work can be
found in Porting applications.Gripe. This is done by e-mail only! Send
such e-mail to the &a.ports; and please include the name/version of
the port, where you got both the port source & distfile(s) from,
and what the text of the error was.Forget it. This is the easiest for most — very few of the
programs in ports can be classified as essential!Grab the pre-compiled package from a ftp server. The
“master” package collection is on FreeBSD's FTP server
in the packages
directory, though check your local mirror first, please!
These are more likely to work (on the whole) than trying to compile
from source and a lot faster besides! Use the &man.pkg.add.1;
program to install a package file on your
system.Some Questions and AnswersQ. I thought this was going to be a discussion about
modems??!A. Ah. You must be thinking of the serial ports on the back of
your computer. We are using “port” here to mean the
result of “porting” a program from one version of Unix
to another. (It is an unfortunate bad habit of computer people to
use the same word to refer to several completely different
things).Q. I thought you were supposed to use packages to install extra
programs?A. Yes, that is usually the quickest and easiest way of doing
it.Q. So why bother with ports then?A. Several reasons:-The licensing conditions on some software distributions
require that they be distributed as source code, not
binaries.Some people do not trust binary distributions. At least
with source code you can (in theory) read through it and look
for potential problems yourself.If you have some local patches, you will need the source to
add them yourself.You might have opinions on how a program should be compiled
that differ from the person who did the package — some
people have strong views on what optimisation setting should be
used, whether to build debug versions and then strip them or
not, etc. etc.Some people like having code around, so they can read it if
they get bored, hack around with it, borrow from it (licence
terms permitting, of course!) and so on.If you ain't got the source, it ain't software! ;-) Q. What is a patch?A. A patch is a small (usually) file that specifies how to go
from one version of a file to another. It contains text that says,
in effect, things like “delete line 23”, “add
these two lines after line 468” or “change line 197 to
this”. Also known as a “diff”, since it is
generated by a program of that name. Q. What is all this about
tarballs?A. It is a file ending in .tar or
.tar.gz (with variations like
.tar.Z, or even .tgz if
you are trying to squeeze the names into a DOS filesystem).Basically, it is a directory tree that has been archived into a
single file (.tar) and optionally compressed
(.gz). This technique was originally used for
Tape ARchives (hence the
name tar), but it is a widely used way of
distributing program source code around the Internet.You can see what files are in them, or even extract them
yourself, by using the standard Unix tar program, which comes with
the base FreeBSD system, like this:-&prompt.user; tar tvzf foobar.tar.gz
&prompt.user; tar xzvf foobar.tar.gz
&prompt.user; tar tvf foobar.tar
&prompt.user; tar xvf foobar.tar Q. And a checksum?A. It is a number generated by adding up all the data in the
file you want to check. If any of the characters change, the
checksum will no longer be equal to the total, so a simple
comparison will allow you to spot the difference. (In practice, it
is done in a more complicated way to spot problems like
position-swapping, which will not show up with a simplistic
addition).Q. I did what you said for compiling
ports from a CDROM and it worked great until I tried to
install the kermit port:-&prompt.root; make install
>> cku190.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://kermit.columbia.edu/kermit/archives/.Why can it not be found? Have I got a dud CDROM?A. The licensing terms for kermit do not allow us to put the
tarball for it on the CDROM, so you will have to fetch it by hand
— sorry! The reason why you got all those error messages was
because you were not connected to the Internet at the time. Once
you have downloaded it from any of the sites above, you can re-start
the process (try and choose the nearest site to you, though, to save
your time and the Internet's bandwidth).Q. I did that, but when I tried to put it into
/usr/ports/distfiles I got some error about not
having permission.A. The ports mechanism looks for the tarball in
/usr/ports/distfiles, but you will not be able
to copy anything there because it is sym-linked to the CDROM, which
is read-only. You can tell it to look somewhere else by
doing&prompt.root; make DISTDIR=/where/you/put/it installQ. Does the ports scheme only work if you have everything in
/usr/ports? My system administrator says I must
put everything under
/u/people/guests/wurzburger, but it does not
seem to work.A. You can use the PORTSDIR and
PREFIX variables to tell the ports mechanism to
use different directories. For instance,&prompt.root; make PORTSDIR=/u/people/guests/wurzburger/ports installwill compile the port in
/u/people/guests/wurzburger/ports and install
everything under /usr/local.&prompt.root; make PREFIX=/u/people/guests/wurzburger/local installwill compile it in /usr/ports and install
it in /u/people/guests/wurzburger/local.And of course&prompt.root; make PORTSDIR=.../ports PREFIX=.../local installwill combine the two (it is too long to fit on the page if I
write it in full, but I am sure you get the idea).If you do not fancy typing all that in every time you install a
port (and to be honest, who would?), it is a good idea to put these
variables into your environment.Q. I do not have a FreeBSD CDROM, but I would like to have all
the tarballs handy on my system so I do not have to wait for a
download every time I install a port. Is there an easy way to get
them all at once?A. To get every single tarball for the ports collection,
do&prompt.root; cd /usr/ports
&prompt.root; make fetchFor all the tarballs for a single ports directory, do&prompt.root; cd /usr/ports/directory
&prompt.root; make fetchand for just one port — well, I think you have guessed
already.Q. I know it is probably faster to fetch the tarballs from one
of the FreeBSD mirror sites close by. Is there any way to tell the
port to fetch them from servers other than ones listed in the
MASTER_SITES?A. Yes. If you know, for example, ftp.FreeBSD.ORG is much closer than sites
listed in MASTER_SITES, do as following
example.&prompt.root; cd /usr/ports/directory
&prompt.root; make MASTER_SITE_OVERRIDE=ftp://ftp.FreeBSD.ORG/pub/FreeBSD/ports/distfiles/ fetchQ. I want to know what files make is going to need before it
tries to pull them down.A. make fetch-list will display a list of
the files needed for a port.Q. Is there any way to stop the port from compiling? I want to
do some hacking on the source before I install it, but it is a bit
tiresome having to watch it and hit control-C every time.A. Doing make extract will stop it after it
has fetched and extracted the source code.Q. I am trying to make my own port and I want to be able to
stop it compiling until I have had a chance to see if my patches
worked properly. Is there something like make
extract, but for patches?A. Yep, make patch is what you want. You
will probably find the PATCH_DEBUG option useful
as well. And by the way, thank you for your efforts!Q. I have heard that some compiler options can cause bugs. Is
this true? How can I make sure that I compile ports with the right
settings?A. Yes, with version 2.6.3 of gcc (the
version shipped with FreeBSD 2.1.0 and 2.1.5), the
option could result in buggy code unless you
used the option as well.
(Most of the ports don't use ). You
should be able to specify the compiler options
used by something like&prompt.root; make CFLAGS='-O2 -fno-strength-reduce' installor by editing /etc/make.conf, but
unfortunately not all ports respect this. The surest way is to do
make configure, then go into the source directory
and inspect the Makefiles by hand, but this can get tedious if the
source has lots of sub-directories, each with their own
Makefiles.Q. There are so many ports it is hard to find the one I want.
Is there a list anywhere of what ports are available?A. Look in the INDEX file in
/usr/ports. If you would like to search the
ports collection for a keyword, you can do that too. For example,
you can find ports relevant to the LISP programming language
using:&prompt.user; cd /usr/ports
&prompt.user; make search key=lispQ. I went to install the foo port but the
system suddenly stopped compiling it and starting compiling the
bar port. What's going on?A. The foo port needs something that is
supplied with bar — for instance, if
foo uses graphics, bar might
have a library with useful graphics processing routines. Or
bar might be a tool that is needed to compile the
foo port. Q. I installed the
grizzle program from the ports and frankly it is
a complete waste of disk space. I want to delete it but I do not
know where it put all the files. Any clues?A. No problem, just do&prompt.root; pkg_delete grizzle-6.5
Q. Hang on a minute, you have to know the version number to use
that command. You do not seriously expect me to remember that, do
you??A. Not at all, you can find it out by doing&prompt.root; pkg_info -a | grep grizzle
Information for grizzle-6.5:
grizzle-6.5 - the combined piano tutorial, LOGO interpreter and shoot 'em up arcade game.Q. Talking of disk space, the ports directory seems to be
taking up an awful lot of room. Is it safe to go in there and
delete things?A. Yes, if you have installed the program and are fairly
certain you will not need the source again, there is no point in
keeping it hanging around. The best way to do this is&prompt.root; cd /usr/ports
&prompt.root; make cleanwhich will go through all the ports subdirectories and delete
everything except the skeletons for each port.Q. I tried that and it still left all those tarballs or
whatever you called them in the distfiles
directory. Can I delete those as well?A. Yes, if you are sure you have finished with them, those can
go as well.Q. I like having lots and lots of programs to play with. Is
there any way of installing all the ports in one go?A. Just do&prompt.root; cd /usr/ports
&prompt.root; make installQ. OK, I tried that, but I thought it would take a very long
time so I went to bed and left it to get on with it. When I looked
at the computer this morning, it had only done three and a half
ports. Did something go wrong?A. No, the problem is that some of the ports need to ask you
questions that we cannot answer for you (eg “Do you want to
print on A4 or US letter sized paper?”) and they need to have
someone on hand to answer them.Q. I really do not want to spend all day staring at the
monitor. Any better ideas?A. OK, do this before you go to bed/work/the local
park:-&prompt.root cd /usr/ports
&prompt.root; make -DBATCH installThis will install every port that does not
require user input. Then, when you come back, do&prompt.root; cd /usr/ports
&prompt.root; make -DIS_INTERACTIVE installto finish the job.Q. At work, we are using frobble, which is
in your ports collection, but we have altered it quite a bit to get
it to do what we need. Is there any way of making our own packages,
so we can distribute it more easily around our sites?A. No problem, assuming you know how to make patches for your
changes:-&prompt.root; cd /usr/ports/somewhere/frobble
&prompt.root; make extract
&prompt.root; cd work/frobble-2.8
[Apply your patches]
&prompt.root; cd ../..
&prompt.root; make packageQ. This ports stuff is really clever. I am desperate to find
out how you did it. What is the secret?A. Nothing secret about it at all, just look at the
bsd.ports.mk and
bsd.ports.subdir.mk files in your makefiles
directory.Readers with an aversion to intricate shell-scripts are
advised not to follow this link...)Making a port yourselfContributed by &a.jkh;, &a.gpalmer;, &a.asami; &a.obrien;
and &a.hoek;. 28 August 1996.So, now you are interested in making your own port? Great!What follows are some guidelines for creating a new port for
FreeBSD. The bulk of the work is done by
/usr/ports/Mk/bsd.port.mk, which all port Makefiles
include. Please refer to that file for more details on the inner
workings of the ports collection. Even if you don't hack Makefiles
daily, it is well commented, and you will still gain much knowledge from
it.Only a fraction of the overridable variables
(VAR) are mentioned in
this document. Most (if not all) are documented at the start of
bsd.port.mk. This file users a non-standard tab
setting. Emacs and
Vim should recognise the setting on loading
the file. vi or ex can be set
to use the correct value by typing :set tabstop=4
once the file has been loaded.Quick PortingThis section tells you how to do a quick port. In many cases, it
is not enough, but we will see.First, get the original tarball and put it into
DISTDIR, which defaults to
/usr/ports/distfiles.The following assumes that the software compiled out-of-the-box,
i.e., there was absolutely no change required for the port to work
on your FreeBSD box. If you needed to change something, you will
have to refer to the next section too.Writing the MakefileThe minimal Makefile would look something
like this:
# New ports collection makefile for: oneko
# Version required: 1.1b
# Date created: 5 December 1994
# Whom: asami
#
# $Id$
#
DISTNAME= oneko-1.1b
CATEGORIES= games
MASTER_SITES= ftp://ftp.cs.columbia.edu/archives/X11R5/contrib/
MAINTAINER= asami@FreeBSD.ORG
MAN1= oneko.1
MANCOMPRESSED= yes
USE_IMAKE= yes
.include <bsd.port.mk>See if you can figure it out. Do not worry about the contents
of the $Id$ line, it will be filled in
automatically by CVS when the port is imported to our main ports
tree. You can find a more detailed example in the sample Makefile section.Writing the description filesThere are three description files that are required for any
port, whether they actually package or not. They are
COMMENT, DESCR, and
PLIST, and reside in the
pkg subdirectory.COMMENTThis is the one-line description of the port.
Please do not include the package name (or
version number of the software) in the comment. Here is an
example:
A cat chasing a mouse all over the screen.DESCRThis is a longer description of the port. One to a few
paragraphs concisely explaining what the port does is
sufficient.This is not a manual or an in-depth
description on how to use or compile the port! Please
be careful if you are copying from the
README or manpage; too often
they are not a concise description of the port or are in an
awkward format (e.g., manpages have justified spacing). If the
ported software has an official WWW homepage, you should list it
here. Prefix one of the websites with
WWW: so that automated tools will work
correctly.It is recommended that you sign your name at the end of this
file, as in:
This is a port of oneko, in which a cat chases a poor mouse all over
the screen.
:
(etc.)
WWW: http://www.oneko.org/
- Satoshi
asami@cs.berkeley.eduPLISTThis file lists all the files installed by the port. It is
also called the “packing list” because the package is
generated by packing the files listed here. The pathnames are
relative to the installation prefix (usually
/usr/local or
/usr/X11R6). If you are using the
MANn variables (as
you should be), do not list any manpages here.Here is a small example:
bin/oneko
lib/X11/app-defaults/Oneko
lib/X11/oneko/cat1.xpm
lib/X11/oneko/cat2.xpm
lib/X11/oneko/mouse.xpm
@dirrm lib/X11/onekoRefer to the &man.pkg.create.1; man page for details on the
packing list.You should list all the files, but not the name directories,
in the list. Also, if the port creates directories for itself
during installtion, make sure to add @dirrm
lines as necessary to remove them when the port is
deleted.It is recommended that you keep all the filenames in this
file sorted alphabetically. It will make verifying the changes
when you upgrade the port much easier.Creating the checksum fileJust type make makesum. The ports make rules
will automatically generate the file
files/md5.Testing the portYou should make sure that the port rules do exactly what you
want it to do, including packaging up the port. These are the
important points you need to verify.PLIST does not contain anything not
installed by your portPLIST contains everything that is
installed by your portYour port can be installed multiple times using the
reinstall targetYour port cleans up
after itself upon deinstallRecommended test orderingmake installmake packagemake deinstallpkg_add `make package-name`make deinstallmake reinstallmake packageMake sure that there aren't any warnings issued in any of the
package and
deinstall stages, After step 3, check to
see if all the new directories are correctly deleted. Also, try
using the software after step 4, to ensure that is works correctly
when installed from a package.Checking your port with portlintPlease use portlint to see if your port
conforms to our guidelines. The portlint program
is part of the ports collection. In particular, your may want to
check if the Makefile is in
the right shape and the package is named
appropriately.Submitting the portFirst, make sure you have read the Do's and Dont's section.Now that you are happy with your port, the only thing remaining
is to put it in the main FreeBSD ports tree and make everybody else
happy about it too. We do not need your work
directory or the pkgname.tgz package, so delete
them now. Next, simply include the output of shar `find
port_dir` in a bug report and send it with the
&man.send-pr.1; program (see Bug
Reports and General Commentary for more information about
&man.send-pr.1;. If the uncompressed port is larger than 20KB,
you should compress it into a tarfile and use &man.uuencode.1;
before including it in the bug report (uuencoded tarfiles are
acceptable even if the bug report is smaller than 20KB but are not
preferred). Be sure to classify the bug report as category
ports and class
change-request. (Do not mark the report
confidential!)One more time, do not include the original source
distfile, the work directory, or the package
you built with make package.In the past, we asked you to upload new port submissions in
our ftp site (ftp.freebsd.org). This
is no longer recommended as read access is turned off on that
incoming/ directory of that site due to the
large amount of pirated software showing up there.We will look at your port, get back to you if necessary, and put
it in the tree. Your name will also appear in the list of
“Additional FreeBSD contributors” on the FreeBSD
Handbook and other files. Isn't that great?!? :)Slow PortingOk, so it was not that simple, and the port required some
modifications to get it to work. In this section, we will explain,
step by step, how to modify it to get it to work with the ports
paradigm.How things workFirst, this is the sequence of events which occurs when the user
first types make in your port's directory, and
you may find that having bsd.port.mk in another
window while you read this really helps to understand it.But do not worry if you do not really understand what
bsd.port.mk is doing, not many people do...
:>The fetch target is run. The
fetch target is responsible for making
sure that the tarball exists locally in
DISTDIR. If fetch
cannot find the required files in DISTDIR it
will look up the URL MASTER_SITES, which is
set in the Makefile, as well as our main ftp site at ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/,
where we put sanctioned distfiles as backup. It will then
attempt to fetch the named distribution file with
FETCH, assuming that the requesting site has
direct access to the Internet. If that succeeds, it will save
the file in DISTDIR for future use and
proceed.The extract target is run. It
looks for your port's distribution file (typically a gzip'd
tarball) in DISTDIR and unpacks it into a
temporary subdirectory specified by WRKDIR
(defaults to work).The patch target is run. First,
any patches defined in PATCHFILES are
applied. Second, if any patches are found in
PATCHDIR (defaults to the
patches subdirectory), they are applied at
this time in alphabetical order.The configure target is run. This
can do any one of many different things.If it exists, scripts/configure is
run.If HAS_CONFIGURE or
GNU_CONFIGURE is set,
WRKSRC/configure is
run.If USE_IMAKE is set,
XMKMF (default: xmkmf
-a) is run.The build target is run. This is
responsible for descending into the port's private working
directory (WRKSRC) and building it. If
USE_GMAKE is set, GNU make
will be used, otherwise the system make will
be used.The above are the default actions. In addition, you can define
targets
pre-something or
post-something,
or put scripts with those names, in the scripts
subdirectory, and they will be run before or after the default
actions are done.For example, if you have a post-extract
target defined in your Makefile, and a file
pre-build in the scripts
subdirectory, the post-extract target will
be called after the regular extraction actions, and the
pre-build script will be executed before the
default build rules are done. It is recommended that you use
Makefile targets if the actions are simple
enough, because it will be easier for someone to figure out what
kind of non-default action the port requires.The default actions are done by the
bsd.port.mk targets
do-something.
For example, the commands to extract a port are in the target
do-extract. If you are not happy with the
default target, you can fix it by redefining the
do-something
target in your Makefile.The “main” targets (e.g.,
extract,
configure, etc.) do nothing more than
make sure all the stages up to that one are completed and call
the real targets or scripts, and they are not intended to be
changed. If you want to fix the extraction, fix
do-extract, but never ever touch
extract!Now that you understand what goes on when the user types
make, let us go through the recommended steps to
create the perfect port.Getting the original sourcesGet the original sources (normally) as a compressed tarball
(foo.tar.gz or
foo.tar.Z) and copy
it into DISTDIR. Always use
mainstream sources when and where you
can.If you cannot find a ftp/http site that is well-connected to the
net, or can only find sites that have irritatingly non-standard
formats, you might want to put a copy on a reliable ftp or http
server that you control (e.g., your home page). Make sure you set
MASTER_SITES to reflect your choice.If you cannot find somewhere convenient and reliable to put the
distfile (if you are a FreeBSD committer, you can just put it in
your public_html/ directory on
freefall), we can “house” it ourselves
by putting it on
ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/LOCAL_PORTS/
as the last resort. Please refer to this location as
MASTER_SITE_LOCAL. Send mail to the &a.ports;if
you are not sure what to do.If your port's distfile changes all the time for no good reason,
consider putting the distfile in your home page and listing it as
the first MASTER_SITES. This will prevent users
from getting checksum mismatch errors, and
also reduce the workload of maintainers of our ftp site. Also, if
there isonly one master site for the port, it is recommended that
you house a backup at your site and list it as the second
MASTER_SITES.If your port requires some additional `patches' that are
available on the Internet, fetch them too and put them in
DISTDIR. Do not worry if they come from a site
other than where you got the main source tarball, we have a way to
handle these situations (see the description of PATCHFILES below).Modifying the portUnpack a copy of the tarball in a private directory and make
whatever changes are necessary to get the port to compile properly
under the current version of FreeBSD. Keep careful
track of everything you do, as you will be automating
the process shortly. Everything, including the deletion, addition
or modification of files should be doable using an automated script
or patch file when your port is finished.If your port requires significant user interaction/customization
to compile or install, you should take a look at one of Larry Wall's
classic Configure scripts and perhaps do
something similar yourself. The goal of the new ports collection is
to make each port as “plug-and-play” as possible for the
end-user while using a minimum of disk space.Unless explicitly stated, patch files, scripts, and other
files you have created and contributed to the FreeBSD ports
collection are assumed to be covered by the standard BSD copyright
conditions.PatchingIn the preparation of the port, files that have been added or
changed can be picked up with a recursive diff for later feeding to
patch. Each set of patches you wish to apply should be collected
into a file named
patch-xx where
xx denotes the sequence in which the
patches will be applied — these are done in
alphabetical order, thus aa
first, ab second and so on. These files should
be stored in PATCHDIR, from where they will be
automatically applied. All patches should be relative to
WRKSRC (generally the directory your port's
tarball unpacks itself into, that being where the build is done).
To make fixes and upgrades easier, you should avoid having more than
one patch fix the same file (e.g., patch-aa and
patch-ab both changing
WRKSRC/foobar.c).ConfiguringInclude any additional customization commands to your
configure script and save it in the
scripts subdirectory. As mentioned above, you
can also do this as Makefile targets and/or
scripts with the name pre-configure or
post-configure.Handling user inputIf your port requires user input to build, configure or install,
then set IS_INTERACTIVE in your Makefile. This
will allow “overnight builds” to skip your port if the
user sets the variable BATCH in his environment (and
if the user sets the variable INTERACTIVE, then
only those ports requiring interaction are
built).It is also recommended that if there are reasonable default
answers to the questions, you check the
PACKAGE_BUILDING variable and turn off the
interactive script when it is set. This will allow us to build the
packages for CD-ROMs and ftp.Configuring the MakefileConfiguring the Makefile is pretty simple, and again we suggest
that you look at existing examples before starting. Also, there is a
sample Makefile in this
handbook, so take a look and please follow the ordering of variables
and sections in that template to make your port easier for others to
read.Now, consider the following problems in sequence as you design
your new Makefile:The original sourceDoes it live in DISTDIR as a standard gzip'd
tarball? If so, you can go on to the next step. If not, you should
look at overriding any of the EXTRACT_CMD,
EXTRACT_BEFORE_ARGS,
EXTRACT_AFTER_ARGS,
EXTRACT_SUFX, or DISTFILES
variables, depending on how alien a format your port's distribution
file is. (The most common case is
EXTRACT_SUFX=.tar.Z, when the tarball is
condensed by regular compress, not gzip.)In the worst case, you can simply create your own
do-extract target to override the default,
though this should be rarely, if ever, necessary.DISTNAMEYou should set DISTNAME to be the base name
of your port. The default rules expect the distribution file list
(DISTFILES) to be named
DISTNAMEEXTRACT_SUFX which, if
it is a normal tarball, is going to be something like
foozolix-1.0.tar.gz for a setting of
DISTNAME=foozolix-1.0.The default rules also expect the tarball(s) to extract into a
subdirectory called
work/DISTNAME, e.g.
work/foozolix-1.0/.All this behavior can be overridden, of course; it simply
represents the most common time-saving defaults. For a port
requiring multiple distribution files, simply set
DISTFILES explicitly. If only a subset of
DISTFILES are actual extractable archives, then
set them up in EXTRACT_ONLY, which will override
the DISTFILES list when it comes to extraction,
and the rest will be just left in DISTDIR for
later use.PKGNAMEIf DISTNAME does not conform to our guidelines for a good package
name, you should set the PKGNAME
variable to something better. See the abovementioned guidelines for
more details.CATEGORIESWhen a package is created, it is put under
/usr/ports/packages/All and links are made from
one or more subdirectories of
/usr/ports/packages. The names of these
subdirectories are specified by the variable
CATEGORIES. It is intended to make life easier
for the user when he is wading through the pile of packages on the
ftp site or the CD-ROM. Please take a look at the existing categories and pick the ones
that are suitable for your port.This list also determines where in the ports tree the port is
imported. If you put more than one category here, it is assumed
that the port files will be put in the subdirectory with the name in
the first category. See the categories section for more
discussion about how to pick the right categories.If you port truly belongs to something that is different from
all the existing ones, you can even create a new category name. In
that case, please send mail to the &a.ports; to propose a new
category.There is no error checking for category names. make
package will happily create a new directory if you
mustype the category name, so be careful!MASTER_SITESRecord the directory part of the ftp/http-URL pointing at the
original tarball in MASTER_SITES. Do not forget
the trailing slash (/)!The make macros will try to use this
specification for grabbing the distribution file with
FETCH if they cannot find it already on the
system.It is recommended that you put multiple sites on this list,
preferably from different continents. This will safeguard against
wide-area network problems, and we are even planning to add support
for automatically determining the closest master site and fetching
from there!If the original tarball is part of one of the following popular
archives: X-contrib, GNU, Perl CPAN, TeX CTAN, or Linux Sunsite, you
refer to those sites in an easy compact form using
MASTER_SITE_XCONTRIB,
MASTER_SITE_GNU,
MASTER_SITE_PERL_CPAN,
MASTER_SITE_TEX_CTAN, and
MASTER_SITE_SUNSITE. Simply set
MASTER_SITE_SUBDIR to the path with in the
archive. Here is an example:
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applicationsThe user can also set the MASTER_SITE_*
variables in /etc/make.conf to override our
choices, and use their favorite mirrors of these popular archives
instead.PATCHFILESIf your port requires some additional patches that are available
by ftp or http, set PATCHFILES to the names of
the files and PATCH_SITES to the URL of the
directory that contains them (the format is the same as
MASTER_SITES).If the patch is not relative to the top of the source tree
(i.e., WKRSRC) because it contains some extra
pathnames, set PATCH_DIST_STRIP accordingly. For
instance, if all the pathnames in the patch have an extra
foozolix-1.0/ in front of the filenames, then set
PATCH_DIST_STRIP=-p1.Do not worry if the patches are compressed, they will be
decompressed automatically if the filenames end with
.gz or .Z.If the patch is distributed with some other files, such as
documentation, in a gzip'd tarball, you can't just use
PATCHFILES. If that is the case, add the name
and the location of the patch tarball to
DISTFILES and MASTER_SITES.
Then, from the pre-patch target, apply the
patch either by running the patch command from there, or copying the
patch file into the PATCHDIR directory and
calling it
patch-xx.Note the tarball will have been extracted alongside the
regular source by then, so there is no need to explicitly extract
it if it is a regular gzip'd or compress'd tarball. If you do the
latter, take extra care not to overwrite something that already
exists in that directory. Also do not forget to add a command to
remove the copied patch in the pre-clean
target.MAINTAINERSet your mail-address here. Please. :)For detailed description of the responsibility of maintainers,
refer to MAINTAINER on
Makefiles section.DependenciesMany ports depend on other ports. There are five variables that
you can use to ensure that all the required bits will be on the
user's machine. There are also some pre-supported dependency
variables for common cases, plus a few more to control the behaviour
of dependencies.LIB_DEPENDSThis variable specifies the shared libraries this port depends
on. It is a list of
lib:dir:target
tuples where lib is the name of the
shared library, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. For example, LIB_DEPENDS=
jpeg\\.9\\.:${PORTSDIR}/graphics/jpeg:install
will check for a shared jpeg library with major version 9, and
descend into the graphics/jpeg subdirectory
of your ports tree to build and install it if it is not found.
The target part can be omitted if it is
equal to DEPENDS_TARGET (which defaults to
install).The lib part is an argument given
to ldconfig -r | grep -wF. There shall be no
reqular expressions in this variable.The dependency is checked twice, once from within the
extract target and then from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system.RUN_DEPENDSThis variable specifies executables or files this port depends
on during run-time. It is a list of
path:dir:target
tuples where path is the name of the
executable or file, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. If path starts with a slash
(/), it is treated as a file and its existence
is tested with test -e; otherwise, it is
assumed to be an executable, and which -s is
used to determine if the program exists in the user's search
path.For example,
RUN_DEPENDS= ${PREFIX}/etc/innd:${PORTSDIR}/news/inn \
wish8.0:${PORTSDIR}/x11-toolkits/tk80will check if the file or directory
/usr/local/etc/innd exists, and build and
install it from the news/inn subdirectory of
the ports tree if it is not found. It will also see if an
executable called wish8.0 is in your search
path, and descend into the x11-toolkits/tk80
subdirectory of your ports tree to build and install it if it is
not found.In this case, innd is actually an
executable; if an executable is in a place that is not expected
to be in a normal user's search path, you should use the full
pathname.The dependency is checked from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system. The target
part can be omitted if it is the same
DEPENDS_TARGET.BUILD_DEPENDSThis variable specifies executables or files this port
requires to build. Like RUN_DEPENDS, it is a
list of
path:dir:target
tuples. For example, BUILD_DEPENDS=
unzip:${PORTSDIR}/archivers/unzip will check
for an executable called unzip, and descend
into the archivers/unzip subdirectory of your
ports tree to build and install it if it is not found.“build” here means everything from extracting to
compilation. The dependency is checked from within the
extract target. The
target part can be omitted if it is
the same as DEPENDS_TARGETFETCH_DEPENDSThis variable specifies executables or files this port
requires to fetch. Like the previous two, it is a list of
path:dir:target
tuples. For example, FETCH_DEPENDS=
ncftp2:${PORTSDIR}/net/ncftp2 will check for an
executable called ncftp2, and descend into the
net/ncftp2 subdirectory of your ports tree to
build and install it if it is not found.The dependency is checked from within the
fetch target. The
target part can be omitted if it is the
same as DEPENDS_TARGET.DEPENDSIf there is a dependency that does not fall into either of the
above four categories, or your port requires to have the source of
the other port extracted in addition to having them installed,
then use this variable. This is a list of
dir:target,
as there is nothing to check, unlike the previous four. The
target part can be omitted if it is the
same as DEPENDS_TARGET.Common dependency variablesDefine USE_XLIB=yes if your port requires
the X Window System to be installed (it is implied by
USE_IMAKE). Define
USE_GMAKE=yes if your port requires GNU
make instead of BSD make.
Define USE_AUTOCONF=yes if your port requires
GNU autoconf to be run. Define USE_QT=yes if
your port uses the latest qt toolkit. Use
USE_PERL5=yes if your port requires version 5
of the perl language. (The last is especially important since
some versions of FreeBSD has perl5 as part of the base system
while others don't.)Notes on dependenciesAs mentioned above, the default target to call when a
dependency is required is DEPENDS_TARGET.
It defaults to install. This is a user
variable; is is never defined in a port's
Makefile. If your port needs a special way
to handle a dependency, use the :target part of
the *_DEPENDS variables instead of redefining
DEPENDS_TARGET.When you type make clean, its dependencies
are automatically cleaned too. If you do not wish this to happen,
define the variable NOCLEANDEPENDS in your
environment.To depend on another port unconditionally, it is customary to
use the string nonexistent as the first field
of BUILD_DEPENDS or
RUN_DEPENDS. Use this only when you need to
the to get to the source of the other port. You can often save
compilation time by specifying the target too. For
instance
BUILD_DEPENDS= /nonexistent:${PORTSDIR}/graphics/jpeg:extract
will always descend to the JPEG port and extract it.Do not use DEPENDS unless there is no other
way the behaviour you want can be accomplished. It will cause the
other port to be always build (and installed, by default), and the
dependency will go into the packages as well. If this is really
what you need, I recommend you write it as
BUILD_DEPENDS and
RUN_DEPENDS instead—at least the
intention will be clear.Building mechanismsIf your package uses GNU make, set
USE_GMAKE=yes. If your package uses
configure, set
HAS_CONFIGURE=yes. If your package uses GNU
configure, set
GNU_CONFIGURE=yes (this implies
HAS_CONFIGURE). If you want to give some extra
arguments to configure (the default argument list
--prefix=${PREFIX} for GNU
configure and empty for non-GNU
configure), set those extra arguments in
CONFIGURE_ARGS. If your package uses GNU
autoconf, set
USE_AUTOCONF=yes. This implies
GNU_CONFIGURE, and will cause
autoconf to be run before
configure.If your package is an X application that creates
Makefiles from Imakefiles
using imake, then set
USE_IMAKE=yes. This will cause the configure
stage to automatically do an xmkmf -a. If the
flag is a problem for your port, set
XMKMF=xmkmf. If the port uses
imake but does not understand the
install.man target,
NO_INSTALL_MANPAGES=yes should be set. In
addition, the author of the original port should be shot. :>If your port's source Makefile has
something else than all as the main build
target, set ALL_TARGET accordingly. Same goes
for install and
INSTALL_TARGET.Special considerationsThere are some more things you have to take into account when you
create a port. This section explains the most common of those.ldconfigIf your port installs a shared library, add a
post-install target to your
Makefile that runs ${LDCONFIG}
-m on the directory where the new library is installed
(usually PREFIX/lib) to
register it into the shared library cache.Also, add a matching @exec /sbin/ldconfig -m
and @unexec /sbin/ldconfig -R pair to your
pkg/PLIST file so that a user who installed the
- package can start using teh shared libraru immediately and
+ package can start using the shared library immediately and
deinstallation will not cause the system to still believe the
library is there. These lines should immediately follow the line
for the shared library itself, as in:
lib/libtvl80.so.1
@exec /sbin/ldconfig -m %D/lib
@unexec /sbin/ldconfig -RNever, ever, ever add a line that says
ldconfig without any arguments to your
Makefile or pkg/PLIST.
- This will reset the shared libraru cache to the contents of
+ This will reset the shared library cache to the contents of
/usr/lib only, and will royally screw up the
user's machine ("Help, xinit does not run anymore after I install
this port!"). Anybody who does this will be shot and cut in 65,536
pieces by a rusty knife and have is liver chopped out by a bunch of
crows and will eternally rot to death in the deepest bowels of hell
(not necessarily in that order…)ELF supportSince FreeBSD is moving to ELF shortly after 3.0-RELEASE, we need
to convert many ports that build shared libraries to support ELF.
Complicating this task is that a 3.0 system can run as both ELF and
a.out, and we wish to unofficially support the 2.2 as long as
possible. Below are the guidelines on how to convert a.out only ports
to support both a.out and ELF compilation.Some part of this list is only applicable during the conversion,
but will be left here for awhile for reference in case you have come
across some old port you wish to upgrade.Moving a.out libraries out of the wayA.out libraries should be moved out of
/usr/local/lib and similar to an
aout subdirectory. (If you don't move them out
of the way, ELF ports will happily overwrite a.out libraries.) The
move-aout-libs target in the 3.0-CURRENT
src/Makefile (called from
aout-to-elf) will do this for you. It will
only move a.out libs so it is safe to call it on a system with both
ELF and a.out libs in the standard directories.FormatThe ports tree will build packages in the format the machine is
in. This means a.out for 2.2 and a.out or ELF for 3.0 depending on
what `objformat` returns. Also, once users move
a.out libraries to a subdirectory, building a.out libraries will be
unsupported. (I.e., it may still work if you know what you are
doing, but you are on your own.)If a port only works for a.out, set
BROKEN_ELF to a string describing the reason
why. Such ports will be skipped during a build on an ELF
system.PORTOBJFORMATbsd.port.mk will set
PORTOBJFORMAT to aout or
elf and export it in the environments
CONFIGURE_ENV, SCRIPTS_ENV and
MAKE_ENV. (It's always going to be
aout in 2.2-STABLE). It is also passed to
PLIST_SUB as
PORTOBJFORMAT=${PORTOBJFORMAT}. (See comment on
ldconfig lines below.)The variable is set using this line in
bsd.port.mk:
PORTOBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aoutPorts' make processes should use this variable to decide what to
do. However, if the port's configure script
already automatically detects an ELF system, it is not necessary to
refer to PORTOBJFORMAT.Building shared librariesThe following are differences in handling shared libraries for
a.out and ELF.Shared library versionsAn ELF shared library should be called
libfoo.so.M
where M is the single version number,
and an a.out library should be called
libfoo.so.M.N
where M is the major version and
N is the the minor version number.
Do not mix those; never install an ELF
shared library called
libfoo.so.N.M
or an a.out shared library (or symlink) called
libfoo.so.N.Linker command linesAssuming cc -shared is used rather than
ld directly, the only difference is that you
need to add
on the command line for ELF.You need to install a symlink from
libfoo.so to
libfoo.so.N to make
ELF linkers happy. Since it should be listed in
PLIST too, and it won't hurt in the a.out case
(some ports even require the link for dynamic loading), you should
just make this link regardless of the setting of
PORTOBJFORMAT.LIB_DEPENDSAll port Makefiles are edited to remove minor numbers from
LIB_DEPENDS, and also to have the regexp support
removed. (E.g., foo\\.1\\.\\(33|40\\) becomes
foo.2.) They will be matched using grep
-wF.PLISTPLIST should contain the short (ELF) shlib
names if the a.out minor number is zero, and the long (a.out) names
otherwise. bsd.port.mk will automatically add
.0 to the end of short shlib lines if
PORTOBJFORMAT equals aout, and
will delete the minor number from long shlib names if
PORTOBJFORMAT equals
elf.In cases where you really need to install shlibs with two
versions on an ELF system or those with one version on an a.out
system (for instance, ports that install compatibility libraries for
other operating systems), define the variable
NO_FILTER_SHLIBS. This will turn off the editing
of PLIST mentioned in the previous
paragraph.ldconfigThe ldconfig line in Makefiles should
read:
${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m ....In PLIST it should read;
@exec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -m ...
@unexec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -RThis is to ensure that the correct ldconfig
will be called depending on the format of the package, not the
default format of the system.MASTERDIRIf your port needs to build slightly different versions of
packages by having a variable (for instance, resolution, or paper
size) take different values, create one subdirectory per package to
make it easier forusers to see what to do, but try to share as many
files as possible between ports. Typically you only need a very short
Makefile in all but one of the directories if you
use variables cleverly. In the sole Makefiles,
you can use MASTERDIR to specify the directory
where the rest of the files are. Also, use a variable as part of
PKGNAME so
the packages will have different names.This will be best demonstrated by an example. This is part of
japanese/xdvi300/Makefile;
PKGNAME= ja-xdvi${RESOLUTION}-17
:
# default
RESOLUTION?= 300
.if ${RESOLUTION} != 118 && ${RESOLUTION} != 240 && \
${RESOLUTION} != 300 && ${RESOLUTION} != 400
@${ECHO} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
@${ECHO} "Possible values are: 118, 240, 300 (default) and 400."
@${FALSE}
.endifjapanese/xdvi300 also has all the regular
patches, package files, etc. If you type make
there, it will take the default value for the resolution (300) and
build the port normally.As for other resolutions, this is the entirexdvi118/Makefile;
RESOLUTION= 118
MASTERDIR= ${.CURDIR}/../xdvi300
.include ${MASTERDIR}/Makefile(xdvi240/Makefile and
xdvi400/Makefile are similar). The
MASTERDIR definition tells
bsd.port.mk that the refulat set of
subdirectories like PATCHDIR and
PKGDIR are to be found under
xdvi300. The RESOLUTION=118
line will override the RESOLUTION=300 line in
xdvi300/Makefile and the port will be built with
resolution set to 118.Shared library versionsFirst, please read our policy on
shared library versioning to understand what to do with
shared library versions in general. Do not blindly assume software
authors know what they are doing; many of them do not. It is very
important that these details are carefully considered, as we have
quite a unique situation where we are trying to have dozens of
potentially incompatible software pairs co-exist. Careless port
imports have caused great trouble regarding shared libraries in the
past (ever wondered why the port jpeg-6b has a
shared library version of 9.0?). If in doubt, send a message to the
&a.ports;. Most of the time, your job ends by determining the right
shared library version and making appropriate patches to implement
it.However, if there is a port which is a different version of the
same software already in the tree, the situation is much more complex.
In short, the FreeBSD implementation does not allow the user to
specify to the linker which version of shared library to link against
(the linker will always pick the highest numbered version). This
means, if there is a libfoo.so.3.2 and
libfoo.so.4.0 in the system, there is no way to
tell the linker to link a particular application to
libfoo.so.3.2. It is essentially completely
overshadowed in terms of compilation-time linkage. In this case, the
only solution is to rename the base part of the
shared library. For instance, change
libfoo.so.4.0 to
libfoo4.so.1.0 so both version 3.2 and 4.0 can be
linked from other ports.ManpagesThe MAN[1-9LN] variables will automatically add
any manpages to pkg/PLIST (this means you must
not list manpages in the
PLIST—see generating PLIST for more). It also
makes the install stage automatically compress or uncompress manpages
depending on the setting of NOMANCOMPRESS in
/etc/make.conf.To specify whether the manpages are compressed upon installation,
use the MANCOMPRESSED variable. This variable can
take three values, yes, no and
maybe. yes means manpages are
already installed compressed, no means they are
not, and maybe means the software already respects
the value of NOMANCOMPRESS so
bsd.port.mk does not have to do anything
special.MANCOMPRESSED is automatically set to
yes if USE_IMAKE is set and
NO_INSTALL_MANPAGES is not set, and to
no otherwise. You don't have to explicitly define
it unless the default is not suitable for your port.If your port anchors its man tree somewhere other than
PREFIX, you can use the
MANPREFIX to set it. Also, if only manpages in
certain sections go in a non-standard place, such as some Perl modules
ports, you can set individual man paths using
MANsectPREFIX (where
sect is one of 1-9,
L or N).If your manpages go to language-specific subdirectories, set the
name of the languages to MANLANG. The value of
this variable defaults to "" (i.e., English
only).Here is an example that puts it all together.
MAN1= foo.1
MAN3= bar.3
MAN4= baz.4
MANLANG= "" ja
MAN3PREFIX= ${PREFIX}/share/foobar
MANCOMPRESSED= yesThis states that six files are installed by this port;
${PREFIX}/man/man1/foo.1.gz
${PREFIX}/man/ja/man1/foo.1.gz
${PREFIX}/share/foobar/man/man3/bar.3.gz
${PREFIX}/share/foobar/man/ja/man3/bar.3.gz
${PREFIX}/man/man4/baz.4.gz
${PREFIX}/man/ja/man4/baz.4.gzPorts that require MotifThere are many programs that require a Motif library (available
from several commercial vendors, while there is a free clone reported
to be able to run many applications in
x11-toolkits/lesstif) to compile. Since it is a
popular toolkit and their licenses usually permit redistribution of
statically linked binaries, we have made special provisions for
handling ports that require Motif in a way that we can easily compile
binaries linked either dynamically (for people who are compiling from
the port) or statically (for people who distribute packages).REQUIRES_MOTIFIf your port requires Motif, define this variable in the
Makefile. This will prevent people who don't own a copy of Motif
from even attempting to build it.MOTIFLIBThis variable will be set by bsd.port.mk to
be the appropriate reference to the Motif library. Please patch the
source to use this wherever the Motif library is referenced in the
Makefile or
Imakefile.There are two common cases:If the port refers to the Motif library as
-lXm in its Makefile or
Imakefile, simply substitute
${MOTIFLIB} for it.If the port uses XmClientLibs in its
Imakefile, change it to
${MOTIFLIB} ${XTOOLLIB}
${XLIB}.Note that MOTIFLIB (usually) expands to
-L/usr/X11R6/lib -lXm or
/usr/X11R6/lib/libXm.a, so there is no need to
add -L or -l in front.X11 fontsIf your port installs fonts for the X Window system, put them in
X11BASE/lib/X11/fonts/local.
This directory is new to XFree86 release 3.3.3. If it does not exist,
please create it, and print out a message urging the user to update
their XFree86 to 3.3.3 or newer, or at least add this directory to the
font path in /etc/XF86Config.Info filesThe new version of texinfo (included in 2.2.2-RELEASE and onwards)
contains a utility called install-info to add and
delete entries to the dir file. If your port
installs any info documents, please follow this instructions so your
port/package will correctly update the user's
PREFIX/info/dir file. (Sorry
for the length of this section, but is it imperative to weave all the
info files together. If done correctly, it will produce a
beautiful listing, so please bear with me!First, this is what you (as a porter) need to know&prompt.user; install-info --help
install-info [OPTION]... [INFO-FILE [DIR-FILE]]
Install INFO-FILE in the Info directory file DIR-FILE.
Options:
--delete Delete existing entries in INFO-FILE;
don't insert any new entries.
:
--entry=TEXT Insert TEXT as an Info directory entry.
:
--section=SEC Put this file's entries in section SEC of the directory. :This program will not actually install info
files; it merely inserts or deletes entries in the
dir file.Here's a seven-step procedure to convert ports to use
install-info. I will use
editors/emacs as an example.Look at the texinfo sources and make a patch to insert
@dircategory and @direntry
statements to files that don't have them. This is part of my
patch:
--- ./man/vip.texi.org Fri Jun 16 15:31:11 1995
+++ ./man/vip.texi Tue May 20 01:28:33 1997
@@ -2,6 +2,10 @@
@setfilename ../info/vip
@settitle VIP
+@dircategory The Emacs editor and associated tools
+@direntry
+* VIP: (vip). A VI-emulation for Emacs.
+@end direntry
@iftex
@finalout
:The format should be self-explanatory. Many authors leave a
dir file in the source tree that contains all
the entries you need, so look around before you try to write your
own. Also, make sure you look into related ports and make the
section names and entry indentations consistent (we recommend that
all entry text start at the 4th tab stop).Note that you can put only one info entry per file because
of a bug in install-info --delete that
deletes only the first entry if you specify multiple entries in
the @direntry section.You can give the dir entries to
install-info as arguments
( and ) instead
of patching the texinfo sources. I do not think this is a good
idea for ports because you need to duplicate the same information
in three places
(Makefile and
@exec/@unexec of
PLIST; see below). However, if you have a
Japanese (or other multibyte encoding) info files, you will have
to use the extra arguments to install-info
because makeinfo can't handle those texinfo
sources. (See Makefile and
PLIST of japanese/skk
for examples on how to do this).Go back to the port directory and do a make clean;
make and verify that the info files are regenerated
from the texinfo sources. Since the texinfo sources are newer than
the info files, they should be rebuilt when you type
make; but many Makefiles
don't include correct dependencies for info files. In
emacs' case, I had to patch the main
Makefile.in so it will descend into the
man subdirectory to rebuild the info
pages.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Tue Apr 15 00:15:28 1997
@@ -184,7 +184,7 @@
# Subdirectories to make recursively. `lisp' is not included
# because the compiled lisp files are part of the distribution
# and you cannot remake them without installing Emacs first.
-SUBDIR = lib-src src
+SUBDIR = lib-src src man
# The makefiles of the directories in $SUBDIR.
SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile
--- ./man/Makefile.in.org Thu Jun 27 15:27:19 1996
+++ ./man/Makefile.in Tue Apr 15 00:29:52 1997
@@ -66,6 +66,7 @@
${srcdir}/gnu1.texi \
${srcdir}/glossary.texi
+all: info
info: $(INFO_TARGETS)
dvi: $(DVI_TARGETS)The second hunk was necessary because the default target in
the man subdir is called
info, while the main
Makefile wants to call
all. I also deleted the installation of
the info info file because we already have
one with the same name in /usr/share/info
(that patch is not shown here).If there is a place in the Makefile that
is installing the dir file, delete it. Your
port may not be doing it. Also, remove any commands that are
otherwise mucking around with the dir
file.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Mon Apr 14 23:38:07 1997
@@ -368,14 +368,8 @@
if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
then \
(cd ${infodir}; \
- if [ -f dir ]; then \
- if [ ! -f dir.old ]; then mv -f dir dir.old; \
- else mv -f dir dir.bak; fi; \
- fi; \
cd ${srcdir}/info ; \
- (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
- (cd $${thisdir}; chmod a+r ${infodir}/dir); \
for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
(cd $${thisdir}; \
${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
chmod a+r ${infodir}/$$f); \(This step is only necessary if you are modifying an existing
port.) Take a look at pkg/PLIST and delete
anything that is trying to patch up info/dir.
They may be in pkg/INSTALL or some other
file, so search extensively.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/04/15 06:32:12
@@ -15,9 +15,6 @@
man/man1/emacs.1.gz
man/man1/etags.1.gz
man/man1/ctags.1.gz
-@unexec cp %D/info/dir %D/info/dir.bak
-info/dir
-@unexec cp %D/info/dir.bak %D/info/dir
info/cl
info/cl-1
info/cl-2Add a post-install target to the
Makefile to create a dir
file if it is not there. Also, call
install-info with the installed info
files.
Index: Makefile
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 1996/11/19 13:14:40 1.26
+++ Makefile 1997/05/20 10:25:09 1.28
@@ -20,5 +20,11 @@
post-install:
.for file in emacs-19.34 emacsclient etags ctags b2m
strip ${PREFIX}/bin/${file}
.endfor
+ if [ ! -f ${PREFIX}/info/dir ]; then \
+ ${SED} -ne '1,/Menu:/p' /usr/share/info/dir > ${PREFIX}/info/dir; \
+ fi
+.for info in emacs vip viper forms gnus mh-e cl sc dired-x ediff ccmode
+ install-info ${PREFIX}/info/${info} ${PREFIX}/info/dir
+.endfor
.include <bsd.port.mk>Do not use anything other than
/usr/share/info/dir and the above command to
create a new info file. In fact, I'd add the first three lines of
the above patch to bsd.port.mk if you (the
porter) wouldn't have to do it in PLIST by
yourself anyway.Edit PLIST and add equivalent
@exec statements and also
@unexec for pkg_delete. You
do not need to delete info/dir with
@unexec.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/05/20 10:25:12 1.17
@@ -16,7 +14,15 @@
man/man1/etags.1.gz
man/man1/ctags.1.gz
+@unexec install-info --delete %D/info/emacs %D/info/dir
:
+@unexec install-info --delete %D/info/ccmode %D/info/dir
info/cl
info/cl-1
@@ -87,6 +94,18 @@
info/viper-3
info/viper-4
+@exec [ -f %D/info/dir ] || sed -ne '1,/Menu:/p' /usr/share/info/dir > %D/info/dir
+@exec install-info %D/info/emacs %D/info/dir
:
+@exec install-info %D/info/ccmode %D/info/dir
libexec/emacs/19.34/i386--freebsd/cvtmail
libexec/emacs/19.34/i386--freebsd/digest-docThe @unexec install-info --delete
commands have to be listed before the info files themselves so
they can read the files. Also, the @exec
install-info commands have to be after the info
files and the @exec command that creates the
the dir file.Test and admire your
work. :). Check the
dir file before and after each step.The pkg/ subdirectoryThere are some tricks we haven't mentioned yet about the
pkg/ subdirectory that come in handy
sometimes.MESSAGEIf you need to display a message to the installer, you may place
the message in pkg/MESSAGE. This capability is
often useful to display additional installation steps to be taken
after a pkg_add or to display licensing
information.The pkg/MESSAGE file does not need to be
added to pkg/PLIST. Also, it will not get
automatically printed if the user is using the port, not the
package, so you should probably display it from the
post-install target yourself.INSTALLIf your port needs to execute commands when the binary package
is installed with pkg_add you can do this via the
pkg/INSTALL script. This script will
automatically be added to the package, and will be run twice by
pkg_add. The first time will as INSTALL
${PKGNAME} PRE-INSTALL and the second time as
INSTALL ${PKGNAME} POST-INSTALL.
$2 can be tested to determine which mode
the script is being run in. The PKG_PREFIX
environmental variable will be set to the package installation
directory. See &man.pkg.add.1; for
additional information.This script is not run automatically if you install the port
with make install. If you are depending on it
being run, you will have to explicitly call it from your port's
Makefile.REQIf your port needs to determine if it should install or not, you
can create a pkg/REQ “requirements”
script. It will be invoked automatically at
installation/deinstallation time to determine whether or not
installation/deinstallation should proceed.Changing PLIST based on make
variablesSome ports, particularly the p5- ports, need to change their
PLIST depending on what options they are
configured with (or version of perl, in the case of p5- ports). To
make this easy, any instances in the PLIST of
%%OSREL%%, %%PERL_VER%%, and
%%PERL_VERSION%% will be substituted for
appropriately. The value of %%OSREL%% is the
numeric revision of the operating system (e.g.,
2.2.7). %%PERL_VERSION%% is
the full version number of perl (e.g., 5.00502)
and %%PERL_VER%% is the perl version number minus
the patchlevel (e.g., 5.005).If you need to make other substitutions, you can set the
PLIST_SUB variable with a list of
VAR=VALUE
pairs and instances of
%%VAR%%' will be
substituted with VALUE in the
PLIST.For instance, if you have a port that installs many files in a
version-specific subdirectory, you can put something like
OCTAVE_VERSION= 2.0.13
PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION}
in the Makefile and use
%%OCTAVE_VERSION%% wherever the version shows up
in PLIST. That way, when you upgrade the port,
you will not have to change dozens (or in some cases, hundreds) of
lines in the PLIST.This substitution (as well as addition of any man pages) will be done between
the do-install and
post-install targets, by reading from
PLIST and writing to TMPPLIST
(default:
WRKDIR/.PLIST.mktmp). So if
your port builds PLIST on the fly, do so in or
before do-install. Also, if your port
needs to edit the resulting file, do so in
post-install to a file named
TMPPLIST.Changing the names of files in the
pkg subdirectoryAll the filenames in the pkg subdirectory
are defined using variables so you can change them in your
Makefile if need be. This is especially useful
when you are sharing the same pkg subdirectory
among several ports or have to write to one of the above files (see
writing to places other than
WRKDIR for why it is a bad idea to write
directly in to the pkg subdirectory.Here is a list of variable names and their default
values.VariableDefault valueCOMMENT${PKGDIR}/DESCRDESCR${PKGDIR}/DESCRPLIST${PKGDIR}/PLISTPKGINSTALL${PKGDIR}/PKGINSTALLPKGDEINSTALL${PKGDIR}/PKGDEINSTALLPKGREQ${PKGDIR}/REQPKGMESSAGE${PKGDIR}/MESSAGEPlease change these variables rather than overriding
PKG_ARGS. If you change
PKG_ARGS, those files will not correctly be
installed in /var/db/pkg upon install from a
port.Licensing ProblemsSome software packages have restrictive licenses or can be in
violation to the law (PKP's patent on public key crypto, ITAR (export
of crypto software) to name just two of them). What we can do with
them varies a lot, depending on the exact wordings of the respective
licenses.It is your responsibility as a porter to read the licensing
terms of the software and make sure that the FreeBSD project will
not be held accountable of violating them by redistributing the
source or compiled binaries either via ftp or CD-ROM. If in doubt,
please contact the &a.ports;.There are two variables you can set in the Makefile to handle the
situations that arise frequently:If the port has a “do not sell for profit” type of
license, set the variable NO_CDROM to a string
describing the reason why. We will make sure such ports won't go
into the CD-ROM come release time. The distfile and package will
still be available via ftp.If the resulting package needs to be built uniquely for each
site, or the resulting binary package can't be distributed due to
licensing; set the variable NO_PACKAGE to a
string describing the reason why. We will make sure such packages
won't go on the ftp site, nor into the CD-ROM come release time.
The distfile will still be included on both however.If the port has legal restrictions on who can use it (e.g.,
crypto stuff) or has a “no commercial use” license,
set the variable RESTRICTED to be the string
describing the reason why. For such ports, the distfiles/packages
will not be available even from our ftp sites.The GNU General Public License (GPL), both version 1 and 2,
should not be a problem for ports.If you are a committer, make sure you update the
ports/LEGAL file too.UpgradingWhen you notice that a port is out of date compared to the latest
version from the original authors, first make sure you have the latest
port. You can find them in the
ports/ports-current directory of the ftp mirror
sites.The next step is to send a mail to the maintainer, if one is
listed in the port's Makefile. That person may
already be working on an upgrade, or have a reason to not upgrade the
port right now (because of, for example, stability problems of the new
version).If the maintainer asks you to do the upgrade or there isn't any
such person to begin with, please make the upgrade and send the
recursive diff (either unified or context diff is fine, but port
committers appear to prefer unified diff more) of the new and old
ports directories to us (e.g., if your modified port directory is
called superedit and the original as in our tree
is superedit.bak, then send us the result of
diff -ruN superedit.bak superedit). Please examine
the output to make sure all the changes make sense. The best way to
send us the diff is by including it to &man.send-pr.1; (category
ports). Please mention any added or deleted files
in the message, as they have to be explicitly specified to CVS when
doing a commit. If the diff is more than about 20KB, please compress
and uuencode it; otherwise, just include it in as is in the PR.Once again, please use &man.diff.1; and not &man.shar.1; to send
updates to ports.Do's and Dont'sHere is a list of common do's and dont's that you encounter during
the porting process.You should check your own port against this list,
but you can also check ports in the PR database that others have
submitted. Submit any comments on ports you check as described in
Bug Reports and General
Commentary. Checking ports in the PR database will both make
it faster for us to commit them, and prove that you know what you are
doing.Strip BinariesDo strip binaries. If the original source already strips the
binaries, fine; otherwise you should add a
post-install rule to to it yourself. Here is an
example;
post-install:
strip ${PREFIX}/bin/xdlUse the &man.file.1; command on the installed executable to
check whether the binary is stripped or not. If it does not say
not stripped, it is stripped.INSTALL_* macrosDo use the macros provided in bsd.port.mk
to ensure correct modes and ownership of files in your own
*-install targets. They are:INSTALL_PROGRAM is a command to install
binary executables.INSTALL_SCRIPT is a command to install
executable scripts.INSTALL_DATA is a command to install
sharable data.INSTALL_MAN is a command to install
manpages and other documentation (it doesn't compress
anything).These are basically the install command with
all the appropriate flags. See below for an example on how to use
them.WRKDIRDo not write anything to files outside
WRKDIR. WRKDIR is the only
place that is guaranteed to be writable during the port build (see
compiling ports from CDROM for an
example of building ports from a read-only tree). If you need to
modigy some file in PKGDIR, do so by redefining a variable, not by
writing over it.WRKDIRPREFIXMake sure your port honors WRKDIRPREFIX.
Most ports don't have to worry about this. In particular, if you
are referring to a WRKDIR of another port, note
that the correct location is
WRKDIRPREFIXPORTSDIR/subdir/name/work not PORTSDIR/subdir/name/work or .CURDIR/../../subdir/name/work or some such.Also, if you are defining WRKDIR yourself,
make sure you prepend
${WKRDIRPREFIX}${.CURDIR} in the
front.Differentiating operating systems and OS versionsYou may come across code that needs modifications or conditional
compilation based upon what version of UNIX it is running under. If
you need to make such changes to the code for conditional
compilation, make sure you make the changes as general as possible
so that we can back-port code to FreeBSD 1.x systems and cross-port
to other BSD systems such as 4.4BSD from CSRG, BSD/386, 386BSD,
NetBSD, and OpenBSD.The preferred way to tell 4.3BSD/Reno (1990) and newer versions
of the BSD code apart is by using the BSD macro
defined in <sys/param.h>. Hopefully that
file is already included; if not, add the code:
#if (defined(__unix__) || defined(unix)) && !defined(USG)
#include <sys/param.h>
#endifto the proper place in the .c file. We
believe that every system that defines these two symbols has
sys/param.h. If you find a system that
doesn't, we would like to know. Please send mail to the
&a.ports;.Another way is to use the GNU Autoconf style of doing
this:
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h>
#endifDon't forget to add -DHAVE_SYS_PARAM_H to the
CFLAGS in the Makefile for
this method.Once you have sys/param.h included, you may
use:
#if (defined(BSD) && (BSD >= 199103))to detect if the code is being compiled on a 4.3 Net2 code base
or newer (e.g. FreeBSD 1.x, 4.3/Reno, NetBSD 0.9, 386BSD, BSD/386
1.1 and below).Use:
#if (defined(BSD) && (BSD >= 199306))to detect if the code is being compiled on a 4.4 code base or
newer (e.g. FreeBSD 2.x, 4.4, NetBSD 1.0, BSD/386 2.0 or
above).The value of the BSD macro is
199506 for the 4.4BSD-Lite2 code base. This is
stated for informational purposes only. It should not be used to
distinguish between versions of FreeBSD based only on 4.4-Lite vs.
versions that have merged in changes from 4.4-Lite2. The
__FreeBSD__ macro should be used instead.Use sparingly:__FreeBSD__ is defined in all versions of
FreeBSD. Use it if the change you are making
only affects FreeBSD. Porting gotchas like
the use of sys_errlist[] vs
strerror() are Berkeleyisms, not FreeBSD
changes.In FreeBSD 2.x, __FreeBSD__ is defined to
be 2. In earlier versions, it is
1. Later versions will bump it to match
their major version number.If you need to tell the difference between a FreeBSD 1.x
system and a FreeBSD 2.x or 3.x system, usually the right answer
is to use the BSD macros described above. If
there actually is a FreeBSD specific change (such as special
shared library options when using ld) then it
is OK to use __FreeBSD__ and #if
__FreeBSD__ > 1 to detect a FreeBSD 2.x and later
system. If you need more granularity in detecting FreeBSD
systems since 2.0-RELEASE you can use the following:
#if __FreeBSD__ >= 2
#include <osreldate.h>
# if __FreeBSD_version >= 199504
/* 2.0.5+ release specific code here */
# endif
#endifRelease__FreeBSD_version2.0-RELEASE1194112.1-CURRENTs199501, 1995032.0.5-RELEASE1995042.2-CURRENT before 2.11995082.1.0-RELEASE1995112.2-CURRENT before 2.1.51995122.1.5-RELEASE1996072.2-CURRENT before 2.1.61996082.1.6-RELEASE1996122.1.7-RELEASE1996122.2-RELEASE2200002.2.1-RELEASE220000 (no change)2.2-STABLE after 2.2.1-RELEASE220000 (no change)2.2-STABLE after texinfo-3.92210012.2-STABLE after top2210022.2.2-RELEASE2220002.2-STABLE after 2.2.2-RELEASE2220012.2.5-RELEASE2250002.2-STABLE after 2.2.5-RELEASE2250012.2-STABLE after ldconfig -R merge2250022.2.6-RELEASE2260002.2.7-RELEASE2270002.2-STABLE after 2.2.7-RELEASE2270012.2-STABLE after semctl(2) change2270022.2.8-RELEASE2280002.2-STABLE after 2.2.8-RELEASE2280013.0-CURRENT before mount(2) change3000003.0-CURRENT after mount(2) change3000013.0-CURRENT after semctl(2) change3000023.0-CURRENT after ioctl arg changes3000033.0-CURRENT after ELF conversion3000043.0-RELEASE3000053.0-CURRENT after 3.0-RELEASE3000063.0-STABLE after 3/4 branch3000073.1-RELEASE3100003.1-STABLE after 3.1-RELEASE3100014.0-CURRENT after 3/4 branch400000Note that 2.2-STABLE sometimes identifies itself as
“2.2.5-STABLE” after the 2.2.5-RELEASE. The pattern
used to be year followed by the month, but we decided to change it
to a more straightforward major/minor system starting from 2.2.
This is because the parallel development on several branches made
it infeasible to classify the releases simply by their real
release dates. If you are making a port now, you don't have to
worry about old -CURRENTs; they are listed here just for your
reference.In the hundreds of ports that have been done, there have only
been one or two cases where __FreeBSD__ should
have been used. Just because an earlier port screwed up and used it
in the wrong place does not mean you should do so too.Writing something after
bsd.port.mkDo not write anything after the .include
<bsd.port.mk> line. it usually can be avoided by
including bsd.port.pre.mk somewhere in the
middle of your Makefile and
bsd.port.post.mk at the end.You need to include either the
pre.mk/post.mk pair or
bsd.port.mk only; don't mix these two.bsd.port.pre.mk only defines a few
variables, which can be used in tests in the
Makefile, bsd.port.post.mk
defines the rest.Here are some important variables defined in
bsd.port.pre.mk (this is not the complete list,
please read bsd.port.mk for the complete
list).VariableDescriptionARCHThe architecture as returned by uname
-m (e.g., i386)OPSYSThe operating system type, as returned by
uname -s (e.g.,
FreeBSD)OSRELThe release version of the operating system (e.g.,
2.1.5 or
2.2.7)OSVERSIONThe numeric version of the operating system, same as
__FreeBSD_version.PORTOBJFORMATThe object format of the system
(aout or elfLOCALBASEThe base of the “local” tree (e.g.,
/usr/local/)X11BASEThe base of the “X11” tree (e.g.,
/usr/X11R6)PREFIXWhere the port installs itself (see more on
PREFIX).If you have to define the variables
USE_IMAKE, USE_X_PREFIX, or
MASTERDIR, do so before including
bsd.port.pre.mk.Here are some examples of things you can write after
bsd.port.pre.mk;
# no need to compile lang/perl5 if perl5 is already in system
.if ${OSVERSION} > 300003
BROKEN= perl is in system
.endif
# only one shlib version number for ELF
.if ${PORTOBJFORMAT} == "elf"
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}
.else
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}.${SHLIB_MINOR}
.endif
# software already makes link for ELF, but not for a.out
post-install:
.if ${PORTOBJFORMAT} == "aout"
${LN} -sf liblinpack.so.1.0 ${PREFIX}/lib/liblinpack.so
.endifInstall additional documentationIf your software has some documentation other than the standard
man and info pages that you think is useful for the user, install it
under PREFIX/share/doc.
This can be done, like the previous item, in the
post-install target.Create a new directory for your port. The directory name should
reflect what the port is. This usually means
PKGNAME minus the version part. However, if you
think the user might want different versions of the port to be
installed at the same time, you can use the whole
PKGNAME.Make the installation dependent to the variable
NOPORTDOCS so that users can disable it in
/etc/make.conf, like this:
post-install:
.if !defined(NOPORTDOCS)
${MKDIR}${PREFIX}/share/doc/xv
${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${PREFIX}/share/doc/xv
.endifDo not forget to add them to pkg/PLIST too!
(Do not worry about NOPORTDOCS here; there is
currently no way for the packages to read variables from
/etc/make.conf.)Also you can use the pkg/MESSAGE file to
display messages upon installation. See the using
pkg/MESSAGE section for
details.MESSAGE does not need to be added to
pkg/PLIST).DIST_SUBDIRDo not let your port clutter
/usr/ports/distfiles. If your port requires a
lot of files to be fetched, or contains a file that has a name that
might conflict with other ports (e.g.,
Makefile), set DIST_SUBDIR
to the name of the port (PKGNAME without the
version part should work fine). This will change
DISTDIR from the default
/usr/ports/distfiles to
/usr/ports/distfiles/DIST_SUBDIR,
and in effect puts everything that is required for your port into
that subdirectory.It will also look at the subdirectory with the same name on the
backup master site at ftp.freebsd.org.
(Setting DISTDIR explicitly in your
Makefile will not accomplish this, so please use
DIST_SUBDIR.)This does not affect the MASTER_SITES you
define in your Makefile.Package informationDo include package information, i.e.
COMMENT, DESCR, and
PLIST, in pkg.Note that these files are not used only for packaging anymore,
and are mandatory now, even if
NO_PACKAGE is set.RCS stringsDo not put RCS strings in patches. CVS will mangle them when we
put the files into the ports tree, and when we check them out again,
they will come out different and the patch will fail. RCS strings
are surrounded by dollar ($) signs, and
typically start with $Id or
$RCS.Recursive diffUsing the recurse () option to
diff to generate patches is fine, but please take
a look at the resulting patches to make sure you don't have any
unnecessary junk in there. In particular, diffs between two backup
files, Makefiles when the port uses
Imake or GNU configure, etc.,
are unnecessary and should be deleted. If you had to edit
configure.in and run
autoconf to regenerate
configure, do not take the diffs of
configure (it often grows to a few thousand
lines!); define USE_AUTOCONF=yes and take the
diffsof configure.in.Also, if you had to delete a file, then you can do it in the
post-extract target rather than as part of
the patch. Once you are happy with the resulting diff, please split
it up into one source file per patch file.PREFIXDo try to make your port install relative to
PREFIX. (The value of this variable will be set
to LOCALBASE (default
/usr/local), unless
USE_X_PREFIX or USE_IMAKE is
set, in which case it will be X11BASE (default
/usr/X11R6).)Not hard-coding /usr/local or
/usr/X11R6 anywhere in the source will make the
port much more flexible and able to cater to the needs of other
sites. For X ports that use imake, this is
automatic; otherwise, this can often be done by simply replacing the
occurrences of /usr/local (or
/usr/X11R6 for X ports that do not use imake)
in the various scripts/Makefiles in the port to read
PREFIX, as this variable is automatically passed
down to every stage of the build and install processes.Do not set USE_X_PREFIX unless your port
truly require it (i.e., it links against X libs or it needs to
reference files in X11BASE).The variable PREFIX can be reassigned in your
Makefile or in the user's environment.
However, it is strongly discouraged for individual ports to set this
variable explicitly in the Makefiles.Also, refer to programs/files from other ports with the
variables mentioned above, not explicit pathnames. For instance, if
your port requires a macro PAGER to be the full
pathname of less, use the compiler flag:
-DPAGER=\"${PREFIX}/bin/less\"
or
-DPAGER=\"${LOCALBASE}/bin/less\"
if this is an X port, instead of
-DPAGER=\"/usr/local/bin/less\". This way it will
have a better chance of working if the system administrator has
moved the whole `/usr/local' tree somewhere else.SubdirectoriesTry to let the port put things in the right subdirectories of
PREFIX. Some ports lump everything and put it in
the subdirectory with the port's name, which is incorrect. Also,
many ports put everything except binaries, header files and manual
pages in the a subdirectory of lib, which does
not bode well with the BSD paradigm. Many of the files should be
moved to one of the following: etc
(setup/configuration files), libexec
(executables started internally), sbin
(executables for superusers/managers), info
(documentation for info browser) or share
(architecture independent files). See man &man.hier.7; for details,
the rules governing
/usr pretty much apply to
/usr/local too. The exception are ports
dealing with USENET “news”. They may use
PREFIX/news as a destination
for their files.Cleaning up empty directoriesDo make your ports clean up after themselves when they are
deinstalled. This is usually accomplished by adding
@dirrm lines for all directories that are
specifically created by the port. You need to delete subdirectories
before you can delete parent directories.
:
lib/X11/oneko/pixmaps/cat.xpm
lib/X11/oneko/sounds/cat.au
:
@dirrm lib/X11/oneko/pixmals
@dirrm lib/X11/oneko/sounds
@dirrm lib/X11/onekoHowever, sometimes @dirrm will give you
errors because other ports also share the same subdirectory. You
can call rmdir from @unexec to
remove only empty directories without warning.
@unexec rmdir %D/share/doc/gimp 2>/dev/null || trueThis will neither print any error messages nor cause
pkg_delete to exit abnormally even if
PREFIX/share/doc/gimp is not
empty due to other ports installing some files in there.UIDsIf your port requires a certain user to be on the installed
system, let the pkg/INSTALL script call
pw to create it automatically. Look at
net/cvsup-mirror for an example.If your port must use the same user/group ID number when it is
installed a binarypackage as when it was compiled, then you mus
choose a free UID from 50 to 99 and register it below. Look at
japanese/Wnn for an example.Make sure you don't use a UID already used by the system or
other ports. This is the current list of UIDs between 50 and
99.
majordom:*:54:54:Majordomo Pseudo User:/usr/local/majordomo:/nonexistent
cyrus:*:60:60:the cyrus mail server:/nonexistent:/nonexistent
gnats:*:61:1:GNATS database owner:/usr/local/share/gnats/gnats-db:/bin/sh
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/nonexistent
pop:*:68:6:Post Office Owner (popper):/nonexistent:/nonexistent
wnn:*:69:7:Wnn:/nonexistent:/nonexistent
ifmail:*:70:66:Ifmail user:/nonexistent:/nonexistent
pgsql:*:70:70:PostgreSQL pseudo-user:/usr/local/pgsql:/bin/sh
ircd:*:72:72:IRCd hybrid:/nonexistent:/nonexistent
alias:*:81:81:QMail user:/var/qmail/alias:/nonexistent
qmaill:*:83:81:QMail user:/var/qmail:/nonexistent
qmaild:*:82:81:QMail user:/var/qmail:/nonexistent
qmailq:*:85:82:QMail user:/var/qmail:/nonexistent
qmails:*:87:82:QMail user:/var/qmail:/nonexistent
qmailp:*:84:81:QMail user:/var/qmail:/nonexistent
qmailr:*:86:82:QMail user:/var/qmail:/nonexistent
msql:*:87:87:mSQL-2 pseudo-user:/var/db/msqldb:/bin/shPlease include a notice when you submit a port (or an upgrade)
that reserves a new UID or GID in this range. This allows us to
keep the list of reserved IDs up to date.Do things rationallyThe Makefile should do things simply and
reasonably. If you can make it a couple of lines shorter or more
readable, then do so. Examples include using a make
.if construct instead of a shell
if construct, not redefining
do-extract if you can redefine
EXTRACT* instead, and using
GNU_CONFIGURE instead of CONFIGURE_ARGS
+= --prefix=${PREFIX}.Respect CFLAGSThe port should respect the CFLAGS variable.
If it doesn't, please add NO_PACKAGE=ignores
cflags to the Makefile.Configuration filesIf your port requires some configuration files in
PREFIX/etc, do
not just install them and list them in
pkg/PLIST. That will cause
pkg_delete to delete files carefully edited by
the user and a new installation to wipe them out.Instead, install sample files with a suffix
(filename.sample
will work well) and print out a message pointing out that the
user has to copy and edit the file before the software can be made
to work.PortlintDo check your work with portlint
before you submit or commit it.FeedbackDo send applicable changes/patches to the original
author/maintainer for inclusion in next release of the code. This
will only make your job that much easier for the next
release.MiscellaneaThe files pkg/DESCR,
pkg/COMMENT, and pkg/PLIST
should each be double-checked. If you are reviewing a port and feel
they can be worded better, do so.Don't copy more copies of the GNU General Public License into
our system, please.Please be careful to note any legal issues! Don't let us
illegally distribute software!If you are stuck…Do look at existing examples and the
bsd.port.mk file before asking us questions!
;)Do ask us questions if you have any trouble! Do not just beat
your head against a wall! :)A Sample MakefileHere is a sample Makefile that you can use to
create a new port. Make sure you remove all the extra comments (ones
between brackets)!It is recommended that you follow this format (ordering of
variables, empty lines between sections, etc.). This format is
designed so that the most important information is easy to locate. We
recommend that you use portlint to check the
Makefile.
[the header...just to make it easier for us to identify the ports.]
# New ports collection makefile for: xdvi
[the version required header should updated when upgrading a port.]
# Version required: pl18 [things like "1.5alpha" are fine here too]
[this is the date when the first version of this Makefile was created.
Never change this when doing an update of the port.]
# Date created: 26 May 1995
[this is the person who did the original port to FreeBSD, in particular, the
person who wrote the first version of this Makefile. Remember, this should
not be changed when upgrading the port later.]
# Whom: Satoshi Asami <asami@FreeBSD.ORG>
#
# $Id$
[ ^^^^ This will be automatically replaced with RCS ID string by CVS
when it is committed to our repository.]
#
[section to describe the port itself and the master site - DISTNAME
is always first, followed by PKGNAME (if necessary), CATEGORIES,
and then MASTER_SITES, which can be followed by MASTER_SITE_SUBDIR.
After those, one of EXTRACT_SUFX or DISTFILES can be specified too.]
DISTNAME= xdvi
PKGNAME= xdvi-pl18
CATEGORIES= print
[do not forget the trailing slash ("/")!
if you aren't using MASTER_SITE_* macros]
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applications
[set this if the source is not in the standard ".tar.gz" form]
EXTRACT_SUFX= .tar.Z
[section for distributed patches -- can be empty]
PATCH_SITES= ftp://ftp.sra.co.jp/pub/X11/japanese/
PATCHFILES= xdvi-18.patch1.gz xdvi-18.patch2.gz
[maintainer; *mandatory*! This is the person (preferably with commit
privileges) who a user can contact for questions and bug reports - this
person should be the porter or someone who can forward questions to the
original porter reasonably promptly. If you really do not want to have
your address here, set it to "ports@FreeBSD.ORG".]
MAINTAINER= asami@FreeBSD.ORG
[dependencies -- can be empty]
RUN_DEPENDS= gs:${PORTSDIR}/print/ghostscript
LIB_DEPENDS= Xpm.5:${PORTSDIR}/graphics/xpm
[this section is for other standard bsd.port.mk variables that do not
belong to any of the above]
[If it asks questions during configure, build, install...]
IS_INTERACTIVE= yes
[If it extracts to a directory other than ${DISTNAME}...]
WRKSRC= ${WRKDIR}/xdvi-new
[If the distributed patches were not made relative to ${WRKSRC}, you
may need to tweak this]
PATCH_DIST_STRIP= -p1
[If it requires a "configure" script generated by GNU autoconf to be run]
GNU_CONFIGURE= yes
[If it requires GNU make, not /usr/bin/make, to build...]
USE_GMAKE= yes
[If it is an X application and requires "xmkmf -a" to be run...]
USE_IMAKE= yes
[et cetera.]
[non-standard variables to be used in the rules below]
MY_FAVORITE_RESPONSE= "yeah, right"
[then the special rules, in the order they are called]
pre-fetch:
i go fetch something, yeah
post-patch:
i need to do something after patch, great
pre-install:
and then some more stuff before installing, wow
[and then the epilogue]
.include <bsd.port.mk>Package NamesThe following are the conventions you should follow in naming your
packages. This is to have our package directory easy to scan, as
there are already lots and lots of packages and users are going to
turn away if they hurt their eyes!The package name should look like
language-name-compiled.specifics-version.numbers.If your DISTNAME doesn't look like that, set
PKGNAME to something in that format.FreeBSD strives to support the native language of its users.
The language- part should be a two
letter abbreviation of the natural language defined by ISO-639 if
the port is specific to a certain language. Examples are
ja for Japanese, ru for
Russian, vi for Vietnamese,
zh for Chinese, ko for
Korean and de for German.The name part should be all lowercases,
except for a really large package (with lots of programs in it).
Things like XFree86 (yes there really is a port of it, check it
out) and ImageMagick fall into this category. Otherwise, convert
the name (or at least the first letter) to lowercase. If the
capital letters are important to the name (for example, with
one-letter names like R or
V) you may use capital letters at your
discretion. There is a tradition of naming Perl 5 modules by
prepending p5- and converting the double-colon
separator to a hyphen; for example, the
Data::Dumper module becomes
p5-Data-Dumper. If the software in question
has numbers, hyphens, or underscores in its name, you may include
them as well (like kinput2).If the port can be built with different hardcoded defaults (usually
part of the directory name in a family of ports), the
-compiled.specifics part should state
the compiled-in defaults (the hyphen is optional). Examples are
papersize and font units.The version string should be a period-separated list of
integers and single lowercase alphabetics. The only exception is
the string pl (meaning `patchlevel'), which can
be used only when there are no major and
minor version numbers in the software.Here are some (real) examples on how to convert a
DISTNAME into a suitable
PKGNAME:Distribution NamePackage NameReasonmule-2.2.2.mule-2.2.2No changes requiredXFree86-3.1.2XFree86-3.1.2No changes requiredEmiClock-1.0.2emiclock-1.0.2No uppercase names for single programsgmod1.4gmod-1.4Need a hyphen before version numbersxmris.4.0.2xmris-4.0.2Need a hyphen before version numbersrdist-1.3alphardist-1.3aNo strings like alpha
allowedes-0.9-beta1es-0.9b1No strings like beta
allowedv3.3beta021.srctiff-3.3What the heck was that anyway?tvtwmtvtwm-pl11Version string always requiredpiewmpiewm-1.0Version string always requiredxvgr-2.10pl1xvgr-2.10.1pl allowed only when no
major/minor version numbersgawk-2.15.6ja-gawk-2.15.6Japanese language versionpsutils-1.13psutils-letter-1.13Papersize hardcoded at package build timepkfontspkfonts300-1.0Package for 300dpi fontsIf there is absolutely no trace of version information in the
original source and it is unlikely that the original author will ever
release another version, just set the version string to
1.0 (like the piewm example above). Otherwise, ask
the original author or use the date string
(yy.mm.dd) as the version.CategoriesAs you already know, ports are classified in several categories.
But for this to wor, it is important that porters and users understand
what each category and how we deicde what to put in each
category.Current list of categoriesFirst, this is the current list of port categories. Those
marked with an asterisk (*) are
virtual categories—those that do not have
a corresponding subdirectory in the ports tree.For non-virtual categories, you will find a one-line
description in the pkg/COMMENT file in that
subdirectory (e.g.,
archivers/pkg/COMMENT).CategoryDescriptionafterstep*Ports to support AfterStep window managerarchiversArchiving tools.astroAstronomical ports.audioSound support.benchmarksBenchmarking utilities.biologyBiology-related software.cadComputer aided design tools.chineseChinese language support.commsCommunication software. Mostly software to talk to
your serial port.convertersCharacter code converters.databasesDatabases.deskutilsThings that used to be on the desktop before
computers were invented.develDevelopment utilities. Do not put libraries here just
because they are libraries—unless they truly don't
belong to anywhere else, they shouldn't be in this
category.editorsGeneral editors. Specialized editors go in the section
for those tools (e.g., a mathematical-formula editor will go
in math).elispEmacs-lisp ports.emulatorsEmulators for other operating systems. Terminal
emulators do not belong
here—X-based ones should go to
x11 and text-based ones to either
comms or misc,
depending on the exact functionality.gamesGames.germanGerman language support.graphicsGraphics utilities.japaneseJapanese language support.kde*Ports that form the K Desktop Environment
(kde).koreanKorean language support.langProgramming languages.mailMail software.mathNumerical computation software and other utilities
for mathematics.mboneMBone applications.miscMiscellaneous utilities—basically things that
doesn't belong to anywhere else. This is the only category
that should not appear with any other non-virtual category.
If you have misc with something else in
your CATEGORIES line, that means you can
safely delete misc and just put the port
in that other subdirectory!netMiscellaneous networking software.newsUSENET news software.offix*Ports from the OffiX suite.palmSoftware support for the 3Com Palm(tm) series.perl5*Ports that require perl version 5 to run.plan9*Various programs from Plan9.printPrinting software. Desktop publishing tools
(previewers, etc.) belong here too.python*Software written in python.russianRussian language support.securitySecurity utilities.shellsCommand line shells.sysutilsSystem utilities.tcl75*Ports that use tcl version 7.5 to run.tcl76*Ports that use tcl version 7.6 to run.tcl80*Ports that use tcl version 8.0 to run.tcl81*Ports that use tcl version 8.1 to run.textprocText processing utilities. It does not include
desktop publishing tools, which go to print/.tk41*Ports that use tk version 4.1 to run.tk42*Ports that use tk version 4.2 to run.tk80*Ports that use tk version 8.0 to run.tk81*Ports that use tk version 8.1 to run.vietnameseVietnamese language support.windowmaker*Ports to support the WindowMaker window
managerwwwSoftware related to the World Wide Web. HTML language
support belong here too.x11The X window system and friends. This category is only
for software that directly support the window system. Do not
put regular X applications here. If your port is an X
application, define USE_XLIB (implied by
USE_IMAKE) and put it in appropriate
categories. Also, many of them go into other
x11-* categories (see below).x11-clocksX11 clocks.x11-fmX11 file managers.x11-fontsX11 fonts and font utilities.x11-toolkitsX11 toolkits.x11-wmX11 window managers.Choosing the right categoryAs many of the categories overlap, you often have to choose
which of the categories should be the primary category of your port.
There are several rules that govern this usse. Here is the list of
priorities, in decreasing order of precedence.Language specific categories alwasys come first. For
example, if your port installs Japanese X11 fonts, then your
CATEGORIES line would read japanese
x11.Specific categories win over less-specific ones. For
instance, an HTML editor should be listed as www
editors, not the other way around. Also, you don't
need to list net when the port belongs to
either of mail, mbone,
news, security, or
www.x11 is used as a secondary category only
when the primary category is a natural language. In particular,
you should not put x11 in the category line
for X applications.If your port truly does not belong anywhere else, put it in
misc.If you are not sure about the category, please put a comment to
that effect in your send-pr submission so we can
discuss it before import it. (If you are a committer, send a note
&a.ports; so we can discuss it first—too often new ports are
imported to a wrong category only to be moved right away.)Changes to this document and the ports systemIf you maintain a lot of ports, you should consider following the
&a.ports;. Important changes to the way ports work will be announced
there. You can always find more detailed information on the latest
changes by looking at the
bsd.port.mk CVS log.That is It, Folks!Boy, this sure was a long tutorial, wasn't it? Thanks for
following us to here, really.Well, now that you know how to do a port, let us go at it and
convert everything in the world into ports! That is the easiest way to
start contributing to the FreeBSD Project! :)
diff --git a/en_US.ISO8859-1/books/handbook/ppp-and-slip/chapter.sgml b/en_US.ISO8859-1/books/handbook/ppp-and-slip/chapter.sgml
index a6b0d462da..2db526fa62 100644
--- a/en_US.ISO8859-1/books/handbook/ppp-and-slip/chapter.sgml
+++ b/en_US.ISO8859-1/books/handbook/ppp-and-slip/chapter.sgml
@@ -1,2487 +1,2488 @@
PPP and SLIPIf your connection to the Internet is through a modem, or you wish to
provide other people with dialup connections to the Internet using
FreeBSD, you have the option of using PPP or SLIP. Furthermore, two
varieties of PPP are provided: user (sometimes
referred to as iijppp) and
kernel. The procedures for configuring both types of
PPP, and for setting up SLIP are described in this chapter.Setting up User PPPUser PPP was introduced to FreeBSD in release 2.0.5 as an addition
to the existing kernel implementation of PPP. So, what is different
about this new PPP that warrants its addition? To quote from the manual
page:
This is a user process PPP software package. Normally, PPP is
implemented as a part of the kernel (e.g. as managed by
pppd) and it is thus somewhat hard to debug and/or
modify its behavior. However, in this implementation PPP is done as a
- user process with the help of the tunnel device driver (tun).
+ user process with the help of the tunnel device driver
+ (tun).
In essence, this means that rather than running a PPP daemon, the
ppp program can be run as and when desired. No PPP interface needs to
be compiled into the kernel, as the program can use the generic tunnel
device to get data into and out of the kernel.From here on out, user ppp will be referred to simply as ppp unless
a distinction needs to be made between it and any other PPP
client/server software such as pppd. Unless
otherwise stated, all commands in this section should be executed as
root.There are a large number of enhancements in version 2 of ppp. You
can discover what version you have by running ppp with no arguments and
typing show version at the prompt. It is a simple
matter to upgrade to the latest version of ppp (under any version of
FreeBSD) by downloading the latest archive via www.Awfulhak.org.Before you startThis document assumes you are in roughly this position:You have an account with an Internet Service Provider (ISP) which
lets you use PPP. Further, you have a modem (or other device)
connected and configured correctly which allows you to connect to your
ISP.You are going to need the following information to hand:Your ISPs phone number(s).Your login name and password. This can be either a regular
unix style login/password pair, or a PPP PAP or CHAP
login/password pair.The IP addresses of one or more nameservers. Normally, you
will be given two IP numbers. You must have
this information for PPP version 1.x
unless you run your own nameserver. From version 2 onwards,
PPP supports nameserver address
negotiation. If your ISP supports this, then using the command
enable dns in your config file will tell
PPP to set the nameservers for
you.The following information may have been supplied by your ISP, but
is not strictly necessary:The IP address of your ISP's gateway. The gateway is the
machine to which you will connect and will be set up as your
default route. If your ISP hasn't given you
this number, we can make one up and your ISP's PPP server will
tell us the correct value when we connect.This IP number is referred to as HISADDR
by ppp.Your ISP's netmask. If your ISP hasn't given you this
information, you can safely use a netmask of 255.255.255.0.If your ISP allocates you a static IP address and hostname
then you can enter this information. Otherwise, we simply let the
peer assign whatever IP number it sees fit.If you do not have any of the required information, contact your
ISP and make sure they provide it to you.Building a ppp ready kernelAs the description states, ppp uses the kernel
tun device. It is necessary to make sure
that your kernel has support for this device compiled in.To check this, go to your kernel compile directory
(/sys/i386/conf or
/sys/pc98/conf) and examine your kernel
configuration file. It needs to have the line
pseudo-device tun 1
in it somewhere. The stock GENERIC kernel has
this as standard, so if you have not installed a custom kernel or you
do not have a /sys directory, you do not have to
change anything.If your kernel configuration file does not have this line in it,
- or you need to configure more than one tun device (for example, if you
+ or you need to configure more than one tun device (for example, if you
are setting up a server and could have 16 dialup ppp connections at
any one time then you will need to use 16 instead
of 1), then you should add the line, re-compile,
re-install and boot the new kernel. Please refer to the Configuring the FreeBSD Kernel section
for more information on kernel configuration.You can check how many tunnel devices your current kernel has by
typing the following:&prompt.root; ifconfig -a
tun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 200.10.100.1 --> 203.10.100.24 netmask 0xffffffff
tun1: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 576
tun2: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 203.10.100.1 --> 203.10.100.20 netmask 0xffffffff
tun3: flags=8010<POINTOPOINT,MULTICAST> mtu 1500This case shows four tunnel devices, two of which are currently
configured and being used. It should be noted that the
RUNNING flag above indicates that the interface has
been used at some point—it is not an error if your interface
does not show up as RUNNING.
- If you have a kernel without the tun device, and you can not
+ If you have a kernel without the tun device, and you can not
rebuild it for some reason, all is not lost. You should be able to
dynamically load the code. Refer to the appropriate
&man.modload.8; and &man.lkm.4; pages for further details.You may also wish to take this opportunity to configure a
firewall. Details can be found in the Firewalls section.Check the tun deviceMost users will only require one tun
device (/dev/tun0). If you have used more (i.e.,
a number other than 1 in the
pseudo-device line in the kernel configuration
file) then alter all references to tun0 below
to reflect whichever device number you are using.The easiest way to make sure that the
tun0 device is configured correctly is to
re-make it. To do this, execute the following commands:&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun0If you require 16 tunnel devices in your kernel, you will need to
- create more than just tun0:
+ create more than just tun0:
&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun15Also, to confirm that the kernel is configured correctly, the
following command should give the indicated output:&prompt.root; ifconfig tun0
tun0: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 1500The RUNNING flag may not yet be set, in which
case you will see:&prompt.root; ifconfig tun0
tun0: flags=8010<POINTOPOINT,MULTICAST> mtu 1500Name Resolution ConfigurationThe resolver is the part of the system that turns IP addresses
into hostnames and vice versa. It can be configured to look for maps
that describe IP to hostname mappings in one of two places. The first
is a file called /etc/hosts (man 5
hosts). The second is the Internet Domain Name Service
(DNS), a distributed data base, the discussion of which is beyond the
scope of this document.This section describes briefly how to configure your
resolver.The resolver is a set of system calls that do the name mappings,
but you have to tell them where to find their information. You do
this by first editing the file /etc/host.conf.
Do not call this file
/etc/hosts.conf (note the extra
s) as the results can be confusing.Edit the /etc/host.conf fileThis file should contain the following two lines (in this
order):
hosts
bindThese instructs the resolver to first look in the file
/etc/hosts, and then to consult the DNS if the
name was not found.Edit the /etc/hosts(5) fileThis file should contain the IP addresses and names of machines
on your network. At a bare minimum it should contain entries for
the machine which will be running ppp. Assuming that your machine
is called foo.bar.com with the IP
address 10.0.0.1,
/etc/hosts should contain:
127.0.0.1 localhost
10.0.0.1 foo.bar.com fooThe first line defines the alias localhost as a
synonym for the current machine. Regardless of your own IP address,
the IP address for this line should always be 127.0.0.1. The second line maps the name
foo.bar.com (and the shorthand
foo) to the IP address 10.0.0.1.If your provider allocates you a static IP address and name,
then use these in place of the 10.0.0.1 entry.Edit the /etc/resolv.conf file/etc/resolv.conf tells the resolver how to
behave. If you are running your own DNS, you may leave this file
empty. Normally, you will need to enter the following
line(s):
nameserver x.x.x.x
nameserver y.y.y.y
domain bar.comThe x.x.x.x and
y.y.y.y
addresses are those given to you by your ISP. Add as many
nameserver lines as your ISP provides. The
domain line defaults to your hostname's domain,
and is probably unnecessary. Refer to the
resolv.conf manual page for details of other
possible entries in this file.If you are running PPP version 2 or greater, the enable
dns command will tell PPP to request that your ISP
confirms the nameserver values. If your ISP supplies different
addresses (or if there are no nameserver lines in
/etc/resolv.conf), PPP will rewrite the file
with the ISP-supplied values.ppp ConfigurationBoth user ppp and pppd (the kernel level
implementation of PPP) use configuration files located in the
/etc/ppp directory. The sample configuration
files provided are a good reference for user ppp, so don't delete
them.Configuring ppp requires that you edit a number
of files, depending on your requirements. What you put in them
depends to some extent on whether your ISP allocates IP addresses
statically (i.e., you get given one IP address, and always use that
one) or dynamically (i.e., your IP address can be different for each
PPP session).PPP and Static IP addressesYou will need to create a configuration file called
/etc/ppp/ppp.conf. It should look similar to
the example below.Lines that end in a : start in the first
column, all other lines should be indented as shown using spaces
or tabs.
1 default:
2 set device /dev/cuaa0
3 set speed 115200
4 set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \"\" ATE1Q0 OK-AT-OK \\dATDT\\TTIMEOUT 40 CONNECT"
5 provider:
6 set phone "(0123) 456 7890"
7 set login "TIMEOUT 10 \"\" \"\" gin:--gin: foo word: bar col: ppp"
8 set timeout 300
9 set ifaddr x.x.x.xy.y.y.y 255.255.255.0 0.0.0.0
10 add default HISADDR
11 enable dnsDo not include the line numbers, they are just for reference in
this discussion.Line 1:Identifies the default entry. Commands in this entry are
executed automatically when ppp is run.Line 2:Identifies the device to which the modem is connected.
COM1: is
/dev/cuaa0 and
COM2: is
/dev/cuaa1.Line 3:Sets the speed you want to connect at. If 115200 doesn't
work (it should with any reasonably new modem), try 38400
instead.Line 4:The dial string. User PPP uses an expect-send syntax
similar to the &man.chat.8; program. Refer to the
manual page for information on the features of this
language.Line 5:Identifies an entry for a provider called
“provider”.Line 6:Sets the phone number for this provider. Multiple phone
numbers may be specified using the : or
| character as a separator. The difference
- between these spearators is described in the ppp manual page.
+ between these separators is described in &man.ppp.8;.
To summarize, if you want to rotate through the numbers, use
the :. If you want to always attempt to
dial the first number first and only use the other numbers if
the first number fails, use the |. Always
quote the entire set of phone numbers as shown.Line 7:The login string is of the same chat-like syntax as the
dial string. In this example, the string works for a service
whose login session looks like this:J. Random Provider
login: foo
password: bar
protocol: pppYou will need to alter this script to suit your own needs.
When you write this script for the first time, you should
enable “chat” logging to ensure that the
conversation is going as expected.If you're using PAP or CHAP, there will be no login at
this point, so your login string can be left blank. See PAP and CHAP
authentication for further details.Line 8:Sets the default timeout (in seconds) for the connection.
Here, the connection will be closed automatically after 300
seconds of inactivity. If you never want to timeout, set this
value to zero.Line 9:Sets the interface addresses. The string
x.x.x.x should be replaced by the
IP address that your provider has allocated to you. The
string y.y.y.y should be replaced
by the IP address that your ISP indicated for their gateway
(the machine to which you connect). If your ISP hasn't given
you a gateway address, use 10.0.0.2/0. If you need to use a
“guessed” address, make sure that you create an
entry in /etc/ppp/ppp.linkup as per the
instructions for PPP and
Dynamic IP addresses. If this line is omitted,
ppp cannot run in or
mode.Line 10:Adds a default route to your ISPs gateway. The special
word HISADDR is replaced with the gateway
address specified on line 9. It is important that this line
appears after line 9, otherwise HISADDR
will not yet be initialized.Line 11:This line tells PPP to ask your ISP to confirm that your
nameserver addresses are correct. If your ISP supports this
facility, PPP can then update
/etc/resolv.conf with the correct
nameserver entries.It is not necessary to add an entry to
ppp.linkup when you have a static IP address as
your routing table entries are already correct before you connect.
You may however wish to create an entry to invoke programs after
connection. This is explained later with the sendmail
example.Example configuration files can be found in the
/etc/ppp directory.PPP and Dynamic IP addressesIf your service provider does not assign static IP numbers,
ppp can be configured to negotiate the local and
remote addresses. This is done by “guessing” an IP
number and allowing ppp to set it up correctly
using the IP Configuration Protocol (IPCP) after connecting. The
ppp.conf configuration is the same as PPP and Static IP addresses,
with the following change:
9 set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0Again, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 9:The number after the / character is the
number of bits of the address that ppp will insist on. You
may wish to use IP numbers more appropriate to your
circumstances, but the above example will always work.The last argument (0.0.0.0) tells PPP
to negotiate using address 0.0.0.0 rather than 10.0.0.1. Do not use
0.0.0.0 as the first argument to
set ifaddr as it prevents PPP from setting
up an intial route in mode.If you are running version 1.x of PPP, uou will also need to
create an entry in /etc/ppp/ppp.linkup.
ppp.linkup is used after a connection has been
established. At this point, ppp will know what
IP addresses should really be used. The
following entry will delete the existing bogus routes, and create
correct ones:
1 provider:
2 delete ALL
3 add 0 0 HISADDRLine 1:On establishing a connection, ppp will
look for an entry in ppp.linkup according
to the following rules: First, try to match the same label as
we used in ppp.conf. If that fails, look
for an entry for the IP number of our gateway. This entry is
a four-octet IP style label. If we still haven't found an
entry, look for the MYADDR entry.Line 2:This line tells ppp to delete all
existing routes for the acquired tun interface (except the
direct route entry).Line 3:This line tells ppp to add a default
route that points to HISADDR.
HISADDR will be replaced with the IP number
of the gateway as negotiated in the IPCP.See the pmdemand entry in the files
/etc/ppp/ppp.conf.sample and
/etc/ppp/ppp.linkup.sample for a detailed
example.Version 2 of PPP introduces “sticky routes”. Any
add or delete lines that
contain MYADDR or HISADDR will
be remembered, and any time the actual values of
MYADDR or HISADDR change, the
routes will be re-applied. This removes the necessity of repeating
these lines in ppp.linkup.Receiving incoming calls with pppThis section describes setting up ppp in a
server role.When you configure ppp to receive incoming
calls on a machine connected to a LAN, you must decide if you wish
to forward packets to the LAN. If you do, you should allocate the
peer an IP number from your LAN's subet, and use the command
enable proxy
in your ppp.conf file. You should also confirm
that the /etc/rc.conf file (this file used to
be called /etc/sysconfig) contains the
following:
gateway=YESWhich getty?Configuring FreeBSD for Dialup
Services provides a good description on enabling dialup
services using getty.An alternative to getty is mgetty,
a smarter version of getty designed with dialup
lines in mind.The advantages of using mgetty is that it
actively talks to modems, meaning if port is
turned off in /etc/ttys then your modem won't
answer the phone.Later versions of mgetty (from 0.99beta
onwards) also support the automatic detection of PPP streams,
allowing your clients script-less access to your server.Refer to Mgetty and
AutoPPP for more information on
mgetty.PPP permissionsppp must normally be run as user id 0. If
however you wish to allow ppp to run in server
mode as a normal user by executing ppp as
described below, that user must be given permission to run
ppp by adding them to the
network group in
/etc/group.You will also need to give them access to one or more sections
of the configuration file using the allow
command:
allow users fred maryIf this command is used in the default
section, it gives the specified users access to everything.Setting up a PPP shell for dynamic-IP usersCreate a file called /etc/ppp/ppp-shell
containing the following:
#!/bin/sh
IDENT=`echo $0 | sed -e 's/^.*-\(.*\)$/\1/'`
CALLEDAS="$IDENT"
TTY=`tty`
if [ x$IDENT = xdialup ]; then
IDENT=`basename $TTY`
fi
echo "PPP for $CALLEDAS on $TTY"
echo "Starting PPP for $IDENT"
exec /usr/sbin/ppp -direct $IDENTThis script should be executable. Now make a symbolic link
called ppp-dialup to this script using the
following commands:&prompt.root; ln -s ppp-shell /etc/ppp/ppp-dialupYou should use this script as the shell
for all your dialup ppp users. This is an example from
/etc/password for a dialup PPP user with
username pchilds. (remember don't directly
edit the password file, use vipw)
pchilds:*:1011:300:Peter Childs PPP:/home/ppp:/etc/ppp/ppp-dialupCreate a /home/ppp directory that is
world readable containing the following 0 byte files
-r--r--r-- 1 root wheel 0 May 27 02:23 .hushlogin
-r--r--r-- 1 root wheel 0 May 27 02:22 .rhosts
which prevents /etc/motd from being
displayed.Setting up a PPP shell for static-IP usersCreate the ppp-shell file as above and
for each account with statically assigned IPs create a symbolic
link to ppp-shell.For example, if you have three dialup customers
fred, sam, and
mary, that you route class C networks for,
you would type the following:&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-fred
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-sam
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-maryEach of these users dialup accounts should have their shell
set to the symbolic link created above. (ie.
mary's shell should be
/etc/ppp/ppp-mary).Setting up ppp.conf for dynamic-IP usersThe /etc/ppp/ppp.conf file should contain
something along the lines of
default:
set debug phase lcp chat
set timeout 0
ttyd0:
set ifaddr 203.14.100.1 203.14.100.20 255.255.255.255
enable proxy
ttyd1:
set ifaddr 203.14.100.1 203.14.100.21 255.255.255.255
enable proxyThe indenting is important.The default: section is loaded for each
session. For each dialup line enabled in
/etc/ttys create an entry similar to the one
for ttyd0: above. Each line should get a
unique IP address from your pool of IP addresses for dynamic
users.Setting up ppp.conf for static-IP
usersAlong with the contents of the sample
/etc/ppp/ppp.conf above you should add a
section for each of the statically assigned dialup users. We will
continue with our fred,
sam, and mary
example.
fred:
set ifaddr 203.14.100.1 203.14.101.1 255.255.255.255
sam:
set ifaddr 203.14.100.1 203.14.102.1 255.255.255.255
mary:
set ifaddr 203.14.100.1 203.14.103.1 255.255.255.255The file /etc/ppp/ppp.linkup should also
contain routing information for each static IP user if required.
The line below would add a route for the 203.14.101.0 class C via the client's
ppp link.
fred:
add 203.14.101.0 netmask 255.255.255.0 HISADDR
sam:
add 203.14.102.0 netmask 255.255.255.0 HISADDR
mary:
add 203.14.103.0 netmask 255.255.255.0 HISADDRMore on mgetty, AutoPPP, and MS
extensionsmgetty and AutoPPPConfiguring and compiling mgetty with the
AUTO_PPP option enabled allows
mgetty to detect the LCP phase of PPP
connections and automatically spawn off a ppp shell. However,
since the default login/password sequence does not occur it is
necessary to authenticate users using either PAP or CHAP.This section assumes the user has successfully configured,
compiled, and installed a version of mgetty
with the AUTO_PPP option (v0.99beta or
later)Make sure your
/usr/local/etc/mgetty+sendfax/login.config
file has the following in it:
/AutoPPP/ - - /etc/ppp/ppp-pap-dialupThis will tell mgetty to run the
ppp-pap-dialup script for detected PPP
connections.Create a file called
/etc/ppp/ppp-pap-dialup containing the
following (the file should be executable):
#!/bin/sh
exec /usr/sbin/ppp -direct pap$IDENTFor each dialup line enabled in
/etc/ttys create a corresponding entry in
/etc/ppp/ppp.conf. This will happily
co-exist with the definitions we created above.
pap:
enable pap
set ifaddr 203.14.100.1 203.14.100.20-203.14.100.40
enable proxyEach user logging in with this method will need to have a
username/password in /etc/ppp/ppp.secret
file, or alternatively add the
enable passwdauthoption to authenticate users via pap from the
/etc/password file.If you wish to assign some users a static IP number, you can
specify the number as the third argument in
/etc/ppp/ppp.secret. See
/etc/ppp/ppp.secret.sample for
examples.MS extentionsIt is possible to configure PPP to supply DNS and NetBIOS
nameserver addresses on demand.To enable these extensions with PPP version 1.x, the
following lines might be added to the relevant section of
/etc/ppp/ppp.conf.
enable msext
set ns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5And for PPP version 2 and above:
accept dns
set dns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5This will tell the clients the primary and secondary name
server addresses, and a netbios nameserver host.In version 2 and above, if the set dns
line is ommitted, PPP will use the values found in
/etc/resolv.conf.PAP and CHAP authenticationSome ISPs set their system up so that the authentication part of
your connection is done using either of the PAP or CHAP
authentication mechanisms. If this is the case, your ISP will not
give a login: prompt when you connect, but will
start talking PPP immediately.PAP is less secure than CHAP, but security is not normally an
issue here as passwords, although being sent as plain text with PAP,
are being transmitted down a serial line only. There's not much room
for crackers to “eavesdrop”.Referring back to the PPP and
Static IP addresses or PPP and Dynamic IP addresses
sections, the following alterations must be made:
7 set login
…
12 set authname MyUserName
13 set authkey MyPasswordAs always, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 7:Your ISP will not normally require that you log into the
server if you're using PAP or CHAP. You must therefore
disable your "set login" string.Line 12:This line specifies your PAP/CHAP user name. You will
need to insert the correct value for
MyUserName.Line 13:This line specifies your PAP/CHAP password. You will need
to insert the correct value for
MyPassword. You may want to add an
additional line
15 accept PAP
or
15 accept CHAP
to make it obvious that this is the intention, but PAP and
CHAP are both accepted by default.Changing your ppp configuration on the
flyIt is possible to talk to the ppp program
while it is running in the background, but only if a suitable
diagnostic port has been set up. To do this, add the following line
to your configuration:
set server /var/run/ppp-tun%d DiagnosticPassword 0177This will tell PPP to listen to the specified unix-domain
socket, asking clients for the specified password before allowing
- access. The %d in the name is replaced with teh
- tun device number that is in use.
+ access. The %d in the name is replaced with the
+ tun device number that is in use.
Once a socket has been set up, the
&man.pppctl.8; program may be used in scripts that wish to
manipulate the running program.Final system configurationYou now have ppp configured, but there are a
few more things to do before it is ready to work. They all involve
editing the /etc/rc.conf file (was
/etc/sysconfig).Working from the top down in this file, make sure the
hostname= line is set, e.g.:
hostname=foo.bar.comIf your ISP has supplied you with a static IP address and name,
it's probably best that you use this name as your host name.Look for the network_interfaces variable. If
you want to configure your system to dial your ISP on demand, make
sure the tun0 device is added to the list,
otherwise remove it.
network_interfaces="lo0 tun0" ifconfig_tun0=The ifconfig_tun0 variable should be empty,
and a file called /etc/start_if.tun0 should be
created. This file should contain the line
ppp -auto mysystemThis script is executed at network configuration time, starting
your ppp daemon in automatic mode. If you have a LAN for which this
machine is a gateway, you may also wish to use the
switch. Refer to the manual page for
further details.Set the router program to NO with the
line
router_enable=NO (/etc/rc.conf)
router=NO (/etc/sysconfig)It is important that the routed daemon is not
started (it's started by default) as routed tends
to delete the default routing table entries created by
ppp.It is probably worth your while ensuring that the
sendmail_flags line does not include the
option, otherwise sendmail will
attempt to do a network lookup every now and then, possibly causing
your machine to dial out. You may try:
sendmail_flags="-bd"The upshot of this is that you must force
sendmail to re-examine the mail queue whenever the
ppp link is up by typing:&prompt.root; /usr/sbin/sendmail -qYou may wish to use the !bg command in
ppp.linkup to do this automatically:
1 provider:
2 delete ALL
3 add 0 0 HISADDR
4 !bg sendmail -bd -q30mIf you don't like this, it is possible to set up a
“dfilter” to block SMTP traffic. Refer to the sample
files for further details.All that is left is to reboot the machine.After rebooting, you can now either type&prompt.root; pppand then dial provider to start the PPP
session, or, if you want ppp to establish sessions
automatically when there is outbound traffic (and you haven't created
the start_if.tun0 script), type&prompt.root; ppp -auto providerSummaryTo recap, the following steps are necessary when setting up ppp
for the first time:Client side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/ppp/ppp.conf.
The pmdemand example should suffice for most
ISPs.If you have a dynamic IP address, create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.Create a start_if.tun0 script if you
require demand dialing.Server side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/passwd (using the
&man.vipw.8; program).Create a profile in this users home directory that runs
ppp -direct direct-server or similar.Create an entry in /etc/ppp/ppp.conf.
The direct-server example should
suffice.Create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.AcknowledgmentsThis section of the handbook was last updated on Monday Aug 10,
1998 by &a.brian;Thanks to the following for their input, comments &
suggestions:&a.nik;&a.dirkvangulik;&a.pjc;Setting up Kernel PPPContributed by &a.gena;.Before you start setting up PPP on your machine make sure that
pppd is located in /usr/sbin and
directory /etc/ppp exists.pppd can work in two modes:as a “client”, i.e. you want to connect your machine
to outside world via PPP serial connection or modem line.as a “server”, i.e. your machine is located on the
network and used to connect other computers using PPP.In both cases you will need to set up an options file
(/etc/ppp/options or ~/.ppprc
if you have more then one user on your machine that uses PPP).You also will need some modem/serial software (preferably kermit) so
you can dial and establish connection with remote host.Working as a PPP clientI used the following /etc/ppp/options to
connect to CISCO terminal server PPP line.
crtscts # enable hardware flow control
modem # modem control line
noipdefault # remote PPP server must supply your IP address.
# if the remote host doesn't send your IP during IPCP
# negotiation , remove this option
passive # wait for LCP packets
domain ppp.foo.com # put your domain name here
:<remote_ip> # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be your
# default routerTo connect:Dial to the remote host using kermit (or other modem program)
enter your user name and password (or whatever is needed to enable
PPP on the remote host)Exit kermit (without hanging up the line).enter:&prompt.root; /usr/src/usr.sbin/pppd.new/pppd /dev/tty0119200Use the appropriate speed and device name.Now your computer is connected with PPP. If the connection fails
for some reasons you can add the option to the
/etc/ppp/options file and check messages on the
console to track the problemFollowing /etc/ppp/pppup script will make all
3 stages automatically:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.dial
pppd /dev/tty01 19200/etc/ppp/kermit.dial is kermit script that
dials and makes all necessary authorization on the remote host.
(Example of such script is attached to the end of this
document)Use the following /etc/ppp/pppdown script to
disconnect the PPP line:
#!/bin/sh
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill -TERM ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
/sbin/ifconfig ppp0 down
/sbin/ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.hup
/etc/ppp/ppptestCheck if PPP is still running
(/usr/etc/ppp/ppptest):
#!/bin/sh
pid=`ps ax| grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'pppd running: PID=' ${pid-NONE}
else
echo 'No pppd running.'
fi
set -x
netstat -n -I ppp0
ifconfig ppp0Hangs up modem line
(/etc/ppp/kermit.hup):
set line /dev/tty01 ; put your modem device here
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
echo \13
exitHere is an alternate method using chat instead
of kermit.Contributed by &a.rhuff;.The following two files are sufficient to accomplish a pppd
connection./etc/ppp/options:
/dev/cuaa1 115200
crtscts # enable hardware flow control
modem # modem control line
connect "/usr/bin/chat -f /etc/ppp/login.chat.script"
noipdefault # remote PPP serve must supply your IP address.
# if the remote host doesn't send your IP during
# IPCP negotiation, remove this option
passive # wait for LCP packets
domain <your.domain> # put your domain name here
: # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be
# your default router/etc/ppp/login.chat.script:(This should actually go into a single line.)
ABORT BUSY ABORT 'NO CARRIER' "" AT OK ATDT<phone.number>
CONNECT "" TIMEOUT 10 ogin:-\\r-ogin: <login-id>
TIMEOUT 5 sword: <password>Once these are installed and modified correctly, all you need to
do is&prompt.root; pppdThis sample based primarily on information provided by: Trev
Roydhouse <Trev.Roydhouse@f401.n711.z3.fidonet.org> and used by
permission.Working as a PPP server/etc/ppp/options:
crtscts # Hardware flow control
netmask 255.255.255.0 # netmask ( not required )
192.114.208.20:192.114.208.165 # ip's of local and remote hosts
# local ip must be different from one
# you assigned to the ethernet ( or other )
# interface on your machine.
# remote IP is ip address that will be
# assigned to the remote machine
domain ppp.foo.com # your domain
passive # wait for LCP
modem # modem lineFollowing /etc/ppp/pppserv script will enable
ppp server on your machine:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
# reset ppp interface
ifconfig ppp0 down
ifconfig ppp0 delete
# enable autoanswer mode
kermit -y /etc/ppp/kermit.ans
# run ppp
pppd /dev/tty01 19200Use this /etc/ppp/pppservdown script to stop
ppp server:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.noansFollowing kermit script will enable/disable autoanswer mode on
your modem (/etc/ppp/kermit.ans):
set line /dev/tty01
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
inp 5 OK
echo \13
out ATS0=1\13 ; change this to out ATS0=0\13 if you want to disable
; autoanswer mod
inp 5 OK
echo \13
exitThis /etc/ppp/kermit.dial script is used for
dialing and authorizing on remote host. You will need to customize it
for your needs. Put your login and password in this script, also you
will need to change input statement depending on responses from your
modem and remote host.
;
; put the com line attached to the modem here:
;
set line /dev/tty01
;
; put the modem speed here:
;
set speed 19200
set file type binary ; full 8 bit file xfer
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
set modem hayes
set dial hangup off
set carrier auto ; Then SET CARRIER if necessary,
set dial display on ; Then SET DIAL if necessary,
set input echo on
set input timeout proceed
set input case ignore
def \%x 0 ; login prompt counter
goto slhup
:slcmd ; put the modem in command mode
echo Put the modem in command mode.
clear ; Clear unread characters from input buffer
pause 1
output +++ ; hayes escape sequence
input 1 OK\13\10 ; wait for OK
if success goto slhup
output \13
pause 1
output at\13
input 1 OK\13\10
if fail goto slcmd ; if modem doesn't answer OK, try again
:slhup ; hang up the phone
clear ; Clear unread characters from input buffer
pause 1
echo Hanging up the phone.
output ath0\13 ; hayes command for on hook
input 2 OK\13\10
if fail goto slcmd ; if no OK answer, put modem in command mode
:sldial ; dial the number
pause 1
echo Dialing.
output atdt9,550311\13\10 ; put phone number here
assign \%x 0 ; zero the time counter
:look
clear ; Clear unread characters from input buffer
increment \%x ; Count the seconds
input 1 {CONNECT }
if success goto sllogin
reinput 1 {NO CARRIER\13\10}
if success goto sldial
reinput 1 {NO DIALTONE\13\10}
if success goto slnodial
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 60 goto look
else goto slhup
:sllogin ; login
assign \%x 0 ; zero the time counter
pause 1
echo Looking for login prompt.
:slloop
increment \%x ; Count the seconds
clear ; Clear unread characters from input buffer
output \13
;
; put your expected login prompt here:
;
input 1 {Username: }
if success goto sluid
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 10 goto slloop ; try 10 times to get a login prompt
else goto slhup ; hang up and start again if 10 failures
:sluid
;
; put your userid here:
;
output ppp-login\13
input 1 {Password: }
;
; put your password here:
;
output ppp-password\13
input 1 {Entering SLIP mode.}
echo
quit
:slnodial
echo \7No dialtone. Check the telephone line!\7
exit 1
; local variables:
; mode: csh
; comment-start: "; "
; comment-start-skip: "; "
; end:Setting up a SLIP ClientContributed by &a.asami; 8 Aug 1995.The following is one way to set up a FreeBSD machine for SLIP on a
static host network. For dynamic hostname assignments (i.e., your
address changes each time you dial up), you probably need to do
something much fancier.First, determine which serial port your modem is connected to. I
have a symbolic link to /dev/modem from
/dev/cuaa1, and only use the modem name in my
configuration files. It can become quite cumbersome when you need to
fix a bunch of files in /etc and
.kermrc's all over the system!/dev/cuaa0 is COM1,
cuaa1 is COM2,
etc.Make sure you have
pseudo-device sl 1
in your kernel's config file. It is included in the
GENERIC kernel, so this will not be a problem
unless you deleted it.Things you have to do only onceAdd your home machine, the gateway and nameservers to your
/etc/hosts file. Mine looks like
this:
127.0.0.1 localhost loghost
136.152.64.181 silvia.HIP.Berkeley.EDU silvia.HIP silvia
136.152.64.1 inr-3.Berkeley.EDU inr-3 slip-gateway
128.32.136.9 ns1.Berkeley.edu ns1
128.32.136.12 ns2.Berkeley.edu ns2By the way, silvia is the name of the car that I had when I
was back in Japan (it is called 2?0SX here in U.S.).Make sure you have before
in your /etc/host.conf.
Otherwise, funny things may happen.Edit the file /etc/rc.conf. Note that
you should edit the file /etc/sysconfig
instead if you are running FreeBSD previous to version
2.2.2.Set your hostname by editing the line that says:
hostname=myname.my.domainYou should give it your full Internet hostname.Add sl0 to the list of network interfaces by changing the
line that says:
network_interfaces="lo0"to:
network_interfaces="lo0 sl0"Set the startup flags of sl0 by adding a line:
ifconfig_sl0="inet ${hostname} slip-gateway netmask 0xffffff00 up"Designate the default router by changing the line:
defaultrouter=NOto:
defaultrouter=slip-gatewayMake a file /etc/resolv.conf which
contains:
domain HIP.Berkeley.EDU
nameserver 128.32.136.9
nameserver 128.32.136.12As you can see, these set up the nameserver hosts. Of course,
the actual domain names and addresses depend on your
environment.Set the password for root and toor (and any other accounts
that does not have a password). Use passwd, do not edit the
/etc/passwd or
/etc/master.passwd files!Reboot your machine and make sure it comes up with the correct
hostname.Making a SLIP connectionDial up, type slip at the prompt, enter
your machine name and password. The things you need to enter
depends on your environment. I use kermit, with a script like
this:
# kermit setup
set modem hayes
set line /dev/modem
set speed 115200
set parity none
set flow rts/cts
set terminal bytesize 8
set file type binary
# The next macro will dial up and login
define slip dial 643-9600, input 10 =>, if failure stop, -
output slip\x0d, input 10 Username:, if failure stop, -
output silvia\x0d, input 10 Password:, if failure stop, -
output ***\x0d, echo \x0aCONNECTED\x0a(of course, you have to change the hostname and password to
fit yours). Then you can just type slip from
the kermit prompt to get connected.Leaving your password in plain text anywhere in the
filesystem is generally a BAD idea. Do it at your own risk. I
am just too lazy.Leave the kermit there (you can suspend it by
z) and as root, type:&prompt.root; slattach -h -c -s 115200 /dev/modemIf you are able to ping hosts on the other
side of the router, you are connected! If it does not work, you
might want to try instead of
as an argument to slattach.How to shutdown the connectionType
&prompt.root; kill -INT `cat /var/run/slattach.modem.pid`
(as root) to kill slattach. Then go back to kermit
(fg if you suspended it) and exit from it
(q).The slattach man page says you have to use ifconfig sl0
down to mark the interface down, but this does not seem to
make any difference for me. (ifconfig sl0 reports
the same thing.)Some times, your modem might refuse to drop the carrier (mine
often does). In that case, simply start kermit and quit it again. It
usually goes out on the second try.TroubleshootingIf it does not work, feel free to ask me. The things that people
tripped over so far:Not using or in
slattach (I have no idea why this can be fatal, but adding this
flag solved the problem for at least one person)Using instead of
(might be hard to see the difference on some fonts).Try ifconfig sl0 to see your interface
status. I get:&prompt.root; ifconfig sl0
sl0: flags=10<POINTOPOINT>
inet 136.152.64.181 --> 136.152.64.1 netmask ffffff00Also, netstat -r will give the routing
table, in case you get the "no route to host" messages from ping.
Mine looks like:&prompt.root; netstat -r
Routing tables
Destination Gateway Flags Refs Use IfaceMTU Rtt Netmasks:
(root node)
(root node)
Route Tree for Protocol Family inet:
(root node) =>
default inr-3.Berkeley.EDU UG 8 224515 sl0 - -
localhost.Berkel localhost.Berkeley UH 5 42127 lo0 - 0.438
inr-3.Berkeley.E silvia.HIP.Berkele UH 1 0 sl0 - -
silvia.HIP.Berke localhost.Berkeley UGH 34 47641234 lo0 - 0.438
(root node)(this is after transferring a bunch of files, your numbers
should be smaller).Setting up a SLIP ServerContributed by &a.ghelmer;. v1.0, 15 May
1995.This document provides suggestions for setting up SLIP Server
services on a FreeBSD system, which typically means configuring your
system to automatically startup connections upon login for remote SLIP
clients. The author has written this document based on his experience;
however, as your system and needs may be different, this document may
not answer all of your questions, and the author cannot be responsible
if you damage your system or lose data due to attempting to follow the
suggestions here.This guide was originally written for SLIP Server services on a
FreeBSD 1.x system. It has been modified to reflect changes in the
pathnames and the removal of the SLIP interface compression flags in
early versions of FreeBSD 2.X, which appear to be the only major changes
between FreeBSD versions. If you do encounter mistakes in this
document, please email the author with enough information to help
correct the problem.PrerequisitesThis document is very technical in nature, so background knowledge
is required. It is assumed that you are familiar with the TCP/IP
network protocol, and in particular, network and node addressing,
network address masks, subnetting, routing, and routing protocols,
such as RIP. Configuring SLIP services on a dial-up server requires a
knowledge of these concepts, and if you are not familiar with them,
please read a copy of either Craig Hunt's TCP/IP Network
Administration published by O'Reilly & Associates,
Inc. (ISBN Number 0-937175-82-X), or Douglas Comer's books on the
TCP/IP protocol.It is further assumed that you have already setup your modem(s)
and configured the appropriate system files to allow logins through
your modems. If you have not prepared your system for this yet,
please see the tutorial for configuring dialup services; if you have a
World-Wide Web browser available, browse the list of tutorials at
http://www.freebsd.org/;
otherwise, check the place where you found this document for a
document named dialup.txt or something similar.
You may also want to check the manual pages for
&man.sio.4; for information on the serial port device driver and
&man.ttys.5;, &man.gettytab.5;, &man.getty.8;, & &man.init.8;
for information relevant to configuring the system to accept logins on
modems, and perhaps &man.stty.1; for information on setting serial
port parameters (such as clocal for
directly-connected serial interfaces).Quick OverviewIn its typical configuration, using FreeBSD as a SLIP server works
as follows: a SLIP user dials up your FreeBSD SLIP Server system and
logs in with a special SLIP login ID that uses
/usr/sbin/sliplogin as the special user's shell.
The sliplogin program browses the file
/etc/sliphome/slip.hosts to find a matching line
for the special user, and if it finds a match, connects the serial
line to an available SLIP interface and then runs the shell script
/etc/sliphome/slip.login to configure the SLIP
interface.An Example of a SLIP Server LoginFor example, if a SLIP user ID were
Shelmerg, Shelmerg's entry
in /etc/master.passwd would look something like
this (except it would be all on one line):
Shelmerg:password:1964:89::0:0:Guy Helmer - SLIP:/usr/users/Shelmerg:/usr/sbin/sliploginWhen Shelmerg logs in,
sliplogin will search
/etc/sliphome/slip.hosts for a line that had a
matching user ID; for example, there may be a line in
/etc/sliphome/slip.hosts that reads:
Shelmerg dc-slip sl-helmer 0xfffffc00 autocompsliplogin will find that matching line, hook
the serial line into the next available SLIP interface, and then
execute /etc/sliphome/slip.login like
this:
/etc/sliphome/slip.login 0 19200 Shelmerg dc-slip sl-helmer 0xfffffc00 autocompIf all goes well, /etc/sliphome/slip.login
will issue an ifconfig for the SLIP interface to
which sliplogin attached itself (slip interface
0, in the above example, which was the first parameter in the list
given to slip.login) to set the local IP
address (dc-slip), remote IP address
(sl-helmer), network mask for the SLIP interface
(0xfffffc00), and any additional
flags (autocomp). If something goes wrong,
sliplogin usually logs good informational
messages via the daemon syslog facility, which
usually goes into /var/log/messages (see the
manual pages for &man.syslogd.8; and
&man.syslog.conf.5, and perhaps check
/etc/syslog.conf to see to which files
syslogd is logging).OK, enough of the examples — let us dive into setting up
the system.Kernel ConfigurationFreeBSD's default kernels usually come with two SLIP interfaces
defined (sl0 and
sl1); you can use netstat
-i to see whether these interfaces are defined in your
kernel.Sample output from netstat -i:Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll
ed0 1500 <Link>0.0.c0.2c.5f.4a 291311 0 174209 0 133
ed0 1500 138.247.224 ivory 291311 0 174209 0 133
lo0 65535 <Link> 79 0 79 0 0
lo0 65535 loop localhost 79 0 79 0 0
sl0* 296 <Link> 0 0 0 0 0
sl1* 296 <Link> 0 0 0 0 0The sl0 and sl1
interfaces shown in netstat -i's output indicate
that there are two SLIP interfaces built into the kernel. (The
asterisks after the sl0 and sl1
indicate that the interfaces are “down”.)However, FreeBSD's default kernels do not come configured to
forward packets (ie, your FreeBSD machine will not act as a router)
due to Internet RFC requirements for Internet hosts (see RFC's 1009
[Requirements for Internet Gateways], 1122 [Requirements for Internet
Hosts — Communication Layers], and perhaps 1127 [A Perspective
on the Host Requirements RFCs]), so if you want your FreeBSD SLIP
Server to act as a router, you will have to edit the
/etc/rc.conf file (called
/etc/sysconfig in FreeBSD releases prior to
2.2.2) and change the setting of the gateway
variable to . If you have an older system which
predates even the /etc/sysconfig file, then add
the following command:
sysctl -w net.inet.ip.forwarding = 1
to your /etc/rc.local file.You will then need to reboot for the new settings to take
effect.You will notice that near the end of the default kernel
configuration file (/sys/i386/conf/GENERIC) is a
line that reads:
pseudo-device sl 2This is the line that defines the number of SLIP devices available
in the kernel; the number at the end of the line is the maximum number
of SLIP connections that may be operating simultaneously.Please refer to Configuring the
FreeBSD Kernel for help in reconfiguring your kernel.Sliplogin ConfigurationAs mentioned earlier, there are three files in the
/etc/sliphome directory that are part of the
configuration for /usr/sbin/sliplogin (see
&man.sliplogin.8; for the actual manual page for
sliplogin): slip.hosts, which
defines the SLIP users & their associated IP addresses;
slip.login, which usually just configures the
SLIP interface; and (optionally) slip.logout,
which undoes slip.login's effects when the serial
connection is terminated.slip.hosts Configuration/etc/sliphome/slip.hosts contains lines
which have at least four items, separated by whitespace:SLIP user's login IDLocal address (local to the SLIP server) of the SLIP
linkRemote address of the SLIP linkNetwork maskThe local and remote addresses may be host names (resolved to IP
addresses by /etc/hosts or by the domain name
service, depending on your specifications in
/etc/host.conf), and I believe the network mask
may be a name that can be resolved by a lookup into
/etc/networks. On a sample system,
/etc/sliphome/slip.hosts looks like
this:
#
# login local-addr remote-addr mask opt1 opt2
# (normal,compress,noicmp)
#
Shelmerg dc-slip sl-helmerg 0xfffffc00 autocompAt the end of the line is one or more of the options. — no header compression — compress headers — compress headers if the
remote end allows it — disable ICMP packets (so any
“ping” packets will be dropped instead of using up
your bandwidth)Note that sliplogin under early releases of
FreeBSD 2 ignored the options that FreeBSD 1.x recognized, so the
options , ,
, and had no effect
until support was added in FreeBSD 2.2 (unless your
slip.login script included code to make use of
the flags).Your choice of local and remote addresses for your SLIP links
depends on whether you are going to dedicate a TCP/IP subnet or if
you are going to use “proxy ARP” on your SLIP server (it
is not “true” proxy ARP, but that is the terminology
used in this document to describe it). If you are not sure which
method to select or how to assign IP addresses, please refer to the
TCP/IP books referenced in the slips-prereqs section and/or
consult your IP network manager.If you are going to use a separate subnet for your SLIP clients,
you will need to allocate the subnet number out of your assigned IP
network number and assign each of your SLIP client's IP numbers out
of that subnet. Then, you will probably either need to configure a
static route to the SLIP subnet via your SLIP server on your nearest
IP router, or install gated on your FreeBSD SLIP
server and configure it to talk the appropriate routing protocols to
your other routers to inform them about your SLIP server's route to
the SLIP subnet.Otherwise, if you will use the “proxy ARP” method,
you will need to assign your SLIP client's IP addresses out of your
SLIP server's Ethernet subnet, and you will also need to adjust your
/etc/sliphome/slip.login and
/etc/sliphome/slip.logout scripts to use
&man.arp.8; to manage the proxy-ARP entries in the SLIP server's
ARP table.slip.login ConfigurationThe typical /etc/sliphome/slip.login file
looks like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6This slip.login file merely
ifconfig's the appropriate SLIP interface with
the local and remote addresses and network mask of the SLIP
interface.If you have decided to use the “proxy ARP” method
(instead of using a separate subnet for your SLIP clients), your
/etc/sliphome/slip.login file will need to look
something like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6
# Answer ARP requests for the SLIP client with our Ethernet addr
/usr/sbin/arp -s $5 00:11:22:33:44:55 pubThe additional line in this slip.login,
arp -s $5 00:11:22:33:44:55 pub, creates an
ARP entry in the SLIP server's ARP table. This ARP entry causes the
SLIP server to respond with the SLIP server's Ethernet MAC address
whenever a another IP node on the Ethernet asks to speak to the SLIP
client's IP address.When using the example above, be sure to replace the Ethernet
MAC address (00:11:22:33:44:55) with the
MAC address of your system's Ethernet card, or your “proxy
ARP” will definitely not work! You can discover your SLIP
server's Ethernet MAC address by looking at the results of running
netstat -i; the second line of the output should
look something like:ed0 1500 <Link>0.2.c1.28.5f.4a 191923 0 129457 0 116This indicates that this particular system's Ethernet MAC
address is 00:02:c1:28:5f:4a — the
periods in the Ethernet MAC address given by netstat
-i must be changed to colons and leading zeros should be
added to each single-digit hexadecimal number to convert the address
into the form that
&man.arp.8; desires; see the manual page on &man.arp.8; for
complete information on usage.When you create /etc/sliphome/slip.login
and /etc/sliphome/slip.logout, the
“execute” bit (ie, chmod 755
/etc/sliphome/slip.login /etc/sliphome/slip.logout)
must be set, or sliplogin will be unable to
execute it.slip.logout Configuration/etc/sliphome/slip.logout is not strictly
needed (unless you are implementing “proxy ARP”), but if
you decide to create it, this is an example of a basic
slip.logout script:
#!/bin/sh -
#
# slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 downIf you are using “proxy ARP”, you will want to have
/etc/sliphome/slip.logout remove the ARP entry
for the SLIP client:
#!/bin/sh -
#
# @(#)slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 down
# Quit answering ARP requests for the SLIP client
/usr/sbin/arp -d $5The arp -d $5 removes the ARP entry that
the “proxy ARP” slip.login added
when the SLIP client logged in.It bears repeating: make sure
/etc/sliphome/slip.logout has the execute
bit set for after you create it (ie, chmod
755 /etc/sliphome/slip.logout).Routing ConsiderationsIf you are not using the “proxy ARP” method for
routing packets between your SLIP clients and the rest of your network
(and perhaps the Internet), you will probably either have to add
static routes to your closest default router(s) to route your SLIP
client subnet via your SLIP server, or you will probably need to
install and configure gated on your FreeBSD SLIP
server so that it will tell your routers via appropriate routing
protocols about your SLIP subnet.Static RoutesAdding static routes to your nearest default routers can be
troublesome (or impossible, if you do not have authority to do
so...). If you have a multiple-router network in your organization,
some routers, such as Cisco and Proteon, may not only need to be
configured with the static route to the SLIP subnet, but also need
to be told which static routes to tell other routers about, so some
expertise and troubleshooting/tweaking may be necessary to get
static-route-based routing to work.Running gatedAn alternative to the headaches of static routes is to install
gated on your FreeBSD SLIP server and configure
it to use the appropriate routing protocols (RIP/OSPF/BGP/EGP) to
tell other routers about your SLIP subnet. You can use
gated from the ports
collection or retrieve and build it yourself from the
GateD anonymous ftp site; I believe the current version as
of this writing is gated-R3_5Alpha_8.tar.Z,
which includes support for FreeBSD “out-of-the-box”.
Complete information and documentation on gated
is available on the Web starting at the Merit GateD
Consortium. Compile and install it, and then write a
/etc/gated.conf file to configure your gated;
here is a sample, similar to what the author used on a FreeBSD SLIP
server:
#
# gated configuration file for dc.dsu.edu; for gated version 3.5alpha5
# Only broadcast RIP information for xxx.xxx.yy out the ed Ethernet interface
#
#
# tracing options
#
traceoptions "/var/tmp/gated.output" replace size 100k files 2 general ;
rip yes {
interface sl noripout noripin ;
interface ed ripin ripout version 1 ;
traceoptions route ;
} ;
#
# Turn on a bunch of tracing info for the interface to the kernel:
kernel {
traceoptions remnants request routes info interface ;
} ;
#
# Propagate the route to xxx.xxx.yy out the Ethernet interface via RIP
#
export proto rip interface ed {
proto direct {
xxx.xxx.yy mask 255.255.252.0 metric 1; # SLIP connections
} ;
} ;
#
# Accept routes from RIP via ed Ethernet interfaces
import proto rip interface ed {
all ;
} ;The above sample gated.conf file broadcasts
routing information regarding the SLIP subnet
xxx.xxx.yy via RIP onto the Ethernet; if
you are using a different Ethernet driver than the
ed driver, you will need to change the
references to the ed interface
appropriately. This sample file also sets up tracing to
/var/tmp/gated.output for debugging
gated's activity; you can certainly turn off the
tracing options if gated works OK for you. You
will need to change the xxx.xxx.yy's into
the network address of your own SLIP subnet (be sure to change the
net mask in the proto direct clause as
well).When you get gated built and installed and
create a configuration file for it, you will need to run
gated in place of routed on
your FreeBSD system; change the routed/gated
startup parameters in /etc/netstart as
appropriate for your system. Please see the manual page for
gated for information on
gated's command-line parameters.AcknowledgmentsThanks to these people for comments and advice regarding this
tutorial:&a.wilko;Piero SeriniPiero@Strider.Inet.IT
diff --git a/en_US.ISO8859-1/books/porters-handbook/book.sgml b/en_US.ISO8859-1/books/porters-handbook/book.sgml
index 113749797a..0ddc65b4b4 100644
--- a/en_US.ISO8859-1/books/porters-handbook/book.sgml
+++ b/en_US.ISO8859-1/books/porters-handbook/book.sgml
@@ -1,4501 +1,4501 @@
Installing Applications: The Ports collectionContributed by &a.jraynard;.The FreeBSD Ports collection allows you to compile and install a very
wide range of applications with a minimum of effort.For all the hype about open standards, getting a program to work on
different versions of Unix in the real world can be a tedious and tricky
business, as anyone who has tried it will know. You may be lucky enough
to find that the program you want will compile cleanly on your system,
install itself in all the right places and run flawlessly “out of
the box”, but this is unfortunately rather rare. With most
programs, you will find yourself doing a fair bit of head-scratching, and
there are quite a few programs that will result in premature greying, or
even chronic alopecia...Some software distributions have attacked this problem by providing
configuration scripts. Some of these are very clever, but they have an
unfortunate tendency to triumphantly announce that your system is
something you have never heard of and then ask you lots of questions that
sound like a final exam in system-level Unix programming (Does
your system's gethitlist function return a const pointer to a fromboz or
a pointer to a const fromboz? Do you have Foonix style unacceptable
exception handling? And if not, why not?).Fortunately, with the Ports collection, all the hard work involved has
already been done, and you can just type make install
and get a working program.Why Have a Ports Collection?The base FreeBSD system comes with a very wide range of tools and
system utilities, but a lot of popular programs are not in the base
system, for good reasons:-Programs that some people cannot live without and other people
cannot stand, such as a certain Lisp-based editor.Programs which are too specialised to put in the base system
(CAD, databases).Programs which fall into the “I must have a look at that
when I get a spare minute” category, rather than
system-critical ones (some languages, perhaps).Programs that are far too much fun to be supplied with a serious
operating system like FreeBSD ;-)However many programs you put in the base system, people will
always want more, and a line has to be drawn somewhere (otherwise
FreeBSD distributions would become absolutely enormous).Obviously it would be unreasonable to expect everyone to port their
favourite programs by hand (not to mention a tremendous amount of
duplicated work), so the FreeBSD Project came up with an ingenious way
of using standard tools that would automate the process.Incidentally, this is an excellent illustration of how “the
Unix way” works in practice by combining a set of simple but very
flexible tools into something very powerful.How Does the Ports Collection Work?Programs are typically distributed on the Internet as a tarball consisting of a Makefile and
the source code for the program and usually some instructions (which are
unfortunately not always as instructive as they could be), with perhaps
a configuration script.The standard scenario is that you FTP down the tarball, extract it
somewhere, glance through the instructions, make any changes that seem
necessary, run the configure script to set things up and use the
standard make program to compile and install the
program from the source.FreeBSD ports still use the tarball mechanism, but use a skeleton to hold the
"knowledge" of how to get the program working on FreeBSD,
rather than expecting the user to be able to work it out. They also
supply their own customised Makefile, so that almost every port
can be built in the same way.If you look at a port skeleton (either on your FreeBSD
system or the
FTP site) and expect to find all sorts of pointy-headed rocket
science lurking there, you may be disappointed by the one or two rather
unexciting-looking files and directories you find there. (We will
discuss in a minute how to go about Getting a port).“How on earth can this do anything?” I hear you cry.
“There is no source code there!”Fear not, gentle reader, all will become clear (hopefully). Let's
see what happens if we try and install a port. I have chosen
ElectricFence, a useful tool for developers,
as the skeleton is more straightforward than most.If you are trying this at home, you will need to be root.&prompt.root; cd /usr/ports/devel/ElectricFence
&prompt.root; make install
>> Checksum OK for ElectricFence-2.0.5.tar.gz.
===> Extracting for ElectricFence-2.0.5
===> Patching for ElectricFence-2.0.5
===> Applying FreeBSD patches for ElectricFence-2.0.5
===> Configuring for ElectricFence-2.0.5
===> Building for ElectricFence-2.0.5
[lots of compiler output...]
===> Installing for ElectricFence-2.0.5
===> Warning: your umask is "0002". If this is not desired, set it to
an appropriate value and install this port again by ``make reinstall''.
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.a /usr/local/lib
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.3 /usr/local/man/man3
===> Compressing manual pages for ElectricFence-2.0.5
===> Registering installation for ElectricFence-2.0.5To avoid confusing the issue, I have completely removed the build
output.If you tried this yourself, you may well have got something like
this at the start:-&prompt.root; make install
>> ElectricFence-2.0.5.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://ftp.doc.ic.ac.uk/Mirrors/sunsite.unc.edu/pub/Linux/devel/lang/c/.The make program has noticed that you did not
have a local copy of the source code and tried to FTP it down so it
could get the job done. I already had the source handy in my example,
so it did not need to fetch it.Let's go through this and see what the make
program was doing.Locate the source code tarball. If it is not available
locally, try to grab it from an FTP site.Run a checksum test on the
tarball to make sure it has not been tampered with, accidentally
truncated, downloaded in ASCII mode, struck by neutrinos while in
transit, etc.Extract the tarball into a temporary work directory.Apply any patches needed to
get the source to compile and run under FreeBSD.Run any configuration script required by the build process and
correctly answer any questions it asks.(Finally!) Compile the code.Install the program executable and other supporting files, man
pages, etc. under the /usr/local hierarchy,
where they will not get mixed up with system programs. This also
makes sure that all the ports you install will go in the same place,
instead of being flung all over your system.Register the installation in a database. This means that, if
you do not like the program, you can cleanly remove all traces of it from your
system.Scroll up to the make output and see if you can
match these steps to it. And if you were not impressed before, you
should be by now!Getting a FreeBSD PortThere are two ways of getting hold of the FreeBSD port for a
program. One requires a FreeBSD CDROM,
the other involves using an Internet
Connection.Compiling ports from CDROMAssuming that your FreeBSD CDROM is in the drive and mounted on
/cdrom (and the mount point
must be /cdrom), you should
then be able to build ports just as you normally do and the port
collection's built in search path should find the tarballs in
/cdrom/ports/distfiles/ (if they exist there)
rather than downloading them over the net.Another way of doing this, if you want to just use the port
skeletons on the CDROM, is to set these variables in
/etc/make.conf:
PORTSDIR= /cdrom/ports
DISTDIR= /tmp/distfiles
WRKDIRPREFIX= /tmpSubstitute /tmp for any place you have enough
free space. Then, just cd to the appropriate
subdirectory under /cdrom/ports and type
make install as usual.
WRKDIRPREFIX will cause the port to be build under
/tmp/cdrom/ports; for instance,
games/oneko will be built under
/tmp/cdrom/ports/games/oneko.There are some ports for which we cannot provide the original
source in the CDROM due to licensing limitations. In that case, you
will need to look at the section on Compiling ports using an Internet
connection.Compiling ports from the InternetIf you do not have a CDROM, or you want to make sure you get the
very latest version of the port you want, you will need to download
the skeleton for the port. Now
this might sound like rather a fiddly job full of pitfalls, but it is
actually very easy.First, if you are running a release version of FreeBSD, make sure
you get the appropriate “upgrade kit” for your release
from the ports web
page. These packages include files that have been updated
since the release that you may need to compile new ports.The key to the skeletons is that the FreeBSD FTP server can create
on-the-fly tarballs for you.
Here is how it works, with the gnats program in the databases
directory as an example (the bits in square brackets are comments. Do
not type them in if you are trying this yourself!):-&prompt.root; cd /usr/ports
&prompt.root; mkdir databases
&prompt.root; cd databases
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports/databases>get gnats.tar
[tars up the gnats skeleton for us]
>quit
&prompt.root; tar xf gnats.tar
[extract the gnats skeleton]
&prompt.root; cd gnats
&prompt.root; make install
[build and install gnats]What happened here? We connected to the FTP server in the usual
way and went to its databases sub-directory.
When we gave it the command get gnats.tar, the FTP
server tarred up the gnats
directory for us.We then extracted the gnats skeleton and went into the gnats
directory to build the port. As we explained earlier, the make process noticed we
did not have a copy of the source locally, so it fetched one before
extracting, patching and building it.Let's try something more ambitious now. Instead of getting a
single port skeleton, let's get a whole sub-directory, for example all
the database skeletons in the ports collection. It looks almost the
same:-&prompt.root; cd /usr/ports
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports>get databases.tar
[tars up the databases directory for us]
>quit
&prompt.root; tar xf databases.tar
[extract all the database skeletons]
&prompt.root; cd databases
&prompt.root; make install
[build and install all the database ports]With half a dozen straightforward commands, we have now got a set
of database programs on our FreeBSD machine! All we did that was
different from getting a single port skeleton and building it was that
we got a whole directory at once, and compiled everything in it at
once. Pretty impressive, no?If you expect to be installing many ports, it is probably worth
downloading all the ports directories.SkeletonsA team of compulsive hackers who have forgotten to eat in a frantic
attempt to make a deadline? Something unpleasant lurking in the FreeBSD
attic? No, a skeleton here is a minimal framework that supplies
everything needed to make the ports magic work.MakefileThe most important component of a skeleton is the Makefile. This
contains various statements that specify how the port should be
compiled and installed. Here is the Makefile for
ElectricFence:-
# New ports collection makefile for: Electric Fence
# Version required: 2.0.5
# Date created: 13 November 1997
# Whom: jraynard
#
# $Id$
#
DISTNAME= ElectricFence-2.0.5
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= devel/lang/c
MAINTAINER= jraynard@freebsd.org
MAN3= libefence.3
do-install:
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
.include <bsd.port.mk>The lines beginning with a "#" sign are comments for the
benefit of human readers (as in most Unix script files).DISTNAME specifies the name of the tarball, but without the
extension.CATEGORIES states what kind of program this is.
In this case, a utility for developers. See the categories section of this
handbook for a complete list.MASTER_SITES is the URL(s) of the master FTP
site, which is used to retrieve the tarball if it is not available on the
local system. This is a site which is regarded as reputable, and is
normally the one from which the program is officially distributed (in
so far as any software is "officially" distributed on the
Internet).MAINTAINER is the email address of the person
who is responsible for updating the skeleton if, for example a new
version of the program comes out.Skipping over the next few lines for a minute, the line
.include <bsd.port.mk> says that the other
statements and commands needed for this port are in a standard file
called bsd.port.mk. As these are the same for
all ports, there is no point in duplicating them all over the place,
so they are kept in a single standard file.This is probably not the place to go into a detailed examination
of how Makefiles work; suffice it to say that the line starting with
MAN3 ensures that the ElectricFence man page is
compressed after installation, to help conserve your precious disk
space. The original port did not provide an
install target, so the three lines from
do-install ensure that the files produced by
this port are placed in the correct destination.The files directoryThe file containing the checksum for the port is called
md5, after the MD5 algorithm used for ports
checksums. It lives in a directory with the slightly confusing name
of files.This directory can also contain other miscellaneous files that are
required by the port and do not belong anywhere else.The patches directoryThis directory contains the patches needed to make everything work
properly under FreeBSD.The pkg directoryThis program contains three quite useful files:-COMMENT — a one-line description of
the program.DESCR — a more detailed
description.PLIST — a list of all the files
that will be created when the program is installed.What to do when a port does not work.Oh. You can do one of four (4) things :Fix it yourself. Technical details on how ports work can be
found in Porting applications.Gripe. This is done by e-mail only! Send
such e-mail to the &a.ports; and please include the name/version of
the port, where you got both the port source & distfile(s) from,
and what the text of the error was.Forget it. This is the easiest for most — very few of the
programs in ports can be classified as essential!Grab the pre-compiled package from a ftp server. The
“master” package collection is on FreeBSD's FTP server
in the packages
directory, though check your local mirror first, please!
These are more likely to work (on the whole) than trying to compile
from source and a lot faster besides! Use the &man.pkg.add.1;
program to install a package file on your
system.Some Questions and AnswersQ. I thought this was going to be a discussion about
modems??!A. Ah. You must be thinking of the serial ports on the back of
your computer. We are using “port” here to mean the
result of “porting” a program from one version of Unix
to another. (It is an unfortunate bad habit of computer people to
use the same word to refer to several completely different
things).Q. I thought you were supposed to use packages to install extra
programs?A. Yes, that is usually the quickest and easiest way of doing
it.Q. So why bother with ports then?A. Several reasons:-The licensing conditions on some software distributions
require that they be distributed as source code, not
binaries.Some people do not trust binary distributions. At least
with source code you can (in theory) read through it and look
for potential problems yourself.If you have some local patches, you will need the source to
add them yourself.You might have opinions on how a program should be compiled
that differ from the person who did the package — some
people have strong views on what optimisation setting should be
used, whether to build debug versions and then strip them or
not, etc. etc.Some people like having code around, so they can read it if
they get bored, hack around with it, borrow from it (licence
terms permitting, of course!) and so on.If you ain't got the source, it ain't software! ;-) Q. What is a patch?A. A patch is a small (usually) file that specifies how to go
from one version of a file to another. It contains text that says,
in effect, things like “delete line 23”, “add
these two lines after line 468” or “change line 197 to
this”. Also known as a “diff”, since it is
generated by a program of that name. Q. What is all this about
tarballs?A. It is a file ending in .tar or
.tar.gz (with variations like
.tar.Z, or even .tgz if
you are trying to squeeze the names into a DOS filesystem).Basically, it is a directory tree that has been archived into a
single file (.tar) and optionally compressed
(.gz). This technique was originally used for
Tape ARchives (hence the
name tar), but it is a widely used way of
distributing program source code around the Internet.You can see what files are in them, or even extract them
yourself, by using the standard Unix tar program, which comes with
the base FreeBSD system, like this:-&prompt.user; tar tvzf foobar.tar.gz
&prompt.user; tar xzvf foobar.tar.gz
&prompt.user; tar tvf foobar.tar
&prompt.user; tar xvf foobar.tar Q. And a checksum?A. It is a number generated by adding up all the data in the
file you want to check. If any of the characters change, the
checksum will no longer be equal to the total, so a simple
comparison will allow you to spot the difference. (In practice, it
is done in a more complicated way to spot problems like
position-swapping, which will not show up with a simplistic
addition).Q. I did what you said for compiling
ports from a CDROM and it worked great until I tried to
install the kermit port:-&prompt.root; make install
>> cku190.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://kermit.columbia.edu/kermit/archives/.Why can it not be found? Have I got a dud CDROM?A. The licensing terms for kermit do not allow us to put the
tarball for it on the CDROM, so you will have to fetch it by hand
— sorry! The reason why you got all those error messages was
because you were not connected to the Internet at the time. Once
you have downloaded it from any of the sites above, you can re-start
the process (try and choose the nearest site to you, though, to save
your time and the Internet's bandwidth).Q. I did that, but when I tried to put it into
/usr/ports/distfiles I got some error about not
having permission.A. The ports mechanism looks for the tarball in
/usr/ports/distfiles, but you will not be able
to copy anything there because it is sym-linked to the CDROM, which
is read-only. You can tell it to look somewhere else by
doing&prompt.root; make DISTDIR=/where/you/put/it installQ. Does the ports scheme only work if you have everything in
/usr/ports? My system administrator says I must
put everything under
/u/people/guests/wurzburger, but it does not
seem to work.A. You can use the PORTSDIR and
PREFIX variables to tell the ports mechanism to
use different directories. For instance,&prompt.root; make PORTSDIR=/u/people/guests/wurzburger/ports installwill compile the port in
/u/people/guests/wurzburger/ports and install
everything under /usr/local.&prompt.root; make PREFIX=/u/people/guests/wurzburger/local installwill compile it in /usr/ports and install
it in /u/people/guests/wurzburger/local.And of course&prompt.root; make PORTSDIR=.../ports PREFIX=.../local installwill combine the two (it is too long to fit on the page if I
write it in full, but I am sure you get the idea).If you do not fancy typing all that in every time you install a
port (and to be honest, who would?), it is a good idea to put these
variables into your environment.Q. I do not have a FreeBSD CDROM, but I would like to have all
the tarballs handy on my system so I do not have to wait for a
download every time I install a port. Is there an easy way to get
them all at once?A. To get every single tarball for the ports collection,
do&prompt.root; cd /usr/ports
&prompt.root; make fetchFor all the tarballs for a single ports directory, do&prompt.root; cd /usr/ports/directory
&prompt.root; make fetchand for just one port — well, I think you have guessed
already.Q. I know it is probably faster to fetch the tarballs from one
of the FreeBSD mirror sites close by. Is there any way to tell the
port to fetch them from servers other than ones listed in the
MASTER_SITES?A. Yes. If you know, for example, ftp.FreeBSD.ORG is much closer than sites
listed in MASTER_SITES, do as following
example.&prompt.root; cd /usr/ports/directory
&prompt.root; make MASTER_SITE_OVERRIDE=ftp://ftp.FreeBSD.ORG/pub/FreeBSD/ports/distfiles/ fetchQ. I want to know what files make is going to need before it
tries to pull them down.A. make fetch-list will display a list of
the files needed for a port.Q. Is there any way to stop the port from compiling? I want to
do some hacking on the source before I install it, but it is a bit
tiresome having to watch it and hit control-C every time.A. Doing make extract will stop it after it
has fetched and extracted the source code.Q. I am trying to make my own port and I want to be able to
stop it compiling until I have had a chance to see if my patches
worked properly. Is there something like make
extract, but for patches?A. Yep, make patch is what you want. You
will probably find the PATCH_DEBUG option useful
as well. And by the way, thank you for your efforts!Q. I have heard that some compiler options can cause bugs. Is
this true? How can I make sure that I compile ports with the right
settings?A. Yes, with version 2.6.3 of gcc (the
version shipped with FreeBSD 2.1.0 and 2.1.5), the
option could result in buggy code unless you
used the option as well.
(Most of the ports don't use ). You
should be able to specify the compiler options
used by something like&prompt.root; make CFLAGS='-O2 -fno-strength-reduce' installor by editing /etc/make.conf, but
unfortunately not all ports respect this. The surest way is to do
make configure, then go into the source directory
and inspect the Makefiles by hand, but this can get tedious if the
source has lots of sub-directories, each with their own
Makefiles.Q. There are so many ports it is hard to find the one I want.
Is there a list anywhere of what ports are available?A. Look in the INDEX file in
/usr/ports. If you would like to search the
ports collection for a keyword, you can do that too. For example,
you can find ports relevant to the LISP programming language
using:&prompt.user; cd /usr/ports
&prompt.user; make search key=lispQ. I went to install the foo port but the
system suddenly stopped compiling it and starting compiling the
bar port. What's going on?A. The foo port needs something that is
supplied with bar — for instance, if
foo uses graphics, bar might
have a library with useful graphics processing routines. Or
bar might be a tool that is needed to compile the
foo port. Q. I installed the
grizzle program from the ports and frankly it is
a complete waste of disk space. I want to delete it but I do not
know where it put all the files. Any clues?A. No problem, just do&prompt.root; pkg_delete grizzle-6.5
Q. Hang on a minute, you have to know the version number to use
that command. You do not seriously expect me to remember that, do
you??A. Not at all, you can find it out by doing&prompt.root; pkg_info -a | grep grizzle
Information for grizzle-6.5:
grizzle-6.5 - the combined piano tutorial, LOGO interpreter and shoot 'em up arcade game.Q. Talking of disk space, the ports directory seems to be
taking up an awful lot of room. Is it safe to go in there and
delete things?A. Yes, if you have installed the program and are fairly
certain you will not need the source again, there is no point in
keeping it hanging around. The best way to do this is&prompt.root; cd /usr/ports
&prompt.root; make cleanwhich will go through all the ports subdirectories and delete
everything except the skeletons for each port.Q. I tried that and it still left all those tarballs or
whatever you called them in the distfiles
directory. Can I delete those as well?A. Yes, if you are sure you have finished with them, those can
go as well.Q. I like having lots and lots of programs to play with. Is
there any way of installing all the ports in one go?A. Just do&prompt.root; cd /usr/ports
&prompt.root; make installQ. OK, I tried that, but I thought it would take a very long
time so I went to bed and left it to get on with it. When I looked
at the computer this morning, it had only done three and a half
ports. Did something go wrong?A. No, the problem is that some of the ports need to ask you
questions that we cannot answer for you (eg “Do you want to
print on A4 or US letter sized paper?”) and they need to have
someone on hand to answer them.Q. I really do not want to spend all day staring at the
monitor. Any better ideas?A. OK, do this before you go to bed/work/the local
park:-&prompt.root cd /usr/ports
&prompt.root; make -DBATCH installThis will install every port that does not
require user input. Then, when you come back, do&prompt.root; cd /usr/ports
&prompt.root; make -DIS_INTERACTIVE installto finish the job.Q. At work, we are using frobble, which is
in your ports collection, but we have altered it quite a bit to get
it to do what we need. Is there any way of making our own packages,
so we can distribute it more easily around our sites?A. No problem, assuming you know how to make patches for your
changes:-&prompt.root; cd /usr/ports/somewhere/frobble
&prompt.root; make extract
&prompt.root; cd work/frobble-2.8
[Apply your patches]
&prompt.root; cd ../..
&prompt.root; make packageQ. This ports stuff is really clever. I am desperate to find
out how you did it. What is the secret?A. Nothing secret about it at all, just look at the
bsd.ports.mk and
bsd.ports.subdir.mk files in your makefiles
directory.Readers with an aversion to intricate shell-scripts are
advised not to follow this link...)Making a port yourselfContributed by &a.jkh;, &a.gpalmer;, &a.asami; &a.obrien;
and &a.hoek;. 28 August 1996.So, now you are interested in making your own port? Great!What follows are some guidelines for creating a new port for
FreeBSD. The bulk of the work is done by
/usr/ports/Mk/bsd.port.mk, which all port Makefiles
include. Please refer to that file for more details on the inner
workings of the ports collection. Even if you don't hack Makefiles
daily, it is well commented, and you will still gain much knowledge from
it.Only a fraction of the overridable variables
(VAR) are mentioned in
this document. Most (if not all) are documented at the start of
bsd.port.mk. This file users a non-standard tab
setting. Emacs and
Vim should recognise the setting on loading
the file. vi or ex can be set
to use the correct value by typing :set tabstop=4
once the file has been loaded.Quick PortingThis section tells you how to do a quick port. In many cases, it
is not enough, but we will see.First, get the original tarball and put it into
DISTDIR, which defaults to
/usr/ports/distfiles.The following assumes that the software compiled out-of-the-box,
i.e., there was absolutely no change required for the port to work
on your FreeBSD box. If you needed to change something, you will
have to refer to the next section too.Writing the MakefileThe minimal Makefile would look something
like this:
# New ports collection makefile for: oneko
# Version required: 1.1b
# Date created: 5 December 1994
# Whom: asami
#
# $Id$
#
DISTNAME= oneko-1.1b
CATEGORIES= games
MASTER_SITES= ftp://ftp.cs.columbia.edu/archives/X11R5/contrib/
MAINTAINER= asami@FreeBSD.ORG
MAN1= oneko.1
MANCOMPRESSED= yes
USE_IMAKE= yes
.include <bsd.port.mk>See if you can figure it out. Do not worry about the contents
of the $Id$ line, it will be filled in
automatically by CVS when the port is imported to our main ports
tree. You can find a more detailed example in the sample Makefile section.Writing the description filesThere are three description files that are required for any
port, whether they actually package or not. They are
COMMENT, DESCR, and
PLIST, and reside in the
pkg subdirectory.COMMENTThis is the one-line description of the port.
Please do not include the package name (or
version number of the software) in the comment. Here is an
example:
A cat chasing a mouse all over the screen.DESCRThis is a longer description of the port. One to a few
paragraphs concisely explaining what the port does is
sufficient.This is not a manual or an in-depth
description on how to use or compile the port! Please
be careful if you are copying from the
README or manpage; too often
they are not a concise description of the port or are in an
awkward format (e.g., manpages have justified spacing). If the
ported software has an official WWW homepage, you should list it
here. Prefix one of the websites with
WWW: so that automated tools will work
correctly.It is recommended that you sign your name at the end of this
file, as in:
This is a port of oneko, in which a cat chases a poor mouse all over
the screen.
:
(etc.)
WWW: http://www.oneko.org/
- Satoshi
asami@cs.berkeley.eduPLISTThis file lists all the files installed by the port. It is
also called the “packing list” because the package is
generated by packing the files listed here. The pathnames are
relative to the installation prefix (usually
/usr/local or
/usr/X11R6). If you are using the
MANn variables (as
you should be), do not list any manpages here.Here is a small example:
bin/oneko
lib/X11/app-defaults/Oneko
lib/X11/oneko/cat1.xpm
lib/X11/oneko/cat2.xpm
lib/X11/oneko/mouse.xpm
@dirrm lib/X11/onekoRefer to the &man.pkg.create.1; man page for details on the
packing list.You should list all the files, but not the name directories,
in the list. Also, if the port creates directories for itself
during installtion, make sure to add @dirrm
lines as necessary to remove them when the port is
deleted.It is recommended that you keep all the filenames in this
file sorted alphabetically. It will make verifying the changes
when you upgrade the port much easier.Creating the checksum fileJust type make makesum. The ports make rules
will automatically generate the file
files/md5.Testing the portYou should make sure that the port rules do exactly what you
want it to do, including packaging up the port. These are the
important points you need to verify.PLIST does not contain anything not
installed by your portPLIST contains everything that is
installed by your portYour port can be installed multiple times using the
reinstall targetYour port cleans up
after itself upon deinstallRecommended test orderingmake installmake packagemake deinstallpkg_add `make package-name`make deinstallmake reinstallmake packageMake sure that there aren't any warnings issued in any of the
package and
deinstall stages, After step 3, check to
see if all the new directories are correctly deleted. Also, try
using the software after step 4, to ensure that is works correctly
when installed from a package.Checking your port with portlintPlease use portlint to see if your port
conforms to our guidelines. The portlint program
is part of the ports collection. In particular, your may want to
check if the Makefile is in
the right shape and the package is named
appropriately.Submitting the portFirst, make sure you have read the Do's and Dont's section.Now that you are happy with your port, the only thing remaining
is to put it in the main FreeBSD ports tree and make everybody else
happy about it too. We do not need your work
directory or the pkgname.tgz package, so delete
them now. Next, simply include the output of shar `find
port_dir` in a bug report and send it with the
&man.send-pr.1; program (see Bug
Reports and General Commentary for more information about
&man.send-pr.1;. If the uncompressed port is larger than 20KB,
you should compress it into a tarfile and use &man.uuencode.1;
before including it in the bug report (uuencoded tarfiles are
acceptable even if the bug report is smaller than 20KB but are not
preferred). Be sure to classify the bug report as category
ports and class
change-request. (Do not mark the report
confidential!)One more time, do not include the original source
distfile, the work directory, or the package
you built with make package.In the past, we asked you to upload new port submissions in
our ftp site (ftp.freebsd.org). This
is no longer recommended as read access is turned off on that
incoming/ directory of that site due to the
large amount of pirated software showing up there.We will look at your port, get back to you if necessary, and put
it in the tree. Your name will also appear in the list of
“Additional FreeBSD contributors” on the FreeBSD
Handbook and other files. Isn't that great?!? :)Slow PortingOk, so it was not that simple, and the port required some
modifications to get it to work. In this section, we will explain,
step by step, how to modify it to get it to work with the ports
paradigm.How things workFirst, this is the sequence of events which occurs when the user
first types make in your port's directory, and
you may find that having bsd.port.mk in another
window while you read this really helps to understand it.But do not worry if you do not really understand what
bsd.port.mk is doing, not many people do...
:>The fetch target is run. The
fetch target is responsible for making
sure that the tarball exists locally in
DISTDIR. If fetch
cannot find the required files in DISTDIR it
will look up the URL MASTER_SITES, which is
set in the Makefile, as well as our main ftp site at ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/,
where we put sanctioned distfiles as backup. It will then
attempt to fetch the named distribution file with
FETCH, assuming that the requesting site has
direct access to the Internet. If that succeeds, it will save
the file in DISTDIR for future use and
proceed.The extract target is run. It
looks for your port's distribution file (typically a gzip'd
tarball) in DISTDIR and unpacks it into a
temporary subdirectory specified by WRKDIR
(defaults to work).The patch target is run. First,
any patches defined in PATCHFILES are
applied. Second, if any patches are found in
PATCHDIR (defaults to the
patches subdirectory), they are applied at
this time in alphabetical order.The configure target is run. This
can do any one of many different things.If it exists, scripts/configure is
run.If HAS_CONFIGURE or
GNU_CONFIGURE is set,
WRKSRC/configure is
run.If USE_IMAKE is set,
XMKMF (default: xmkmf
-a) is run.The build target is run. This is
responsible for descending into the port's private working
directory (WRKSRC) and building it. If
USE_GMAKE is set, GNU make
will be used, otherwise the system make will
be used.The above are the default actions. In addition, you can define
targets
pre-something or
post-something,
or put scripts with those names, in the scripts
subdirectory, and they will be run before or after the default
actions are done.For example, if you have a post-extract
target defined in your Makefile, and a file
pre-build in the scripts
subdirectory, the post-extract target will
be called after the regular extraction actions, and the
pre-build script will be executed before the
default build rules are done. It is recommended that you use
Makefile targets if the actions are simple
enough, because it will be easier for someone to figure out what
kind of non-default action the port requires.The default actions are done by the
bsd.port.mk targets
do-something.
For example, the commands to extract a port are in the target
do-extract. If you are not happy with the
default target, you can fix it by redefining the
do-something
target in your Makefile.The “main” targets (e.g.,
extract,
configure, etc.) do nothing more than
make sure all the stages up to that one are completed and call
the real targets or scripts, and they are not intended to be
changed. If you want to fix the extraction, fix
do-extract, but never ever touch
extract!Now that you understand what goes on when the user types
make, let us go through the recommended steps to
create the perfect port.Getting the original sourcesGet the original sources (normally) as a compressed tarball
(foo.tar.gz or
foo.tar.Z) and copy
it into DISTDIR. Always use
mainstream sources when and where you
can.If you cannot find a ftp/http site that is well-connected to the
net, or can only find sites that have irritatingly non-standard
formats, you might want to put a copy on a reliable ftp or http
server that you control (e.g., your home page). Make sure you set
MASTER_SITES to reflect your choice.If you cannot find somewhere convenient and reliable to put the
distfile (if you are a FreeBSD committer, you can just put it in
your public_html/ directory on
freefall), we can “house” it ourselves
by putting it on
ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/LOCAL_PORTS/
as the last resort. Please refer to this location as
MASTER_SITE_LOCAL. Send mail to the &a.ports;if
you are not sure what to do.If your port's distfile changes all the time for no good reason,
consider putting the distfile in your home page and listing it as
the first MASTER_SITES. This will prevent users
from getting checksum mismatch errors, and
also reduce the workload of maintainers of our ftp site. Also, if
there isonly one master site for the port, it is recommended that
you house a backup at your site and list it as the second
MASTER_SITES.If your port requires some additional `patches' that are
available on the Internet, fetch them too and put them in
DISTDIR. Do not worry if they come from a site
other than where you got the main source tarball, we have a way to
handle these situations (see the description of PATCHFILES below).Modifying the portUnpack a copy of the tarball in a private directory and make
whatever changes are necessary to get the port to compile properly
under the current version of FreeBSD. Keep careful
track of everything you do, as you will be automating
the process shortly. Everything, including the deletion, addition
or modification of files should be doable using an automated script
or patch file when your port is finished.If your port requires significant user interaction/customization
to compile or install, you should take a look at one of Larry Wall's
classic Configure scripts and perhaps do
something similar yourself. The goal of the new ports collection is
to make each port as “plug-and-play” as possible for the
end-user while using a minimum of disk space.Unless explicitly stated, patch files, scripts, and other
files you have created and contributed to the FreeBSD ports
collection are assumed to be covered by the standard BSD copyright
conditions.PatchingIn the preparation of the port, files that have been added or
changed can be picked up with a recursive diff for later feeding to
patch. Each set of patches you wish to apply should be collected
into a file named
patch-xx where
xx denotes the sequence in which the
patches will be applied — these are done in
alphabetical order, thus aa
first, ab second and so on. These files should
be stored in PATCHDIR, from where they will be
automatically applied. All patches should be relative to
WRKSRC (generally the directory your port's
tarball unpacks itself into, that being where the build is done).
To make fixes and upgrades easier, you should avoid having more than
one patch fix the same file (e.g., patch-aa and
patch-ab both changing
WRKSRC/foobar.c).ConfiguringInclude any additional customization commands to your
configure script and save it in the
scripts subdirectory. As mentioned above, you
can also do this as Makefile targets and/or
scripts with the name pre-configure or
post-configure.Handling user inputIf your port requires user input to build, configure or install,
then set IS_INTERACTIVE in your Makefile. This
will allow “overnight builds” to skip your port if the
user sets the variable BATCH in his environment (and
if the user sets the variable INTERACTIVE, then
only those ports requiring interaction are
built).It is also recommended that if there are reasonable default
answers to the questions, you check the
PACKAGE_BUILDING variable and turn off the
interactive script when it is set. This will allow us to build the
packages for CD-ROMs and ftp.Configuring the MakefileConfiguring the Makefile is pretty simple, and again we suggest
that you look at existing examples before starting. Also, there is a
sample Makefile in this
handbook, so take a look and please follow the ordering of variables
and sections in that template to make your port easier for others to
read.Now, consider the following problems in sequence as you design
your new Makefile:The original sourceDoes it live in DISTDIR as a standard gzip'd
tarball? If so, you can go on to the next step. If not, you should
look at overriding any of the EXTRACT_CMD,
EXTRACT_BEFORE_ARGS,
EXTRACT_AFTER_ARGS,
EXTRACT_SUFX, or DISTFILES
variables, depending on how alien a format your port's distribution
file is. (The most common case is
EXTRACT_SUFX=.tar.Z, when the tarball is
condensed by regular compress, not gzip.)In the worst case, you can simply create your own
do-extract target to override the default,
though this should be rarely, if ever, necessary.DISTNAMEYou should set DISTNAME to be the base name
of your port. The default rules expect the distribution file list
(DISTFILES) to be named
DISTNAMEEXTRACT_SUFX which, if
it is a normal tarball, is going to be something like
foozolix-1.0.tar.gz for a setting of
DISTNAME=foozolix-1.0.The default rules also expect the tarball(s) to extract into a
subdirectory called
work/DISTNAME, e.g.
work/foozolix-1.0/.All this behavior can be overridden, of course; it simply
represents the most common time-saving defaults. For a port
requiring multiple distribution files, simply set
DISTFILES explicitly. If only a subset of
DISTFILES are actual extractable archives, then
set them up in EXTRACT_ONLY, which will override
the DISTFILES list when it comes to extraction,
and the rest will be just left in DISTDIR for
later use.PKGNAMEIf DISTNAME does not conform to our guidelines for a good package
name, you should set the PKGNAME
variable to something better. See the abovementioned guidelines for
more details.CATEGORIESWhen a package is created, it is put under
/usr/ports/packages/All and links are made from
one or more subdirectories of
/usr/ports/packages. The names of these
subdirectories are specified by the variable
CATEGORIES. It is intended to make life easier
for the user when he is wading through the pile of packages on the
ftp site or the CD-ROM. Please take a look at the existing categories and pick the ones
that are suitable for your port.This list also determines where in the ports tree the port is
imported. If you put more than one category here, it is assumed
that the port files will be put in the subdirectory with the name in
the first category. See the categories section for more
discussion about how to pick the right categories.If you port truly belongs to something that is different from
all the existing ones, you can even create a new category name. In
that case, please send mail to the &a.ports; to propose a new
category.There is no error checking for category names. make
package will happily create a new directory if you
mustype the category name, so be careful!MASTER_SITESRecord the directory part of the ftp/http-URL pointing at the
original tarball in MASTER_SITES. Do not forget
the trailing slash (/)!The make macros will try to use this
specification for grabbing the distribution file with
FETCH if they cannot find it already on the
system.It is recommended that you put multiple sites on this list,
preferably from different continents. This will safeguard against
wide-area network problems, and we are even planning to add support
for automatically determining the closest master site and fetching
from there!If the original tarball is part of one of the following popular
archives: X-contrib, GNU, Perl CPAN, TeX CTAN, or Linux Sunsite, you
refer to those sites in an easy compact form using
MASTER_SITE_XCONTRIB,
MASTER_SITE_GNU,
MASTER_SITE_PERL_CPAN,
MASTER_SITE_TEX_CTAN, and
MASTER_SITE_SUNSITE. Simply set
MASTER_SITE_SUBDIR to the path with in the
archive. Here is an example:
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applicationsThe user can also set the MASTER_SITE_*
variables in /etc/make.conf to override our
choices, and use their favorite mirrors of these popular archives
instead.PATCHFILESIf your port requires some additional patches that are available
by ftp or http, set PATCHFILES to the names of
the files and PATCH_SITES to the URL of the
directory that contains them (the format is the same as
MASTER_SITES).If the patch is not relative to the top of the source tree
(i.e., WKRSRC) because it contains some extra
pathnames, set PATCH_DIST_STRIP accordingly. For
instance, if all the pathnames in the patch have an extra
foozolix-1.0/ in front of the filenames, then set
PATCH_DIST_STRIP=-p1.Do not worry if the patches are compressed, they will be
decompressed automatically if the filenames end with
.gz or .Z.If the patch is distributed with some other files, such as
documentation, in a gzip'd tarball, you can't just use
PATCHFILES. If that is the case, add the name
and the location of the patch tarball to
DISTFILES and MASTER_SITES.
Then, from the pre-patch target, apply the
patch either by running the patch command from there, or copying the
patch file into the PATCHDIR directory and
calling it
patch-xx.Note the tarball will have been extracted alongside the
regular source by then, so there is no need to explicitly extract
it if it is a regular gzip'd or compress'd tarball. If you do the
latter, take extra care not to overwrite something that already
exists in that directory. Also do not forget to add a command to
remove the copied patch in the pre-clean
target.MAINTAINERSet your mail-address here. Please. :)For detailed description of the responsibility of maintainers,
refer to MAINTAINER on
Makefiles section.DependenciesMany ports depend on other ports. There are five variables that
you can use to ensure that all the required bits will be on the
user's machine. There are also some pre-supported dependency
variables for common cases, plus a few more to control the behaviour
of dependencies.LIB_DEPENDSThis variable specifies the shared libraries this port depends
on. It is a list of
lib:dir:target
tuples where lib is the name of the
shared library, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. For example, LIB_DEPENDS=
jpeg\\.9\\.:${PORTSDIR}/graphics/jpeg:install
will check for a shared jpeg library with major version 9, and
descend into the graphics/jpeg subdirectory
of your ports tree to build and install it if it is not found.
The target part can be omitted if it is
equal to DEPENDS_TARGET (which defaults to
install).The lib part is an argument given
to ldconfig -r | grep -wF. There shall be no
reqular expressions in this variable.The dependency is checked twice, once from within the
extract target and then from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system.RUN_DEPENDSThis variable specifies executables or files this port depends
on during run-time. It is a list of
path:dir:target
tuples where path is the name of the
executable or file, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. If path starts with a slash
(/), it is treated as a file and its existence
is tested with test -e; otherwise, it is
assumed to be an executable, and which -s is
used to determine if the program exists in the user's search
path.For example,
RUN_DEPENDS= ${PREFIX}/etc/innd:${PORTSDIR}/news/inn \
wish8.0:${PORTSDIR}/x11-toolkits/tk80will check if the file or directory
/usr/local/etc/innd exists, and build and
install it from the news/inn subdirectory of
the ports tree if it is not found. It will also see if an
executable called wish8.0 is in your search
path, and descend into the x11-toolkits/tk80
subdirectory of your ports tree to build and install it if it is
not found.In this case, innd is actually an
executable; if an executable is in a place that is not expected
to be in a normal user's search path, you should use the full
pathname.The dependency is checked from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system. The target
part can be omitted if it is the same
DEPENDS_TARGET.BUILD_DEPENDSThis variable specifies executables or files this port
requires to build. Like RUN_DEPENDS, it is a
list of
path:dir:target
tuples. For example, BUILD_DEPENDS=
unzip:${PORTSDIR}/archivers/unzip will check
for an executable called unzip, and descend
into the archivers/unzip subdirectory of your
ports tree to build and install it if it is not found.“build” here means everything from extracting to
compilation. The dependency is checked from within the
extract target. The
target part can be omitted if it is
the same as DEPENDS_TARGETFETCH_DEPENDSThis variable specifies executables or files this port
requires to fetch. Like the previous two, it is a list of
path:dir:target
tuples. For example, FETCH_DEPENDS=
ncftp2:${PORTSDIR}/net/ncftp2 will check for an
executable called ncftp2, and descend into the
net/ncftp2 subdirectory of your ports tree to
build and install it if it is not found.The dependency is checked from within the
fetch target. The
target part can be omitted if it is the
same as DEPENDS_TARGET.DEPENDSIf there is a dependency that does not fall into either of the
above four categories, or your port requires to have the source of
the other port extracted in addition to having them installed,
then use this variable. This is a list of
dir:target,
as there is nothing to check, unlike the previous four. The
target part can be omitted if it is the
same as DEPENDS_TARGET.Common dependency variablesDefine USE_XLIB=yes if your port requires
the X Window System to be installed (it is implied by
USE_IMAKE). Define
USE_GMAKE=yes if your port requires GNU
make instead of BSD make.
Define USE_AUTOCONF=yes if your port requires
GNU autoconf to be run. Define USE_QT=yes if
your port uses the latest qt toolkit. Use
USE_PERL5=yes if your port requires version 5
of the perl language. (The last is especially important since
some versions of FreeBSD has perl5 as part of the base system
while others don't.)Notes on dependenciesAs mentioned above, the default target to call when a
dependency is required is DEPENDS_TARGET.
It defaults to install. This is a user
variable; is is never defined in a port's
Makefile. If your port needs a special way
to handle a dependency, use the :target part of
the *_DEPENDS variables instead of redefining
DEPENDS_TARGET.When you type make clean, its dependencies
are automatically cleaned too. If you do not wish this to happen,
define the variable NOCLEANDEPENDS in your
environment.To depend on another port unconditionally, it is customary to
use the string nonexistent as the first field
of BUILD_DEPENDS or
RUN_DEPENDS. Use this only when you need to
the to get to the source of the other port. You can often save
compilation time by specifying the target too. For
instance
BUILD_DEPENDS= /nonexistent:${PORTSDIR}/graphics/jpeg:extract
will always descend to the JPEG port and extract it.Do not use DEPENDS unless there is no other
way the behaviour you want can be accomplished. It will cause the
other port to be always build (and installed, by default), and the
dependency will go into the packages as well. If this is really
what you need, I recommend you write it as
BUILD_DEPENDS and
RUN_DEPENDS instead—at least the
intention will be clear.Building mechanismsIf your package uses GNU make, set
USE_GMAKE=yes. If your package uses
configure, set
HAS_CONFIGURE=yes. If your package uses GNU
configure, set
GNU_CONFIGURE=yes (this implies
HAS_CONFIGURE). If you want to give some extra
arguments to configure (the default argument list
--prefix=${PREFIX} for GNU
configure and empty for non-GNU
configure), set those extra arguments in
CONFIGURE_ARGS. If your package uses GNU
autoconf, set
USE_AUTOCONF=yes. This implies
GNU_CONFIGURE, and will cause
autoconf to be run before
configure.If your package is an X application that creates
Makefiles from Imakefiles
using imake, then set
USE_IMAKE=yes. This will cause the configure
stage to automatically do an xmkmf -a. If the
flag is a problem for your port, set
XMKMF=xmkmf. If the port uses
imake but does not understand the
install.man target,
NO_INSTALL_MANPAGES=yes should be set. In
addition, the author of the original port should be shot. :>If your port's source Makefile has
something else than all as the main build
target, set ALL_TARGET accordingly. Same goes
for install and
INSTALL_TARGET.Special considerationsThere are some more things you have to take into account when you
create a port. This section explains the most common of those.ldconfigIf your port installs a shared library, add a
post-install target to your
Makefile that runs ${LDCONFIG}
-m on the directory where the new library is installed
(usually PREFIX/lib) to
register it into the shared library cache.Also, add a matching @exec /sbin/ldconfig -m
and @unexec /sbin/ldconfig -R pair to your
pkg/PLIST file so that a user who installed the
- package can start using teh shared libraru immediately and
+ package can start using the shared library immediately and
deinstallation will not cause the system to still believe the
library is there. These lines should immediately follow the line
for the shared library itself, as in:
lib/libtvl80.so.1
@exec /sbin/ldconfig -m %D/lib
@unexec /sbin/ldconfig -RNever, ever, ever add a line that says
ldconfig without any arguments to your
Makefile or pkg/PLIST.
- This will reset the shared libraru cache to the contents of
+ This will reset the shared library cache to the contents of
/usr/lib only, and will royally screw up the
user's machine ("Help, xinit does not run anymore after I install
this port!"). Anybody who does this will be shot and cut in 65,536
pieces by a rusty knife and have is liver chopped out by a bunch of
crows and will eternally rot to death in the deepest bowels of hell
(not necessarily in that order…)ELF supportSince FreeBSD is moving to ELF shortly after 3.0-RELEASE, we need
to convert many ports that build shared libraries to support ELF.
Complicating this task is that a 3.0 system can run as both ELF and
a.out, and we wish to unofficially support the 2.2 as long as
possible. Below are the guidelines on how to convert a.out only ports
to support both a.out and ELF compilation.Some part of this list is only applicable during the conversion,
but will be left here for awhile for reference in case you have come
across some old port you wish to upgrade.Moving a.out libraries out of the wayA.out libraries should be moved out of
/usr/local/lib and similar to an
aout subdirectory. (If you don't move them out
of the way, ELF ports will happily overwrite a.out libraries.) The
move-aout-libs target in the 3.0-CURRENT
src/Makefile (called from
aout-to-elf) will do this for you. It will
only move a.out libs so it is safe to call it on a system with both
ELF and a.out libs in the standard directories.FormatThe ports tree will build packages in the format the machine is
in. This means a.out for 2.2 and a.out or ELF for 3.0 depending on
what `objformat` returns. Also, once users move
a.out libraries to a subdirectory, building a.out libraries will be
unsupported. (I.e., it may still work if you know what you are
doing, but you are on your own.)If a port only works for a.out, set
BROKEN_ELF to a string describing the reason
why. Such ports will be skipped during a build on an ELF
system.PORTOBJFORMATbsd.port.mk will set
PORTOBJFORMAT to aout or
elf and export it in the environments
CONFIGURE_ENV, SCRIPTS_ENV and
MAKE_ENV. (It's always going to be
aout in 2.2-STABLE). It is also passed to
PLIST_SUB as
PORTOBJFORMAT=${PORTOBJFORMAT}. (See comment on
ldconfig lines below.)The variable is set using this line in
bsd.port.mk:
PORTOBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aoutPorts' make processes should use this variable to decide what to
do. However, if the port's configure script
already automatically detects an ELF system, it is not necessary to
refer to PORTOBJFORMAT.Building shared librariesThe following are differences in handling shared libraries for
a.out and ELF.Shared library versionsAn ELF shared library should be called
libfoo.so.M
where M is the single version number,
and an a.out library should be called
libfoo.so.M.N
where M is the major version and
N is the the minor version number.
Do not mix those; never install an ELF
shared library called
libfoo.so.N.M
or an a.out shared library (or symlink) called
libfoo.so.N.Linker command linesAssuming cc -shared is used rather than
ld directly, the only difference is that you
need to add
on the command line for ELF.You need to install a symlink from
libfoo.so to
libfoo.so.N to make
ELF linkers happy. Since it should be listed in
PLIST too, and it won't hurt in the a.out case
(some ports even require the link for dynamic loading), you should
just make this link regardless of the setting of
PORTOBJFORMAT.LIB_DEPENDSAll port Makefiles are edited to remove minor numbers from
LIB_DEPENDS, and also to have the regexp support
removed. (E.g., foo\\.1\\.\\(33|40\\) becomes
foo.2.) They will be matched using grep
-wF.PLISTPLIST should contain the short (ELF) shlib
names if the a.out minor number is zero, and the long (a.out) names
otherwise. bsd.port.mk will automatically add
.0 to the end of short shlib lines if
PORTOBJFORMAT equals aout, and
will delete the minor number from long shlib names if
PORTOBJFORMAT equals
elf.In cases where you really need to install shlibs with two
versions on an ELF system or those with one version on an a.out
system (for instance, ports that install compatibility libraries for
other operating systems), define the variable
NO_FILTER_SHLIBS. This will turn off the editing
of PLIST mentioned in the previous
paragraph.ldconfigThe ldconfig line in Makefiles should
read:
${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m ....In PLIST it should read;
@exec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -m ...
@unexec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -RThis is to ensure that the correct ldconfig
will be called depending on the format of the package, not the
default format of the system.MASTERDIRIf your port needs to build slightly different versions of
packages by having a variable (for instance, resolution, or paper
size) take different values, create one subdirectory per package to
make it easier forusers to see what to do, but try to share as many
files as possible between ports. Typically you only need a very short
Makefile in all but one of the directories if you
use variables cleverly. In the sole Makefiles,
you can use MASTERDIR to specify the directory
where the rest of the files are. Also, use a variable as part of
PKGNAME so
the packages will have different names.This will be best demonstrated by an example. This is part of
japanese/xdvi300/Makefile;
PKGNAME= ja-xdvi${RESOLUTION}-17
:
# default
RESOLUTION?= 300
.if ${RESOLUTION} != 118 && ${RESOLUTION} != 240 && \
${RESOLUTION} != 300 && ${RESOLUTION} != 400
@${ECHO} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
@${ECHO} "Possible values are: 118, 240, 300 (default) and 400."
@${FALSE}
.endifjapanese/xdvi300 also has all the regular
patches, package files, etc. If you type make
there, it will take the default value for the resolution (300) and
build the port normally.As for other resolutions, this is the entirexdvi118/Makefile;
RESOLUTION= 118
MASTERDIR= ${.CURDIR}/../xdvi300
.include ${MASTERDIR}/Makefile(xdvi240/Makefile and
xdvi400/Makefile are similar). The
MASTERDIR definition tells
bsd.port.mk that the refulat set of
subdirectories like PATCHDIR and
PKGDIR are to be found under
xdvi300. The RESOLUTION=118
line will override the RESOLUTION=300 line in
xdvi300/Makefile and the port will be built with
resolution set to 118.Shared library versionsFirst, please read our policy on
shared library versioning to understand what to do with
shared library versions in general. Do not blindly assume software
authors know what they are doing; many of them do not. It is very
important that these details are carefully considered, as we have
quite a unique situation where we are trying to have dozens of
potentially incompatible software pairs co-exist. Careless port
imports have caused great trouble regarding shared libraries in the
past (ever wondered why the port jpeg-6b has a
shared library version of 9.0?). If in doubt, send a message to the
&a.ports;. Most of the time, your job ends by determining the right
shared library version and making appropriate patches to implement
it.However, if there is a port which is a different version of the
same software already in the tree, the situation is much more complex.
In short, the FreeBSD implementation does not allow the user to
specify to the linker which version of shared library to link against
(the linker will always pick the highest numbered version). This
means, if there is a libfoo.so.3.2 and
libfoo.so.4.0 in the system, there is no way to
tell the linker to link a particular application to
libfoo.so.3.2. It is essentially completely
overshadowed in terms of compilation-time linkage. In this case, the
only solution is to rename the base part of the
shared library. For instance, change
libfoo.so.4.0 to
libfoo4.so.1.0 so both version 3.2 and 4.0 can be
linked from other ports.ManpagesThe MAN[1-9LN] variables will automatically add
any manpages to pkg/PLIST (this means you must
not list manpages in the
PLIST—see generating PLIST for more). It also
makes the install stage automatically compress or uncompress manpages
depending on the setting of NOMANCOMPRESS in
/etc/make.conf.To specify whether the manpages are compressed upon installation,
use the MANCOMPRESSED variable. This variable can
take three values, yes, no and
maybe. yes means manpages are
already installed compressed, no means they are
not, and maybe means the software already respects
the value of NOMANCOMPRESS so
bsd.port.mk does not have to do anything
special.MANCOMPRESSED is automatically set to
yes if USE_IMAKE is set and
NO_INSTALL_MANPAGES is not set, and to
no otherwise. You don't have to explicitly define
it unless the default is not suitable for your port.If your port anchors its man tree somewhere other than
PREFIX, you can use the
MANPREFIX to set it. Also, if only manpages in
certain sections go in a non-standard place, such as some Perl modules
ports, you can set individual man paths using
MANsectPREFIX (where
sect is one of 1-9,
L or N).If your manpages go to language-specific subdirectories, set the
name of the languages to MANLANG. The value of
this variable defaults to "" (i.e., English
only).Here is an example that puts it all together.
MAN1= foo.1
MAN3= bar.3
MAN4= baz.4
MANLANG= "" ja
MAN3PREFIX= ${PREFIX}/share/foobar
MANCOMPRESSED= yesThis states that six files are installed by this port;
${PREFIX}/man/man1/foo.1.gz
${PREFIX}/man/ja/man1/foo.1.gz
${PREFIX}/share/foobar/man/man3/bar.3.gz
${PREFIX}/share/foobar/man/ja/man3/bar.3.gz
${PREFIX}/man/man4/baz.4.gz
${PREFIX}/man/ja/man4/baz.4.gzPorts that require MotifThere are many programs that require a Motif library (available
from several commercial vendors, while there is a free clone reported
to be able to run many applications in
x11-toolkits/lesstif) to compile. Since it is a
popular toolkit and their licenses usually permit redistribution of
statically linked binaries, we have made special provisions for
handling ports that require Motif in a way that we can easily compile
binaries linked either dynamically (for people who are compiling from
the port) or statically (for people who distribute packages).REQUIRES_MOTIFIf your port requires Motif, define this variable in the
Makefile. This will prevent people who don't own a copy of Motif
from even attempting to build it.MOTIFLIBThis variable will be set by bsd.port.mk to
be the appropriate reference to the Motif library. Please patch the
source to use this wherever the Motif library is referenced in the
Makefile or
Imakefile.There are two common cases:If the port refers to the Motif library as
-lXm in its Makefile or
Imakefile, simply substitute
${MOTIFLIB} for it.If the port uses XmClientLibs in its
Imakefile, change it to
${MOTIFLIB} ${XTOOLLIB}
${XLIB}.Note that MOTIFLIB (usually) expands to
-L/usr/X11R6/lib -lXm or
/usr/X11R6/lib/libXm.a, so there is no need to
add -L or -l in front.X11 fontsIf your port installs fonts for the X Window system, put them in
X11BASE/lib/X11/fonts/local.
This directory is new to XFree86 release 3.3.3. If it does not exist,
please create it, and print out a message urging the user to update
their XFree86 to 3.3.3 or newer, or at least add this directory to the
font path in /etc/XF86Config.Info filesThe new version of texinfo (included in 2.2.2-RELEASE and onwards)
contains a utility called install-info to add and
delete entries to the dir file. If your port
installs any info documents, please follow this instructions so your
port/package will correctly update the user's
PREFIX/info/dir file. (Sorry
for the length of this section, but is it imperative to weave all the
info files together. If done correctly, it will produce a
beautiful listing, so please bear with me!First, this is what you (as a porter) need to know&prompt.user; install-info --help
install-info [OPTION]... [INFO-FILE [DIR-FILE]]
Install INFO-FILE in the Info directory file DIR-FILE.
Options:
--delete Delete existing entries in INFO-FILE;
don't insert any new entries.
:
--entry=TEXT Insert TEXT as an Info directory entry.
:
--section=SEC Put this file's entries in section SEC of the directory. :This program will not actually install info
files; it merely inserts or deletes entries in the
dir file.Here's a seven-step procedure to convert ports to use
install-info. I will use
editors/emacs as an example.Look at the texinfo sources and make a patch to insert
@dircategory and @direntry
statements to files that don't have them. This is part of my
patch:
--- ./man/vip.texi.org Fri Jun 16 15:31:11 1995
+++ ./man/vip.texi Tue May 20 01:28:33 1997
@@ -2,6 +2,10 @@
@setfilename ../info/vip
@settitle VIP
+@dircategory The Emacs editor and associated tools
+@direntry
+* VIP: (vip). A VI-emulation for Emacs.
+@end direntry
@iftex
@finalout
:The format should be self-explanatory. Many authors leave a
dir file in the source tree that contains all
the entries you need, so look around before you try to write your
own. Also, make sure you look into related ports and make the
section names and entry indentations consistent (we recommend that
all entry text start at the 4th tab stop).Note that you can put only one info entry per file because
of a bug in install-info --delete that
deletes only the first entry if you specify multiple entries in
the @direntry section.You can give the dir entries to
install-info as arguments
( and ) instead
of patching the texinfo sources. I do not think this is a good
idea for ports because you need to duplicate the same information
in three places
(Makefile and
@exec/@unexec of
PLIST; see below). However, if you have a
Japanese (or other multibyte encoding) info files, you will have
to use the extra arguments to install-info
because makeinfo can't handle those texinfo
sources. (See Makefile and
PLIST of japanese/skk
for examples on how to do this).Go back to the port directory and do a make clean;
make and verify that the info files are regenerated
from the texinfo sources. Since the texinfo sources are newer than
the info files, they should be rebuilt when you type
make; but many Makefiles
don't include correct dependencies for info files. In
emacs' case, I had to patch the main
Makefile.in so it will descend into the
man subdirectory to rebuild the info
pages.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Tue Apr 15 00:15:28 1997
@@ -184,7 +184,7 @@
# Subdirectories to make recursively. `lisp' is not included
# because the compiled lisp files are part of the distribution
# and you cannot remake them without installing Emacs first.
-SUBDIR = lib-src src
+SUBDIR = lib-src src man
# The makefiles of the directories in $SUBDIR.
SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile
--- ./man/Makefile.in.org Thu Jun 27 15:27:19 1996
+++ ./man/Makefile.in Tue Apr 15 00:29:52 1997
@@ -66,6 +66,7 @@
${srcdir}/gnu1.texi \
${srcdir}/glossary.texi
+all: info
info: $(INFO_TARGETS)
dvi: $(DVI_TARGETS)The second hunk was necessary because the default target in
the man subdir is called
info, while the main
Makefile wants to call
all. I also deleted the installation of
the info info file because we already have
one with the same name in /usr/share/info
(that patch is not shown here).If there is a place in the Makefile that
is installing the dir file, delete it. Your
port may not be doing it. Also, remove any commands that are
otherwise mucking around with the dir
file.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Mon Apr 14 23:38:07 1997
@@ -368,14 +368,8 @@
if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
then \
(cd ${infodir}; \
- if [ -f dir ]; then \
- if [ ! -f dir.old ]; then mv -f dir dir.old; \
- else mv -f dir dir.bak; fi; \
- fi; \
cd ${srcdir}/info ; \
- (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
- (cd $${thisdir}; chmod a+r ${infodir}/dir); \
for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
(cd $${thisdir}; \
${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
chmod a+r ${infodir}/$$f); \(This step is only necessary if you are modifying an existing
port.) Take a look at pkg/PLIST and delete
anything that is trying to patch up info/dir.
They may be in pkg/INSTALL or some other
file, so search extensively.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/04/15 06:32:12
@@ -15,9 +15,6 @@
man/man1/emacs.1.gz
man/man1/etags.1.gz
man/man1/ctags.1.gz
-@unexec cp %D/info/dir %D/info/dir.bak
-info/dir
-@unexec cp %D/info/dir.bak %D/info/dir
info/cl
info/cl-1
info/cl-2Add a post-install target to the
Makefile to create a dir
file if it is not there. Also, call
install-info with the installed info
files.
Index: Makefile
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 1996/11/19 13:14:40 1.26
+++ Makefile 1997/05/20 10:25:09 1.28
@@ -20,5 +20,11 @@
post-install:
.for file in emacs-19.34 emacsclient etags ctags b2m
strip ${PREFIX}/bin/${file}
.endfor
+ if [ ! -f ${PREFIX}/info/dir ]; then \
+ ${SED} -ne '1,/Menu:/p' /usr/share/info/dir > ${PREFIX}/info/dir; \
+ fi
+.for info in emacs vip viper forms gnus mh-e cl sc dired-x ediff ccmode
+ install-info ${PREFIX}/info/${info} ${PREFIX}/info/dir
+.endfor
.include <bsd.port.mk>Do not use anything other than
/usr/share/info/dir and the above command to
create a new info file. In fact, I'd add the first three lines of
the above patch to bsd.port.mk if you (the
porter) wouldn't have to do it in PLIST by
yourself anyway.Edit PLIST and add equivalent
@exec statements and also
@unexec for pkg_delete. You
do not need to delete info/dir with
@unexec.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/05/20 10:25:12 1.17
@@ -16,7 +14,15 @@
man/man1/etags.1.gz
man/man1/ctags.1.gz
+@unexec install-info --delete %D/info/emacs %D/info/dir
:
+@unexec install-info --delete %D/info/ccmode %D/info/dir
info/cl
info/cl-1
@@ -87,6 +94,18 @@
info/viper-3
info/viper-4
+@exec [ -f %D/info/dir ] || sed -ne '1,/Menu:/p' /usr/share/info/dir > %D/info/dir
+@exec install-info %D/info/emacs %D/info/dir
:
+@exec install-info %D/info/ccmode %D/info/dir
libexec/emacs/19.34/i386--freebsd/cvtmail
libexec/emacs/19.34/i386--freebsd/digest-docThe @unexec install-info --delete
commands have to be listed before the info files themselves so
they can read the files. Also, the @exec
install-info commands have to be after the info
files and the @exec command that creates the
the dir file.Test and admire your
work. :). Check the
dir file before and after each step.The pkg/ subdirectoryThere are some tricks we haven't mentioned yet about the
pkg/ subdirectory that come in handy
sometimes.MESSAGEIf you need to display a message to the installer, you may place
the message in pkg/MESSAGE. This capability is
often useful to display additional installation steps to be taken
after a pkg_add or to display licensing
information.The pkg/MESSAGE file does not need to be
added to pkg/PLIST. Also, it will not get
automatically printed if the user is using the port, not the
package, so you should probably display it from the
post-install target yourself.INSTALLIf your port needs to execute commands when the binary package
is installed with pkg_add you can do this via the
pkg/INSTALL script. This script will
automatically be added to the package, and will be run twice by
pkg_add. The first time will as INSTALL
${PKGNAME} PRE-INSTALL and the second time as
INSTALL ${PKGNAME} POST-INSTALL.
$2 can be tested to determine which mode
the script is being run in. The PKG_PREFIX
environmental variable will be set to the package installation
directory. See &man.pkg.add.1; for
additional information.This script is not run automatically if you install the port
with make install. If you are depending on it
being run, you will have to explicitly call it from your port's
Makefile.REQIf your port needs to determine if it should install or not, you
can create a pkg/REQ “requirements”
script. It will be invoked automatically at
installation/deinstallation time to determine whether or not
installation/deinstallation should proceed.Changing PLIST based on make
variablesSome ports, particularly the p5- ports, need to change their
PLIST depending on what options they are
configured with (or version of perl, in the case of p5- ports). To
make this easy, any instances in the PLIST of
%%OSREL%%, %%PERL_VER%%, and
%%PERL_VERSION%% will be substituted for
appropriately. The value of %%OSREL%% is the
numeric revision of the operating system (e.g.,
2.2.7). %%PERL_VERSION%% is
the full version number of perl (e.g., 5.00502)
and %%PERL_VER%% is the perl version number minus
the patchlevel (e.g., 5.005).If you need to make other substitutions, you can set the
PLIST_SUB variable with a list of
VAR=VALUE
pairs and instances of
%%VAR%%' will be
substituted with VALUE in the
PLIST.For instance, if you have a port that installs many files in a
version-specific subdirectory, you can put something like
OCTAVE_VERSION= 2.0.13
PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION}
in the Makefile and use
%%OCTAVE_VERSION%% wherever the version shows up
in PLIST. That way, when you upgrade the port,
you will not have to change dozens (or in some cases, hundreds) of
lines in the PLIST.This substitution (as well as addition of any man pages) will be done between
the do-install and
post-install targets, by reading from
PLIST and writing to TMPPLIST
(default:
WRKDIR/.PLIST.mktmp). So if
your port builds PLIST on the fly, do so in or
before do-install. Also, if your port
needs to edit the resulting file, do so in
post-install to a file named
TMPPLIST.Changing the names of files in the
pkg subdirectoryAll the filenames in the pkg subdirectory
are defined using variables so you can change them in your
Makefile if need be. This is especially useful
when you are sharing the same pkg subdirectory
among several ports or have to write to one of the above files (see
writing to places other than
WRKDIR for why it is a bad idea to write
directly in to the pkg subdirectory.Here is a list of variable names and their default
values.VariableDefault valueCOMMENT${PKGDIR}/DESCRDESCR${PKGDIR}/DESCRPLIST${PKGDIR}/PLISTPKGINSTALL${PKGDIR}/PKGINSTALLPKGDEINSTALL${PKGDIR}/PKGDEINSTALLPKGREQ${PKGDIR}/REQPKGMESSAGE${PKGDIR}/MESSAGEPlease change these variables rather than overriding
PKG_ARGS. If you change
PKG_ARGS, those files will not correctly be
installed in /var/db/pkg upon install from a
port.Licensing ProblemsSome software packages have restrictive licenses or can be in
violation to the law (PKP's patent on public key crypto, ITAR (export
of crypto software) to name just two of them). What we can do with
them varies a lot, depending on the exact wordings of the respective
licenses.It is your responsibility as a porter to read the licensing
terms of the software and make sure that the FreeBSD project will
not be held accountable of violating them by redistributing the
source or compiled binaries either via ftp or CD-ROM. If in doubt,
please contact the &a.ports;.There are two variables you can set in the Makefile to handle the
situations that arise frequently:If the port has a “do not sell for profit” type of
license, set the variable NO_CDROM to a string
describing the reason why. We will make sure such ports won't go
into the CD-ROM come release time. The distfile and package will
still be available via ftp.If the resulting package needs to be built uniquely for each
site, or the resulting binary package can't be distributed due to
licensing; set the variable NO_PACKAGE to a
string describing the reason why. We will make sure such packages
won't go on the ftp site, nor into the CD-ROM come release time.
The distfile will still be included on both however.If the port has legal restrictions on who can use it (e.g.,
crypto stuff) or has a “no commercial use” license,
set the variable RESTRICTED to be the string
describing the reason why. For such ports, the distfiles/packages
will not be available even from our ftp sites.The GNU General Public License (GPL), both version 1 and 2,
should not be a problem for ports.If you are a committer, make sure you update the
ports/LEGAL file too.UpgradingWhen you notice that a port is out of date compared to the latest
version from the original authors, first make sure you have the latest
port. You can find them in the
ports/ports-current directory of the ftp mirror
sites.The next step is to send a mail to the maintainer, if one is
listed in the port's Makefile. That person may
already be working on an upgrade, or have a reason to not upgrade the
port right now (because of, for example, stability problems of the new
version).If the maintainer asks you to do the upgrade or there isn't any
such person to begin with, please make the upgrade and send the
recursive diff (either unified or context diff is fine, but port
committers appear to prefer unified diff more) of the new and old
ports directories to us (e.g., if your modified port directory is
called superedit and the original as in our tree
is superedit.bak, then send us the result of
diff -ruN superedit.bak superedit). Please examine
the output to make sure all the changes make sense. The best way to
send us the diff is by including it to &man.send-pr.1; (category
ports). Please mention any added or deleted files
in the message, as they have to be explicitly specified to CVS when
doing a commit. If the diff is more than about 20KB, please compress
and uuencode it; otherwise, just include it in as is in the PR.Once again, please use &man.diff.1; and not &man.shar.1; to send
updates to ports.Do's and Dont'sHere is a list of common do's and dont's that you encounter during
the porting process.You should check your own port against this list,
but you can also check ports in the PR database that others have
submitted. Submit any comments on ports you check as described in
Bug Reports and General
Commentary. Checking ports in the PR database will both make
it faster for us to commit them, and prove that you know what you are
doing.Strip BinariesDo strip binaries. If the original source already strips the
binaries, fine; otherwise you should add a
post-install rule to to it yourself. Here is an
example;
post-install:
strip ${PREFIX}/bin/xdlUse the &man.file.1; command on the installed executable to
check whether the binary is stripped or not. If it does not say
not stripped, it is stripped.INSTALL_* macrosDo use the macros provided in bsd.port.mk
to ensure correct modes and ownership of files in your own
*-install targets. They are:INSTALL_PROGRAM is a command to install
binary executables.INSTALL_SCRIPT is a command to install
executable scripts.INSTALL_DATA is a command to install
sharable data.INSTALL_MAN is a command to install
manpages and other documentation (it doesn't compress
anything).These are basically the install command with
all the appropriate flags. See below for an example on how to use
them.WRKDIRDo not write anything to files outside
WRKDIR. WRKDIR is the only
place that is guaranteed to be writable during the port build (see
compiling ports from CDROM for an
example of building ports from a read-only tree). If you need to
modigy some file in PKGDIR, do so by redefining a variable, not by
writing over it.WRKDIRPREFIXMake sure your port honors WRKDIRPREFIX.
Most ports don't have to worry about this. In particular, if you
are referring to a WRKDIR of another port, note
that the correct location is
WRKDIRPREFIXPORTSDIR/subdir/name/work not PORTSDIR/subdir/name/work or .CURDIR/../../subdir/name/work or some such.Also, if you are defining WRKDIR yourself,
make sure you prepend
${WKRDIRPREFIX}${.CURDIR} in the
front.Differentiating operating systems and OS versionsYou may come across code that needs modifications or conditional
compilation based upon what version of UNIX it is running under. If
you need to make such changes to the code for conditional
compilation, make sure you make the changes as general as possible
so that we can back-port code to FreeBSD 1.x systems and cross-port
to other BSD systems such as 4.4BSD from CSRG, BSD/386, 386BSD,
NetBSD, and OpenBSD.The preferred way to tell 4.3BSD/Reno (1990) and newer versions
of the BSD code apart is by using the BSD macro
defined in <sys/param.h>. Hopefully that
file is already included; if not, add the code:
#if (defined(__unix__) || defined(unix)) && !defined(USG)
#include <sys/param.h>
#endifto the proper place in the .c file. We
believe that every system that defines these two symbols has
sys/param.h. If you find a system that
doesn't, we would like to know. Please send mail to the
&a.ports;.Another way is to use the GNU Autoconf style of doing
this:
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h>
#endifDon't forget to add -DHAVE_SYS_PARAM_H to the
CFLAGS in the Makefile for
this method.Once you have sys/param.h included, you may
use:
#if (defined(BSD) && (BSD >= 199103))to detect if the code is being compiled on a 4.3 Net2 code base
or newer (e.g. FreeBSD 1.x, 4.3/Reno, NetBSD 0.9, 386BSD, BSD/386
1.1 and below).Use:
#if (defined(BSD) && (BSD >= 199306))to detect if the code is being compiled on a 4.4 code base or
newer (e.g. FreeBSD 2.x, 4.4, NetBSD 1.0, BSD/386 2.0 or
above).The value of the BSD macro is
199506 for the 4.4BSD-Lite2 code base. This is
stated for informational purposes only. It should not be used to
distinguish between versions of FreeBSD based only on 4.4-Lite vs.
versions that have merged in changes from 4.4-Lite2. The
__FreeBSD__ macro should be used instead.Use sparingly:__FreeBSD__ is defined in all versions of
FreeBSD. Use it if the change you are making
only affects FreeBSD. Porting gotchas like
the use of sys_errlist[] vs
strerror() are Berkeleyisms, not FreeBSD
changes.In FreeBSD 2.x, __FreeBSD__ is defined to
be 2. In earlier versions, it is
1. Later versions will bump it to match
their major version number.If you need to tell the difference between a FreeBSD 1.x
system and a FreeBSD 2.x or 3.x system, usually the right answer
is to use the BSD macros described above. If
there actually is a FreeBSD specific change (such as special
shared library options when using ld) then it
is OK to use __FreeBSD__ and #if
__FreeBSD__ > 1 to detect a FreeBSD 2.x and later
system. If you need more granularity in detecting FreeBSD
systems since 2.0-RELEASE you can use the following:
#if __FreeBSD__ >= 2
#include <osreldate.h>
# if __FreeBSD_version >= 199504
/* 2.0.5+ release specific code here */
# endif
#endifRelease__FreeBSD_version2.0-RELEASE1194112.1-CURRENTs199501, 1995032.0.5-RELEASE1995042.2-CURRENT before 2.11995082.1.0-RELEASE1995112.2-CURRENT before 2.1.51995122.1.5-RELEASE1996072.2-CURRENT before 2.1.61996082.1.6-RELEASE1996122.1.7-RELEASE1996122.2-RELEASE2200002.2.1-RELEASE220000 (no change)2.2-STABLE after 2.2.1-RELEASE220000 (no change)2.2-STABLE after texinfo-3.92210012.2-STABLE after top2210022.2.2-RELEASE2220002.2-STABLE after 2.2.2-RELEASE2220012.2.5-RELEASE2250002.2-STABLE after 2.2.5-RELEASE2250012.2-STABLE after ldconfig -R merge2250022.2.6-RELEASE2260002.2.7-RELEASE2270002.2-STABLE after 2.2.7-RELEASE2270012.2-STABLE after semctl(2) change2270022.2.8-RELEASE2280002.2-STABLE after 2.2.8-RELEASE2280013.0-CURRENT before mount(2) change3000003.0-CURRENT after mount(2) change3000013.0-CURRENT after semctl(2) change3000023.0-CURRENT after ioctl arg changes3000033.0-CURRENT after ELF conversion3000043.0-RELEASE3000053.0-CURRENT after 3.0-RELEASE3000063.0-STABLE after 3/4 branch3000073.1-RELEASE3100003.1-STABLE after 3.1-RELEASE3100014.0-CURRENT after 3/4 branch400000Note that 2.2-STABLE sometimes identifies itself as
“2.2.5-STABLE” after the 2.2.5-RELEASE. The pattern
used to be year followed by the month, but we decided to change it
to a more straightforward major/minor system starting from 2.2.
This is because the parallel development on several branches made
it infeasible to classify the releases simply by their real
release dates. If you are making a port now, you don't have to
worry about old -CURRENTs; they are listed here just for your
reference.In the hundreds of ports that have been done, there have only
been one or two cases where __FreeBSD__ should
have been used. Just because an earlier port screwed up and used it
in the wrong place does not mean you should do so too.Writing something after
bsd.port.mkDo not write anything after the .include
<bsd.port.mk> line. it usually can be avoided by
including bsd.port.pre.mk somewhere in the
middle of your Makefile and
bsd.port.post.mk at the end.You need to include either the
pre.mk/post.mk pair or
bsd.port.mk only; don't mix these two.bsd.port.pre.mk only defines a few
variables, which can be used in tests in the
Makefile, bsd.port.post.mk
defines the rest.Here are some important variables defined in
bsd.port.pre.mk (this is not the complete list,
please read bsd.port.mk for the complete
list).VariableDescriptionARCHThe architecture as returned by uname
-m (e.g., i386)OPSYSThe operating system type, as returned by
uname -s (e.g.,
FreeBSD)OSRELThe release version of the operating system (e.g.,
2.1.5 or
2.2.7)OSVERSIONThe numeric version of the operating system, same as
__FreeBSD_version.PORTOBJFORMATThe object format of the system
(aout or elfLOCALBASEThe base of the “local” tree (e.g.,
/usr/local/)X11BASEThe base of the “X11” tree (e.g.,
/usr/X11R6)PREFIXWhere the port installs itself (see more on
PREFIX).If you have to define the variables
USE_IMAKE, USE_X_PREFIX, or
MASTERDIR, do so before including
bsd.port.pre.mk.Here are some examples of things you can write after
bsd.port.pre.mk;
# no need to compile lang/perl5 if perl5 is already in system
.if ${OSVERSION} > 300003
BROKEN= perl is in system
.endif
# only one shlib version number for ELF
.if ${PORTOBJFORMAT} == "elf"
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}
.else
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}.${SHLIB_MINOR}
.endif
# software already makes link for ELF, but not for a.out
post-install:
.if ${PORTOBJFORMAT} == "aout"
${LN} -sf liblinpack.so.1.0 ${PREFIX}/lib/liblinpack.so
.endifInstall additional documentationIf your software has some documentation other than the standard
man and info pages that you think is useful for the user, install it
under PREFIX/share/doc.
This can be done, like the previous item, in the
post-install target.Create a new directory for your port. The directory name should
reflect what the port is. This usually means
PKGNAME minus the version part. However, if you
think the user might want different versions of the port to be
installed at the same time, you can use the whole
PKGNAME.Make the installation dependent to the variable
NOPORTDOCS so that users can disable it in
/etc/make.conf, like this:
post-install:
.if !defined(NOPORTDOCS)
${MKDIR}${PREFIX}/share/doc/xv
${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${PREFIX}/share/doc/xv
.endifDo not forget to add them to pkg/PLIST too!
(Do not worry about NOPORTDOCS here; there is
currently no way for the packages to read variables from
/etc/make.conf.)Also you can use the pkg/MESSAGE file to
display messages upon installation. See the using
pkg/MESSAGE section for
details.MESSAGE does not need to be added to
pkg/PLIST).DIST_SUBDIRDo not let your port clutter
/usr/ports/distfiles. If your port requires a
lot of files to be fetched, or contains a file that has a name that
might conflict with other ports (e.g.,
Makefile), set DIST_SUBDIR
to the name of the port (PKGNAME without the
version part should work fine). This will change
DISTDIR from the default
/usr/ports/distfiles to
/usr/ports/distfiles/DIST_SUBDIR,
and in effect puts everything that is required for your port into
that subdirectory.It will also look at the subdirectory with the same name on the
backup master site at ftp.freebsd.org.
(Setting DISTDIR explicitly in your
Makefile will not accomplish this, so please use
DIST_SUBDIR.)This does not affect the MASTER_SITES you
define in your Makefile.Package informationDo include package information, i.e.
COMMENT, DESCR, and
PLIST, in pkg.Note that these files are not used only for packaging anymore,
and are mandatory now, even if
NO_PACKAGE is set.RCS stringsDo not put RCS strings in patches. CVS will mangle them when we
put the files into the ports tree, and when we check them out again,
they will come out different and the patch will fail. RCS strings
are surrounded by dollar ($) signs, and
typically start with $Id or
$RCS.Recursive diffUsing the recurse () option to
diff to generate patches is fine, but please take
a look at the resulting patches to make sure you don't have any
unnecessary junk in there. In particular, diffs between two backup
files, Makefiles when the port uses
Imake or GNU configure, etc.,
are unnecessary and should be deleted. If you had to edit
configure.in and run
autoconf to regenerate
configure, do not take the diffs of
configure (it often grows to a few thousand
lines!); define USE_AUTOCONF=yes and take the
diffsof configure.in.Also, if you had to delete a file, then you can do it in the
post-extract target rather than as part of
the patch. Once you are happy with the resulting diff, please split
it up into one source file per patch file.PREFIXDo try to make your port install relative to
PREFIX. (The value of this variable will be set
to LOCALBASE (default
/usr/local), unless
USE_X_PREFIX or USE_IMAKE is
set, in which case it will be X11BASE (default
/usr/X11R6).)Not hard-coding /usr/local or
/usr/X11R6 anywhere in the source will make the
port much more flexible and able to cater to the needs of other
sites. For X ports that use imake, this is
automatic; otherwise, this can often be done by simply replacing the
occurrences of /usr/local (or
/usr/X11R6 for X ports that do not use imake)
in the various scripts/Makefiles in the port to read
PREFIX, as this variable is automatically passed
down to every stage of the build and install processes.Do not set USE_X_PREFIX unless your port
truly require it (i.e., it links against X libs or it needs to
reference files in X11BASE).The variable PREFIX can be reassigned in your
Makefile or in the user's environment.
However, it is strongly discouraged for individual ports to set this
variable explicitly in the Makefiles.Also, refer to programs/files from other ports with the
variables mentioned above, not explicit pathnames. For instance, if
your port requires a macro PAGER to be the full
pathname of less, use the compiler flag:
-DPAGER=\"${PREFIX}/bin/less\"
or
-DPAGER=\"${LOCALBASE}/bin/less\"
if this is an X port, instead of
-DPAGER=\"/usr/local/bin/less\". This way it will
have a better chance of working if the system administrator has
moved the whole `/usr/local' tree somewhere else.SubdirectoriesTry to let the port put things in the right subdirectories of
PREFIX. Some ports lump everything and put it in
the subdirectory with the port's name, which is incorrect. Also,
many ports put everything except binaries, header files and manual
pages in the a subdirectory of lib, which does
not bode well with the BSD paradigm. Many of the files should be
moved to one of the following: etc
(setup/configuration files), libexec
(executables started internally), sbin
(executables for superusers/managers), info
(documentation for info browser) or share
(architecture independent files). See man &man.hier.7; for details,
the rules governing
/usr pretty much apply to
/usr/local too. The exception are ports
dealing with USENET “news”. They may use
PREFIX/news as a destination
for their files.Cleaning up empty directoriesDo make your ports clean up after themselves when they are
deinstalled. This is usually accomplished by adding
@dirrm lines for all directories that are
specifically created by the port. You need to delete subdirectories
before you can delete parent directories.
:
lib/X11/oneko/pixmaps/cat.xpm
lib/X11/oneko/sounds/cat.au
:
@dirrm lib/X11/oneko/pixmals
@dirrm lib/X11/oneko/sounds
@dirrm lib/X11/onekoHowever, sometimes @dirrm will give you
errors because other ports also share the same subdirectory. You
can call rmdir from @unexec to
remove only empty directories without warning.
@unexec rmdir %D/share/doc/gimp 2>/dev/null || trueThis will neither print any error messages nor cause
pkg_delete to exit abnormally even if
PREFIX/share/doc/gimp is not
empty due to other ports installing some files in there.UIDsIf your port requires a certain user to be on the installed
system, let the pkg/INSTALL script call
pw to create it automatically. Look at
net/cvsup-mirror for an example.If your port must use the same user/group ID number when it is
installed a binarypackage as when it was compiled, then you mus
choose a free UID from 50 to 99 and register it below. Look at
japanese/Wnn for an example.Make sure you don't use a UID already used by the system or
other ports. This is the current list of UIDs between 50 and
99.
majordom:*:54:54:Majordomo Pseudo User:/usr/local/majordomo:/nonexistent
cyrus:*:60:60:the cyrus mail server:/nonexistent:/nonexistent
gnats:*:61:1:GNATS database owner:/usr/local/share/gnats/gnats-db:/bin/sh
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/nonexistent
pop:*:68:6:Post Office Owner (popper):/nonexistent:/nonexistent
wnn:*:69:7:Wnn:/nonexistent:/nonexistent
ifmail:*:70:66:Ifmail user:/nonexistent:/nonexistent
pgsql:*:70:70:PostgreSQL pseudo-user:/usr/local/pgsql:/bin/sh
ircd:*:72:72:IRCd hybrid:/nonexistent:/nonexistent
alias:*:81:81:QMail user:/var/qmail/alias:/nonexistent
qmaill:*:83:81:QMail user:/var/qmail:/nonexistent
qmaild:*:82:81:QMail user:/var/qmail:/nonexistent
qmailq:*:85:82:QMail user:/var/qmail:/nonexistent
qmails:*:87:82:QMail user:/var/qmail:/nonexistent
qmailp:*:84:81:QMail user:/var/qmail:/nonexistent
qmailr:*:86:82:QMail user:/var/qmail:/nonexistent
msql:*:87:87:mSQL-2 pseudo-user:/var/db/msqldb:/bin/shPlease include a notice when you submit a port (or an upgrade)
that reserves a new UID or GID in this range. This allows us to
keep the list of reserved IDs up to date.Do things rationallyThe Makefile should do things simply and
reasonably. If you can make it a couple of lines shorter or more
readable, then do so. Examples include using a make
.if construct instead of a shell
if construct, not redefining
do-extract if you can redefine
EXTRACT* instead, and using
GNU_CONFIGURE instead of CONFIGURE_ARGS
+= --prefix=${PREFIX}.Respect CFLAGSThe port should respect the CFLAGS variable.
If it doesn't, please add NO_PACKAGE=ignores
cflags to the Makefile.Configuration filesIf your port requires some configuration files in
PREFIX/etc, do
not just install them and list them in
pkg/PLIST. That will cause
pkg_delete to delete files carefully edited by
the user and a new installation to wipe them out.Instead, install sample files with a suffix
(filename.sample
will work well) and print out a message pointing out that the
user has to copy and edit the file before the software can be made
to work.PortlintDo check your work with portlint
before you submit or commit it.FeedbackDo send applicable changes/patches to the original
author/maintainer for inclusion in next release of the code. This
will only make your job that much easier for the next
release.MiscellaneaThe files pkg/DESCR,
pkg/COMMENT, and pkg/PLIST
should each be double-checked. If you are reviewing a port and feel
they can be worded better, do so.Don't copy more copies of the GNU General Public License into
our system, please.Please be careful to note any legal issues! Don't let us
illegally distribute software!If you are stuck…Do look at existing examples and the
bsd.port.mk file before asking us questions!
;)Do ask us questions if you have any trouble! Do not just beat
your head against a wall! :)A Sample MakefileHere is a sample Makefile that you can use to
create a new port. Make sure you remove all the extra comments (ones
between brackets)!It is recommended that you follow this format (ordering of
variables, empty lines between sections, etc.). This format is
designed so that the most important information is easy to locate. We
recommend that you use portlint to check the
Makefile.
[the header...just to make it easier for us to identify the ports.]
# New ports collection makefile for: xdvi
[the version required header should updated when upgrading a port.]
# Version required: pl18 [things like "1.5alpha" are fine here too]
[this is the date when the first version of this Makefile was created.
Never change this when doing an update of the port.]
# Date created: 26 May 1995
[this is the person who did the original port to FreeBSD, in particular, the
person who wrote the first version of this Makefile. Remember, this should
not be changed when upgrading the port later.]
# Whom: Satoshi Asami <asami@FreeBSD.ORG>
#
# $Id$
[ ^^^^ This will be automatically replaced with RCS ID string by CVS
when it is committed to our repository.]
#
[section to describe the port itself and the master site - DISTNAME
is always first, followed by PKGNAME (if necessary), CATEGORIES,
and then MASTER_SITES, which can be followed by MASTER_SITE_SUBDIR.
After those, one of EXTRACT_SUFX or DISTFILES can be specified too.]
DISTNAME= xdvi
PKGNAME= xdvi-pl18
CATEGORIES= print
[do not forget the trailing slash ("/")!
if you aren't using MASTER_SITE_* macros]
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applications
[set this if the source is not in the standard ".tar.gz" form]
EXTRACT_SUFX= .tar.Z
[section for distributed patches -- can be empty]
PATCH_SITES= ftp://ftp.sra.co.jp/pub/X11/japanese/
PATCHFILES= xdvi-18.patch1.gz xdvi-18.patch2.gz
[maintainer; *mandatory*! This is the person (preferably with commit
privileges) who a user can contact for questions and bug reports - this
person should be the porter or someone who can forward questions to the
original porter reasonably promptly. If you really do not want to have
your address here, set it to "ports@FreeBSD.ORG".]
MAINTAINER= asami@FreeBSD.ORG
[dependencies -- can be empty]
RUN_DEPENDS= gs:${PORTSDIR}/print/ghostscript
LIB_DEPENDS= Xpm.5:${PORTSDIR}/graphics/xpm
[this section is for other standard bsd.port.mk variables that do not
belong to any of the above]
[If it asks questions during configure, build, install...]
IS_INTERACTIVE= yes
[If it extracts to a directory other than ${DISTNAME}...]
WRKSRC= ${WRKDIR}/xdvi-new
[If the distributed patches were not made relative to ${WRKSRC}, you
may need to tweak this]
PATCH_DIST_STRIP= -p1
[If it requires a "configure" script generated by GNU autoconf to be run]
GNU_CONFIGURE= yes
[If it requires GNU make, not /usr/bin/make, to build...]
USE_GMAKE= yes
[If it is an X application and requires "xmkmf -a" to be run...]
USE_IMAKE= yes
[et cetera.]
[non-standard variables to be used in the rules below]
MY_FAVORITE_RESPONSE= "yeah, right"
[then the special rules, in the order they are called]
pre-fetch:
i go fetch something, yeah
post-patch:
i need to do something after patch, great
pre-install:
and then some more stuff before installing, wow
[and then the epilogue]
.include <bsd.port.mk>Package NamesThe following are the conventions you should follow in naming your
packages. This is to have our package directory easy to scan, as
there are already lots and lots of packages and users are going to
turn away if they hurt their eyes!The package name should look like
language-name-compiled.specifics-version.numbers.If your DISTNAME doesn't look like that, set
PKGNAME to something in that format.FreeBSD strives to support the native language of its users.
The language- part should be a two
letter abbreviation of the natural language defined by ISO-639 if
the port is specific to a certain language. Examples are
ja for Japanese, ru for
Russian, vi for Vietnamese,
zh for Chinese, ko for
Korean and de for German.The name part should be all lowercases,
except for a really large package (with lots of programs in it).
Things like XFree86 (yes there really is a port of it, check it
out) and ImageMagick fall into this category. Otherwise, convert
the name (or at least the first letter) to lowercase. If the
capital letters are important to the name (for example, with
one-letter names like R or
V) you may use capital letters at your
discretion. There is a tradition of naming Perl 5 modules by
prepending p5- and converting the double-colon
separator to a hyphen; for example, the
Data::Dumper module becomes
p5-Data-Dumper. If the software in question
has numbers, hyphens, or underscores in its name, you may include
them as well (like kinput2).If the port can be built with different hardcoded defaults (usually
part of the directory name in a family of ports), the
-compiled.specifics part should state
the compiled-in defaults (the hyphen is optional). Examples are
papersize and font units.The version string should be a period-separated list of
integers and single lowercase alphabetics. The only exception is
the string pl (meaning `patchlevel'), which can
be used only when there are no major and
minor version numbers in the software.Here are some (real) examples on how to convert a
DISTNAME into a suitable
PKGNAME:Distribution NamePackage NameReasonmule-2.2.2.mule-2.2.2No changes requiredXFree86-3.1.2XFree86-3.1.2No changes requiredEmiClock-1.0.2emiclock-1.0.2No uppercase names for single programsgmod1.4gmod-1.4Need a hyphen before version numbersxmris.4.0.2xmris-4.0.2Need a hyphen before version numbersrdist-1.3alphardist-1.3aNo strings like alpha
allowedes-0.9-beta1es-0.9b1No strings like beta
allowedv3.3beta021.srctiff-3.3What the heck was that anyway?tvtwmtvtwm-pl11Version string always requiredpiewmpiewm-1.0Version string always requiredxvgr-2.10pl1xvgr-2.10.1pl allowed only when no
major/minor version numbersgawk-2.15.6ja-gawk-2.15.6Japanese language versionpsutils-1.13psutils-letter-1.13Papersize hardcoded at package build timepkfontspkfonts300-1.0Package for 300dpi fontsIf there is absolutely no trace of version information in the
original source and it is unlikely that the original author will ever
release another version, just set the version string to
1.0 (like the piewm example above). Otherwise, ask
the original author or use the date string
(yy.mm.dd) as the version.CategoriesAs you already know, ports are classified in several categories.
But for this to wor, it is important that porters and users understand
what each category and how we deicde what to put in each
category.Current list of categoriesFirst, this is the current list of port categories. Those
marked with an asterisk (*) are
virtual categories—those that do not have
a corresponding subdirectory in the ports tree.For non-virtual categories, you will find a one-line
description in the pkg/COMMENT file in that
subdirectory (e.g.,
archivers/pkg/COMMENT).CategoryDescriptionafterstep*Ports to support AfterStep window managerarchiversArchiving tools.astroAstronomical ports.audioSound support.benchmarksBenchmarking utilities.biologyBiology-related software.cadComputer aided design tools.chineseChinese language support.commsCommunication software. Mostly software to talk to
your serial port.convertersCharacter code converters.databasesDatabases.deskutilsThings that used to be on the desktop before
computers were invented.develDevelopment utilities. Do not put libraries here just
because they are libraries—unless they truly don't
belong to anywhere else, they shouldn't be in this
category.editorsGeneral editors. Specialized editors go in the section
for those tools (e.g., a mathematical-formula editor will go
in math).elispEmacs-lisp ports.emulatorsEmulators for other operating systems. Terminal
emulators do not belong
here—X-based ones should go to
x11 and text-based ones to either
comms or misc,
depending on the exact functionality.gamesGames.germanGerman language support.graphicsGraphics utilities.japaneseJapanese language support.kde*Ports that form the K Desktop Environment
(kde).koreanKorean language support.langProgramming languages.mailMail software.mathNumerical computation software and other utilities
for mathematics.mboneMBone applications.miscMiscellaneous utilities—basically things that
doesn't belong to anywhere else. This is the only category
that should not appear with any other non-virtual category.
If you have misc with something else in
your CATEGORIES line, that means you can
safely delete misc and just put the port
in that other subdirectory!netMiscellaneous networking software.newsUSENET news software.offix*Ports from the OffiX suite.palmSoftware support for the 3Com Palm(tm) series.perl5*Ports that require perl version 5 to run.plan9*Various programs from Plan9.printPrinting software. Desktop publishing tools
(previewers, etc.) belong here too.python*Software written in python.russianRussian language support.securitySecurity utilities.shellsCommand line shells.sysutilsSystem utilities.tcl75*Ports that use tcl version 7.5 to run.tcl76*Ports that use tcl version 7.6 to run.tcl80*Ports that use tcl version 8.0 to run.tcl81*Ports that use tcl version 8.1 to run.textprocText processing utilities. It does not include
desktop publishing tools, which go to print/.tk41*Ports that use tk version 4.1 to run.tk42*Ports that use tk version 4.2 to run.tk80*Ports that use tk version 8.0 to run.tk81*Ports that use tk version 8.1 to run.vietnameseVietnamese language support.windowmaker*Ports to support the WindowMaker window
managerwwwSoftware related to the World Wide Web. HTML language
support belong here too.x11The X window system and friends. This category is only
for software that directly support the window system. Do not
put regular X applications here. If your port is an X
application, define USE_XLIB (implied by
USE_IMAKE) and put it in appropriate
categories. Also, many of them go into other
x11-* categories (see below).x11-clocksX11 clocks.x11-fmX11 file managers.x11-fontsX11 fonts and font utilities.x11-toolkitsX11 toolkits.x11-wmX11 window managers.Choosing the right categoryAs many of the categories overlap, you often have to choose
which of the categories should be the primary category of your port.
There are several rules that govern this usse. Here is the list of
priorities, in decreasing order of precedence.Language specific categories alwasys come first. For
example, if your port installs Japanese X11 fonts, then your
CATEGORIES line would read japanese
x11.Specific categories win over less-specific ones. For
instance, an HTML editor should be listed as www
editors, not the other way around. Also, you don't
need to list net when the port belongs to
either of mail, mbone,
news, security, or
www.x11 is used as a secondary category only
when the primary category is a natural language. In particular,
you should not put x11 in the category line
for X applications.If your port truly does not belong anywhere else, put it in
misc.If you are not sure about the category, please put a comment to
that effect in your send-pr submission so we can
discuss it before import it. (If you are a committer, send a note
&a.ports; so we can discuss it first—too often new ports are
imported to a wrong category only to be moved right away.)Changes to this document and the ports systemIf you maintain a lot of ports, you should consider following the
&a.ports;. Important changes to the way ports work will be announced
there. You can always find more detailed information on the latest
changes by looking at the
bsd.port.mk CVS log.That is It, Folks!Boy, this sure was a long tutorial, wasn't it? Thanks for
following us to here, really.Well, now that you know how to do a port, let us go at it and
convert everything in the world into ports! That is the easiest way to
start contributing to the FreeBSD Project! :)
diff --git a/en_US.ISO_8859-1/books/handbook/contrib/chapter.sgml b/en_US.ISO_8859-1/books/handbook/contrib/chapter.sgml
index 8b2d3c3c88..ccdb16f558 100644
--- a/en_US.ISO_8859-1/books/handbook/contrib/chapter.sgml
+++ b/en_US.ISO_8859-1/books/handbook/contrib/chapter.sgml
@@ -1,5715 +1,5715 @@
Contributing to FreeBSDContributed by &a.jkh;.So you want to contribute something to FreeBSD? That is great! We can
always use the help, and FreeBSD is one of those systems that
relies on the contributions of its user base in order
to survive. Your contributions are not only appreciated, they are vital
to FreeBSD's continued growth!Contrary to what some people might also have you believe, you do not
need to be a hot-shot programmer or a close personal friend of the FreeBSD
core team in order to have your contributions accepted. The FreeBSD
Project's development is done by a large and growing number of
international contributors whose ages and areas of technical expertise
vary greatly, and there is always more work to be done than there are
people available to do it.Since the FreeBSD project is responsible for an entire operating
system environment (and its installation) rather than just a kernel or a
few scattered utilities, our TODO list also spans a
very wide range of tasks, from documentation, beta testing and
presentation to highly specialized types of kernel development. No matter
what your skill level, there is almost certainly something you can do to
help the project!Commercial entities engaged in FreeBSD-related enterprises are also
encouraged to contact us. Need a special extension to make your product
work? You will find us receptive to your requests, given that they are not
too outlandish. Working on a value-added product? Please let us know! We
may be able to work cooperatively on some aspect of it. The free software
world is challenging a lot of existing assumptions about how software is
developed, sold, and maintained throughout its life cycle, and we urge you
to at least give it a second look.What Is NeededThe following list of tasks and sub-projects represents something of
an amalgam of the various core team TODO lists and
user requests we have collected over the last couple of months. Where
possible, tasks have been ranked by degree of urgency. If you are
interested in working on one of the tasks you see here, send mail to the
coordinator listed by clicking on their names. If no coordinator has
been appointed, maybe you would like to volunteer?High priority tasksThe following tasks are considered to be urgent, usually because
they represent something that is badly broken or sorely needed:3-stage boot issues. Overall coordination: &a.hackers;Do WinNT compatible drive tagging so that the 3rd stage
can provide an accurate mapping of BIOS geometries for
disks.Filesystem problems. Overall coordination: &a.fs;Fix the MSDOS file system.Clean up and document the nullfs filesystem code.
Coordinator: &a.eivind;Fix the union file system. Coordinator: &a.dg;Implement Int13 vm86 disk driver. Coordinator:
&a.hackers;New bus architecture. Coordinator: &a.newbus;Port existing ISA drivers to new architecture.Move all interrupt-management code to appropriate parts of
the bus drivers.Port PCI subsystem to new architecture. Coordinator:
&a.dfr;Figure out the right way to handle removable devices and
then use that as a substrate on which PC-Card and CardBus
support can be implemented.Resolve the probe/attach priority issue once and for
all.Move any remaining buses over to the new
architecture.Kernel issues. Overall coordination: &a.hackers;Add more pro-active security infrastructure. Overall
coordination: &a.security;Build something like Tripwire(TM) into the kernel, with a
remote and local part. There are a number of cryptographic
issues to getting this right; contact the coordinator for
details. Coordinator: &a.eivind;Make the entire kernel use suser()
instead of comparing to 0. It is presently using about half
of each. Coordinator: &a.eivind;Split securelevels into different parts, to allow an
administrator to throw away those privileges he can throw
away. Setting the overall securelevel needs to have the same
effect as now, obviously. Coordinator: &a.eivind;Make it possible to upload a list of “allowed
program” to BPF, and then block BPF from accepting other
programs. This would allow BPF to be used e.g. for DHCP,
without allowing an attacker to start snooping the local
network.Update the security checker script. We should at least
grab all the checks from the other BSD derivatives, and add
checks that a system with securelevel increased also have
reasonable flags on the relevant parts. Coordinator:
&a.eivind;Add authorization infrastructure to the kernel, to allow
different authorization policies. Part of this could be done
by modifying suser(). Coordinatory:
&a.eivind;
- Add code to teh NFS layer so that you cannot
+ Add code to the NFS layer so that you cannot
chdir("..") out of an NFS partition. E.g.,
/usr is a UFS partition with
/usr/src NFS exported. Now it is
possible to use the NFS filehandle for
/usr/src to get access to
/usr.Medium priority tasksThe following tasks need to be done, but not with any particular
urgency:Full KLD based driver support/Configuration Manager.Write a configuration manager (in the 3rd stage boot?)
that probes your hardware in a sane manner, keeps only the
KLDs required for your hardware, etc.PCMCIA/PCCARD. Coordinators: &a.msmith; and &a.phk;Documentation!Reliable operation of the pcic driver (needs
testing).Recognizer and handler for sio.c
(mostly done).Recognizer and handler for ed.c
(mostly done).Recognizer and handler for ep.c
(mostly done).User-mode recognizer and handler (partially done).Advanced Power Management. Coordinators: &a.msmith; and
&a.phk;APM sub-driver (mostly done).IDE/ATA disk sub-driver (partially done).syscons/pcvt sub-driver.Integration with the PCMCIA/PCCARD drivers
(suspend/resume).Low priority tasksThe following tasks are purely cosmetic or represent such an
investment of work that it is not likely that anyone will get them
done anytime soon:The first N items are from Terry Lambert
terry@lambert.orgNetWare Server (protected mode ODI driver) loader and
subservices to allow the use of ODI card drivers supplied with
network cards. The same thing for NDIS drivers and NetWare SCSI
drivers.An "upgrade system" option that works on Linux boxes instead
of just previous rev FreeBSD boxes.Symmetric Multiprocessing with kernel preemption (requires
kernel preemption).A concerted effort at support for portable computers. This is
somewhat handled by changing PCMCIA bridging rules and power
management event handling. But there are things like detecting
internal vs. external display and picking a different screen
resolution based on that fact, not spinning down the disk if the
machine is in dock, and allowing dock-based cards to disappear
without affecting the machines ability to boot (same issue for
PCMCIA).Smaller tasksMost of the tasks listed in the previous sections require either a
considerable investment of time or an in-depth knowledge of the
FreeBSD kernel (or both). However, there are also many useful tasks
which are suitable for "weekend hackers", or people without
programming skills.If you run FreeBSD-current and have a good Internet
connection, there is a machine current.freebsd.org which builds a full
release once a day — every now and again, try and install
the latest release from it and report any failures in the
process.Read the freebsd-bugs mailing list. There
might be a problem you can comment constructively on or with
patches you can test. Or you could even try to fix one of the
problems yourself.Read through the FAQ and Handbook periodically. If anything
is badly explained, out of date or even just completely wrong, let
us know. Even better, send us a fix (SGML is not difficult to
learn, but there is no objection to ASCII submissions).Help translate FreeBSD documentation into your native language
(if not already available) — just send an email to &a.doc;
asking if anyone is working on it. Note that you are not
committing yourself to translating every single FreeBSD document
by doing this — in fact, the documentation most in need of
translation is the installation instructions.Read the freebsd-questions mailing list and &ng.misc
occasionally (or even regularly). It can be very satisfying to
share your expertise and help people solve their problems;
sometimes you may even learn something new yourself! These forums
can also be a source of ideas for things to work on.If you know of any bugfixes which have been successfully
applied to -current but have not been merged into -stable after a
decent interval (normally a couple of weeks), send the committer a
polite reminder.Move contributed software to src/contrib
in the source tree.Make sure code in src/contrib is up to
date.Look for year 2000 bugs (and fix any you find!)Build the source tree (or just part of it) with extra warnings
enabled and clean up the warnings.Fix warnings for ports which do deprecated things like using
gets() or including malloc.h.If you have contributed any ports, send your patches back to
the original author (this will make your life easier when they
bring out the next version)Suggest further tasks for this list!How to ContributeContributions to the system generally fall into one or more of the
following 6 categories:Bug reports and general commentaryAn idea or suggestion of general technical
interest should be mailed to the &a.hackers;. Likewise, people with
an interest in such things (and a tolerance for a
high volume of mail!) may subscribe to the
hackers mailing list by sending mail to &a.majordomo;. See mailing lists for more information
about this and other mailing lists.If you find a bug or are submitting a specific change, please
report it using the &man.send-pr.1; program or its WEB-based
equivalent. Try to fill-in each field of the bug report.
Unless they exceed 65KB, include any patches directly in the report.
Consider compressing them and using &man.uuencode.1; if they exceed
20KB. Upload very large submissions to ftp.freebsd.org:/pub/FreeBSD/incoming/.After filing a report, you should receive confirmation along with
a tracking number. Keep this tracking number so that you can update
us with details about the problem by sending mail to
bug-followup@FreeBSD.ORG. Use the number as the
message subject, e.g. "Re: kern/3377". Additional
information for any bug report should be submitted this way.If you do not receive confirmation in a timely fashion (3 days to
a week, depending on your email connection) or are, for some reason,
unable to use the &man.send-pr.1; command, then you may ask
someone to file it for you by sending mail to the &a.bugs;.Changes to the documentationChanges to the documentation are overseen by the &a.doc;. Send
submissions and changes (even small ones are welcome!) using
send-pr as described in Bug Reports and General
Commentary.Changes to existing source codeAn addition or change to the existing source code is a somewhat
trickier affair and depends a lot on how far out of date you are with
the current state of the core FreeBSD development. There is a special
on-going release of FreeBSD known as “FreeBSD-current”
which is made available in a variety of ways for the convenience of
developers working actively on the system. See Staying current with FreeBSD for more
information about getting and using FreeBSD-current.Working from older sources unfortunately means that your changes
may sometimes be too obsolete or too divergent for easy re-integration
into FreeBSD. Chances of this can be minimized somewhat by
subscribing to the &a.announce; and the &a.current; lists, where
discussions on the current state of the system take place.Assuming that you can manage to secure fairly up-to-date sources
to base your changes on, the next step is to produce a set of diffs to
send to the FreeBSD maintainers. This is done with the &man.diff.1;
command, with the “context diff” form
being preferred. For example:&prompt.user; diff -c oldfile newfile
or
&prompt.user; diff -c -r olddir newdir
would generate such a set of context diffs for the given source file
or directory hierarchy. See the man page for &man.diff.1; for more
details.Once you have a set of diffs (which you may test with the
&man.patch.1; command), you should submit them for inclusion with
FreeBSD. Use the &man.send-pr.1; program as described in Bug Reports and General Commentary.
Do not just send the diffs to the &a.hackers; or
they will get lost! We greatly appreciate your submission (this is a
volunteer project!); because we are busy, we may not be able to
address it immediately, but it will remain in the pr database until we
do.If you feel it appropriate (e.g. you have added, deleted, or
renamed files), bundle your changes into a tar file
and run the &man.uuencode.1; program on it. Shar archives are also
welcome.If your change is of a potentially sensitive nature, e.g. you are
unsure of copyright issues governing its further distribution or you
are simply not ready to release it without a tighter review first,
then you should send it to &a.core; directly rather than submitting it
with &man.send-pr.1;. The core mailing list reaches a much smaller
group of people who do much of the day-to-day work on FreeBSD. Note
that this group is also very busy and so you
should only send mail to them where it is truly necessary.Please refer to man 9 intro and man 9
style for some information on coding style. We would
appreciate it if you were at least aware of this information before
submitting code.New code or major value-added packagesIn the rare case of a significant contribution of a large body
work, or the addition of an important new feature to FreeBSD, it
becomes almost always necessary to either send changes as uuencode'd
tar files or upload them to our ftp site ftp://ftp.FreeBSD.ORG/pub/FreeBSD/incoming.When working with large amounts of code, the touchy subject of
copyrights also invariably comes up. Acceptable copyrights for code
included in FreeBSD are:The BSD copyright. This copyright is most preferred due to
its “no strings attached” nature and general
attractiveness to commercial enterprises. Far from discouraging
such commercial use, the FreeBSD Project actively encourages such
participation by commercial interests who might eventually be
inclined to invest something of their own into FreeBSD.The GNU Public License, or “GPL”. This license is
not quite as popular with us due to the amount of extra effort
demanded of anyone using the code for commercial purposes, but
given the sheer quantity of GPL'd code we currently require
(compiler, assembler, text formatter, etc) it would be silly to
refuse additional contributions under this license. Code under
the GPL also goes into a different part of the tree, that being
/sys/gnu or
/usr/src/gnu, and is therefore easily
identifiable to anyone for whom the GPL presents a problem.Contributions coming under any other type of copyright must be
carefully reviewed before their inclusion into FreeBSD will be
considered. Contributions for which particularly restrictive
commercial copyrights apply are generally rejected, though the authors
are always encouraged to make such changes available through their own
channels.To place a “BSD-style” copyright on your work, include
the following text at the very beginning of every source code file you
wish to protect, replacing the text between the %%
with the appropriate information.
Copyright (c) %%proper_years_here%%
%%your_name_here%%, %%your_state%% %%your_zip%%.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer as
the first lines of this file unmodified.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY %%your_name_here%% ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL %%your_name_here%% BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
$Id$For your convenience, a copy of this text can be found in
/usr/share/examples/etc/bsd-style-copyright.Money, Hardware or Internet accessWe are always very happy to accept donations to further the cause
of the FreeBSD Project and, in a volunteer effort like ours, a little
can go a long way! Donations of hardware are also very important to
expanding our list of supported peripherals since we generally lack
the funds to buy such items ourselves.Donating fundsWhile the FreeBSD Project is not a 501(c)(3) (charitable)
corporation and hence cannot offer special tax incentives for any
donations made, any such donations will be gratefully accepted on
behalf of the project by FreeBSD, Inc.FreeBSD, Inc. was founded in early 1995 by &a.jkh; and &a.dg;
with the goal of furthering the aims of the FreeBSD Project and
giving it a minimal corporate presence. Any and all funds donated
(as well as any profits that may eventually be realized by FreeBSD,
Inc.) will be used exclusively to further the project's
goals.Please make any checks payable to FreeBSD, Inc., sent in care of
the following address:FreeBSD, Inc.c/o Jordan Hubbard4041 Pike Lane, Suite FConcordCA, 94520(currently using the Walnut Creek CDROM address until a PO box
can be opened)Wire transfers may also be sent directly to:Bank Of AmericaConcord Main OfficeP.O. Box 37176San FranciscoCA, 94137-5176Routing #: 121-000-358Account #: 01411-07441 (FreeBSD, Inc.)Any correspondence related to donations should be sent to Jordan
Hubbard jkh@FreeBSD.org, either via email or to the
FreeBSD, Inc. postal address given above.If you do not wish to be listed in our donors section, please specify this when
making your donation. Thanks!Donating hardwareDonations of hardware in any of the 3 following categories are
also gladly accepted by the FreeBSD Project:General purpose hardware such as disk drives, memory or
complete systems should be sent to the FreeBSD, Inc. address
listed in the donating funds
section.Hardware for which ongoing compliance testing is desired.
We are currently trying to put together a testing lab of all
components that FreeBSD supports so that proper regression
testing can be done with each new release. We are still lacking
many important pieces (network cards, motherboards, etc) and if
you would like to make such a donation, please contact &a.dg;
for information on which items are still required.Hardware currently unsupported by FreeBSD for which you
would like to see such support added. Please contact the
&a.core; before sending such items as we will need to find a
developer willing to take on the task before we can accept
delivery of new hardware.Donating Internet accessWe can always use new mirror sites for FTP, WWW or
cvsup. If you would like to be such a mirror,
please contact the FreeBSD project administrators
admin@FreeBSD.ORG for more information.Donors GalleryThe FreeBSD Project is indebted to the following donors and would
like to publically thank them here!Contributors to the central server
project:The following individuals and businesses made it possible for
the FreeBSD Project to build a new central server machine to
eventually replace freefall.freebsd.org
by donating the following items:Ade Barkah mbarkah@freebsd.org and his
employer, Hemisphere
Online, donated a Pentium Pro (P6) 200Mhz
CPUASA
Computers donated a Tyan 1662
motherboard.Joe McGuckin joe@via.net of ViaNet Communications donated
a Kingston ethernet controller.Jack O'Neill jack@diamond.xtalwind.net
donated an NCR 53C875 SCSI controller
card.Ulf Zimmermann ulf@Alameda.net of Alameda Networks donated
128MB of memory, a 4 Gb disk
drive and the case.Direct funding:The following individuals and businesses have generously
contributed direct funding to the project:Annelise Anderson
ANDRSN@HOOVER.STANFORD.EDUMatt Dillon dillon@best.netEpilogue Technology
CorporationSean Eric FaganDon Scott WildeGianmarco Giovannelli
gmarco@masternet.itJosef C. Grosch joeg@truenorth.orgRobert T. MorrisChuck Robey chuckr@freebsd.orgKenneth P. Stox ken@stox.sa.enteract.com of
Imaginary Landscape,
LLC.Dmitry S. Kohmanyuk dk@dog.farm.orgLaser5 of Japan
(a portion of the profits from sales of their various FreeBSD
CD-ROMs.Fuki Shuppan
Publishing Co. donated a portion of their profits from
Hajimete no FreeBSD (FreeBSD, Getting
started) to the FreeBSD and XFree86 projects.ASCII Corp.
donated a portion of their profits from several FreeBSD-related
books to the FreeBSD project.Yokogawa Electric
Corp has generously donated significant funding to the
FreeBSD project.BuffNETPacific
SolutionsSiemens AG
via Andre
AlbsmeierChris SilvaHardware contributors:The following individuals and businesses have generously
contributed hardware for testing and device driver
development/support:Walnut Creek CDROM for providing the Pentium P5-90 and
486/DX2-66 EISA/VL systems that are being used for our
development work, to say nothing of the network access and other
donations of hardware resources.TRW Financial Systems, Inc. provided 130 PCs, three 68 GB
fileservers, twelve Ethernets, two routers and an ATM switch for
debugging the diskless code.Dermot McDonnell donated the Toshiba XM3401B CDROM drive
currently used in freefall.&a.chuck; contributed his floppy tape streamer for
experimental work.Larry Altneu larry@ALR.COM, and &a.wilko;,
provided Wangtek and Archive QIC-02 tape drives in order to
improve the wt driver.Ernst Winter ewinter@lobo.muc.de contributed
a 2.88 MB floppy drive to the project. This will hopefully
increase the pressure for rewriting the floppy disk driver.
;-)Tekram
Technologies sent one each of their DC-390, DC-390U
and DC-390F FAST and ULTRA SCSI host adapter cards for
regression testing of the NCR and AMD drivers with their cards.
They are also to be applauded for making driver sources for free
operating systems available from their FTP server ftp://ftp.tekram.com/scsi/FreeBSD.Larry M. Augustin contributed not only a
Symbios Sym8751S SCSI card, but also a set of data books,
including one about the forthcoming Sym53c895 chip with Ultra-2
and LVD support, and the latest programming manual with
information on how to safely use the advanced features of the
latest Symbios SCSI chips. Thanks a lot!Christoph Kukulies kuku@freebsd.org donated
an FX120 12 speed Mitsumi CDROM drive for IDE CDROM driver
development.Special contributors:Walnut Creek CDROM
has donated almost more than we can say (see the history document for more details).
In particular, we would like to thank them for the original
hardware used for freefall.FreeBSD.ORG, our primary
development machine, and for thud.FreeBSD.ORG, a testing and build
box. We are also indebted to them for funding various
contributors over the years and providing us with unrestricted
use of their T1 connection to the Internet.The interface
business GmbH, Dresden has been patiently supporting
&a.joerg; who has often preferred FreeBSD work over paywork, and
used to fall back to their (quite expensive) EUnet Internet
connection whenever his private connection became too slow or
flakey to work with it...Berkeley Software Design,
Inc. has contributed their DOS emulator code to the
remaining BSD world, which is used in the
dosemu command.Core Team AlumnusThe following people were members of the FreeBSD core team during
the period indicated. We thank them for their past efforts in the
service of the FreeBSD project.In rough chronological order:Guido van Rooij (1995 - 1999)John Dyson (1993 - 1998)Nate Williams (1992 - 1996)Rod Grimes (1992 - 1995)Andreas Schulz (1992 - 1995)Geoff Rehmet (1993 - 1995)Paul Richards (1992 - 1995)Scott Mace (1993 - 1994)Andrew Moore (1993 - 1994)Christoph Robitschko (1993 - 1994)J. T. Conklin (1992 - 1993)Derived Software ContributorsThis software was originally derived from William F. Jolitz's 386BSD
release 0.1, though almost none of the original 386BSD specific code
remains. This software has been essentially re-implemented from the
4.4BSD-Lite release provided by the Computer Science Research Group
(CSRG) at the University of California, Berkeley and associated academic
contributors.There are also portions of NetBSD and OpenBSD that have been
integrated into FreeBSD as well, and we would therefore like to thank
all the contributors to NetBSD and OpenBSD for their work.Additional FreeBSD Contributors(in alphabetical order by first name):ABURAYA Ryushirou rewsirow@ff.iij4u.or.jpAMAGAI Yoshiji amagai@nue.orgAaron Bornstein aaronb@j51.comAaron Smith aaron@tau.veritas.comAchim Patzner ap@noses.comAda T Lim ada@bsd.orgAdam Baran badam@mw.mil.plAdam Glass glass@postgres.berkeley.eduAdam McDougall mcdouga9@egr.msu.eduAdrian Colley aecolley@ois.ieAdrian Hall adrian@ibmpcug.co.ukAdrian Mariano adrian@cam.cornell.eduAdrian Steinmann ast@marabu.chAdrian T. Filipi-Martin
atf3r@agate.cs.virginia.eduAjit Thyagarajan unknownAkio Morita
amorita@meadow.scphys.kyoto-u.ac.jpAkira SAWADA unknownAkira Watanabe
akira@myaw.ei.meisei-u.ac.jpAkito Fujita fujita@zoo.ncl.omron.co.jpAlain Kalker
A.C.P.M.Kalker@student.utwente.nlAlan Bawden alan@curry.epilogue.comAlan Cox alc@cs.rice.eduAlec Wolman wolman@cs.washington.eduAled Morris aledm@routers.co.ukAlex garbanzo@hooked.netAlex D. Chen
dhchen@Canvas.dorm7.nccu.edu.twAlex G. Bulushev bag@demos.suAlex Le Heux alexlh@funk.orgAlexander B. Povolotsky tarkhil@mgt.msk.ruAlexander Leidinger
netchild@wurzelausix.CS.Uni-SB.DEAlexandre Snarskii snar@paranoia.ruAlistair G. Crooks agc@uts.amdahl.comAllan Saddi asaddi@philosophysw.comAllen Campbell allenc@verinet.comAmakawa Shuhei amakawa@hoh.t.u-tokyo.ac.jpAmancio Hasty hasty@star-gate.comAmir Farah amir@comtrol.comAmy Baron amee@beer.orgAnatoly A. Orehovsky tolik@mpeks.tomsk.suAnatoly Vorobey mellon@pobox.comAnders Nordby nickerne@nome.noAnders Thulin Anders.X.Thulin@telia.seAndras Olah olah@cs.utwente.nlAndre Albsmeier
Andre.Albsmeier@mchp.siemens.deAndre Oppermann andre@pipeline.chAndreas Haakh ah@alman.robin.deAndreas Kohout shanee@rabbit.augusta.deAndreas Lohr andreas@marvin.RoBIN.deAndreas Schulz unknownAndreas Wetzel mickey@deadline.snafu.deAndreas Wrede andreas@planix.comAndres Vega Garcia unknownAndrew Atrens atreand@statcan.caAndrew Gillham gillham@andrews.eduAndrew Gordon andrew.gordon@net-tel.co.ukAndrew Herbert andrew@werple.apana.org.auAndrew J. Korty ajk@purdue.eduAndrew L. Moore alm@mclink.comAndrew McRae amcrae@cisco.comAndrew Stevenson andrew@ugh.net.auAndrew Timonin tim@pool1.convey.ruAndrew V. Stesin stesin@elvisti.kiev.uaAndrew Webster awebster@dataradio.comAndrey Zakhvatov andy@icc.surw.chel.suAndy Farkas andyf@speednet.com.auAndy Valencia ajv@csd.mot.comAndy Whitcroft andy@sarc.city.ac.ukAngelo Turetta ATuretta@stylo.itAnthony C. Chavez magus@xmission.comAnthony Yee-Hang Chan yeehang@netcom.comAnton Berezin tobez@plab.ku.dkAntti Kaipila anttik@iki.fiAre Bryne are.bryne@communique.noAri Suutari ari@suutari.iki.fiArjan de Vet devet@IAEhv.nlArne Henrik Juul arnej@Lise.Unit.NOAssar Westerlund assar@sics.seAtsushi Furuta furuta@sra.co.jpAtsushi Murai amurai@spec.co.jpBakul Shah bvs@bitblocks.comBarry Bierbauch pivrnec@vszbr.czBarry Lustig barry@ictv.comBen Hutchinson benhutch@xfiles.org.ukBen Jackson unknownBen Smithurst ben@scientia.demon.co.ukBen Walter bwalter@itachi.swcp.comBenjamin Lewis bhlewis@gte.netBernd Rosauer br@schiele-ct.deBill Kish kish@osf.orgBill Trost trost@cloud.rain.comBlaz Zupan blaz@amis.netBob Van Valzah Bob@whitebarn.comBob Willcox bob@luke.pmr.comBoris Staeblow balu@dva.in-berlin.deBoyd R. Faulkner faulkner@asgard.bga.comBrad Karp karp@eecs.harvard.eduBradley Dunn bradley@dunn.orgBrandon Gillespie brandon@roguetrader.com&a.wlloydBob Wilcox bob@obiwan.uucpBoyd Faulkner faulkner@mpd.tandem.comBrent J. Nordquist bjn@visi.comBrett Lymn blymn@mulga.awadi.com.AUBrett Taylor
brett@peloton.physics.montana.eduBrian Campbell brianc@pobox.comBrian Clapper bmc@willscreek.comBrian Cully shmit@kublai.comBrian F. Feldman green@unixhelp.orgBrian Handy
handy@lambic.space.lockheed.comBrian Litzinger brian@MediaCity.comBrian McGovern bmcgover@cisco.comBrian Moore ziff@houdini.eecs.umich.eduBrian R. Haug haug@conterra.comBrian Tao taob@risc.orgBrion Moss brion@queeg.comBruce A. Mah bmah@ca.sandia.govBruce Albrecht bruce@zuhause.mn.orgBruce Gingery bgingery@gtcs.comBruce J. Keeler loodvrij@gridpoint.comBruce Murphy packrat@iinet.net.auBruce Walter walter@fortean.comCarey Jones mcj@acquiesce.orgCarl Fongheiser cmf@netins.netCarl Mascott cmascott@world.std.comCasper casper@acc.amCastor Fu castor@geocast.comCejka Rudolf cejkar@dcse.fee.vutbr.czChain Lee chain@110.netCharles Hannum mycroft@ai.mit.eduCharles Henrich henrich@msu.eduCharles Mott cmott@srv.netCharles Owens owensc@enc.eduChet Ramey chet@odin.INS.CWRU.EduChia-liang Kao clkao@CirX.ORGChiharu Shibata chi@bd.mbn.or.jpChip Norkus unknownChoi Jun Ho junker@jazz.snu.ac.krChris Costello chris@holly.dyndns.orgChris Csanady cc@tarsier.ca.sandia.govChris Dabrowski chris@vader.orgChris Dillon cdillon@wolves.k12.mo.usChris Piazza cpiazza@home.netChris Shenton
cshenton@angst.it.hq.nasa.govChris Stenton jacs@gnome.co.ukChris Timmons skynyrd@opus.cts.cwu.eduChris Torek torek@ee.lbl.govChristian Gusenbauer
cg@fimp01.fim.uni-linz.ac.atChristian Haury Christian.Haury@sagem.frChristian Weisgerber
naddy@bigeye.rhein-neckar.deChristoph P. Kukulies kuku@FreeBSD.orgChristoph Robitschko
chmr@edvz.tu-graz.ac.atChristoph Weber-Fahr
wefa@callcenter.systemhaus.netChristopher G. Demetriou
cgd@postgres.berkeley.eduChristopher T. Johnson
cjohnson@neunacht.netgsi.comChrisy Luke chrisy@flix.netChuck Hein chein@cisco.comClive Lin clive@CiRX.ORGColman Reilly careilly@tcd.ieConrad Sabatier conrads@neosoft.comCoranth Gryphon gryphon@healer.comCornelis van der Laan
nils@guru.ims.uni-stuttgart.deCove Schneider cove@brazil.nbn.comCraig Leres leres@ee.lbl.govCraig Loomis unknownCraig Metz cmetz@inner.netCraig Spannring cts@internetcds.comCraig Struble cstruble@vt.eduCristian Ferretti cfs@riemann.mat.puc.clCurt Mayer curt@toad.comCy Schubert cschuber@uumail.gov.bc.caDI. Christian Gusenbauer
cg@scotty.edvz.uni-linz.ac.atDai Ishijima ishijima@tri.pref.osaka.jpDamian Hamill damian@cablenet.netDan Cross tenser@spitfire.ecsel.psu.eduDan Lukes dan@obluda.czDan Nelson dnelson@emsphone.comDan Walters hannibal@cyberstation.netDaniel Baker dbaker@crash.ops.neosoft.comDaniel M. Eischen
deischen@iworks.InterWorks.orgDaniel O'Connor doconnor@gsoft.com.auDaniel Poirot poirot@aio.jsc.nasa.govDaniel Rock rock@cs.uni-sb.deDanny Egen unknownDanny J. Zerkel dzerkel@phofarm.comDarren Reed avalon@coombs.anu.edu.auDave Adkins adkin003@tc.umn.eduDave Andersen angio@aros.netDave Blizzard dblizzar@sprynet.comDave Bodenstab imdave@synet.netDave Burgess burgess@hrd769.brooks.af.milDave Chapeskie dchapes@ddm.on.caDave Cornejo dave@dogwood.comDave Edmondson davided@sco.comDave Glowacki dglo@ssec.wisc.eduDave Marquardt marquard@austin.ibm.comDave Tweten tweten@FreeBSD.orgDavid A. Adkins adkin003@tc.umn.eduDavid A. Bader dbader@umiacs.umd.eduDavid Borman dab@bsdi.comDavid Dawes dawes@XFree86.orgDavid Filo filo@yahoo.comDavid Holland dholland@eecs.harvard.eduDavid Holloway daveh@gwythaint.tamis.comDavid Horwitt dhorwitt@ucsd.eduDavid Hovemeyer daveho@infocom.comDavid Jones dej@qpoint.torfree.netDavid Kelly dkelly@tomcat1.tbe.comDavid Kulp dkulp@neomorphic.comDavid L. Nugent davidn@blaze.net.auDavid Leonard d@scry.dstc.edu.auDavid Malone dwmalone@maths.tcd.ieDavid Muir Sharnoff muir@idiom.comDavid S. Miller davem@jenolan.rutgers.eduDavid Wolfskill dhw@whistle.comDean Gaudet dgaudet@arctic.orgDean Huxley dean@fsa.caDenis Fortin unknownDennis Glatting
dennis.glatting@software-munitions.comDenton Gentry denny1@home.comDerek Inksetter derek@saidev.comDima Sivachenko dima@Chg.RUDirk Keunecke dk@panda.rhein-main.deDirk Nehrling nerle@pdv.deDmitry Khrustalev dima@xyzzy.machaon.ruDmitry Kohmanyuk dk@farm.orgDom Mitchell dom@myrddin.demon.co.ukDon Croyle croyle@gelemna.ft-wayne.in.us&a.whiteside;Don Morrison dmorrisn@u.washington.eduDon Yuniskis dgy@rtd.comDonald Maddox dmaddox@conterra.comDoug Barton studded@dal.netDouglas Ambrisko ambrisko@whistle.comDouglas Carmichael dcarmich@mcs.comDouglas Crosher dtc@scrooge.ee.swin.oz.auDrew Derbyshire ahd@kew.comDuncan Barclay dmlb@ragnet.demon.co.ukDustin Sallings dustin@spy.netEckart "Isegrim" Hofmann
Isegrim@Wunder-Nett.orgEd Gold
vegold01@starbase.spd.louisville.eduEd Hudson elh@p5.spnet.comEdward Wang edward@edcom.comEdwin Groothus edwin@nwm.wan.philips.comEiji-usagi-MATSUmoto usagi@clave.gr.jpELISA Font ProjectElmar Bartel
bartel@informatik.tu-muenchen.deEric A. Griff eagriff@global2000.netEric Blood eblood@cs.unr.eduEric J. Haug ejh@slustl.slu.eduEric J. Schwertfeger eric@cybernut.comEric L. Hernes erich@lodgenet.comEric P. Scott eps@sirius.comEric Sprinkle eric@ennovatenetworks.comErich Stefan Boleyn erich@uruk.orgErik E. Rantapaa rantapaa@math.umn.eduErik H. Moe ehm@cris.comErnst Winter ewinter@lobo.muc.deEugene M. Kim astralblue@usa.netEugene Radchenko genie@qsar.chem.msu.suEvan Champion evanc@synapse.netFaried Nawaz fn@Hungry.COMFlemming Jacobsen fj@tfs.comFong-Ching Liaw fong@juniper.netFrancis M J Hsieh mjshieh@life.nthu.edu.twFrank Bartels knarf@camelot.deFrank Chen Hsiung Chan
frankch@waru.life.nthu.edu.twFrank Durda IV uhclem@nemesis.lonestar.orgFrank MacLachlan fpm@n2.netFrank Nobis fn@Radio-do.deFrank Volf volf@oasis.IAEhv.nlFrank ten Wolde franky@pinewood.nlFrank van der Linden frank@fwi.uva.nlFred Cawthorne fcawth@jjarray.umn.eduFred Gilham gilham@csl.sri.comFred Templin templin@erg.sri.comFrederick Earl Gray fgray@rice.eduFUJIMOTO Kensaku
fujimoto@oscar.elec.waseda.ac.jpFUJISHIMA Satsuki k5@respo.or.jpFURUSAWA Kazuhisa
furusawa@com.cs.osakafu-u.ac.jpGabor Kincses gabor@acm.orgGabor Zahemszky zgabor@CoDe.huGarance A Drosehn gad@eclipse.its.rpi.eduGareth McCaughan gjm11@dpmms.cam.ac.ukGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGary J. garyj@rks32.pcs.dec.comGary Kline kline@thought.orgGaspar Chilingarov nightmar@lemming.acc.amGea-Suan Lin gsl@tpts4.seed.net.twGeoff Rehmet csgr@alpha.ru.ac.zaGeorg Wagner georg.wagner@ubs.comGerard Roudier groudier@club-internet.frGianmarco Giovannelli
gmarco@giovannelli.itGil Kloepfer Jr. gil@limbic.ssdl.comGilad Rom rom_glsa@ein-hashofet.co.ilGinga Kawaguti
ginga@amalthea.phys.s.u-tokyo.ac.jpGiles Lean giles@nemeton.com.auGlen Foster gfoster@gfoster.comGlenn Johnson gljohns@bellsouth.netGodmar Back gback@facility.cs.utah.eduGoran Hammarback goran@astro.uu.seGord Matzigkeit gord@enci.ucalgary.caGordon Greeff gvg@uunet.co.zaGraham Wheeler gram@cdsec.comGreg A. Woods woods@zeus.leitch.comGreg Ansley gja@ansley.comGreg Troxel gdt@ir.bbn.comGreg Ungerer gerg@stallion.oz.auGregory Bond gnb@itga.com.auGregory D. Moncreaff
moncrg@bt340707.res.ray.comGuy Harris guy@netapp.comGuy Helmer ghelmer@cs.iastate.eduHAMADA Naoki hamada@astec.co.jpHONDA Yasuhiro
honda@kashio.info.mie-u.ac.jpHOSOBUCHI Noriyuki hoso@buchi.tama.or.jpHannu Savolainen hannu@voxware.pp.fiHans Huebner hans@artcom.deHans Petter Bieker zerium@webindex.noHans Zuidam hans@brandinnovators.comHarlan Stenn Harlan.Stenn@pfcs.comHarold Barker hbarker@dsms.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHeikki Suonsivu hsu@cs.hut.fiHeiko W. Rupp unknownHelmut F. Wirth hfwirth@ping.atHenrik Vestergaard Draboel
hvd@terry.ping.dkHerb Peyerl hpeyerl@NetBSD.orgHideaki Ohmon ohmon@tom.sfc.keio.ac.jpHidekazu Kuroki hidekazu@cs.titech.ac.jpHideki Yamamoto hyama@acm.orgHidetoshi Shimokawa
simokawa@sat.t.u-tokyo.ac.jpHideyuki Suzuki
hideyuki@sat.t.u-tokyo.ac.jpHirayama Issei iss@mail.wbs.ne.jpHiroaki Sakai sakai@miya.ee.kagu.sut.ac.jpHiroharu Tamaru tamaru@ap.t.u-tokyo.ac.jpHironori Ikura hikura@kaisei.orgHiroshi Nishikawa nis@pluto.dti.ne.jpHiroya Tsubakimoto unknownHiroyuki NAKAJI
nakaji@zeisei3.dpri.kyoto-u.ac.jpHolger Veit Holger.Veit@gmd.deHolm Tiffe holm@geophysik.tu-freiberg.deHorance Chou
horance@freedom.ie.cycu.edu.twHorihiro Kumagaio kuma@jp.freebsd.orgHr.Ladavac lada@ws2301.gud.siemens.co.atHubert Feyrer hubertf@NetBSD.ORGHugh F. Mahon hugh@nsmdserv.cnd.hp.comHugh Mahon h_mahon@fc.hp.comHung-Chi Chu hcchu@r350.ee.ntu.edu.twIMAI Takeshi take-i@ceres.dti.ne.jpIMAMURA Tomoaki
tomoak-i@is.aist-nara.ac.jpIan Dowse iedowse@maths.tcd.ieIan Holland ianh@tortuga.com.auIan Struble ian@broken.netIan Vaudrey i.vaudrey@bigfoot.comIgor Khasilev igor@jabber.paco.odessa.uaIgor Roshchin str@giganda.komkon.orgIgor Sviridov siac@ua.netIgor Vinokurov igor@zynaps.ruIkuo Nakagawa ikuo@isl.intec.co.jpIlya V. Komarov mur@lynx.ruIssei Suzuki issei@jp.FreeBSD.orgItsuro Saito saito@miv.t.u-tokyo.ac.jpJ. Bryant jbryant@argus.flash.netJ. David Lowe lowe@saturn5.comJ. Han hjh@best.comJ. Hawk jhawk@MIT.EDUJ.T. Conklin jtc@cygnus.comJ.T. Jang keith@email.gcn.net.twJack jack@zeus.xtalwind.netJacob Bohn Lorensen jacob@jblhome.ping.mkJagane D Sundar jagane@netcom.comJake Hamby jehamby@lightside.comJames Clark jjc@jclark.comJames D. Stewart jds@c4systm.comJames Jegers jimj@miller.cs.uwm.eduJames Raynard
fhackers@jraynard.demon.co.ukJames T. Liu jtliu@phlebas.rockefeller.eduJames da Silva jds@cs.umd.eduJan Conard
charly@fachschaften.tu-muenchen.deJan Koum jkb@FreeBSD.orgJanick Taillandier
Janick.Taillandier@ratp.frJanusz Kokot janek@gaja.ipan.lublin.plJarle Greipsland jarle@idt.unit.noJason Garman init@risen.orgJason Thorpe thorpej@NetBSD.orgJason Wright jason@OpenBSD.orgJason Young
doogie@forbidden-donut.anet-stl.comJavier Martin Rueda jmrueda@diatel.upm.esJay Fenlason hack@datacube.comJaye Mathisen mrcpu@cdsnet.netJeff Bartig jeffb@doit.wisc.eduJeff Forys jeff@forys.cranbury.nj.usJeff Kletsky Jeff@Wagsky.comJeffrey Evans evans@scnc.k12.mi.usJeffrey Wheat jeff@cetlink.netJens Schweikhardt schweikh@noc.dfn.dJeremy Allison jallison@whistle.comJeremy Chatfield jdc@xinside.comJeremy Lea reg@shale.csir.co.zaJeremy Prior unknownJeroen Ruigrok/Asmodai asmodai@wxs.nlJesse Rosenstock jmr@ugcs.caltech.eduJian-Da Li jdli@csie.nctu.edu.twJim Babb babb@FreeBSD.orgJim Binkley jrb@cs.pdx.eduJim Carroll jim@carroll.comJim Flowers jflowers@ezo.netJim Leppek jleppek@harris.comJim Lowe james@cs.uwm.eduJim Mattson jmattson@sonic.netJim Mercer jim@komodo.reptiles.orgJim Mock jim@phrantic.phear.netJim Wilson wilson@moria.cygnus.comJimbo Bahooli
griffin@blackhole.iceworld.orgJin Guojun jin@george.lbl.govJoachim Kuebart unknownJoao Carlos Mendes Luis jonny@jonny.eng.brJochen Pohl jpo.drs@sni.deJoe "Marcus" Clarke marcus@miami.eduJoe Abley jabley@clear.co.nzJoe Jih-Shian Lu jslu@dns.ntu.edu.twJoe Orthoefer j_orthoefer@tia.netJoe Traister traister@mojozone.orgJoel Faedi Joel.Faedi@esial.u-nancy.frJoel Ray Holveck joelh@gnu.orgJoel Sutton sutton@aardvark.apana.org.auJohan Granlund johan@granlund.nuJohan Karlsson k@numeri.campus.luth.seJohan Larsson johan@moon.campus.luth.seJohann Tonsing jtonsing@mikom.csir.co.zaJohannes Helander unknownJohannes Stille unknownJohn Baldwin jobaldwi@vt.eduJohn Beckett jbeckett@southern.eduJohn Beukema jbeukema@hk.super.netJohn Brezak unknownJohn Capo jc@irbs.comJohn F. Woods jfw@jfwhome.funhouse.comJohn Goerzen
jgoerzen@alexanderwohl.complete.orgJohn Hay jhay@mikom.csir.co.zaJohn Heidemann johnh@isi.eduJohn Hood cgull@owl.orgJohn Kohl unknownJohn Lind john@starfire.mn.orgJohn Mackin john@physiol.su.oz.auJohn P johnp@lodgenet.comJohn Perry perry@vishnu.alias.netJohn Preisler john@vapornet.comJohn Rochester jr@cs.mun.caJohn Sadler john_sadler@alum.mit.eduJohn Saunders john@pacer.nlc.net.auJohn W. DeBoskey jwd@unx.sas.comJohn Wehle john@feith.comJohn Woods jfw@eddie.mit.eduJon Morgan morgan@terminus.trailblazer.comJonathan H N Chin jc254@newton.cam.ac.ukJonathan Hanna
jh@pc-21490.bc.rogers.wave.caJorge Goncalves j@bug.fe.up.ptJorge M. Goncalves ee96199@tom.fe.up.ptJos Backus jbackus@plex.nlJose M. Alcaide jose@we.lc.ehu.esJosef Grosch
jgrosch@superior.mooseriver.comJosef Karthauser joe@uk.freebsd.orgJoseph Stein joes@wstein.comJosh Gilliam josh@quick.netJosh Tiefenbach josh@ican.netJuergen Lock nox@jelal.hb.north.deJuha Inkari inkari@cc.hut.fiJukka A. Ukkonen jua@iki.fiJulian Assange proff@suburbia.netJulian Coleman j.d.coleman@ncl.ac.ukJulian H. Stacey jhs@freebsd.orgJulian Jenkins kaveman@magna.com.auJunichi Satoh junichi@jp.freebsd.orgJunji SAKAI sakai@jp.freebsd.orgJunya WATANABE junya-w@remus.dti.ne.jpK.Higashino a00303@cc.hc.keio.ac.jpKUNISHIMA Takeo kunishi@c.oka-pu.ac.jpKai Vorma vode@snakemail.hut.fiKaleb S. Keithley kaleb@ics.comKaneda Hiloshi vanitas@ma3.seikyou.ne.jpKapil Chowksey kchowksey@hss.hns.comKarl Denninger karl@mcs.comKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comKato Takenori
kato@eclogite.eps.nagoya-u.ac.jpKawanobe Koh kawanobe@st.rim.or.jpKazuhiko Kiriyama kiri@kiri.toba-cmt.ac.jpKazuo Horikawa horikawa@jp.FreeBSD.orgKees Jan Koster kjk1@ukc.ac.ukKeith Bostic bostic@bostic.comKeith E. Walker unknownKeith Moore unknownKeith Sklower unknownKen Hornstein unknownKen Key key@cs.utk.eduKen Mayer kmayer@freegate.comKenji Saito marukun@mx2.nisiq.netKenji Tomita tommyk@da2.so-net.or.jpKenneth Furge kenneth.furge@us.endress.comKenneth Monville desmo@bandwidth.orgKenneth R. Westerback krw@tcn.netKenneth Stailey kstailey@gnu.ai.mit.eduKent Talarico kent@shipwreck.tsoft.netKent Vander Velden graphix@iastate.eduKentaro Inagaki JBD01226@niftyserve.ne.jpKevin Bracey kbracey@art.acorn.co.ukKevin Day toasty@dragondata.comKevin Lahey kml@nas.nasa.govKevin Street street@iname.comKevin Van Maren vanmaren@fast.cs.utah.eduKiroh HARADA kiroh@kh.rim.or.jpKlaus Klein kleink@layla.inka.deKlaus-J. Wolf Yanestra@t-online.deKoichi Sato copan@ppp.fastnet.or.jpKostya Lukin lukin@okbmei.msk.suKouichi Hirabayashi kh@mogami-wire.co.jpKurt D. Zeilenga Kurt@Boolean.NETKurt Olsen kurto@tiny.mcs.usu.eduL. Jonas Olsson
ljo@ljo-slip.DIALIN.CWRU.EduLars Köller
Lars.Koeller@Uni-Bielefeld.DELarry Altneu larry@ALR.COMLaurence Lopez lopez@mv.mv.comLee Cremeans lcremean@tidalwave.netLiang Tai-hwa
avatar@www.mmlab.cse.yzu.edu.twLon Willett lon%softt.uucp@math.utah.eduLouis A. Mamakos louie@TransSys.COMLouis Mamakos loiue@TransSys.comLucas James Lucas.James@ldjpc.apana.org.auLyndon Nerenberg lyndon@orthanc.comM.C. Wong unknownMANTANI Nobutaka nobutaka@nobutaka.comMIHIRA Sanpei Yoshiro sanpei@sanpei.orgMITA Yoshio mita@jp.FreeBSD.ORGMITSUNAGA Noriaki
mitchy@er.ams.eng.osaka-u.ac.jpMOROHOSHI Akihiko moro@race.u-tokyo.ac.jpMagnus Enbom dot@tinto.campus.luth.seMahesh Neelakanta mahesh@gcomm.comMakoto MATSUSHITA matusita@jp.freebsd.orgMakoto WATANABE
watanabe@zlab.phys.nagoya-u.ac.jpMalte Lance malte.lance@gmx.netManu Iyengar
iyengar@grunthos.pscwa.psca.comMarc Frajola marc@dev.comMarc Ramirez mrami@mramirez.sy.yale.eduMarc Slemko marcs@znep.comMarc van Kempen wmbfmk@urc.tue.nlMarcel Moolenaar marcel@scc.nlMario Sergio Fujikawa Ferreira
lioux@gns.com.brMark Andrews unknownMark Cammidge mark@gmtunx.ee.uct.ac.zaMark Diekhans markd@grizzly.comMark Huizer xaa@stack.nlMark J. Taylor mtaylor@cybernet.comMark Krentel krentel@rice.eduMark Mayo markm@vmunix.comMark Thompson thompson@tgsoft.comMark Tinguely tinguely@plains.nodak.eduMark Treacy unknownMark Valentine mark@linus.demon.co.ukMartin BirgmeierMartin Ibert mib@ppe.bb-data.deMartin Kammerhofer dada@sbox.tu-graz.ac.atMartin Renters martin@tdc.on.caMartti Kuparinen
martti.kuparinen@ericsson.comMasachika ISHIZUKA
ishizuka@isis.min.ntt.jpMas.TAKEMURA unknownMasafumi NAKANE max@wide.ad.jpMasahiro Sekiguchi
seki@sysrap.cs.fujitsu.co.jpMasanobu Saitoh msaitoh@spa.is.uec.ac.jpMasanori Kanaoka kana@saijo.mke.mei.co.jpMasanori Kiriake seiken@ARGV.ACMasatoshi TAMURA
tamrin@shinzan.kuee.kyoto-u.ac.jpMats Lofkvist mal@algonet.seMatt Bartley mbartley@lear35.cytex.comMatt Thomas matt@3am-software.comMatt White mwhite+@CMU.EDUMatthew C. Mead mmead@Glock.COMMatthew Cashdollar mattc@rfcnet.comMatthew Flatt mflatt@cs.rice.eduMatthew Fuller fullermd@futuresouth.comMatthew N. Dodd winter@jurai.netMatthew Stein matt@bdd.netMatthias Pfaller leo@dachau.marco.deMatthias Scheler tron@netbsd.orgMattias Gronlund
Mattias.Gronlund@sa.erisoft.seMattias Pantzare pantzer@ludd.luth.seMaurice Castro
maurice@planet.serc.rmit.edu.auMax Euston meuston@jmrodgers.comMax Khon fjoe@husky.iclub.nsu.ruMaxim Bolotin max@rsu.ruMicha Class
michael_class@hpbbse.bbn.hp.comMichael Butler imb@scgt.oz.auMichael Butschky butsch@computi.erols.comMichael Clay mclay@weareb.orgMichael Elbel me@FreeBSD.ORGMichael Galassi nerd@percival.rain.comMichael Hancock michaelh@cet.co.jpMichael Hohmuth hohmuth@inf.tu-dresden.deMichael Perlman canuck@caam.rice.eduMichael Petry petry@netwolf.NetMasters.comMichael Reifenberger root@totum.plaut.deMichael Searle searle@longacre.demon.co.ukMichal Listos mcl@Amnesiac.123.orgMichio Karl Jinbo
karl@marcer.nagaokaut.ac.jpMiguel Angel Sagreras
msagre@cactus.fi.uba.arMihoko Tanaka m_tonaka@pa.yokogawa.co.jpMika Nystrom mika@cs.caltech.eduMikael Hybsch micke@dynas.seMikael Karpberg
karpen@ocean.campus.luth.seMike Del repenting@hotmail.comMike Durian durian@plutotech.comMike Durkin mdurkin@tsoft.sf-bay.orgMike E. Matsnev mike@azog.cs.msu.suMike Evans mevans@candle.comMike Grupenhoff kashmir@umiacs.umd.eduMike Hibler mike@marker.cs.utah.eduMike Karels unknownMike McGaughey mmcg@cs.monash.edu.auMike Meyer mwm@shiva.the-park.comMike Mitchell mitchell@ref.tfs.comMike Murphy mrm@alpharel.comMike Peck mike@binghamton.eduMike Spengler mks@msc.eduMikhail A. Sokolov mishania@demos.suMikhail Teterin mi@aldan.ziplink.netMing-I Hseh PA@FreeBSD.ee.Ntu.edu.TWMitsuru IWASAKI iwasaki@pc.jaring.myMonte Mitzelfelt monte@gonefishing.orgMorgan Davis root@io.cts.comMostyn Lewis mostyn@mrl.comMotoyuki Kasahara m-kasahr@sra.co.jpMotoyuki Konno motoyuki@snipe.rim.or.jpMunechika Sumikawa sumikawa@kame.netMurray Stokely murray@cdrom.comN.G.Smith ngs@sesame.hensa.ac.ukNAGAO Tadaaki nagao@cs.titech.ac.jpNAKAJI Hiroyuki
nakaji@zeisei.dpri.kyoto-u.ac.jpNAKAMURA Kazushi nkazushi@highway.or.jpNAKAMURA Motonori
motonori@econ.kyoto-u.ac.jpNIIMI Satoshi sa2c@and.or.jpNOKUBI Hirotaka h-nokubi@yyy.or.jpNadav Eiron nadav@barcode.co.ilNanbor Wang nw1@cs.wustl.eduNaofumi Honda
honda@Kururu.math.sci.hokudai.ac.jpNaoki Hamada nao@tom-yam.or.jpNarvi narvi@haldjas.folklore.eeNathan Ahlstrom nrahlstr@winternet.comNathan Dorfman nathan@rtfm.netNeal Fachan kneel@ishiboo.comNeil Blakey-Milner nbm@rucus.ru.ac.zaNiall Smart rotel@indigo.ieNick Barnes Nick.Barnes@pobox.comNick Handel nhandel@NeoSoft.comNick Hilliard nick@foobar.org&a.nsayer;Nick Williams njw@cs.city.ac.ukNickolay N. Dudorov nnd@itfs.nsk.suNiklas Hallqvist niklas@filippa.appli.seNisha Talagala nisha@cs.berkeley.eduNo Name ZW6T-KND@j.asahi-net.or.jpNo Name adrian@virginia.eduNo Name alex@elvisti.kiev.uaNo Name anto@netscape.netNo Name bobson@egg.ics.nitch.ac.jpNo Name bovynf@awe.beNo Name burg@is.ge.comNo Name chris@gnome.co.ukNo Name colsen@usa.netNo Name coredump@nervosa.comNo Name dannyman@arh0300.urh.uiuc.eduNo Name davids@SECNET.COMNo Name derek@free.orgNo Name devet@adv.IAEhv.nlNo Name djv@bedford.netNo Name dvv@sprint.netNo Name enami@ba2.so-net.or.jpNo Name flash@eru.tubank.msk.suNo Name flash@hway.ruNo Name fn@pain.csrv.uidaho.eduNo Name gclarkii@netport.neosoft.comNo Name gordon@sheaky.lonestar.orgNo Name graaf@iae.nlNo Name greg@greg.rim.or.jpNo Name grossman@cygnus.comNo Name gusw@fub46.zedat.fu-berlin.deNo Name hfir@math.rochester.eduNo Name hnokubi@yyy.or.jpNo Name iaint@css.tuu.utas.edu.auNo Name invis@visi.comNo Name ishisone@sra.co.jpNo Name iverson@lionheart.comNo Name jpt@magic.netNo Name junker@jazz.snu.ac.krNo Name k-sugyou@ccs.mt.nec.co.jpNo Name kenji@reseau.toyonaka.osaka.jpNo Name kfurge@worldnet.att.netNo Name lh@aus.orgNo Name lhecking@nmrc.ucc.ieNo Name mrgreen@mame.mu.oz.auNo Name nakagawa@jp.freebsd.orgNo Name ohki@gssm.otsuka.tsukuba.ac.jpNo Name owaki@st.rim.or.jpNo Name pechter@shell.monmouth.comNo Name pete@pelican.pelican.comNo Name pritc003@maroon.tc.umn.eduNo Name risner@stdio.comNo Name roman@rpd.univ.kiev.uaNo Name root@ns2.redline.ruNo Name root@uglabgw.ug.cs.sunysb.eduNo Name stephen.ma@jtec.com.auNo Name sumii@is.s.u-tokyo.ac.jpNo Name takas-su@is.aist-nara.ac.jpNo Name tamone@eig.unige.chNo Name tjevans@raleigh.ibm.comNo Name tony-o@iij.ad.jp amurai@spec.co.jpNo Name torii@tcd.hitachi.co.jpNo Name uenami@imasy.or.jpNo Name uhlar@netlab.skNo Name vode@hut.fiNo Name wlloyd@mpd.caNo Name wlr@furball.wellsfargo.comNo Name wmbfmk@urc.tue.nlNo Name yamagata@nwgpc.kek.jpNo Name ziggy@ryan.orgNobuhiro Yasutomi nobu@psrc.isac.co.jpNobuyuki Koganemaru
kogane@koganemaru.co.jpNorio Suzuki nosuzuki@e-mail.ne.jpNoritaka Ishizumi graphite@jp.FreeBSD.ORGNoriyuki Soda soda@sra.co.jpOlaf Wagner wagner@luthien.in-berlin.deOleg Sharoiko os@rsu.ruOliver Breuninger ob@seicom.NETOliver Friedrichs oliver@secnet.comOliver Fromme
oliver.fromme@heim3.tu-clausthal.deOliver Laumann
net@informatik.uni-bremen.deOliver Oberdorf oly@world.std.comOlof Johansson offe@ludd.luth.seOsokin Sergey aka oZZ ozz@freebsd.org.ruPace Willisson pace@blitz.comPaco Rosich rosich@modico.eleinf.uv.esPalle Girgensohn girgen@partitur.seParag Patel parag@cgt.comPascal Pederiva pascal@zuo.dec.comPasvorn Boonmark boonmark@juniper.netPatrick Gardella patrick@cre8tivegroup.comPatrick Hausen unknownPaul Antonov apg@demos.suPaul F. Werkowski unknownPaul Fox pgf@foxharp.boston.ma.usPaul Koch koch@thehub.com.auPaul Kranenburg pk@NetBSD.orgPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPaul S. LaFollette, Jr. unknownPaul Saab paul@mu.orgPaul Sandys myj@nyct.netPaul T. Root proot@horton.iaces.comPaul Vixie paul@vix.comPaulo Menezes paulo@isr.uc.ptPaulo Menezes pm@dee.uc.ptPedro A M Vazquez vazquez@IQM.Unicamp.BRPedro Giffuni giffunip@asme.orgPete Bentley pete@demon.netPeter Childs pjchilds@imforei.apana.org.auPeter Cornelius pc@inr.fzk.dePeter Haight peterh@prognet.comPeter Jeremy perer.jeremy@alcatel.com.auPeter M. Chen pmchen@eecs.umich.eduPeter Much peter@citylink.dinoex.sub.orgPeter Olsson unknownPeter Philipp pjp@bsd-daemon.netPeter Stubbs PETERS@staidan.qld.edu.auPhil Maker pjm@cs.ntu.edu.auPhil Sutherland
philsuth@mycroft.dialix.oz.auPhil Taylor phil@zipmail.co.ukPhilip Musumeci philip@rmit.edu.auPierre Y. Dampure pierre.dampure@k2c.co.ukPius Fischer pius@ienet.comPomegranate daver@flag.blackened.netPowerdog Industries
kevin.ruddy@powerdog.comR. Kym HorsellRajesh Vaidheeswarran rv@fore.comRalf Friedl friedl@informatik.uni-kl.deRandal S. Masutani randal@comtest.comRandall Hopper rhh@ct.picker.comRandall W. Dean rwd@osf.orgRandy Bush rbush@bainbridge.verio.netReinier Bezuidenhout
rbezuide@mikom.csir.co.zaRemy Card Remy.Card@masi.ibp.frRicardas Cepas rch@richard.eu.orgRiccardo Veraldi veraldi@cs.unibo.itRichard Henderson richard@atheist.tamu.eduRichard Hwang rhwang@bigpanda.comRichard J Kuhns rjk@watson.grauel.comRichard M. Neswold
rneswold@drmemory.fnal.govRichard Seaman, Jr. dick@tar.comRichard Stallman rms@gnu.ai.mit.eduRichard Straka straka@user1.inficad.comRichard Tobin richard@cogsci.ed.ac.ukRichard Wackerbarth rkw@Dataplex.NETRichard Winkel rich@math.missouri.eduRichard Wiwatowski rjwiwat@adelaide.on.netRick Macklem rick@snowhite.cis.uoguelph.caRick Macklin unknownRob Austein sra@epilogue.comRob Mallory rmallory@qualcomm.comRob Snow rsnow@txdirect.netRobert Crowe bob@speakez.comRobert D. Thrush rd@phoenix.aii.comRobert Eckardt
roberte@MEP.Ruhr-Uni-Bochum.deRobert Sanders rsanders@mindspring.comRobert Sexton robert@kudra.comRobert Shady rls@id.netRobert Swindells swindellsr@genrad.co.ukRobert Watson robert@cyrus.watson.orgRobert Withrow witr@rwwa.comRobert Yoder unknownRobin Carey
robin@mailgate.dtc.rankxerox.co.ukRoger Hardiman roger@cs.strath.ac.ukRoland Jesse jesse@cs.uni-magdeburg.deRon Bickers rbickers@intercenter.netRon Lenk rlenk@widget.xmission.comRonald Kuehn kuehn@rz.tu-clausthal.deRudolf Cejka unknownRuslan Belkin rus@home2.UA.netRuslan Ermilov ru@ucb.crimea.uaRuslan Shevchenko rssh@cam.grad.kiev.uaRussell L. Carter rcarter@pinyon.orgRussell Vincent rv@groa.uct.ac.zaRyan Younce ryany@pobox.comSANETO Takanori sanewo@strg.sony.co.jpSAWADA Mizuki miz@qb3.so-net.ne.jpSUGIMURA Takashi sugimura@jp.FreeBSD.ORGSURANYI Peter
suranyip@jks.is.tsukuba.ac.jpSakari Jalovaara sja@tekla.fiSam Hartman hartmans@mit.eduSamuel Lam skl@ScalableNetwork.comSamuele Zannoli zannoli@cs.unibo.itSander Vesik sander@haldjas.folklore.eeSandro Sigala ssigala@globalnet.itSascha Blank blank@fox.uni-trier.deSascha Wildner swildner@channelz.GUN.deSatoh Junichi junichi@astec.co.jpScot Elliott scot@poptart.orgScot W. Hetzel hetzels@westbend.netScott A. Kenney saken@rmta.ml.orgScott Blachowicz
scott.blachowicz@seaslug.orgScott Burris scott@pita.cns.ucla.eduScott Hazen Mueller scott@zorch.sf-bay.orgScott Michel scottm@cs.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSebastian Strollo seb@erix.ericsson.seSeigou TANIMURA
tanimura@naklab.dnj.ynu.ac.jpSerge A. Babkin babkin@hq.icb.chel.suSerge V. Vakulenko vak@zebub.msk.suSergei Chechetkin
csl@whale.sunbay.crimea.uaSergei S. Laskavy laskavy@pc759.cs.msu.suSergey Gershtein sg@mplik.ruSergey Potapov sp@alkor.ruSergey Shkonda serg@bcs.zp.uaSergey V.Dorokhov svd@kbtelecom.nalnet.ruSergio Lenzi lenzi@bsi.com.brShaun Courtney shaun@emma.eng.uct.ac.zaShawn M. Carey smcarey@mailbox.syr.eduSheldon Hearn axl@iafrica.comShigio Yamaguchi shigio@wafu.netgate.netShinya Esu esu@yk.rim.or.jpShunsuke Akiyama akiyama@jp.freebsd.orgSimon simon@masi.ibp.frSimon Burge simonb@telstra.com.auSimon J Gerraty sjg@melb.bull.oz.auSimon Marlow simonm@dcs.gla.ac.ukSimon Shapiro shimon@simon-shapiro.orgSin'ichiro MIYATANI siu@phaseone.co.jpSlaven Rezic eserte@cs.tu-berlin.deSoochon Radee slr@mitre.orgSoren Dayton csdayton@midway.uchicago.eduSoren Dossing sauber@netcom.comSoren S. Jorvang soren@dt.dkStefan Bethke stb@hanse.deStefan Eggers seggers@semyam.dinoco.deStefan Moeding s.moeding@ndh.netStefan Petri unknownStefan `Sec` Zehl sec@42.orgSteinar Haug sthaug@nethelp.noStephane E. Potvin sepotvin@videotron.caStephane Legrand stephane@lituus.frStephen Clawson
sclawson@marker.cs.utah.eduStephen F. Combs combssf@salem.ge.comStephen Farrell stephen@farrell.orgStephen Hocking sysseh@devetir.qld.gov.auStephen J. Roznowski sjr@home.netStephen McKay syssgm@devetir.qld.gov.auStephen Melvin melvin@zytek.comSteve Bauer sbauer@rock.sdsmt.eduSteve Coltrin spcoltri@io.comSteve Deering unknownSteve Gerakines steve2@genesis.tiac.netSteve Gericke steveg@comtrol.comSteve Piette steve@simon.chi.il.USSteve Schwarz schwarz@alpharel.comSteven G. Kargl
kargl@troutmask.apl.washington.eduSteven H. Samorodin samorodi@NUXI.comSteven McCanne mccanne@cs.berkeley.eduSteven Plite splite@purdue.eduSteven Wallace unknownStuart Henderson
stuart@internationalschool.co.ukSue Blake sue@welearn.com.auSugimoto Sadahiro ixtl@komaba.utmc.or.jpSugiura Shiro ssugiura@duo.co.jpSujal Patel smpatel@wam.umd.eduSune Stjerneby stjerneby@usa.netSuzuki Yoshiaki
zensyo@ann.tama.kawasaki.jpTadashi Kumano kumano@strl.nhk.or.jpTaguchi Takeshi taguchi@tohoku.iij.ad.jpTakahashi Yoshihiro nyan@dd.catv.ne.jpTakahiro Yugawa yugawa@orleans.rim.or.jpTakanori Watanabe
takawata@shidahara1.planet.sci.kobe-u.ac.jpTakashi Mega mega@minz.orgTakashi Uozu j1594016@ed.kagu.sut.ac.jpTakayuki Ariga a00821@cc.hc.keio.ac.jpTakeru NAIKI naiki@bfd.es.hokudai.ac.jpTakeshi Amaike amaike@iri.co.jpTakeshi MUTOH mutoh@info.nara-k.ac.jpTakeshi Ohashi
ohashi@mickey.ai.kyutech.ac.jpTakeshi WATANABE
watanabe@crayon.earth.s.kobe-u.ac.jpTakuya SHIOZAKI
tshiozak@makino.ise.chuo-u.ac.jpTatoku Ogaito tacha@tera.fukui-med.ac.jpTatsumi HOSOKAWA hosokawa@jp.FreeBSD.orgTed Buswell tbuswell@mediaone.netTed Faber faber@isi.eduTed Lemon unknownTerry Lambert terry@lambert.orgTerry Lee terry@uivlsi.csl.uiuc.eduTetsuya Furukawa tetsuya@secom-sis.co.jpTheo de Raadt deraadt@OpenBSD.orgThomas thomas@mathematik.uni-Bremen.deThomas D. Dean tomdean@ix.netcom.comThomas David Rivers rivers@dignus.comThomas G. McWilliams tgm@netcom.comThomas Gellekum
thomas@ghpc8.ihf.rwth-aachen.deThomas Graichen
graichen@omega.physik.fu-berlin.deThomas König
Thomas.Koenig@ciw.uni-karlsruhe.deThomas Ptacek unknownThomas Stevens tas@stevens.orgThomas Stromberg tstrombe@rtci.comThomas Valentino Crimi
tcrimi+@andrew.cmu.eduThomas Wintergerst thomas@lemur.nord.deÞórður Ívarsson
totii@est.isTim Kientzle kientzle@netcom.comTim Singletary
tsingle@sunland.gsfc.nasa.govTim Wilkinson tim@sarc.city.ac.ukTimo J. Rinne tri@iki.fiTodd Miller millert@openbsd.orgTom root@majestix.cmr.noTom tom@sdf.comTom Gray - DCA dcasba@rain.orgTom Hukins tom@eborcom.comTom Jobbins tom@tom.tjTom Pusateri pusateri@juniper.netTom Rush tarush@mindspring.comTom Samplonius tom@misery.sdf.comTomohiko Kurahashi
kura@melchior.q.t.u-tokyo.ac.jpTony Kimball alk@Think.COMTony Li tli@jnx.comTony Lynn wing@cc.nsysu.edu.twTorbjorn Granlund tege@matematik.su.seToshihiko ARAI toshi@tenchi.ne.jpToshihiko SHIMOKAWA toshi@tea.forus.or.jpToshihiro Kanda candy@kgc.co.jpToshiomi Moriki
Toshiomi.Moriki@ma1.seikyou.ne.jpTrefor S. trefor@flevel.co.ukTrevor Blackwell tlb@viaweb.comURATA Shuichiro s-urata@nmit.tmg.nec.co.jpUdo Schweigert ust@cert.siemens.deUgo Paternostro paterno@dsi.unifi.itUlf Kieber kieber@sax.deUlli Linzen ulli@perceval.camelot.deUstimenko Semen semen@iclub.nsu.ruUwe Arndt arndt@mailhost.uni-koblenz.deVadim Chekan vadim@gc.lviv.uaVadim Kolontsov vadim@tversu.ac.ruVadim Mikhailov mvp@braz.ruVan Jacobson van@ee.lbl.govVasily V. Grechishnikov
bazilio@ns1.ied-vorstu.ac.ruVasim Valejev vasim@uddias.diaspro.comVernon J. Schryver vjs@mica.denver.sgi.comVic Abell abe@cc.purdue.eduVille Eerola ve@sci.fiVincent Poy vince@venus.gaianet.netVincenzo Capuano
VCAPUANO@vmprofs.esoc.esa.deVirgil Champlin champlin@pa.dec.comVladimir A. Jakovenko
vovik@ntu-kpi.kiev.uaVladimir Kushnir kushn@mail.kar.netVsevolod Lobko seva@alex-ua.comW. Gerald Hicks wghicks@bellsouth.netW. Richard Stevens rstevens@noao.eduWalt Howard howard@ee.utah.eduWarren Toomey wkt@csadfa.cs.adfa.oz.auWayne Scott wscott@ichips.intel.comWerner Griessl
werner@btp1da.phy.uni-bayreuth.deWes Santee wsantee@wsantee.oz.netWietse Venema wietse@wzv.win.tue.nlWilfredo Sanchez wsanchez@apple.comWiljo Heinen wiljo@freeside.ki.open.deWilko Bulte wilko@yedi.iaf.nlWillem Jan Withagen wjw@surf.IAE.nlWilliam Jolitz withheldWilliam Liao william@tale.netWojtek Pilorz
wpilorz@celebris.bdk.lublin.plWolfgang Helbig helbig@ba-stuttgart.deWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@FreeBSD.orgWu Ching-hong woju@FreeBSD.ee.Ntu.edu.TWYarema yds@ingress.comYaroslav Terletsky ts@polynet.lviv.uaYasuhito FUTATSUKI futatuki@fureai.or.jpYen-Shuo Su yssu@CCCA.NCTU.edu.twYing-Chieh Liao ijliao@csie.NCTU.edu.twYixin Jin yjin@rain.cs.ucla.eduYoshiaki Uchikawa yoshiaki@kt.rim.or.jpYoshihiko OHTA yohta@bres.tsukuba.ac.jpYoshihisa NAKAGAWA
y-nakaga@ccs.mt.nec.co.jpYoshikazu Goto gotoh@ae.anritsu.co.jpYoshimasa Ohnishi
ohnishi@isc.kyutech.ac.jpYoshishige Arai ryo2@on.rim.or.jpYuichi MATSUTAKA matutaka@osa.att.ne.jpYujiro MIYATA
miyata@bioele.nuee.nagoya-u.ac.jpYukihiro Nakai nacai@iname.comYusuke Nawano azuki@azkey.orgYuu Yashiki s974123@cc.matsuyama-u.ac.jpYuval Yarom yval@cs.huji.ac.ilYves Fonk yves@cpcoup5.tn.tudelft.nlYves Fonk yves@dutncp8.tn.tudelft.nlZach Heilig zach@gaffaneys.comZahemszhky Gabor zgabor@code.huZhong Ming-Xun zmx@mail.CDPA.nsysu.edu.twarci vega@sophia.inria.frder Mouse mouse@Collatz.McRCIM.McGill.EDUfrf frf@xocolatl.comEge Rekk aagero@aage.priv.no386BSD Patch Kit Patch Contributors(in alphabetical order by first name):Adam Glass glass@postgres.berkeley.eduAdrian Hall adrian@ibmpcug.co.ukAndrey A. Chernov ache@astral.msk.suAndrew Herbert andrew@werple.apana.org.auAndrew Moore alm@netcom.comAndy Valencia ajv@csd.mot.comjtk@netcom.comArne Henrik Juul arnej@Lise.Unit.NOBakul Shah bvs@bitblocks.comBarry Lustig barry@ictv.comBob Wilcox bob@obiwan.uucpBranko LankesterBrett Lymn blymn@mulga.awadi.com.AUCharles Hannum mycroft@ai.mit.eduChris G. Demetriou
cgd@postgres.berkeley.eduChris Torek torek@ee.lbl.govChristoph Robitschko
chmr@edvz.tu-graz.ac.atDaniel Poirot poirot@aio.jsc.nasa.govDave Burgess burgess@hrd769.brooks.af.milDave Rivers rivers@ponds.uucpDavid Dawes dawes@physics.su.OZ.AUDavid Greenman dg@Root.COMEric J. Haug ejh@slustl.slu.eduFelix Gaehtgens
felix@escape.vsse.in-berlin.deFrank Maclachlan fpm@crash.cts.comGary A. Browning gab10@griffcd.amdahl.comGary Howland gary@hotlava.comGeoff Rehmet csgr@alpha.ru.ac.zaGoran Hammarback goran@astro.uu.seGuido van Rooij guido@gvr.orgGuy Harris guy@auspex.comHavard Eidnes
Havard.Eidnes@runit.sintef.noHerb Peyerl hpeyerl@novatel.cuc.ab.caHolger Veit Holger.Veit@gmd.deIshii Masahiro, R. Kym HorsellJ.T. Conklin jtc@cygnus.comJagane D Sundar jagane@netcom.comJames Clark jjc@jclark.comJames Jegers jimj@miller.cs.uwm.eduJames W. DolterJames da Silva jds@cs.umd.edu et alJay Fenlason hack@datacube.comJim Wilson wilson@moria.cygnus.comJörg Lohse
lohse@tech7.informatik.uni-hamburg.deJörg Wunsch
joerg_wunsch@uriah.heep.sax.deJohn DysonJohn Woods jfw@eddie.mit.eduJordan K. Hubbard jkh@whisker.hubbard.ieJulian Elischer julian@dialix.oz.auJulian Stacey jhs@freebsd.orgKarl Dietz Karl.Dietz@triplan.comKarl Lehenbauer karl@NeoSoft.comkarl@one.neosoft.comKeith Bostic bostic@toe.CS.Berkeley.EDUKen HughesKent Talarico kent@shipwreck.tsoft.netKevin Lahey kml%rokkaku.UUCP@mathcs.emory.edukml@mosquito.cis.ufl.eduMarc Frajola marc@dev.comMark Tinguely tinguely@plains.nodak.edutinguely@hookie.cs.ndsu.NoDak.eduMartin Renters martin@tdc.on.caMichael Clay mclay@weareb.orgMichael Galassi nerd@percival.rain.comMike Durkin mdurkin@tsoft.sf-bay.orgNaoki Hamada nao@tom-yam.or.jpNate Williams nate@bsd.coe.montana.eduNick Handel nhandel@NeoSoft.comnick@madhouse.neosoft.comPace Willisson pace@blitz.comPaul Kranenburg pk@cs.few.eur.nlPaul Mackerras paulus@cs.anu.edu.auPaul Popelka paulp@uts.amdahl.comPeter da Silva peter@NeoSoft.comPhil Sutherland
philsuth@mycroft.dialix.oz.auPoul-Henning Kampphk@FreeBSD.ORGRalf Friedl friedl@informatik.uni-kl.deRick Macklem root@snowhite.cis.uoguelph.caRobert D. Thrush rd@phoenix.aii.comRodney W. Grimes rgrimes@cdrom.comSascha Wildner swildner@channelz.GUN.deScott Burris scott@pita.cns.ucla.eduScott Reynolds scott@clmqt.marquette.mi.usSean Eric Fagan sef@kithrup.comSimon J Gerraty sjg@melb.bull.oz.ausjg@zen.void.oz.auStephen McKay syssgm@devetir.qld.gov.auTerry Lambert terry@icarus.weber.eduTerry Lee terry@uivlsi.csl.uiuc.eduTor Egge Tor.Egge@idi.ntnu.noWarren Toomey wkt@csadfa.cs.adfa.oz.auWiljo Heinen wiljo@freeside.ki.open.deWilliam Jolitz withheldWolfgang Solfrank ws@tools.deWolfgang Stanglmeier wolf@dentaro.GUN.deYuval Yarom yval@cs.huji.ac.il
diff --git a/en_US.ISO_8859-1/books/handbook/ports/chapter.sgml b/en_US.ISO_8859-1/books/handbook/ports/chapter.sgml
index 23009b15fa..dc2cf404cc 100644
--- a/en_US.ISO_8859-1/books/handbook/ports/chapter.sgml
+++ b/en_US.ISO_8859-1/books/handbook/ports/chapter.sgml
@@ -1,4501 +1,4501 @@
Installing Applications: The Ports collectionContributed by &a.jraynard;.The FreeBSD Ports collection allows you to compile and install a very
wide range of applications with a minimum of effort.For all the hype about open standards, getting a program to work on
different versions of Unix in the real world can be a tedious and tricky
business, as anyone who has tried it will know. You may be lucky enough
to find that the program you want will compile cleanly on your system,
install itself in all the right places and run flawlessly “out of
the box”, but this is unfortunately rather rare. With most
programs, you will find yourself doing a fair bit of head-scratching, and
there are quite a few programs that will result in premature greying, or
even chronic alopecia...Some software distributions have attacked this problem by providing
configuration scripts. Some of these are very clever, but they have an
unfortunate tendency to triumphantly announce that your system is
something you have never heard of and then ask you lots of questions that
sound like a final exam in system-level Unix programming (Does
your system's gethitlist function return a const pointer to a fromboz or
a pointer to a const fromboz? Do you have Foonix style unacceptable
exception handling? And if not, why not?).Fortunately, with the Ports collection, all the hard work involved has
already been done, and you can just type make install
and get a working program.Why Have a Ports Collection?The base FreeBSD system comes with a very wide range of tools and
system utilities, but a lot of popular programs are not in the base
system, for good reasons:-Programs that some people cannot live without and other people
cannot stand, such as a certain Lisp-based editor.Programs which are too specialised to put in the base system
(CAD, databases).Programs which fall into the “I must have a look at that
when I get a spare minute” category, rather than
system-critical ones (some languages, perhaps).Programs that are far too much fun to be supplied with a serious
operating system like FreeBSD ;-)However many programs you put in the base system, people will
always want more, and a line has to be drawn somewhere (otherwise
FreeBSD distributions would become absolutely enormous).Obviously it would be unreasonable to expect everyone to port their
favourite programs by hand (not to mention a tremendous amount of
duplicated work), so the FreeBSD Project came up with an ingenious way
of using standard tools that would automate the process.Incidentally, this is an excellent illustration of how “the
Unix way” works in practice by combining a set of simple but very
flexible tools into something very powerful.How Does the Ports Collection Work?Programs are typically distributed on the Internet as a tarball consisting of a Makefile and
the source code for the program and usually some instructions (which are
unfortunately not always as instructive as they could be), with perhaps
a configuration script.The standard scenario is that you FTP down the tarball, extract it
somewhere, glance through the instructions, make any changes that seem
necessary, run the configure script to set things up and use the
standard make program to compile and install the
program from the source.FreeBSD ports still use the tarball mechanism, but use a skeleton to hold the
"knowledge" of how to get the program working on FreeBSD,
rather than expecting the user to be able to work it out. They also
supply their own customised Makefile, so that almost every port
can be built in the same way.If you look at a port skeleton (either on your FreeBSD
system or the
FTP site) and expect to find all sorts of pointy-headed rocket
science lurking there, you may be disappointed by the one or two rather
unexciting-looking files and directories you find there. (We will
discuss in a minute how to go about Getting a port).“How on earth can this do anything?” I hear you cry.
“There is no source code there!”Fear not, gentle reader, all will become clear (hopefully). Let's
see what happens if we try and install a port. I have chosen
ElectricFence, a useful tool for developers,
as the skeleton is more straightforward than most.If you are trying this at home, you will need to be root.&prompt.root; cd /usr/ports/devel/ElectricFence
&prompt.root; make install
>> Checksum OK for ElectricFence-2.0.5.tar.gz.
===> Extracting for ElectricFence-2.0.5
===> Patching for ElectricFence-2.0.5
===> Applying FreeBSD patches for ElectricFence-2.0.5
===> Configuring for ElectricFence-2.0.5
===> Building for ElectricFence-2.0.5
[lots of compiler output...]
===> Installing for ElectricFence-2.0.5
===> Warning: your umask is "0002". If this is not desired, set it to
an appropriate value and install this port again by ``make reinstall''.
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.a /usr/local/lib
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.3 /usr/local/man/man3
===> Compressing manual pages for ElectricFence-2.0.5
===> Registering installation for ElectricFence-2.0.5To avoid confusing the issue, I have completely removed the build
output.If you tried this yourself, you may well have got something like
this at the start:-&prompt.root; make install
>> ElectricFence-2.0.5.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://ftp.doc.ic.ac.uk/Mirrors/sunsite.unc.edu/pub/Linux/devel/lang/c/.The make program has noticed that you did not
have a local copy of the source code and tried to FTP it down so it
could get the job done. I already had the source handy in my example,
so it did not need to fetch it.Let's go through this and see what the make
program was doing.Locate the source code tarball. If it is not available
locally, try to grab it from an FTP site.Run a checksum test on the
tarball to make sure it has not been tampered with, accidentally
truncated, downloaded in ASCII mode, struck by neutrinos while in
transit, etc.Extract the tarball into a temporary work directory.Apply any patches needed to
get the source to compile and run under FreeBSD.Run any configuration script required by the build process and
correctly answer any questions it asks.(Finally!) Compile the code.Install the program executable and other supporting files, man
pages, etc. under the /usr/local hierarchy,
where they will not get mixed up with system programs. This also
makes sure that all the ports you install will go in the same place,
instead of being flung all over your system.Register the installation in a database. This means that, if
you do not like the program, you can cleanly remove all traces of it from your
system.Scroll up to the make output and see if you can
match these steps to it. And if you were not impressed before, you
should be by now!Getting a FreeBSD PortThere are two ways of getting hold of the FreeBSD port for a
program. One requires a FreeBSD CDROM,
the other involves using an Internet
Connection.Compiling ports from CDROMAssuming that your FreeBSD CDROM is in the drive and mounted on
/cdrom (and the mount point
must be /cdrom), you should
then be able to build ports just as you normally do and the port
collection's built in search path should find the tarballs in
/cdrom/ports/distfiles/ (if they exist there)
rather than downloading them over the net.Another way of doing this, if you want to just use the port
skeletons on the CDROM, is to set these variables in
/etc/make.conf:
PORTSDIR= /cdrom/ports
DISTDIR= /tmp/distfiles
WRKDIRPREFIX= /tmpSubstitute /tmp for any place you have enough
free space. Then, just cd to the appropriate
subdirectory under /cdrom/ports and type
make install as usual.
WRKDIRPREFIX will cause the port to be build under
/tmp/cdrom/ports; for instance,
games/oneko will be built under
/tmp/cdrom/ports/games/oneko.There are some ports for which we cannot provide the original
source in the CDROM due to licensing limitations. In that case, you
will need to look at the section on Compiling ports using an Internet
connection.Compiling ports from the InternetIf you do not have a CDROM, or you want to make sure you get the
very latest version of the port you want, you will need to download
the skeleton for the port. Now
this might sound like rather a fiddly job full of pitfalls, but it is
actually very easy.First, if you are running a release version of FreeBSD, make sure
you get the appropriate “upgrade kit” for your release
from the ports web
page. These packages include files that have been updated
since the release that you may need to compile new ports.The key to the skeletons is that the FreeBSD FTP server can create
on-the-fly tarballs for you.
Here is how it works, with the gnats program in the databases
directory as an example (the bits in square brackets are comments. Do
not type them in if you are trying this yourself!):-&prompt.root; cd /usr/ports
&prompt.root; mkdir databases
&prompt.root; cd databases
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports/databases>get gnats.tar
[tars up the gnats skeleton for us]
>quit
&prompt.root; tar xf gnats.tar
[extract the gnats skeleton]
&prompt.root; cd gnats
&prompt.root; make install
[build and install gnats]What happened here? We connected to the FTP server in the usual
way and went to its databases sub-directory.
When we gave it the command get gnats.tar, the FTP
server tarred up the gnats
directory for us.We then extracted the gnats skeleton and went into the gnats
directory to build the port. As we explained earlier, the make process noticed we
did not have a copy of the source locally, so it fetched one before
extracting, patching and building it.Let's try something more ambitious now. Instead of getting a
single port skeleton, let's get a whole sub-directory, for example all
the database skeletons in the ports collection. It looks almost the
same:-&prompt.root; cd /usr/ports
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports>get databases.tar
[tars up the databases directory for us]
>quit
&prompt.root; tar xf databases.tar
[extract all the database skeletons]
&prompt.root; cd databases
&prompt.root; make install
[build and install all the database ports]With half a dozen straightforward commands, we have now got a set
of database programs on our FreeBSD machine! All we did that was
different from getting a single port skeleton and building it was that
we got a whole directory at once, and compiled everything in it at
once. Pretty impressive, no?If you expect to be installing many ports, it is probably worth
downloading all the ports directories.SkeletonsA team of compulsive hackers who have forgotten to eat in a frantic
attempt to make a deadline? Something unpleasant lurking in the FreeBSD
attic? No, a skeleton here is a minimal framework that supplies
everything needed to make the ports magic work.MakefileThe most important component of a skeleton is the Makefile. This
contains various statements that specify how the port should be
compiled and installed. Here is the Makefile for
ElectricFence:-
# New ports collection makefile for: Electric Fence
# Version required: 2.0.5
# Date created: 13 November 1997
# Whom: jraynard
#
# $Id$
#
DISTNAME= ElectricFence-2.0.5
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= devel/lang/c
MAINTAINER= jraynard@freebsd.org
MAN3= libefence.3
do-install:
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
.include <bsd.port.mk>The lines beginning with a "#" sign are comments for the
benefit of human readers (as in most Unix script files).DISTNAME specifies the name of the tarball, but without the
extension.CATEGORIES states what kind of program this is.
In this case, a utility for developers. See the categories section of this
handbook for a complete list.MASTER_SITES is the URL(s) of the master FTP
site, which is used to retrieve the tarball if it is not available on the
local system. This is a site which is regarded as reputable, and is
normally the one from which the program is officially distributed (in
so far as any software is "officially" distributed on the
Internet).MAINTAINER is the email address of the person
who is responsible for updating the skeleton if, for example a new
version of the program comes out.Skipping over the next few lines for a minute, the line
.include <bsd.port.mk> says that the other
statements and commands needed for this port are in a standard file
called bsd.port.mk. As these are the same for
all ports, there is no point in duplicating them all over the place,
so they are kept in a single standard file.This is probably not the place to go into a detailed examination
of how Makefiles work; suffice it to say that the line starting with
MAN3 ensures that the ElectricFence man page is
compressed after installation, to help conserve your precious disk
space. The original port did not provide an
install target, so the three lines from
do-install ensure that the files produced by
this port are placed in the correct destination.The files directoryThe file containing the checksum for the port is called
md5, after the MD5 algorithm used for ports
checksums. It lives in a directory with the slightly confusing name
of files.This directory can also contain other miscellaneous files that are
required by the port and do not belong anywhere else.The patches directoryThis directory contains the patches needed to make everything work
properly under FreeBSD.The pkg directoryThis program contains three quite useful files:-COMMENT — a one-line description of
the program.DESCR — a more detailed
description.PLIST — a list of all the files
that will be created when the program is installed.What to do when a port does not work.Oh. You can do one of four (4) things :Fix it yourself. Technical details on how ports work can be
found in Porting applications.Gripe. This is done by e-mail only! Send
such e-mail to the &a.ports; and please include the name/version of
the port, where you got both the port source & distfile(s) from,
and what the text of the error was.Forget it. This is the easiest for most — very few of the
programs in ports can be classified as essential!Grab the pre-compiled package from a ftp server. The
“master” package collection is on FreeBSD's FTP server
in the packages
directory, though check your local mirror first, please!
These are more likely to work (on the whole) than trying to compile
from source and a lot faster besides! Use the &man.pkg.add.1;
program to install a package file on your
system.Some Questions and AnswersQ. I thought this was going to be a discussion about
modems??!A. Ah. You must be thinking of the serial ports on the back of
your computer. We are using “port” here to mean the
result of “porting” a program from one version of Unix
to another. (It is an unfortunate bad habit of computer people to
use the same word to refer to several completely different
things).Q. I thought you were supposed to use packages to install extra
programs?A. Yes, that is usually the quickest and easiest way of doing
it.Q. So why bother with ports then?A. Several reasons:-The licensing conditions on some software distributions
require that they be distributed as source code, not
binaries.Some people do not trust binary distributions. At least
with source code you can (in theory) read through it and look
for potential problems yourself.If you have some local patches, you will need the source to
add them yourself.You might have opinions on how a program should be compiled
that differ from the person who did the package — some
people have strong views on what optimisation setting should be
used, whether to build debug versions and then strip them or
not, etc. etc.Some people like having code around, so they can read it if
they get bored, hack around with it, borrow from it (licence
terms permitting, of course!) and so on.If you ain't got the source, it ain't software! ;-) Q. What is a patch?A. A patch is a small (usually) file that specifies how to go
from one version of a file to another. It contains text that says,
in effect, things like “delete line 23”, “add
these two lines after line 468” or “change line 197 to
this”. Also known as a “diff”, since it is
generated by a program of that name. Q. What is all this about
tarballs?A. It is a file ending in .tar or
.tar.gz (with variations like
.tar.Z, or even .tgz if
you are trying to squeeze the names into a DOS filesystem).Basically, it is a directory tree that has been archived into a
single file (.tar) and optionally compressed
(.gz). This technique was originally used for
Tape ARchives (hence the
name tar), but it is a widely used way of
distributing program source code around the Internet.You can see what files are in them, or even extract them
yourself, by using the standard Unix tar program, which comes with
the base FreeBSD system, like this:-&prompt.user; tar tvzf foobar.tar.gz
&prompt.user; tar xzvf foobar.tar.gz
&prompt.user; tar tvf foobar.tar
&prompt.user; tar xvf foobar.tar Q. And a checksum?A. It is a number generated by adding up all the data in the
file you want to check. If any of the characters change, the
checksum will no longer be equal to the total, so a simple
comparison will allow you to spot the difference. (In practice, it
is done in a more complicated way to spot problems like
position-swapping, which will not show up with a simplistic
addition).Q. I did what you said for compiling
ports from a CDROM and it worked great until I tried to
install the kermit port:-&prompt.root; make install
>> cku190.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://kermit.columbia.edu/kermit/archives/.Why can it not be found? Have I got a dud CDROM?A. The licensing terms for kermit do not allow us to put the
tarball for it on the CDROM, so you will have to fetch it by hand
— sorry! The reason why you got all those error messages was
because you were not connected to the Internet at the time. Once
you have downloaded it from any of the sites above, you can re-start
the process (try and choose the nearest site to you, though, to save
your time and the Internet's bandwidth).Q. I did that, but when I tried to put it into
/usr/ports/distfiles I got some error about not
having permission.A. The ports mechanism looks for the tarball in
/usr/ports/distfiles, but you will not be able
to copy anything there because it is sym-linked to the CDROM, which
is read-only. You can tell it to look somewhere else by
doing&prompt.root; make DISTDIR=/where/you/put/it installQ. Does the ports scheme only work if you have everything in
/usr/ports? My system administrator says I must
put everything under
/u/people/guests/wurzburger, but it does not
seem to work.A. You can use the PORTSDIR and
PREFIX variables to tell the ports mechanism to
use different directories. For instance,&prompt.root; make PORTSDIR=/u/people/guests/wurzburger/ports installwill compile the port in
/u/people/guests/wurzburger/ports and install
everything under /usr/local.&prompt.root; make PREFIX=/u/people/guests/wurzburger/local installwill compile it in /usr/ports and install
it in /u/people/guests/wurzburger/local.And of course&prompt.root; make PORTSDIR=.../ports PREFIX=.../local installwill combine the two (it is too long to fit on the page if I
write it in full, but I am sure you get the idea).If you do not fancy typing all that in every time you install a
port (and to be honest, who would?), it is a good idea to put these
variables into your environment.Q. I do not have a FreeBSD CDROM, but I would like to have all
the tarballs handy on my system so I do not have to wait for a
download every time I install a port. Is there an easy way to get
them all at once?A. To get every single tarball for the ports collection,
do&prompt.root; cd /usr/ports
&prompt.root; make fetchFor all the tarballs for a single ports directory, do&prompt.root; cd /usr/ports/directory
&prompt.root; make fetchand for just one port — well, I think you have guessed
already.Q. I know it is probably faster to fetch the tarballs from one
of the FreeBSD mirror sites close by. Is there any way to tell the
port to fetch them from servers other than ones listed in the
MASTER_SITES?A. Yes. If you know, for example, ftp.FreeBSD.ORG is much closer than sites
listed in MASTER_SITES, do as following
example.&prompt.root; cd /usr/ports/directory
&prompt.root; make MASTER_SITE_OVERRIDE=ftp://ftp.FreeBSD.ORG/pub/FreeBSD/ports/distfiles/ fetchQ. I want to know what files make is going to need before it
tries to pull them down.A. make fetch-list will display a list of
the files needed for a port.Q. Is there any way to stop the port from compiling? I want to
do some hacking on the source before I install it, but it is a bit
tiresome having to watch it and hit control-C every time.A. Doing make extract will stop it after it
has fetched and extracted the source code.Q. I am trying to make my own port and I want to be able to
stop it compiling until I have had a chance to see if my patches
worked properly. Is there something like make
extract, but for patches?A. Yep, make patch is what you want. You
will probably find the PATCH_DEBUG option useful
as well. And by the way, thank you for your efforts!Q. I have heard that some compiler options can cause bugs. Is
this true? How can I make sure that I compile ports with the right
settings?A. Yes, with version 2.6.3 of gcc (the
version shipped with FreeBSD 2.1.0 and 2.1.5), the
option could result in buggy code unless you
used the option as well.
(Most of the ports don't use ). You
should be able to specify the compiler options
used by something like&prompt.root; make CFLAGS='-O2 -fno-strength-reduce' installor by editing /etc/make.conf, but
unfortunately not all ports respect this. The surest way is to do
make configure, then go into the source directory
and inspect the Makefiles by hand, but this can get tedious if the
source has lots of sub-directories, each with their own
Makefiles.Q. There are so many ports it is hard to find the one I want.
Is there a list anywhere of what ports are available?A. Look in the INDEX file in
/usr/ports. If you would like to search the
ports collection for a keyword, you can do that too. For example,
you can find ports relevant to the LISP programming language
using:&prompt.user; cd /usr/ports
&prompt.user; make search key=lispQ. I went to install the foo port but the
system suddenly stopped compiling it and starting compiling the
bar port. What's going on?A. The foo port needs something that is
supplied with bar — for instance, if
foo uses graphics, bar might
have a library with useful graphics processing routines. Or
bar might be a tool that is needed to compile the
foo port. Q. I installed the
grizzle program from the ports and frankly it is
a complete waste of disk space. I want to delete it but I do not
know where it put all the files. Any clues?A. No problem, just do&prompt.root; pkg_delete grizzle-6.5
Q. Hang on a minute, you have to know the version number to use
that command. You do not seriously expect me to remember that, do
you??A. Not at all, you can find it out by doing&prompt.root; pkg_info -a | grep grizzle
Information for grizzle-6.5:
grizzle-6.5 - the combined piano tutorial, LOGO interpreter and shoot 'em up arcade game.Q. Talking of disk space, the ports directory seems to be
taking up an awful lot of room. Is it safe to go in there and
delete things?A. Yes, if you have installed the program and are fairly
certain you will not need the source again, there is no point in
keeping it hanging around. The best way to do this is&prompt.root; cd /usr/ports
&prompt.root; make cleanwhich will go through all the ports subdirectories and delete
everything except the skeletons for each port.Q. I tried that and it still left all those tarballs or
whatever you called them in the distfiles
directory. Can I delete those as well?A. Yes, if you are sure you have finished with them, those can
go as well.Q. I like having lots and lots of programs to play with. Is
there any way of installing all the ports in one go?A. Just do&prompt.root; cd /usr/ports
&prompt.root; make installQ. OK, I tried that, but I thought it would take a very long
time so I went to bed and left it to get on with it. When I looked
at the computer this morning, it had only done three and a half
ports. Did something go wrong?A. No, the problem is that some of the ports need to ask you
questions that we cannot answer for you (eg “Do you want to
print on A4 or US letter sized paper?”) and they need to have
someone on hand to answer them.Q. I really do not want to spend all day staring at the
monitor. Any better ideas?A. OK, do this before you go to bed/work/the local
park:-&prompt.root cd /usr/ports
&prompt.root; make -DBATCH installThis will install every port that does not
require user input. Then, when you come back, do&prompt.root; cd /usr/ports
&prompt.root; make -DIS_INTERACTIVE installto finish the job.Q. At work, we are using frobble, which is
in your ports collection, but we have altered it quite a bit to get
it to do what we need. Is there any way of making our own packages,
so we can distribute it more easily around our sites?A. No problem, assuming you know how to make patches for your
changes:-&prompt.root; cd /usr/ports/somewhere/frobble
&prompt.root; make extract
&prompt.root; cd work/frobble-2.8
[Apply your patches]
&prompt.root; cd ../..
&prompt.root; make packageQ. This ports stuff is really clever. I am desperate to find
out how you did it. What is the secret?A. Nothing secret about it at all, just look at the
bsd.ports.mk and
bsd.ports.subdir.mk files in your makefiles
directory.Readers with an aversion to intricate shell-scripts are
advised not to follow this link...)Making a port yourselfContributed by &a.jkh;, &a.gpalmer;, &a.asami; &a.obrien;
and &a.hoek;. 28 August 1996.So, now you are interested in making your own port? Great!What follows are some guidelines for creating a new port for
FreeBSD. The bulk of the work is done by
/usr/ports/Mk/bsd.port.mk, which all port Makefiles
include. Please refer to that file for more details on the inner
workings of the ports collection. Even if you don't hack Makefiles
daily, it is well commented, and you will still gain much knowledge from
it.Only a fraction of the overridable variables
(VAR) are mentioned in
this document. Most (if not all) are documented at the start of
bsd.port.mk. This file users a non-standard tab
setting. Emacs and
Vim should recognise the setting on loading
the file. vi or ex can be set
to use the correct value by typing :set tabstop=4
once the file has been loaded.Quick PortingThis section tells you how to do a quick port. In many cases, it
is not enough, but we will see.First, get the original tarball and put it into
DISTDIR, which defaults to
/usr/ports/distfiles.The following assumes that the software compiled out-of-the-box,
i.e., there was absolutely no change required for the port to work
on your FreeBSD box. If you needed to change something, you will
have to refer to the next section too.Writing the MakefileThe minimal Makefile would look something
like this:
# New ports collection makefile for: oneko
# Version required: 1.1b
# Date created: 5 December 1994
# Whom: asami
#
# $Id$
#
DISTNAME= oneko-1.1b
CATEGORIES= games
MASTER_SITES= ftp://ftp.cs.columbia.edu/archives/X11R5/contrib/
MAINTAINER= asami@FreeBSD.ORG
MAN1= oneko.1
MANCOMPRESSED= yes
USE_IMAKE= yes
.include <bsd.port.mk>See if you can figure it out. Do not worry about the contents
of the $Id$ line, it will be filled in
automatically by CVS when the port is imported to our main ports
tree. You can find a more detailed example in the sample Makefile section.Writing the description filesThere are three description files that are required for any
port, whether they actually package or not. They are
COMMENT, DESCR, and
PLIST, and reside in the
pkg subdirectory.COMMENTThis is the one-line description of the port.
Please do not include the package name (or
version number of the software) in the comment. Here is an
example:
A cat chasing a mouse all over the screen.DESCRThis is a longer description of the port. One to a few
paragraphs concisely explaining what the port does is
sufficient.This is not a manual or an in-depth
description on how to use or compile the port! Please
be careful if you are copying from the
README or manpage; too often
they are not a concise description of the port or are in an
awkward format (e.g., manpages have justified spacing). If the
ported software has an official WWW homepage, you should list it
here. Prefix one of the websites with
WWW: so that automated tools will work
correctly.It is recommended that you sign your name at the end of this
file, as in:
This is a port of oneko, in which a cat chases a poor mouse all over
the screen.
:
(etc.)
WWW: http://www.oneko.org/
- Satoshi
asami@cs.berkeley.eduPLISTThis file lists all the files installed by the port. It is
also called the “packing list” because the package is
generated by packing the files listed here. The pathnames are
relative to the installation prefix (usually
/usr/local or
/usr/X11R6). If you are using the
MANn variables (as
you should be), do not list any manpages here.Here is a small example:
bin/oneko
lib/X11/app-defaults/Oneko
lib/X11/oneko/cat1.xpm
lib/X11/oneko/cat2.xpm
lib/X11/oneko/mouse.xpm
@dirrm lib/X11/onekoRefer to the &man.pkg.create.1; man page for details on the
packing list.You should list all the files, but not the name directories,
in the list. Also, if the port creates directories for itself
during installtion, make sure to add @dirrm
lines as necessary to remove them when the port is
deleted.It is recommended that you keep all the filenames in this
file sorted alphabetically. It will make verifying the changes
when you upgrade the port much easier.Creating the checksum fileJust type make makesum. The ports make rules
will automatically generate the file
files/md5.Testing the portYou should make sure that the port rules do exactly what you
want it to do, including packaging up the port. These are the
important points you need to verify.PLIST does not contain anything not
installed by your portPLIST contains everything that is
installed by your portYour port can be installed multiple times using the
reinstall targetYour port cleans up
after itself upon deinstallRecommended test orderingmake installmake packagemake deinstallpkg_add `make package-name`make deinstallmake reinstallmake packageMake sure that there aren't any warnings issued in any of the
package and
deinstall stages, After step 3, check to
see if all the new directories are correctly deleted. Also, try
using the software after step 4, to ensure that is works correctly
when installed from a package.Checking your port with portlintPlease use portlint to see if your port
conforms to our guidelines. The portlint program
is part of the ports collection. In particular, your may want to
check if the Makefile is in
the right shape and the package is named
appropriately.Submitting the portFirst, make sure you have read the Do's and Dont's section.Now that you are happy with your port, the only thing remaining
is to put it in the main FreeBSD ports tree and make everybody else
happy about it too. We do not need your work
directory or the pkgname.tgz package, so delete
them now. Next, simply include the output of shar `find
port_dir` in a bug report and send it with the
&man.send-pr.1; program (see Bug
Reports and General Commentary for more information about
&man.send-pr.1;. If the uncompressed port is larger than 20KB,
you should compress it into a tarfile and use &man.uuencode.1;
before including it in the bug report (uuencoded tarfiles are
acceptable even if the bug report is smaller than 20KB but are not
preferred). Be sure to classify the bug report as category
ports and class
change-request. (Do not mark the report
confidential!)One more time, do not include the original source
distfile, the work directory, or the package
you built with make package.In the past, we asked you to upload new port submissions in
our ftp site (ftp.freebsd.org). This
is no longer recommended as read access is turned off on that
incoming/ directory of that site due to the
large amount of pirated software showing up there.We will look at your port, get back to you if necessary, and put
it in the tree. Your name will also appear in the list of
“Additional FreeBSD contributors” on the FreeBSD
Handbook and other files. Isn't that great?!? :)Slow PortingOk, so it was not that simple, and the port required some
modifications to get it to work. In this section, we will explain,
step by step, how to modify it to get it to work with the ports
paradigm.How things workFirst, this is the sequence of events which occurs when the user
first types make in your port's directory, and
you may find that having bsd.port.mk in another
window while you read this really helps to understand it.But do not worry if you do not really understand what
bsd.port.mk is doing, not many people do...
:>The fetch target is run. The
fetch target is responsible for making
sure that the tarball exists locally in
DISTDIR. If fetch
cannot find the required files in DISTDIR it
will look up the URL MASTER_SITES, which is
set in the Makefile, as well as our main ftp site at ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/,
where we put sanctioned distfiles as backup. It will then
attempt to fetch the named distribution file with
FETCH, assuming that the requesting site has
direct access to the Internet. If that succeeds, it will save
the file in DISTDIR for future use and
proceed.The extract target is run. It
looks for your port's distribution file (typically a gzip'd
tarball) in DISTDIR and unpacks it into a
temporary subdirectory specified by WRKDIR
(defaults to work).The patch target is run. First,
any patches defined in PATCHFILES are
applied. Second, if any patches are found in
PATCHDIR (defaults to the
patches subdirectory), they are applied at
this time in alphabetical order.The configure target is run. This
can do any one of many different things.If it exists, scripts/configure is
run.If HAS_CONFIGURE or
GNU_CONFIGURE is set,
WRKSRC/configure is
run.If USE_IMAKE is set,
XMKMF (default: xmkmf
-a) is run.The build target is run. This is
responsible for descending into the port's private working
directory (WRKSRC) and building it. If
USE_GMAKE is set, GNU make
will be used, otherwise the system make will
be used.The above are the default actions. In addition, you can define
targets
pre-something or
post-something,
or put scripts with those names, in the scripts
subdirectory, and they will be run before or after the default
actions are done.For example, if you have a post-extract
target defined in your Makefile, and a file
pre-build in the scripts
subdirectory, the post-extract target will
be called after the regular extraction actions, and the
pre-build script will be executed before the
default build rules are done. It is recommended that you use
Makefile targets if the actions are simple
enough, because it will be easier for someone to figure out what
kind of non-default action the port requires.The default actions are done by the
bsd.port.mk targets
do-something.
For example, the commands to extract a port are in the target
do-extract. If you are not happy with the
default target, you can fix it by redefining the
do-something
target in your Makefile.The “main” targets (e.g.,
extract,
configure, etc.) do nothing more than
make sure all the stages up to that one are completed and call
the real targets or scripts, and they are not intended to be
changed. If you want to fix the extraction, fix
do-extract, but never ever touch
extract!Now that you understand what goes on when the user types
make, let us go through the recommended steps to
create the perfect port.Getting the original sourcesGet the original sources (normally) as a compressed tarball
(foo.tar.gz or
foo.tar.Z) and copy
it into DISTDIR. Always use
mainstream sources when and where you
can.If you cannot find a ftp/http site that is well-connected to the
net, or can only find sites that have irritatingly non-standard
formats, you might want to put a copy on a reliable ftp or http
server that you control (e.g., your home page). Make sure you set
MASTER_SITES to reflect your choice.If you cannot find somewhere convenient and reliable to put the
distfile (if you are a FreeBSD committer, you can just put it in
your public_html/ directory on
freefall), we can “house” it ourselves
by putting it on
ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/LOCAL_PORTS/
as the last resort. Please refer to this location as
MASTER_SITE_LOCAL. Send mail to the &a.ports;if
you are not sure what to do.If your port's distfile changes all the time for no good reason,
consider putting the distfile in your home page and listing it as
the first MASTER_SITES. This will prevent users
from getting checksum mismatch errors, and
also reduce the workload of maintainers of our ftp site. Also, if
there isonly one master site for the port, it is recommended that
you house a backup at your site and list it as the second
MASTER_SITES.If your port requires some additional `patches' that are
available on the Internet, fetch them too and put them in
DISTDIR. Do not worry if they come from a site
other than where you got the main source tarball, we have a way to
handle these situations (see the description of PATCHFILES below).Modifying the portUnpack a copy of the tarball in a private directory and make
whatever changes are necessary to get the port to compile properly
under the current version of FreeBSD. Keep careful
track of everything you do, as you will be automating
the process shortly. Everything, including the deletion, addition
or modification of files should be doable using an automated script
or patch file when your port is finished.If your port requires significant user interaction/customization
to compile or install, you should take a look at one of Larry Wall's
classic Configure scripts and perhaps do
something similar yourself. The goal of the new ports collection is
to make each port as “plug-and-play” as possible for the
end-user while using a minimum of disk space.Unless explicitly stated, patch files, scripts, and other
files you have created and contributed to the FreeBSD ports
collection are assumed to be covered by the standard BSD copyright
conditions.PatchingIn the preparation of the port, files that have been added or
changed can be picked up with a recursive diff for later feeding to
patch. Each set of patches you wish to apply should be collected
into a file named
patch-xx where
xx denotes the sequence in which the
patches will be applied — these are done in
alphabetical order, thus aa
first, ab second and so on. These files should
be stored in PATCHDIR, from where they will be
automatically applied. All patches should be relative to
WRKSRC (generally the directory your port's
tarball unpacks itself into, that being where the build is done).
To make fixes and upgrades easier, you should avoid having more than
one patch fix the same file (e.g., patch-aa and
patch-ab both changing
WRKSRC/foobar.c).ConfiguringInclude any additional customization commands to your
configure script and save it in the
scripts subdirectory. As mentioned above, you
can also do this as Makefile targets and/or
scripts with the name pre-configure or
post-configure.Handling user inputIf your port requires user input to build, configure or install,
then set IS_INTERACTIVE in your Makefile. This
will allow “overnight builds” to skip your port if the
user sets the variable BATCH in his environment (and
if the user sets the variable INTERACTIVE, then
only those ports requiring interaction are
built).It is also recommended that if there are reasonable default
answers to the questions, you check the
PACKAGE_BUILDING variable and turn off the
interactive script when it is set. This will allow us to build the
packages for CD-ROMs and ftp.Configuring the MakefileConfiguring the Makefile is pretty simple, and again we suggest
that you look at existing examples before starting. Also, there is a
sample Makefile in this
handbook, so take a look and please follow the ordering of variables
and sections in that template to make your port easier for others to
read.Now, consider the following problems in sequence as you design
your new Makefile:The original sourceDoes it live in DISTDIR as a standard gzip'd
tarball? If so, you can go on to the next step. If not, you should
look at overriding any of the EXTRACT_CMD,
EXTRACT_BEFORE_ARGS,
EXTRACT_AFTER_ARGS,
EXTRACT_SUFX, or DISTFILES
variables, depending on how alien a format your port's distribution
file is. (The most common case is
EXTRACT_SUFX=.tar.Z, when the tarball is
condensed by regular compress, not gzip.)In the worst case, you can simply create your own
do-extract target to override the default,
though this should be rarely, if ever, necessary.DISTNAMEYou should set DISTNAME to be the base name
of your port. The default rules expect the distribution file list
(DISTFILES) to be named
DISTNAMEEXTRACT_SUFX which, if
it is a normal tarball, is going to be something like
foozolix-1.0.tar.gz for a setting of
DISTNAME=foozolix-1.0.The default rules also expect the tarball(s) to extract into a
subdirectory called
work/DISTNAME, e.g.
work/foozolix-1.0/.All this behavior can be overridden, of course; it simply
represents the most common time-saving defaults. For a port
requiring multiple distribution files, simply set
DISTFILES explicitly. If only a subset of
DISTFILES are actual extractable archives, then
set them up in EXTRACT_ONLY, which will override
the DISTFILES list when it comes to extraction,
and the rest will be just left in DISTDIR for
later use.PKGNAMEIf DISTNAME does not conform to our guidelines for a good package
name, you should set the PKGNAME
variable to something better. See the abovementioned guidelines for
more details.CATEGORIESWhen a package is created, it is put under
/usr/ports/packages/All and links are made from
one or more subdirectories of
/usr/ports/packages. The names of these
subdirectories are specified by the variable
CATEGORIES. It is intended to make life easier
for the user when he is wading through the pile of packages on the
ftp site or the CD-ROM. Please take a look at the existing categories and pick the ones
that are suitable for your port.This list also determines where in the ports tree the port is
imported. If you put more than one category here, it is assumed
that the port files will be put in the subdirectory with the name in
the first category. See the categories section for more
discussion about how to pick the right categories.If you port truly belongs to something that is different from
all the existing ones, you can even create a new category name. In
that case, please send mail to the &a.ports; to propose a new
category.There is no error checking for category names. make
package will happily create a new directory if you
mustype the category name, so be careful!MASTER_SITESRecord the directory part of the ftp/http-URL pointing at the
original tarball in MASTER_SITES. Do not forget
the trailing slash (/)!The make macros will try to use this
specification for grabbing the distribution file with
FETCH if they cannot find it already on the
system.It is recommended that you put multiple sites on this list,
preferably from different continents. This will safeguard against
wide-area network problems, and we are even planning to add support
for automatically determining the closest master site and fetching
from there!If the original tarball is part of one of the following popular
archives: X-contrib, GNU, Perl CPAN, TeX CTAN, or Linux Sunsite, you
refer to those sites in an easy compact form using
MASTER_SITE_XCONTRIB,
MASTER_SITE_GNU,
MASTER_SITE_PERL_CPAN,
MASTER_SITE_TEX_CTAN, and
MASTER_SITE_SUNSITE. Simply set
MASTER_SITE_SUBDIR to the path with in the
archive. Here is an example:
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applicationsThe user can also set the MASTER_SITE_*
variables in /etc/make.conf to override our
choices, and use their favorite mirrors of these popular archives
instead.PATCHFILESIf your port requires some additional patches that are available
by ftp or http, set PATCHFILES to the names of
the files and PATCH_SITES to the URL of the
directory that contains them (the format is the same as
MASTER_SITES).If the patch is not relative to the top of the source tree
(i.e., WKRSRC) because it contains some extra
pathnames, set PATCH_DIST_STRIP accordingly. For
instance, if all the pathnames in the patch have an extra
foozolix-1.0/ in front of the filenames, then set
PATCH_DIST_STRIP=-p1.Do not worry if the patches are compressed, they will be
decompressed automatically if the filenames end with
.gz or .Z.If the patch is distributed with some other files, such as
documentation, in a gzip'd tarball, you can't just use
PATCHFILES. If that is the case, add the name
and the location of the patch tarball to
DISTFILES and MASTER_SITES.
Then, from the pre-patch target, apply the
patch either by running the patch command from there, or copying the
patch file into the PATCHDIR directory and
calling it
patch-xx.Note the tarball will have been extracted alongside the
regular source by then, so there is no need to explicitly extract
it if it is a regular gzip'd or compress'd tarball. If you do the
latter, take extra care not to overwrite something that already
exists in that directory. Also do not forget to add a command to
remove the copied patch in the pre-clean
target.MAINTAINERSet your mail-address here. Please. :)For detailed description of the responsibility of maintainers,
refer to MAINTAINER on
Makefiles section.DependenciesMany ports depend on other ports. There are five variables that
you can use to ensure that all the required bits will be on the
user's machine. There are also some pre-supported dependency
variables for common cases, plus a few more to control the behaviour
of dependencies.LIB_DEPENDSThis variable specifies the shared libraries this port depends
on. It is a list of
lib:dir:target
tuples where lib is the name of the
shared library, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. For example, LIB_DEPENDS=
jpeg\\.9\\.:${PORTSDIR}/graphics/jpeg:install
will check for a shared jpeg library with major version 9, and
descend into the graphics/jpeg subdirectory
of your ports tree to build and install it if it is not found.
The target part can be omitted if it is
equal to DEPENDS_TARGET (which defaults to
install).The lib part is an argument given
to ldconfig -r | grep -wF. There shall be no
reqular expressions in this variable.The dependency is checked twice, once from within the
extract target and then from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system.RUN_DEPENDSThis variable specifies executables or files this port depends
on during run-time. It is a list of
path:dir:target
tuples where path is the name of the
executable or file, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. If path starts with a slash
(/), it is treated as a file and its existence
is tested with test -e; otherwise, it is
assumed to be an executable, and which -s is
used to determine if the program exists in the user's search
path.For example,
RUN_DEPENDS= ${PREFIX}/etc/innd:${PORTSDIR}/news/inn \
wish8.0:${PORTSDIR}/x11-toolkits/tk80will check if the file or directory
/usr/local/etc/innd exists, and build and
install it from the news/inn subdirectory of
the ports tree if it is not found. It will also see if an
executable called wish8.0 is in your search
path, and descend into the x11-toolkits/tk80
subdirectory of your ports tree to build and install it if it is
not found.In this case, innd is actually an
executable; if an executable is in a place that is not expected
to be in a normal user's search path, you should use the full
pathname.The dependency is checked from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system. The target
part can be omitted if it is the same
DEPENDS_TARGET.BUILD_DEPENDSThis variable specifies executables or files this port
requires to build. Like RUN_DEPENDS, it is a
list of
path:dir:target
tuples. For example, BUILD_DEPENDS=
unzip:${PORTSDIR}/archivers/unzip will check
for an executable called unzip, and descend
into the archivers/unzip subdirectory of your
ports tree to build and install it if it is not found.“build” here means everything from extracting to
compilation. The dependency is checked from within the
extract target. The
target part can be omitted if it is
the same as DEPENDS_TARGETFETCH_DEPENDSThis variable specifies executables or files this port
requires to fetch. Like the previous two, it is a list of
path:dir:target
tuples. For example, FETCH_DEPENDS=
ncftp2:${PORTSDIR}/net/ncftp2 will check for an
executable called ncftp2, and descend into the
net/ncftp2 subdirectory of your ports tree to
build and install it if it is not found.The dependency is checked from within the
fetch target. The
target part can be omitted if it is the
same as DEPENDS_TARGET.DEPENDSIf there is a dependency that does not fall into either of the
above four categories, or your port requires to have the source of
the other port extracted in addition to having them installed,
then use this variable. This is a list of
dir:target,
as there is nothing to check, unlike the previous four. The
target part can be omitted if it is the
same as DEPENDS_TARGET.Common dependency variablesDefine USE_XLIB=yes if your port requires
the X Window System to be installed (it is implied by
USE_IMAKE). Define
USE_GMAKE=yes if your port requires GNU
make instead of BSD make.
Define USE_AUTOCONF=yes if your port requires
GNU autoconf to be run. Define USE_QT=yes if
your port uses the latest qt toolkit. Use
USE_PERL5=yes if your port requires version 5
of the perl language. (The last is especially important since
some versions of FreeBSD has perl5 as part of the base system
while others don't.)Notes on dependenciesAs mentioned above, the default target to call when a
dependency is required is DEPENDS_TARGET.
It defaults to install. This is a user
variable; is is never defined in a port's
Makefile. If your port needs a special way
to handle a dependency, use the :target part of
the *_DEPENDS variables instead of redefining
DEPENDS_TARGET.When you type make clean, its dependencies
are automatically cleaned too. If you do not wish this to happen,
define the variable NOCLEANDEPENDS in your
environment.To depend on another port unconditionally, it is customary to
use the string nonexistent as the first field
of BUILD_DEPENDS or
RUN_DEPENDS. Use this only when you need to
the to get to the source of the other port. You can often save
compilation time by specifying the target too. For
instance
BUILD_DEPENDS= /nonexistent:${PORTSDIR}/graphics/jpeg:extract
will always descend to the JPEG port and extract it.Do not use DEPENDS unless there is no other
way the behaviour you want can be accomplished. It will cause the
other port to be always build (and installed, by default), and the
dependency will go into the packages as well. If this is really
what you need, I recommend you write it as
BUILD_DEPENDS and
RUN_DEPENDS instead—at least the
intention will be clear.Building mechanismsIf your package uses GNU make, set
USE_GMAKE=yes. If your package uses
configure, set
HAS_CONFIGURE=yes. If your package uses GNU
configure, set
GNU_CONFIGURE=yes (this implies
HAS_CONFIGURE). If you want to give some extra
arguments to configure (the default argument list
--prefix=${PREFIX} for GNU
configure and empty for non-GNU
configure), set those extra arguments in
CONFIGURE_ARGS. If your package uses GNU
autoconf, set
USE_AUTOCONF=yes. This implies
GNU_CONFIGURE, and will cause
autoconf to be run before
configure.If your package is an X application that creates
Makefiles from Imakefiles
using imake, then set
USE_IMAKE=yes. This will cause the configure
stage to automatically do an xmkmf -a. If the
flag is a problem for your port, set
XMKMF=xmkmf. If the port uses
imake but does not understand the
install.man target,
NO_INSTALL_MANPAGES=yes should be set. In
addition, the author of the original port should be shot. :>If your port's source Makefile has
something else than all as the main build
target, set ALL_TARGET accordingly. Same goes
for install and
INSTALL_TARGET.Special considerationsThere are some more things you have to take into account when you
create a port. This section explains the most common of those.ldconfigIf your port installs a shared library, add a
post-install target to your
Makefile that runs ${LDCONFIG}
-m on the directory where the new library is installed
(usually PREFIX/lib) to
register it into the shared library cache.Also, add a matching @exec /sbin/ldconfig -m
and @unexec /sbin/ldconfig -R pair to your
pkg/PLIST file so that a user who installed the
- package can start using teh shared libraru immediately and
+ package can start using the shared library immediately and
deinstallation will not cause the system to still believe the
library is there. These lines should immediately follow the line
for the shared library itself, as in:
lib/libtvl80.so.1
@exec /sbin/ldconfig -m %D/lib
@unexec /sbin/ldconfig -RNever, ever, ever add a line that says
ldconfig without any arguments to your
Makefile or pkg/PLIST.
- This will reset the shared libraru cache to the contents of
+ This will reset the shared library cache to the contents of
/usr/lib only, and will royally screw up the
user's machine ("Help, xinit does not run anymore after I install
this port!"). Anybody who does this will be shot and cut in 65,536
pieces by a rusty knife and have is liver chopped out by a bunch of
crows and will eternally rot to death in the deepest bowels of hell
(not necessarily in that order…)ELF supportSince FreeBSD is moving to ELF shortly after 3.0-RELEASE, we need
to convert many ports that build shared libraries to support ELF.
Complicating this task is that a 3.0 system can run as both ELF and
a.out, and we wish to unofficially support the 2.2 as long as
possible. Below are the guidelines on how to convert a.out only ports
to support both a.out and ELF compilation.Some part of this list is only applicable during the conversion,
but will be left here for awhile for reference in case you have come
across some old port you wish to upgrade.Moving a.out libraries out of the wayA.out libraries should be moved out of
/usr/local/lib and similar to an
aout subdirectory. (If you don't move them out
of the way, ELF ports will happily overwrite a.out libraries.) The
move-aout-libs target in the 3.0-CURRENT
src/Makefile (called from
aout-to-elf) will do this for you. It will
only move a.out libs so it is safe to call it on a system with both
ELF and a.out libs in the standard directories.FormatThe ports tree will build packages in the format the machine is
in. This means a.out for 2.2 and a.out or ELF for 3.0 depending on
what `objformat` returns. Also, once users move
a.out libraries to a subdirectory, building a.out libraries will be
unsupported. (I.e., it may still work if you know what you are
doing, but you are on your own.)If a port only works for a.out, set
BROKEN_ELF to a string describing the reason
why. Such ports will be skipped during a build on an ELF
system.PORTOBJFORMATbsd.port.mk will set
PORTOBJFORMAT to aout or
elf and export it in the environments
CONFIGURE_ENV, SCRIPTS_ENV and
MAKE_ENV. (It's always going to be
aout in 2.2-STABLE). It is also passed to
PLIST_SUB as
PORTOBJFORMAT=${PORTOBJFORMAT}. (See comment on
ldconfig lines below.)The variable is set using this line in
bsd.port.mk:
PORTOBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aoutPorts' make processes should use this variable to decide what to
do. However, if the port's configure script
already automatically detects an ELF system, it is not necessary to
refer to PORTOBJFORMAT.Building shared librariesThe following are differences in handling shared libraries for
a.out and ELF.Shared library versionsAn ELF shared library should be called
libfoo.so.M
where M is the single version number,
and an a.out library should be called
libfoo.so.M.N
where M is the major version and
N is the the minor version number.
Do not mix those; never install an ELF
shared library called
libfoo.so.N.M
or an a.out shared library (or symlink) called
libfoo.so.N.Linker command linesAssuming cc -shared is used rather than
ld directly, the only difference is that you
need to add
on the command line for ELF.You need to install a symlink from
libfoo.so to
libfoo.so.N to make
ELF linkers happy. Since it should be listed in
PLIST too, and it won't hurt in the a.out case
(some ports even require the link for dynamic loading), you should
just make this link regardless of the setting of
PORTOBJFORMAT.LIB_DEPENDSAll port Makefiles are edited to remove minor numbers from
LIB_DEPENDS, and also to have the regexp support
removed. (E.g., foo\\.1\\.\\(33|40\\) becomes
foo.2.) They will be matched using grep
-wF.PLISTPLIST should contain the short (ELF) shlib
names if the a.out minor number is zero, and the long (a.out) names
otherwise. bsd.port.mk will automatically add
.0 to the end of short shlib lines if
PORTOBJFORMAT equals aout, and
will delete the minor number from long shlib names if
PORTOBJFORMAT equals
elf.In cases where you really need to install shlibs with two
versions on an ELF system or those with one version on an a.out
system (for instance, ports that install compatibility libraries for
other operating systems), define the variable
NO_FILTER_SHLIBS. This will turn off the editing
of PLIST mentioned in the previous
paragraph.ldconfigThe ldconfig line in Makefiles should
read:
${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m ....In PLIST it should read;
@exec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -m ...
@unexec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -RThis is to ensure that the correct ldconfig
will be called depending on the format of the package, not the
default format of the system.MASTERDIRIf your port needs to build slightly different versions of
packages by having a variable (for instance, resolution, or paper
size) take different values, create one subdirectory per package to
make it easier forusers to see what to do, but try to share as many
files as possible between ports. Typically you only need a very short
Makefile in all but one of the directories if you
use variables cleverly. In the sole Makefiles,
you can use MASTERDIR to specify the directory
where the rest of the files are. Also, use a variable as part of
PKGNAME so
the packages will have different names.This will be best demonstrated by an example. This is part of
japanese/xdvi300/Makefile;
PKGNAME= ja-xdvi${RESOLUTION}-17
:
# default
RESOLUTION?= 300
.if ${RESOLUTION} != 118 && ${RESOLUTION} != 240 && \
${RESOLUTION} != 300 && ${RESOLUTION} != 400
@${ECHO} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
@${ECHO} "Possible values are: 118, 240, 300 (default) and 400."
@${FALSE}
.endifjapanese/xdvi300 also has all the regular
patches, package files, etc. If you type make
there, it will take the default value for the resolution (300) and
build the port normally.As for other resolutions, this is the entirexdvi118/Makefile;
RESOLUTION= 118
MASTERDIR= ${.CURDIR}/../xdvi300
.include ${MASTERDIR}/Makefile(xdvi240/Makefile and
xdvi400/Makefile are similar). The
MASTERDIR definition tells
bsd.port.mk that the refulat set of
subdirectories like PATCHDIR and
PKGDIR are to be found under
xdvi300. The RESOLUTION=118
line will override the RESOLUTION=300 line in
xdvi300/Makefile and the port will be built with
resolution set to 118.Shared library versionsFirst, please read our policy on
shared library versioning to understand what to do with
shared library versions in general. Do not blindly assume software
authors know what they are doing; many of them do not. It is very
important that these details are carefully considered, as we have
quite a unique situation where we are trying to have dozens of
potentially incompatible software pairs co-exist. Careless port
imports have caused great trouble regarding shared libraries in the
past (ever wondered why the port jpeg-6b has a
shared library version of 9.0?). If in doubt, send a message to the
&a.ports;. Most of the time, your job ends by determining the right
shared library version and making appropriate patches to implement
it.However, if there is a port which is a different version of the
same software already in the tree, the situation is much more complex.
In short, the FreeBSD implementation does not allow the user to
specify to the linker which version of shared library to link against
(the linker will always pick the highest numbered version). This
means, if there is a libfoo.so.3.2 and
libfoo.so.4.0 in the system, there is no way to
tell the linker to link a particular application to
libfoo.so.3.2. It is essentially completely
overshadowed in terms of compilation-time linkage. In this case, the
only solution is to rename the base part of the
shared library. For instance, change
libfoo.so.4.0 to
libfoo4.so.1.0 so both version 3.2 and 4.0 can be
linked from other ports.ManpagesThe MAN[1-9LN] variables will automatically add
any manpages to pkg/PLIST (this means you must
not list manpages in the
PLIST—see generating PLIST for more). It also
makes the install stage automatically compress or uncompress manpages
depending on the setting of NOMANCOMPRESS in
/etc/make.conf.To specify whether the manpages are compressed upon installation,
use the MANCOMPRESSED variable. This variable can
take three values, yes, no and
maybe. yes means manpages are
already installed compressed, no means they are
not, and maybe means the software already respects
the value of NOMANCOMPRESS so
bsd.port.mk does not have to do anything
special.MANCOMPRESSED is automatically set to
yes if USE_IMAKE is set and
NO_INSTALL_MANPAGES is not set, and to
no otherwise. You don't have to explicitly define
it unless the default is not suitable for your port.If your port anchors its man tree somewhere other than
PREFIX, you can use the
MANPREFIX to set it. Also, if only manpages in
certain sections go in a non-standard place, such as some Perl modules
ports, you can set individual man paths using
MANsectPREFIX (where
sect is one of 1-9,
L or N).If your manpages go to language-specific subdirectories, set the
name of the languages to MANLANG. The value of
this variable defaults to "" (i.e., English
only).Here is an example that puts it all together.
MAN1= foo.1
MAN3= bar.3
MAN4= baz.4
MANLANG= "" ja
MAN3PREFIX= ${PREFIX}/share/foobar
MANCOMPRESSED= yesThis states that six files are installed by this port;
${PREFIX}/man/man1/foo.1.gz
${PREFIX}/man/ja/man1/foo.1.gz
${PREFIX}/share/foobar/man/man3/bar.3.gz
${PREFIX}/share/foobar/man/ja/man3/bar.3.gz
${PREFIX}/man/man4/baz.4.gz
${PREFIX}/man/ja/man4/baz.4.gzPorts that require MotifThere are many programs that require a Motif library (available
from several commercial vendors, while there is a free clone reported
to be able to run many applications in
x11-toolkits/lesstif) to compile. Since it is a
popular toolkit and their licenses usually permit redistribution of
statically linked binaries, we have made special provisions for
handling ports that require Motif in a way that we can easily compile
binaries linked either dynamically (for people who are compiling from
the port) or statically (for people who distribute packages).REQUIRES_MOTIFIf your port requires Motif, define this variable in the
Makefile. This will prevent people who don't own a copy of Motif
from even attempting to build it.MOTIFLIBThis variable will be set by bsd.port.mk to
be the appropriate reference to the Motif library. Please patch the
source to use this wherever the Motif library is referenced in the
Makefile or
Imakefile.There are two common cases:If the port refers to the Motif library as
-lXm in its Makefile or
Imakefile, simply substitute
${MOTIFLIB} for it.If the port uses XmClientLibs in its
Imakefile, change it to
${MOTIFLIB} ${XTOOLLIB}
${XLIB}.Note that MOTIFLIB (usually) expands to
-L/usr/X11R6/lib -lXm or
/usr/X11R6/lib/libXm.a, so there is no need to
add -L or -l in front.X11 fontsIf your port installs fonts for the X Window system, put them in
X11BASE/lib/X11/fonts/local.
This directory is new to XFree86 release 3.3.3. If it does not exist,
please create it, and print out a message urging the user to update
their XFree86 to 3.3.3 or newer, or at least add this directory to the
font path in /etc/XF86Config.Info filesThe new version of texinfo (included in 2.2.2-RELEASE and onwards)
contains a utility called install-info to add and
delete entries to the dir file. If your port
installs any info documents, please follow this instructions so your
port/package will correctly update the user's
PREFIX/info/dir file. (Sorry
for the length of this section, but is it imperative to weave all the
info files together. If done correctly, it will produce a
beautiful listing, so please bear with me!First, this is what you (as a porter) need to know&prompt.user; install-info --help
install-info [OPTION]... [INFO-FILE [DIR-FILE]]
Install INFO-FILE in the Info directory file DIR-FILE.
Options:
--delete Delete existing entries in INFO-FILE;
don't insert any new entries.
:
--entry=TEXT Insert TEXT as an Info directory entry.
:
--section=SEC Put this file's entries in section SEC of the directory. :This program will not actually install info
files; it merely inserts or deletes entries in the
dir file.Here's a seven-step procedure to convert ports to use
install-info. I will use
editors/emacs as an example.Look at the texinfo sources and make a patch to insert
@dircategory and @direntry
statements to files that don't have them. This is part of my
patch:
--- ./man/vip.texi.org Fri Jun 16 15:31:11 1995
+++ ./man/vip.texi Tue May 20 01:28:33 1997
@@ -2,6 +2,10 @@
@setfilename ../info/vip
@settitle VIP
+@dircategory The Emacs editor and associated tools
+@direntry
+* VIP: (vip). A VI-emulation for Emacs.
+@end direntry
@iftex
@finalout
:The format should be self-explanatory. Many authors leave a
dir file in the source tree that contains all
the entries you need, so look around before you try to write your
own. Also, make sure you look into related ports and make the
section names and entry indentations consistent (we recommend that
all entry text start at the 4th tab stop).Note that you can put only one info entry per file because
of a bug in install-info --delete that
deletes only the first entry if you specify multiple entries in
the @direntry section.You can give the dir entries to
install-info as arguments
( and ) instead
of patching the texinfo sources. I do not think this is a good
idea for ports because you need to duplicate the same information
in three places
(Makefile and
@exec/@unexec of
PLIST; see below). However, if you have a
Japanese (or other multibyte encoding) info files, you will have
to use the extra arguments to install-info
because makeinfo can't handle those texinfo
sources. (See Makefile and
PLIST of japanese/skk
for examples on how to do this).Go back to the port directory and do a make clean;
make and verify that the info files are regenerated
from the texinfo sources. Since the texinfo sources are newer than
the info files, they should be rebuilt when you type
make; but many Makefiles
don't include correct dependencies for info files. In
emacs' case, I had to patch the main
Makefile.in so it will descend into the
man subdirectory to rebuild the info
pages.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Tue Apr 15 00:15:28 1997
@@ -184,7 +184,7 @@
# Subdirectories to make recursively. `lisp' is not included
# because the compiled lisp files are part of the distribution
# and you cannot remake them without installing Emacs first.
-SUBDIR = lib-src src
+SUBDIR = lib-src src man
# The makefiles of the directories in $SUBDIR.
SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile
--- ./man/Makefile.in.org Thu Jun 27 15:27:19 1996
+++ ./man/Makefile.in Tue Apr 15 00:29:52 1997
@@ -66,6 +66,7 @@
${srcdir}/gnu1.texi \
${srcdir}/glossary.texi
+all: info
info: $(INFO_TARGETS)
dvi: $(DVI_TARGETS)The second hunk was necessary because the default target in
the man subdir is called
info, while the main
Makefile wants to call
all. I also deleted the installation of
the info info file because we already have
one with the same name in /usr/share/info
(that patch is not shown here).If there is a place in the Makefile that
is installing the dir file, delete it. Your
port may not be doing it. Also, remove any commands that are
otherwise mucking around with the dir
file.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Mon Apr 14 23:38:07 1997
@@ -368,14 +368,8 @@
if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
then \
(cd ${infodir}; \
- if [ -f dir ]; then \
- if [ ! -f dir.old ]; then mv -f dir dir.old; \
- else mv -f dir dir.bak; fi; \
- fi; \
cd ${srcdir}/info ; \
- (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
- (cd $${thisdir}; chmod a+r ${infodir}/dir); \
for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
(cd $${thisdir}; \
${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
chmod a+r ${infodir}/$$f); \(This step is only necessary if you are modifying an existing
port.) Take a look at pkg/PLIST and delete
anything that is trying to patch up info/dir.
They may be in pkg/INSTALL or some other
file, so search extensively.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/04/15 06:32:12
@@ -15,9 +15,6 @@
man/man1/emacs.1.gz
man/man1/etags.1.gz
man/man1/ctags.1.gz
-@unexec cp %D/info/dir %D/info/dir.bak
-info/dir
-@unexec cp %D/info/dir.bak %D/info/dir
info/cl
info/cl-1
info/cl-2Add a post-install target to the
Makefile to create a dir
file if it is not there. Also, call
install-info with the installed info
files.
Index: Makefile
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 1996/11/19 13:14:40 1.26
+++ Makefile 1997/05/20 10:25:09 1.28
@@ -20,5 +20,11 @@
post-install:
.for file in emacs-19.34 emacsclient etags ctags b2m
strip ${PREFIX}/bin/${file}
.endfor
+ if [ ! -f ${PREFIX}/info/dir ]; then \
+ ${SED} -ne '1,/Menu:/p' /usr/share/info/dir > ${PREFIX}/info/dir; \
+ fi
+.for info in emacs vip viper forms gnus mh-e cl sc dired-x ediff ccmode
+ install-info ${PREFIX}/info/${info} ${PREFIX}/info/dir
+.endfor
.include <bsd.port.mk>Do not use anything other than
/usr/share/info/dir and the above command to
create a new info file. In fact, I'd add the first three lines of
the above patch to bsd.port.mk if you (the
porter) wouldn't have to do it in PLIST by
yourself anyway.Edit PLIST and add equivalent
@exec statements and also
@unexec for pkg_delete. You
do not need to delete info/dir with
@unexec.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/05/20 10:25:12 1.17
@@ -16,7 +14,15 @@
man/man1/etags.1.gz
man/man1/ctags.1.gz
+@unexec install-info --delete %D/info/emacs %D/info/dir
:
+@unexec install-info --delete %D/info/ccmode %D/info/dir
info/cl
info/cl-1
@@ -87,6 +94,18 @@
info/viper-3
info/viper-4
+@exec [ -f %D/info/dir ] || sed -ne '1,/Menu:/p' /usr/share/info/dir > %D/info/dir
+@exec install-info %D/info/emacs %D/info/dir
:
+@exec install-info %D/info/ccmode %D/info/dir
libexec/emacs/19.34/i386--freebsd/cvtmail
libexec/emacs/19.34/i386--freebsd/digest-docThe @unexec install-info --delete
commands have to be listed before the info files themselves so
they can read the files. Also, the @exec
install-info commands have to be after the info
files and the @exec command that creates the
the dir file.Test and admire your
work. :). Check the
dir file before and after each step.The pkg/ subdirectoryThere are some tricks we haven't mentioned yet about the
pkg/ subdirectory that come in handy
sometimes.MESSAGEIf you need to display a message to the installer, you may place
the message in pkg/MESSAGE. This capability is
often useful to display additional installation steps to be taken
after a pkg_add or to display licensing
information.The pkg/MESSAGE file does not need to be
added to pkg/PLIST. Also, it will not get
automatically printed if the user is using the port, not the
package, so you should probably display it from the
post-install target yourself.INSTALLIf your port needs to execute commands when the binary package
is installed with pkg_add you can do this via the
pkg/INSTALL script. This script will
automatically be added to the package, and will be run twice by
pkg_add. The first time will as INSTALL
${PKGNAME} PRE-INSTALL and the second time as
INSTALL ${PKGNAME} POST-INSTALL.
$2 can be tested to determine which mode
the script is being run in. The PKG_PREFIX
environmental variable will be set to the package installation
directory. See &man.pkg.add.1; for
additional information.This script is not run automatically if you install the port
with make install. If you are depending on it
being run, you will have to explicitly call it from your port's
Makefile.REQIf your port needs to determine if it should install or not, you
can create a pkg/REQ “requirements”
script. It will be invoked automatically at
installation/deinstallation time to determine whether or not
installation/deinstallation should proceed.Changing PLIST based on make
variablesSome ports, particularly the p5- ports, need to change their
PLIST depending on what options they are
configured with (or version of perl, in the case of p5- ports). To
make this easy, any instances in the PLIST of
%%OSREL%%, %%PERL_VER%%, and
%%PERL_VERSION%% will be substituted for
appropriately. The value of %%OSREL%% is the
numeric revision of the operating system (e.g.,
2.2.7). %%PERL_VERSION%% is
the full version number of perl (e.g., 5.00502)
and %%PERL_VER%% is the perl version number minus
the patchlevel (e.g., 5.005).If you need to make other substitutions, you can set the
PLIST_SUB variable with a list of
VAR=VALUE
pairs and instances of
%%VAR%%' will be
substituted with VALUE in the
PLIST.For instance, if you have a port that installs many files in a
version-specific subdirectory, you can put something like
OCTAVE_VERSION= 2.0.13
PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION}
in the Makefile and use
%%OCTAVE_VERSION%% wherever the version shows up
in PLIST. That way, when you upgrade the port,
you will not have to change dozens (or in some cases, hundreds) of
lines in the PLIST.This substitution (as well as addition of any man pages) will be done between
the do-install and
post-install targets, by reading from
PLIST and writing to TMPPLIST
(default:
WRKDIR/.PLIST.mktmp). So if
your port builds PLIST on the fly, do so in or
before do-install. Also, if your port
needs to edit the resulting file, do so in
post-install to a file named
TMPPLIST.Changing the names of files in the
pkg subdirectoryAll the filenames in the pkg subdirectory
are defined using variables so you can change them in your
Makefile if need be. This is especially useful
when you are sharing the same pkg subdirectory
among several ports or have to write to one of the above files (see
writing to places other than
WRKDIR for why it is a bad idea to write
directly in to the pkg subdirectory.Here is a list of variable names and their default
values.VariableDefault valueCOMMENT${PKGDIR}/DESCRDESCR${PKGDIR}/DESCRPLIST${PKGDIR}/PLISTPKGINSTALL${PKGDIR}/PKGINSTALLPKGDEINSTALL${PKGDIR}/PKGDEINSTALLPKGREQ${PKGDIR}/REQPKGMESSAGE${PKGDIR}/MESSAGEPlease change these variables rather than overriding
PKG_ARGS. If you change
PKG_ARGS, those files will not correctly be
installed in /var/db/pkg upon install from a
port.Licensing ProblemsSome software packages have restrictive licenses or can be in
violation to the law (PKP's patent on public key crypto, ITAR (export
of crypto software) to name just two of them). What we can do with
them varies a lot, depending on the exact wordings of the respective
licenses.It is your responsibility as a porter to read the licensing
terms of the software and make sure that the FreeBSD project will
not be held accountable of violating them by redistributing the
source or compiled binaries either via ftp or CD-ROM. If in doubt,
please contact the &a.ports;.There are two variables you can set in the Makefile to handle the
situations that arise frequently:If the port has a “do not sell for profit” type of
license, set the variable NO_CDROM to a string
describing the reason why. We will make sure such ports won't go
into the CD-ROM come release time. The distfile and package will
still be available via ftp.If the resulting package needs to be built uniquely for each
site, or the resulting binary package can't be distributed due to
licensing; set the variable NO_PACKAGE to a
string describing the reason why. We will make sure such packages
won't go on the ftp site, nor into the CD-ROM come release time.
The distfile will still be included on both however.If the port has legal restrictions on who can use it (e.g.,
crypto stuff) or has a “no commercial use” license,
set the variable RESTRICTED to be the string
describing the reason why. For such ports, the distfiles/packages
will not be available even from our ftp sites.The GNU General Public License (GPL), both version 1 and 2,
should not be a problem for ports.If you are a committer, make sure you update the
ports/LEGAL file too.UpgradingWhen you notice that a port is out of date compared to the latest
version from the original authors, first make sure you have the latest
port. You can find them in the
ports/ports-current directory of the ftp mirror
sites.The next step is to send a mail to the maintainer, if one is
listed in the port's Makefile. That person may
already be working on an upgrade, or have a reason to not upgrade the
port right now (because of, for example, stability problems of the new
version).If the maintainer asks you to do the upgrade or there isn't any
such person to begin with, please make the upgrade and send the
recursive diff (either unified or context diff is fine, but port
committers appear to prefer unified diff more) of the new and old
ports directories to us (e.g., if your modified port directory is
called superedit and the original as in our tree
is superedit.bak, then send us the result of
diff -ruN superedit.bak superedit). Please examine
the output to make sure all the changes make sense. The best way to
send us the diff is by including it to &man.send-pr.1; (category
ports). Please mention any added or deleted files
in the message, as they have to be explicitly specified to CVS when
doing a commit. If the diff is more than about 20KB, please compress
and uuencode it; otherwise, just include it in as is in the PR.Once again, please use &man.diff.1; and not &man.shar.1; to send
updates to ports.Do's and Dont'sHere is a list of common do's and dont's that you encounter during
the porting process.You should check your own port against this list,
but you can also check ports in the PR database that others have
submitted. Submit any comments on ports you check as described in
Bug Reports and General
Commentary. Checking ports in the PR database will both make
it faster for us to commit them, and prove that you know what you are
doing.Strip BinariesDo strip binaries. If the original source already strips the
binaries, fine; otherwise you should add a
post-install rule to to it yourself. Here is an
example;
post-install:
strip ${PREFIX}/bin/xdlUse the &man.file.1; command on the installed executable to
check whether the binary is stripped or not. If it does not say
not stripped, it is stripped.INSTALL_* macrosDo use the macros provided in bsd.port.mk
to ensure correct modes and ownership of files in your own
*-install targets. They are:INSTALL_PROGRAM is a command to install
binary executables.INSTALL_SCRIPT is a command to install
executable scripts.INSTALL_DATA is a command to install
sharable data.INSTALL_MAN is a command to install
manpages and other documentation (it doesn't compress
anything).These are basically the install command with
all the appropriate flags. See below for an example on how to use
them.WRKDIRDo not write anything to files outside
WRKDIR. WRKDIR is the only
place that is guaranteed to be writable during the port build (see
compiling ports from CDROM for an
example of building ports from a read-only tree). If you need to
modigy some file in PKGDIR, do so by redefining a variable, not by
writing over it.WRKDIRPREFIXMake sure your port honors WRKDIRPREFIX.
Most ports don't have to worry about this. In particular, if you
are referring to a WRKDIR of another port, note
that the correct location is
WRKDIRPREFIXPORTSDIR/subdir/name/work not PORTSDIR/subdir/name/work or .CURDIR/../../subdir/name/work or some such.Also, if you are defining WRKDIR yourself,
make sure you prepend
${WKRDIRPREFIX}${.CURDIR} in the
front.Differentiating operating systems and OS versionsYou may come across code that needs modifications or conditional
compilation based upon what version of UNIX it is running under. If
you need to make such changes to the code for conditional
compilation, make sure you make the changes as general as possible
so that we can back-port code to FreeBSD 1.x systems and cross-port
to other BSD systems such as 4.4BSD from CSRG, BSD/386, 386BSD,
NetBSD, and OpenBSD.The preferred way to tell 4.3BSD/Reno (1990) and newer versions
of the BSD code apart is by using the BSD macro
defined in <sys/param.h>. Hopefully that
file is already included; if not, add the code:
#if (defined(__unix__) || defined(unix)) && !defined(USG)
#include <sys/param.h>
#endifto the proper place in the .c file. We
believe that every system that defines these two symbols has
sys/param.h. If you find a system that
doesn't, we would like to know. Please send mail to the
&a.ports;.Another way is to use the GNU Autoconf style of doing
this:
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h>
#endifDon't forget to add -DHAVE_SYS_PARAM_H to the
CFLAGS in the Makefile for
this method.Once you have sys/param.h included, you may
use:
#if (defined(BSD) && (BSD >= 199103))to detect if the code is being compiled on a 4.3 Net2 code base
or newer (e.g. FreeBSD 1.x, 4.3/Reno, NetBSD 0.9, 386BSD, BSD/386
1.1 and below).Use:
#if (defined(BSD) && (BSD >= 199306))to detect if the code is being compiled on a 4.4 code base or
newer (e.g. FreeBSD 2.x, 4.4, NetBSD 1.0, BSD/386 2.0 or
above).The value of the BSD macro is
199506 for the 4.4BSD-Lite2 code base. This is
stated for informational purposes only. It should not be used to
distinguish between versions of FreeBSD based only on 4.4-Lite vs.
versions that have merged in changes from 4.4-Lite2. The
__FreeBSD__ macro should be used instead.Use sparingly:__FreeBSD__ is defined in all versions of
FreeBSD. Use it if the change you are making
only affects FreeBSD. Porting gotchas like
the use of sys_errlist[] vs
strerror() are Berkeleyisms, not FreeBSD
changes.In FreeBSD 2.x, __FreeBSD__ is defined to
be 2. In earlier versions, it is
1. Later versions will bump it to match
their major version number.If you need to tell the difference between a FreeBSD 1.x
system and a FreeBSD 2.x or 3.x system, usually the right answer
is to use the BSD macros described above. If
there actually is a FreeBSD specific change (such as special
shared library options when using ld) then it
is OK to use __FreeBSD__ and #if
__FreeBSD__ > 1 to detect a FreeBSD 2.x and later
system. If you need more granularity in detecting FreeBSD
systems since 2.0-RELEASE you can use the following:
#if __FreeBSD__ >= 2
#include <osreldate.h>
# if __FreeBSD_version >= 199504
/* 2.0.5+ release specific code here */
# endif
#endifRelease__FreeBSD_version2.0-RELEASE1194112.1-CURRENTs199501, 1995032.0.5-RELEASE1995042.2-CURRENT before 2.11995082.1.0-RELEASE1995112.2-CURRENT before 2.1.51995122.1.5-RELEASE1996072.2-CURRENT before 2.1.61996082.1.6-RELEASE1996122.1.7-RELEASE1996122.2-RELEASE2200002.2.1-RELEASE220000 (no change)2.2-STABLE after 2.2.1-RELEASE220000 (no change)2.2-STABLE after texinfo-3.92210012.2-STABLE after top2210022.2.2-RELEASE2220002.2-STABLE after 2.2.2-RELEASE2220012.2.5-RELEASE2250002.2-STABLE after 2.2.5-RELEASE2250012.2-STABLE after ldconfig -R merge2250022.2.6-RELEASE2260002.2.7-RELEASE2270002.2-STABLE after 2.2.7-RELEASE2270012.2-STABLE after semctl(2) change2270022.2.8-RELEASE2280002.2-STABLE after 2.2.8-RELEASE2280013.0-CURRENT before mount(2) change3000003.0-CURRENT after mount(2) change3000013.0-CURRENT after semctl(2) change3000023.0-CURRENT after ioctl arg changes3000033.0-CURRENT after ELF conversion3000043.0-RELEASE3000053.0-CURRENT after 3.0-RELEASE3000063.0-STABLE after 3/4 branch3000073.1-RELEASE3100003.1-STABLE after 3.1-RELEASE3100014.0-CURRENT after 3/4 branch400000Note that 2.2-STABLE sometimes identifies itself as
“2.2.5-STABLE” after the 2.2.5-RELEASE. The pattern
used to be year followed by the month, but we decided to change it
to a more straightforward major/minor system starting from 2.2.
This is because the parallel development on several branches made
it infeasible to classify the releases simply by their real
release dates. If you are making a port now, you don't have to
worry about old -CURRENTs; they are listed here just for your
reference.In the hundreds of ports that have been done, there have only
been one or two cases where __FreeBSD__ should
have been used. Just because an earlier port screwed up and used it
in the wrong place does not mean you should do so too.Writing something after
bsd.port.mkDo not write anything after the .include
<bsd.port.mk> line. it usually can be avoided by
including bsd.port.pre.mk somewhere in the
middle of your Makefile and
bsd.port.post.mk at the end.You need to include either the
pre.mk/post.mk pair or
bsd.port.mk only; don't mix these two.bsd.port.pre.mk only defines a few
variables, which can be used in tests in the
Makefile, bsd.port.post.mk
defines the rest.Here are some important variables defined in
bsd.port.pre.mk (this is not the complete list,
please read bsd.port.mk for the complete
list).VariableDescriptionARCHThe architecture as returned by uname
-m (e.g., i386)OPSYSThe operating system type, as returned by
uname -s (e.g.,
FreeBSD)OSRELThe release version of the operating system (e.g.,
2.1.5 or
2.2.7)OSVERSIONThe numeric version of the operating system, same as
__FreeBSD_version.PORTOBJFORMATThe object format of the system
(aout or elfLOCALBASEThe base of the “local” tree (e.g.,
/usr/local/)X11BASEThe base of the “X11” tree (e.g.,
/usr/X11R6)PREFIXWhere the port installs itself (see more on
PREFIX).If you have to define the variables
USE_IMAKE, USE_X_PREFIX, or
MASTERDIR, do so before including
bsd.port.pre.mk.Here are some examples of things you can write after
bsd.port.pre.mk;
# no need to compile lang/perl5 if perl5 is already in system
.if ${OSVERSION} > 300003
BROKEN= perl is in system
.endif
# only one shlib version number for ELF
.if ${PORTOBJFORMAT} == "elf"
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}
.else
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}.${SHLIB_MINOR}
.endif
# software already makes link for ELF, but not for a.out
post-install:
.if ${PORTOBJFORMAT} == "aout"
${LN} -sf liblinpack.so.1.0 ${PREFIX}/lib/liblinpack.so
.endifInstall additional documentationIf your software has some documentation other than the standard
man and info pages that you think is useful for the user, install it
under PREFIX/share/doc.
This can be done, like the previous item, in the
post-install target.Create a new directory for your port. The directory name should
reflect what the port is. This usually means
PKGNAME minus the version part. However, if you
think the user might want different versions of the port to be
installed at the same time, you can use the whole
PKGNAME.Make the installation dependent to the variable
NOPORTDOCS so that users can disable it in
/etc/make.conf, like this:
post-install:
.if !defined(NOPORTDOCS)
${MKDIR}${PREFIX}/share/doc/xv
${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${PREFIX}/share/doc/xv
.endifDo not forget to add them to pkg/PLIST too!
(Do not worry about NOPORTDOCS here; there is
currently no way for the packages to read variables from
/etc/make.conf.)Also you can use the pkg/MESSAGE file to
display messages upon installation. See the using
pkg/MESSAGE section for
details.MESSAGE does not need to be added to
pkg/PLIST).DIST_SUBDIRDo not let your port clutter
/usr/ports/distfiles. If your port requires a
lot of files to be fetched, or contains a file that has a name that
might conflict with other ports (e.g.,
Makefile), set DIST_SUBDIR
to the name of the port (PKGNAME without the
version part should work fine). This will change
DISTDIR from the default
/usr/ports/distfiles to
/usr/ports/distfiles/DIST_SUBDIR,
and in effect puts everything that is required for your port into
that subdirectory.It will also look at the subdirectory with the same name on the
backup master site at ftp.freebsd.org.
(Setting DISTDIR explicitly in your
Makefile will not accomplish this, so please use
DIST_SUBDIR.)This does not affect the MASTER_SITES you
define in your Makefile.Package informationDo include package information, i.e.
COMMENT, DESCR, and
PLIST, in pkg.Note that these files are not used only for packaging anymore,
and are mandatory now, even if
NO_PACKAGE is set.RCS stringsDo not put RCS strings in patches. CVS will mangle them when we
put the files into the ports tree, and when we check them out again,
they will come out different and the patch will fail. RCS strings
are surrounded by dollar ($) signs, and
typically start with $Id or
$RCS.Recursive diffUsing the recurse () option to
diff to generate patches is fine, but please take
a look at the resulting patches to make sure you don't have any
unnecessary junk in there. In particular, diffs between two backup
files, Makefiles when the port uses
Imake or GNU configure, etc.,
are unnecessary and should be deleted. If you had to edit
configure.in and run
autoconf to regenerate
configure, do not take the diffs of
configure (it often grows to a few thousand
lines!); define USE_AUTOCONF=yes and take the
diffsof configure.in.Also, if you had to delete a file, then you can do it in the
post-extract target rather than as part of
the patch. Once you are happy with the resulting diff, please split
it up into one source file per patch file.PREFIXDo try to make your port install relative to
PREFIX. (The value of this variable will be set
to LOCALBASE (default
/usr/local), unless
USE_X_PREFIX or USE_IMAKE is
set, in which case it will be X11BASE (default
/usr/X11R6).)Not hard-coding /usr/local or
/usr/X11R6 anywhere in the source will make the
port much more flexible and able to cater to the needs of other
sites. For X ports that use imake, this is
automatic; otherwise, this can often be done by simply replacing the
occurrences of /usr/local (or
/usr/X11R6 for X ports that do not use imake)
in the various scripts/Makefiles in the port to read
PREFIX, as this variable is automatically passed
down to every stage of the build and install processes.Do not set USE_X_PREFIX unless your port
truly require it (i.e., it links against X libs or it needs to
reference files in X11BASE).The variable PREFIX can be reassigned in your
Makefile or in the user's environment.
However, it is strongly discouraged for individual ports to set this
variable explicitly in the Makefiles.Also, refer to programs/files from other ports with the
variables mentioned above, not explicit pathnames. For instance, if
your port requires a macro PAGER to be the full
pathname of less, use the compiler flag:
-DPAGER=\"${PREFIX}/bin/less\"
or
-DPAGER=\"${LOCALBASE}/bin/less\"
if this is an X port, instead of
-DPAGER=\"/usr/local/bin/less\". This way it will
have a better chance of working if the system administrator has
moved the whole `/usr/local' tree somewhere else.SubdirectoriesTry to let the port put things in the right subdirectories of
PREFIX. Some ports lump everything and put it in
the subdirectory with the port's name, which is incorrect. Also,
many ports put everything except binaries, header files and manual
pages in the a subdirectory of lib, which does
not bode well with the BSD paradigm. Many of the files should be
moved to one of the following: etc
(setup/configuration files), libexec
(executables started internally), sbin
(executables for superusers/managers), info
(documentation for info browser) or share
(architecture independent files). See man &man.hier.7; for details,
the rules governing
/usr pretty much apply to
/usr/local too. The exception are ports
dealing with USENET “news”. They may use
PREFIX/news as a destination
for their files.Cleaning up empty directoriesDo make your ports clean up after themselves when they are
deinstalled. This is usually accomplished by adding
@dirrm lines for all directories that are
specifically created by the port. You need to delete subdirectories
before you can delete parent directories.
:
lib/X11/oneko/pixmaps/cat.xpm
lib/X11/oneko/sounds/cat.au
:
@dirrm lib/X11/oneko/pixmals
@dirrm lib/X11/oneko/sounds
@dirrm lib/X11/onekoHowever, sometimes @dirrm will give you
errors because other ports also share the same subdirectory. You
can call rmdir from @unexec to
remove only empty directories without warning.
@unexec rmdir %D/share/doc/gimp 2>/dev/null || trueThis will neither print any error messages nor cause
pkg_delete to exit abnormally even if
PREFIX/share/doc/gimp is not
empty due to other ports installing some files in there.UIDsIf your port requires a certain user to be on the installed
system, let the pkg/INSTALL script call
pw to create it automatically. Look at
net/cvsup-mirror for an example.If your port must use the same user/group ID number when it is
installed a binarypackage as when it was compiled, then you mus
choose a free UID from 50 to 99 and register it below. Look at
japanese/Wnn for an example.Make sure you don't use a UID already used by the system or
other ports. This is the current list of UIDs between 50 and
99.
majordom:*:54:54:Majordomo Pseudo User:/usr/local/majordomo:/nonexistent
cyrus:*:60:60:the cyrus mail server:/nonexistent:/nonexistent
gnats:*:61:1:GNATS database owner:/usr/local/share/gnats/gnats-db:/bin/sh
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/nonexistent
pop:*:68:6:Post Office Owner (popper):/nonexistent:/nonexistent
wnn:*:69:7:Wnn:/nonexistent:/nonexistent
ifmail:*:70:66:Ifmail user:/nonexistent:/nonexistent
pgsql:*:70:70:PostgreSQL pseudo-user:/usr/local/pgsql:/bin/sh
ircd:*:72:72:IRCd hybrid:/nonexistent:/nonexistent
alias:*:81:81:QMail user:/var/qmail/alias:/nonexistent
qmaill:*:83:81:QMail user:/var/qmail:/nonexistent
qmaild:*:82:81:QMail user:/var/qmail:/nonexistent
qmailq:*:85:82:QMail user:/var/qmail:/nonexistent
qmails:*:87:82:QMail user:/var/qmail:/nonexistent
qmailp:*:84:81:QMail user:/var/qmail:/nonexistent
qmailr:*:86:82:QMail user:/var/qmail:/nonexistent
msql:*:87:87:mSQL-2 pseudo-user:/var/db/msqldb:/bin/shPlease include a notice when you submit a port (or an upgrade)
that reserves a new UID or GID in this range. This allows us to
keep the list of reserved IDs up to date.Do things rationallyThe Makefile should do things simply and
reasonably. If you can make it a couple of lines shorter or more
readable, then do so. Examples include using a make
.if construct instead of a shell
if construct, not redefining
do-extract if you can redefine
EXTRACT* instead, and using
GNU_CONFIGURE instead of CONFIGURE_ARGS
+= --prefix=${PREFIX}.Respect CFLAGSThe port should respect the CFLAGS variable.
If it doesn't, please add NO_PACKAGE=ignores
cflags to the Makefile.Configuration filesIf your port requires some configuration files in
PREFIX/etc, do
not just install them and list them in
pkg/PLIST. That will cause
pkg_delete to delete files carefully edited by
the user and a new installation to wipe them out.Instead, install sample files with a suffix
(filename.sample
will work well) and print out a message pointing out that the
user has to copy and edit the file before the software can be made
to work.PortlintDo check your work with portlint
before you submit or commit it.FeedbackDo send applicable changes/patches to the original
author/maintainer for inclusion in next release of the code. This
will only make your job that much easier for the next
release.MiscellaneaThe files pkg/DESCR,
pkg/COMMENT, and pkg/PLIST
should each be double-checked. If you are reviewing a port and feel
they can be worded better, do so.Don't copy more copies of the GNU General Public License into
our system, please.Please be careful to note any legal issues! Don't let us
illegally distribute software!If you are stuck…Do look at existing examples and the
bsd.port.mk file before asking us questions!
;)Do ask us questions if you have any trouble! Do not just beat
your head against a wall! :)A Sample MakefileHere is a sample Makefile that you can use to
create a new port. Make sure you remove all the extra comments (ones
between brackets)!It is recommended that you follow this format (ordering of
variables, empty lines between sections, etc.). This format is
designed so that the most important information is easy to locate. We
recommend that you use portlint to check the
Makefile.
[the header...just to make it easier for us to identify the ports.]
# New ports collection makefile for: xdvi
[the version required header should updated when upgrading a port.]
# Version required: pl18 [things like "1.5alpha" are fine here too]
[this is the date when the first version of this Makefile was created.
Never change this when doing an update of the port.]
# Date created: 26 May 1995
[this is the person who did the original port to FreeBSD, in particular, the
person who wrote the first version of this Makefile. Remember, this should
not be changed when upgrading the port later.]
# Whom: Satoshi Asami <asami@FreeBSD.ORG>
#
# $Id$
[ ^^^^ This will be automatically replaced with RCS ID string by CVS
when it is committed to our repository.]
#
[section to describe the port itself and the master site - DISTNAME
is always first, followed by PKGNAME (if necessary), CATEGORIES,
and then MASTER_SITES, which can be followed by MASTER_SITE_SUBDIR.
After those, one of EXTRACT_SUFX or DISTFILES can be specified too.]
DISTNAME= xdvi
PKGNAME= xdvi-pl18
CATEGORIES= print
[do not forget the trailing slash ("/")!
if you aren't using MASTER_SITE_* macros]
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applications
[set this if the source is not in the standard ".tar.gz" form]
EXTRACT_SUFX= .tar.Z
[section for distributed patches -- can be empty]
PATCH_SITES= ftp://ftp.sra.co.jp/pub/X11/japanese/
PATCHFILES= xdvi-18.patch1.gz xdvi-18.patch2.gz
[maintainer; *mandatory*! This is the person (preferably with commit
privileges) who a user can contact for questions and bug reports - this
person should be the porter or someone who can forward questions to the
original porter reasonably promptly. If you really do not want to have
your address here, set it to "ports@FreeBSD.ORG".]
MAINTAINER= asami@FreeBSD.ORG
[dependencies -- can be empty]
RUN_DEPENDS= gs:${PORTSDIR}/print/ghostscript
LIB_DEPENDS= Xpm.5:${PORTSDIR}/graphics/xpm
[this section is for other standard bsd.port.mk variables that do not
belong to any of the above]
[If it asks questions during configure, build, install...]
IS_INTERACTIVE= yes
[If it extracts to a directory other than ${DISTNAME}...]
WRKSRC= ${WRKDIR}/xdvi-new
[If the distributed patches were not made relative to ${WRKSRC}, you
may need to tweak this]
PATCH_DIST_STRIP= -p1
[If it requires a "configure" script generated by GNU autoconf to be run]
GNU_CONFIGURE= yes
[If it requires GNU make, not /usr/bin/make, to build...]
USE_GMAKE= yes
[If it is an X application and requires "xmkmf -a" to be run...]
USE_IMAKE= yes
[et cetera.]
[non-standard variables to be used in the rules below]
MY_FAVORITE_RESPONSE= "yeah, right"
[then the special rules, in the order they are called]
pre-fetch:
i go fetch something, yeah
post-patch:
i need to do something after patch, great
pre-install:
and then some more stuff before installing, wow
[and then the epilogue]
.include <bsd.port.mk>Package NamesThe following are the conventions you should follow in naming your
packages. This is to have our package directory easy to scan, as
there are already lots and lots of packages and users are going to
turn away if they hurt their eyes!The package name should look like
language-name-compiled.specifics-version.numbers.If your DISTNAME doesn't look like that, set
PKGNAME to something in that format.FreeBSD strives to support the native language of its users.
The language- part should be a two
letter abbreviation of the natural language defined by ISO-639 if
the port is specific to a certain language. Examples are
ja for Japanese, ru for
Russian, vi for Vietnamese,
zh for Chinese, ko for
Korean and de for German.The name part should be all lowercases,
except for a really large package (with lots of programs in it).
Things like XFree86 (yes there really is a port of it, check it
out) and ImageMagick fall into this category. Otherwise, convert
the name (or at least the first letter) to lowercase. If the
capital letters are important to the name (for example, with
one-letter names like R or
V) you may use capital letters at your
discretion. There is a tradition of naming Perl 5 modules by
prepending p5- and converting the double-colon
separator to a hyphen; for example, the
Data::Dumper module becomes
p5-Data-Dumper. If the software in question
has numbers, hyphens, or underscores in its name, you may include
them as well (like kinput2).If the port can be built with different hardcoded defaults (usually
part of the directory name in a family of ports), the
-compiled.specifics part should state
the compiled-in defaults (the hyphen is optional). Examples are
papersize and font units.The version string should be a period-separated list of
integers and single lowercase alphabetics. The only exception is
the string pl (meaning `patchlevel'), which can
be used only when there are no major and
minor version numbers in the software.Here are some (real) examples on how to convert a
DISTNAME into a suitable
PKGNAME:Distribution NamePackage NameReasonmule-2.2.2.mule-2.2.2No changes requiredXFree86-3.1.2XFree86-3.1.2No changes requiredEmiClock-1.0.2emiclock-1.0.2No uppercase names for single programsgmod1.4gmod-1.4Need a hyphen before version numbersxmris.4.0.2xmris-4.0.2Need a hyphen before version numbersrdist-1.3alphardist-1.3aNo strings like alpha
allowedes-0.9-beta1es-0.9b1No strings like beta
allowedv3.3beta021.srctiff-3.3What the heck was that anyway?tvtwmtvtwm-pl11Version string always requiredpiewmpiewm-1.0Version string always requiredxvgr-2.10pl1xvgr-2.10.1pl allowed only when no
major/minor version numbersgawk-2.15.6ja-gawk-2.15.6Japanese language versionpsutils-1.13psutils-letter-1.13Papersize hardcoded at package build timepkfontspkfonts300-1.0Package for 300dpi fontsIf there is absolutely no trace of version information in the
original source and it is unlikely that the original author will ever
release another version, just set the version string to
1.0 (like the piewm example above). Otherwise, ask
the original author or use the date string
(yy.mm.dd) as the version.CategoriesAs you already know, ports are classified in several categories.
But for this to wor, it is important that porters and users understand
what each category and how we deicde what to put in each
category.Current list of categoriesFirst, this is the current list of port categories. Those
marked with an asterisk (*) are
virtual categories—those that do not have
a corresponding subdirectory in the ports tree.For non-virtual categories, you will find a one-line
description in the pkg/COMMENT file in that
subdirectory (e.g.,
archivers/pkg/COMMENT).CategoryDescriptionafterstep*Ports to support AfterStep window managerarchiversArchiving tools.astroAstronomical ports.audioSound support.benchmarksBenchmarking utilities.biologyBiology-related software.cadComputer aided design tools.chineseChinese language support.commsCommunication software. Mostly software to talk to
your serial port.convertersCharacter code converters.databasesDatabases.deskutilsThings that used to be on the desktop before
computers were invented.develDevelopment utilities. Do not put libraries here just
because they are libraries—unless they truly don't
belong to anywhere else, they shouldn't be in this
category.editorsGeneral editors. Specialized editors go in the section
for those tools (e.g., a mathematical-formula editor will go
in math).elispEmacs-lisp ports.emulatorsEmulators for other operating systems. Terminal
emulators do not belong
here—X-based ones should go to
x11 and text-based ones to either
comms or misc,
depending on the exact functionality.gamesGames.germanGerman language support.graphicsGraphics utilities.japaneseJapanese language support.kde*Ports that form the K Desktop Environment
(kde).koreanKorean language support.langProgramming languages.mailMail software.mathNumerical computation software and other utilities
for mathematics.mboneMBone applications.miscMiscellaneous utilities—basically things that
doesn't belong to anywhere else. This is the only category
that should not appear with any other non-virtual category.
If you have misc with something else in
your CATEGORIES line, that means you can
safely delete misc and just put the port
in that other subdirectory!netMiscellaneous networking software.newsUSENET news software.offix*Ports from the OffiX suite.palmSoftware support for the 3Com Palm(tm) series.perl5*Ports that require perl version 5 to run.plan9*Various programs from Plan9.printPrinting software. Desktop publishing tools
(previewers, etc.) belong here too.python*Software written in python.russianRussian language support.securitySecurity utilities.shellsCommand line shells.sysutilsSystem utilities.tcl75*Ports that use tcl version 7.5 to run.tcl76*Ports that use tcl version 7.6 to run.tcl80*Ports that use tcl version 8.0 to run.tcl81*Ports that use tcl version 8.1 to run.textprocText processing utilities. It does not include
desktop publishing tools, which go to print/.tk41*Ports that use tk version 4.1 to run.tk42*Ports that use tk version 4.2 to run.tk80*Ports that use tk version 8.0 to run.tk81*Ports that use tk version 8.1 to run.vietnameseVietnamese language support.windowmaker*Ports to support the WindowMaker window
managerwwwSoftware related to the World Wide Web. HTML language
support belong here too.x11The X window system and friends. This category is only
for software that directly support the window system. Do not
put regular X applications here. If your port is an X
application, define USE_XLIB (implied by
USE_IMAKE) and put it in appropriate
categories. Also, many of them go into other
x11-* categories (see below).x11-clocksX11 clocks.x11-fmX11 file managers.x11-fontsX11 fonts and font utilities.x11-toolkitsX11 toolkits.x11-wmX11 window managers.Choosing the right categoryAs many of the categories overlap, you often have to choose
which of the categories should be the primary category of your port.
There are several rules that govern this usse. Here is the list of
priorities, in decreasing order of precedence.Language specific categories alwasys come first. For
example, if your port installs Japanese X11 fonts, then your
CATEGORIES line would read japanese
x11.Specific categories win over less-specific ones. For
instance, an HTML editor should be listed as www
editors, not the other way around. Also, you don't
need to list net when the port belongs to
either of mail, mbone,
news, security, or
www.x11 is used as a secondary category only
when the primary category is a natural language. In particular,
you should not put x11 in the category line
for X applications.If your port truly does not belong anywhere else, put it in
misc.If you are not sure about the category, please put a comment to
that effect in your send-pr submission so we can
discuss it before import it. (If you are a committer, send a note
&a.ports; so we can discuss it first—too often new ports are
imported to a wrong category only to be moved right away.)Changes to this document and the ports systemIf you maintain a lot of ports, you should consider following the
&a.ports;. Important changes to the way ports work will be announced
there. You can always find more detailed information on the latest
changes by looking at the
bsd.port.mk CVS log.That is It, Folks!Boy, this sure was a long tutorial, wasn't it? Thanks for
following us to here, really.Well, now that you know how to do a port, let us go at it and
convert everything in the world into ports! That is the easiest way to
start contributing to the FreeBSD Project! :)
diff --git a/en_US.ISO_8859-1/books/handbook/ppp-and-slip/chapter.sgml b/en_US.ISO_8859-1/books/handbook/ppp-and-slip/chapter.sgml
index a6b0d462da..2db526fa62 100644
--- a/en_US.ISO_8859-1/books/handbook/ppp-and-slip/chapter.sgml
+++ b/en_US.ISO_8859-1/books/handbook/ppp-and-slip/chapter.sgml
@@ -1,2487 +1,2488 @@
PPP and SLIPIf your connection to the Internet is through a modem, or you wish to
provide other people with dialup connections to the Internet using
FreeBSD, you have the option of using PPP or SLIP. Furthermore, two
varieties of PPP are provided: user (sometimes
referred to as iijppp) and
kernel. The procedures for configuring both types of
PPP, and for setting up SLIP are described in this chapter.Setting up User PPPUser PPP was introduced to FreeBSD in release 2.0.5 as an addition
to the existing kernel implementation of PPP. So, what is different
about this new PPP that warrants its addition? To quote from the manual
page:
This is a user process PPP software package. Normally, PPP is
implemented as a part of the kernel (e.g. as managed by
pppd) and it is thus somewhat hard to debug and/or
modify its behavior. However, in this implementation PPP is done as a
- user process with the help of the tunnel device driver (tun).
+ user process with the help of the tunnel device driver
+ (tun).
In essence, this means that rather than running a PPP daemon, the
ppp program can be run as and when desired. No PPP interface needs to
be compiled into the kernel, as the program can use the generic tunnel
device to get data into and out of the kernel.From here on out, user ppp will be referred to simply as ppp unless
a distinction needs to be made between it and any other PPP
client/server software such as pppd. Unless
otherwise stated, all commands in this section should be executed as
root.There are a large number of enhancements in version 2 of ppp. You
can discover what version you have by running ppp with no arguments and
typing show version at the prompt. It is a simple
matter to upgrade to the latest version of ppp (under any version of
FreeBSD) by downloading the latest archive via www.Awfulhak.org.Before you startThis document assumes you are in roughly this position:You have an account with an Internet Service Provider (ISP) which
lets you use PPP. Further, you have a modem (or other device)
connected and configured correctly which allows you to connect to your
ISP.You are going to need the following information to hand:Your ISPs phone number(s).Your login name and password. This can be either a regular
unix style login/password pair, or a PPP PAP or CHAP
login/password pair.The IP addresses of one or more nameservers. Normally, you
will be given two IP numbers. You must have
this information for PPP version 1.x
unless you run your own nameserver. From version 2 onwards,
PPP supports nameserver address
negotiation. If your ISP supports this, then using the command
enable dns in your config file will tell
PPP to set the nameservers for
you.The following information may have been supplied by your ISP, but
is not strictly necessary:The IP address of your ISP's gateway. The gateway is the
machine to which you will connect and will be set up as your
default route. If your ISP hasn't given you
this number, we can make one up and your ISP's PPP server will
tell us the correct value when we connect.This IP number is referred to as HISADDR
by ppp.Your ISP's netmask. If your ISP hasn't given you this
information, you can safely use a netmask of 255.255.255.0.If your ISP allocates you a static IP address and hostname
then you can enter this information. Otherwise, we simply let the
peer assign whatever IP number it sees fit.If you do not have any of the required information, contact your
ISP and make sure they provide it to you.Building a ppp ready kernelAs the description states, ppp uses the kernel
tun device. It is necessary to make sure
that your kernel has support for this device compiled in.To check this, go to your kernel compile directory
(/sys/i386/conf or
/sys/pc98/conf) and examine your kernel
configuration file. It needs to have the line
pseudo-device tun 1
in it somewhere. The stock GENERIC kernel has
this as standard, so if you have not installed a custom kernel or you
do not have a /sys directory, you do not have to
change anything.If your kernel configuration file does not have this line in it,
- or you need to configure more than one tun device (for example, if you
+ or you need to configure more than one tun device (for example, if you
are setting up a server and could have 16 dialup ppp connections at
any one time then you will need to use 16 instead
of 1), then you should add the line, re-compile,
re-install and boot the new kernel. Please refer to the Configuring the FreeBSD Kernel section
for more information on kernel configuration.You can check how many tunnel devices your current kernel has by
typing the following:&prompt.root; ifconfig -a
tun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 200.10.100.1 --> 203.10.100.24 netmask 0xffffffff
tun1: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 576
tun2: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
inet 203.10.100.1 --> 203.10.100.20 netmask 0xffffffff
tun3: flags=8010<POINTOPOINT,MULTICAST> mtu 1500This case shows four tunnel devices, two of which are currently
configured and being used. It should be noted that the
RUNNING flag above indicates that the interface has
been used at some point—it is not an error if your interface
does not show up as RUNNING.
- If you have a kernel without the tun device, and you can not
+ If you have a kernel without the tun device, and you can not
rebuild it for some reason, all is not lost. You should be able to
dynamically load the code. Refer to the appropriate
&man.modload.8; and &man.lkm.4; pages for further details.You may also wish to take this opportunity to configure a
firewall. Details can be found in the Firewalls section.Check the tun deviceMost users will only require one tun
device (/dev/tun0). If you have used more (i.e.,
a number other than 1 in the
pseudo-device line in the kernel configuration
file) then alter all references to tun0 below
to reflect whichever device number you are using.The easiest way to make sure that the
tun0 device is configured correctly is to
re-make it. To do this, execute the following commands:&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun0If you require 16 tunnel devices in your kernel, you will need to
- create more than just tun0:
+ create more than just tun0:
&prompt.root; cd /dev
&prompt.root; ./MAKEDEV tun15Also, to confirm that the kernel is configured correctly, the
following command should give the indicated output:&prompt.root; ifconfig tun0
tun0: flags=8050<POINTOPOINT,RUNNING,MULTICAST> mtu 1500The RUNNING flag may not yet be set, in which
case you will see:&prompt.root; ifconfig tun0
tun0: flags=8010<POINTOPOINT,MULTICAST> mtu 1500Name Resolution ConfigurationThe resolver is the part of the system that turns IP addresses
into hostnames and vice versa. It can be configured to look for maps
that describe IP to hostname mappings in one of two places. The first
is a file called /etc/hosts (man 5
hosts). The second is the Internet Domain Name Service
(DNS), a distributed data base, the discussion of which is beyond the
scope of this document.This section describes briefly how to configure your
resolver.The resolver is a set of system calls that do the name mappings,
but you have to tell them where to find their information. You do
this by first editing the file /etc/host.conf.
Do not call this file
/etc/hosts.conf (note the extra
s) as the results can be confusing.Edit the /etc/host.conf fileThis file should contain the following two lines (in this
order):
hosts
bindThese instructs the resolver to first look in the file
/etc/hosts, and then to consult the DNS if the
name was not found.Edit the /etc/hosts(5) fileThis file should contain the IP addresses and names of machines
on your network. At a bare minimum it should contain entries for
the machine which will be running ppp. Assuming that your machine
is called foo.bar.com with the IP
address 10.0.0.1,
/etc/hosts should contain:
127.0.0.1 localhost
10.0.0.1 foo.bar.com fooThe first line defines the alias localhost as a
synonym for the current machine. Regardless of your own IP address,
the IP address for this line should always be 127.0.0.1. The second line maps the name
foo.bar.com (and the shorthand
foo) to the IP address 10.0.0.1.If your provider allocates you a static IP address and name,
then use these in place of the 10.0.0.1 entry.Edit the /etc/resolv.conf file/etc/resolv.conf tells the resolver how to
behave. If you are running your own DNS, you may leave this file
empty. Normally, you will need to enter the following
line(s):
nameserver x.x.x.x
nameserver y.y.y.y
domain bar.comThe x.x.x.x and
y.y.y.y
addresses are those given to you by your ISP. Add as many
nameserver lines as your ISP provides. The
domain line defaults to your hostname's domain,
and is probably unnecessary. Refer to the
resolv.conf manual page for details of other
possible entries in this file.If you are running PPP version 2 or greater, the enable
dns command will tell PPP to request that your ISP
confirms the nameserver values. If your ISP supplies different
addresses (or if there are no nameserver lines in
/etc/resolv.conf), PPP will rewrite the file
with the ISP-supplied values.ppp ConfigurationBoth user ppp and pppd (the kernel level
implementation of PPP) use configuration files located in the
/etc/ppp directory. The sample configuration
files provided are a good reference for user ppp, so don't delete
them.Configuring ppp requires that you edit a number
of files, depending on your requirements. What you put in them
depends to some extent on whether your ISP allocates IP addresses
statically (i.e., you get given one IP address, and always use that
one) or dynamically (i.e., your IP address can be different for each
PPP session).PPP and Static IP addressesYou will need to create a configuration file called
/etc/ppp/ppp.conf. It should look similar to
the example below.Lines that end in a : start in the first
column, all other lines should be indented as shown using spaces
or tabs.
1 default:
2 set device /dev/cuaa0
3 set speed 115200
4 set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \"\" ATE1Q0 OK-AT-OK \\dATDT\\TTIMEOUT 40 CONNECT"
5 provider:
6 set phone "(0123) 456 7890"
7 set login "TIMEOUT 10 \"\" \"\" gin:--gin: foo word: bar col: ppp"
8 set timeout 300
9 set ifaddr x.x.x.xy.y.y.y 255.255.255.0 0.0.0.0
10 add default HISADDR
11 enable dnsDo not include the line numbers, they are just for reference in
this discussion.Line 1:Identifies the default entry. Commands in this entry are
executed automatically when ppp is run.Line 2:Identifies the device to which the modem is connected.
COM1: is
/dev/cuaa0 and
COM2: is
/dev/cuaa1.Line 3:Sets the speed you want to connect at. If 115200 doesn't
work (it should with any reasonably new modem), try 38400
instead.Line 4:The dial string. User PPP uses an expect-send syntax
similar to the &man.chat.8; program. Refer to the
manual page for information on the features of this
language.Line 5:Identifies an entry for a provider called
“provider”.Line 6:Sets the phone number for this provider. Multiple phone
numbers may be specified using the : or
| character as a separator. The difference
- between these spearators is described in the ppp manual page.
+ between these separators is described in &man.ppp.8;.
To summarize, if you want to rotate through the numbers, use
the :. If you want to always attempt to
dial the first number first and only use the other numbers if
the first number fails, use the |. Always
quote the entire set of phone numbers as shown.Line 7:The login string is of the same chat-like syntax as the
dial string. In this example, the string works for a service
whose login session looks like this:J. Random Provider
login: foo
password: bar
protocol: pppYou will need to alter this script to suit your own needs.
When you write this script for the first time, you should
enable “chat” logging to ensure that the
conversation is going as expected.If you're using PAP or CHAP, there will be no login at
this point, so your login string can be left blank. See PAP and CHAP
authentication for further details.Line 8:Sets the default timeout (in seconds) for the connection.
Here, the connection will be closed automatically after 300
seconds of inactivity. If you never want to timeout, set this
value to zero.Line 9:Sets the interface addresses. The string
x.x.x.x should be replaced by the
IP address that your provider has allocated to you. The
string y.y.y.y should be replaced
by the IP address that your ISP indicated for their gateway
(the machine to which you connect). If your ISP hasn't given
you a gateway address, use 10.0.0.2/0. If you need to use a
“guessed” address, make sure that you create an
entry in /etc/ppp/ppp.linkup as per the
instructions for PPP and
Dynamic IP addresses. If this line is omitted,
ppp cannot run in or
mode.Line 10:Adds a default route to your ISPs gateway. The special
word HISADDR is replaced with the gateway
address specified on line 9. It is important that this line
appears after line 9, otherwise HISADDR
will not yet be initialized.Line 11:This line tells PPP to ask your ISP to confirm that your
nameserver addresses are correct. If your ISP supports this
facility, PPP can then update
/etc/resolv.conf with the correct
nameserver entries.It is not necessary to add an entry to
ppp.linkup when you have a static IP address as
your routing table entries are already correct before you connect.
You may however wish to create an entry to invoke programs after
connection. This is explained later with the sendmail
example.Example configuration files can be found in the
/etc/ppp directory.PPP and Dynamic IP addressesIf your service provider does not assign static IP numbers,
ppp can be configured to negotiate the local and
remote addresses. This is done by “guessing” an IP
number and allowing ppp to set it up correctly
using the IP Configuration Protocol (IPCP) after connecting. The
ppp.conf configuration is the same as PPP and Static IP addresses,
with the following change:
9 set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0Again, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 9:The number after the / character is the
number of bits of the address that ppp will insist on. You
may wish to use IP numbers more appropriate to your
circumstances, but the above example will always work.The last argument (0.0.0.0) tells PPP
to negotiate using address 0.0.0.0 rather than 10.0.0.1. Do not use
0.0.0.0 as the first argument to
set ifaddr as it prevents PPP from setting
up an intial route in mode.If you are running version 1.x of PPP, uou will also need to
create an entry in /etc/ppp/ppp.linkup.
ppp.linkup is used after a connection has been
established. At this point, ppp will know what
IP addresses should really be used. The
following entry will delete the existing bogus routes, and create
correct ones:
1 provider:
2 delete ALL
3 add 0 0 HISADDRLine 1:On establishing a connection, ppp will
look for an entry in ppp.linkup according
to the following rules: First, try to match the same label as
we used in ppp.conf. If that fails, look
for an entry for the IP number of our gateway. This entry is
a four-octet IP style label. If we still haven't found an
entry, look for the MYADDR entry.Line 2:This line tells ppp to delete all
existing routes for the acquired tun interface (except the
direct route entry).Line 3:This line tells ppp to add a default
route that points to HISADDR.
HISADDR will be replaced with the IP number
of the gateway as negotiated in the IPCP.See the pmdemand entry in the files
/etc/ppp/ppp.conf.sample and
/etc/ppp/ppp.linkup.sample for a detailed
example.Version 2 of PPP introduces “sticky routes”. Any
add or delete lines that
contain MYADDR or HISADDR will
be remembered, and any time the actual values of
MYADDR or HISADDR change, the
routes will be re-applied. This removes the necessity of repeating
these lines in ppp.linkup.Receiving incoming calls with pppThis section describes setting up ppp in a
server role.When you configure ppp to receive incoming
calls on a machine connected to a LAN, you must decide if you wish
to forward packets to the LAN. If you do, you should allocate the
peer an IP number from your LAN's subet, and use the command
enable proxy
in your ppp.conf file. You should also confirm
that the /etc/rc.conf file (this file used to
be called /etc/sysconfig) contains the
following:
gateway=YESWhich getty?Configuring FreeBSD for Dialup
Services provides a good description on enabling dialup
services using getty.An alternative to getty is mgetty,
a smarter version of getty designed with dialup
lines in mind.The advantages of using mgetty is that it
actively talks to modems, meaning if port is
turned off in /etc/ttys then your modem won't
answer the phone.Later versions of mgetty (from 0.99beta
onwards) also support the automatic detection of PPP streams,
allowing your clients script-less access to your server.Refer to Mgetty and
AutoPPP for more information on
mgetty.PPP permissionsppp must normally be run as user id 0. If
however you wish to allow ppp to run in server
mode as a normal user by executing ppp as
described below, that user must be given permission to run
ppp by adding them to the
network group in
/etc/group.You will also need to give them access to one or more sections
of the configuration file using the allow
command:
allow users fred maryIf this command is used in the default
section, it gives the specified users access to everything.Setting up a PPP shell for dynamic-IP usersCreate a file called /etc/ppp/ppp-shell
containing the following:
#!/bin/sh
IDENT=`echo $0 | sed -e 's/^.*-\(.*\)$/\1/'`
CALLEDAS="$IDENT"
TTY=`tty`
if [ x$IDENT = xdialup ]; then
IDENT=`basename $TTY`
fi
echo "PPP for $CALLEDAS on $TTY"
echo "Starting PPP for $IDENT"
exec /usr/sbin/ppp -direct $IDENTThis script should be executable. Now make a symbolic link
called ppp-dialup to this script using the
following commands:&prompt.root; ln -s ppp-shell /etc/ppp/ppp-dialupYou should use this script as the shell
for all your dialup ppp users. This is an example from
/etc/password for a dialup PPP user with
username pchilds. (remember don't directly
edit the password file, use vipw)
pchilds:*:1011:300:Peter Childs PPP:/home/ppp:/etc/ppp/ppp-dialupCreate a /home/ppp directory that is
world readable containing the following 0 byte files
-r--r--r-- 1 root wheel 0 May 27 02:23 .hushlogin
-r--r--r-- 1 root wheel 0 May 27 02:22 .rhosts
which prevents /etc/motd from being
displayed.Setting up a PPP shell for static-IP usersCreate the ppp-shell file as above and
for each account with statically assigned IPs create a symbolic
link to ppp-shell.For example, if you have three dialup customers
fred, sam, and
mary, that you route class C networks for,
you would type the following:&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-fred
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-sam
&prompt.root; ln -s /etc/ppp/ppp-shell /etc/ppp/ppp-maryEach of these users dialup accounts should have their shell
set to the symbolic link created above. (ie.
mary's shell should be
/etc/ppp/ppp-mary).Setting up ppp.conf for dynamic-IP usersThe /etc/ppp/ppp.conf file should contain
something along the lines of
default:
set debug phase lcp chat
set timeout 0
ttyd0:
set ifaddr 203.14.100.1 203.14.100.20 255.255.255.255
enable proxy
ttyd1:
set ifaddr 203.14.100.1 203.14.100.21 255.255.255.255
enable proxyThe indenting is important.The default: section is loaded for each
session. For each dialup line enabled in
/etc/ttys create an entry similar to the one
for ttyd0: above. Each line should get a
unique IP address from your pool of IP addresses for dynamic
users.Setting up ppp.conf for static-IP
usersAlong with the contents of the sample
/etc/ppp/ppp.conf above you should add a
section for each of the statically assigned dialup users. We will
continue with our fred,
sam, and mary
example.
fred:
set ifaddr 203.14.100.1 203.14.101.1 255.255.255.255
sam:
set ifaddr 203.14.100.1 203.14.102.1 255.255.255.255
mary:
set ifaddr 203.14.100.1 203.14.103.1 255.255.255.255The file /etc/ppp/ppp.linkup should also
contain routing information for each static IP user if required.
The line below would add a route for the 203.14.101.0 class C via the client's
ppp link.
fred:
add 203.14.101.0 netmask 255.255.255.0 HISADDR
sam:
add 203.14.102.0 netmask 255.255.255.0 HISADDR
mary:
add 203.14.103.0 netmask 255.255.255.0 HISADDRMore on mgetty, AutoPPP, and MS
extensionsmgetty and AutoPPPConfiguring and compiling mgetty with the
AUTO_PPP option enabled allows
mgetty to detect the LCP phase of PPP
connections and automatically spawn off a ppp shell. However,
since the default login/password sequence does not occur it is
necessary to authenticate users using either PAP or CHAP.This section assumes the user has successfully configured,
compiled, and installed a version of mgetty
with the AUTO_PPP option (v0.99beta or
later)Make sure your
/usr/local/etc/mgetty+sendfax/login.config
file has the following in it:
/AutoPPP/ - - /etc/ppp/ppp-pap-dialupThis will tell mgetty to run the
ppp-pap-dialup script for detected PPP
connections.Create a file called
/etc/ppp/ppp-pap-dialup containing the
following (the file should be executable):
#!/bin/sh
exec /usr/sbin/ppp -direct pap$IDENTFor each dialup line enabled in
/etc/ttys create a corresponding entry in
/etc/ppp/ppp.conf. This will happily
co-exist with the definitions we created above.
pap:
enable pap
set ifaddr 203.14.100.1 203.14.100.20-203.14.100.40
enable proxyEach user logging in with this method will need to have a
username/password in /etc/ppp/ppp.secret
file, or alternatively add the
enable passwdauthoption to authenticate users via pap from the
/etc/password file.If you wish to assign some users a static IP number, you can
specify the number as the third argument in
/etc/ppp/ppp.secret. See
/etc/ppp/ppp.secret.sample for
examples.MS extentionsIt is possible to configure PPP to supply DNS and NetBIOS
nameserver addresses on demand.To enable these extensions with PPP version 1.x, the
following lines might be added to the relevant section of
/etc/ppp/ppp.conf.
enable msext
set ns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5And for PPP version 2 and above:
accept dns
set dns 203.14.100.1 203.14.100.2
set nbns 203.14.100.5This will tell the clients the primary and secondary name
server addresses, and a netbios nameserver host.In version 2 and above, if the set dns
line is ommitted, PPP will use the values found in
/etc/resolv.conf.PAP and CHAP authenticationSome ISPs set their system up so that the authentication part of
your connection is done using either of the PAP or CHAP
authentication mechanisms. If this is the case, your ISP will not
give a login: prompt when you connect, but will
start talking PPP immediately.PAP is less secure than CHAP, but security is not normally an
issue here as passwords, although being sent as plain text with PAP,
are being transmitted down a serial line only. There's not much room
for crackers to “eavesdrop”.Referring back to the PPP and
Static IP addresses or PPP and Dynamic IP addresses
sections, the following alterations must be made:
7 set login
…
12 set authname MyUserName
13 set authkey MyPasswordAs always, do not include the line numbers, they are just for
reference in this discussion. Indentation of at least one space is
required.Line 7:Your ISP will not normally require that you log into the
server if you're using PAP or CHAP. You must therefore
disable your "set login" string.Line 12:This line specifies your PAP/CHAP user name. You will
need to insert the correct value for
MyUserName.Line 13:This line specifies your PAP/CHAP password. You will need
to insert the correct value for
MyPassword. You may want to add an
additional line
15 accept PAP
or
15 accept CHAP
to make it obvious that this is the intention, but PAP and
CHAP are both accepted by default.Changing your ppp configuration on the
flyIt is possible to talk to the ppp program
while it is running in the background, but only if a suitable
diagnostic port has been set up. To do this, add the following line
to your configuration:
set server /var/run/ppp-tun%d DiagnosticPassword 0177This will tell PPP to listen to the specified unix-domain
socket, asking clients for the specified password before allowing
- access. The %d in the name is replaced with teh
- tun device number that is in use.
+ access. The %d in the name is replaced with the
+ tun device number that is in use.
Once a socket has been set up, the
&man.pppctl.8; program may be used in scripts that wish to
manipulate the running program.Final system configurationYou now have ppp configured, but there are a
few more things to do before it is ready to work. They all involve
editing the /etc/rc.conf file (was
/etc/sysconfig).Working from the top down in this file, make sure the
hostname= line is set, e.g.:
hostname=foo.bar.comIf your ISP has supplied you with a static IP address and name,
it's probably best that you use this name as your host name.Look for the network_interfaces variable. If
you want to configure your system to dial your ISP on demand, make
sure the tun0 device is added to the list,
otherwise remove it.
network_interfaces="lo0 tun0" ifconfig_tun0=The ifconfig_tun0 variable should be empty,
and a file called /etc/start_if.tun0 should be
created. This file should contain the line
ppp -auto mysystemThis script is executed at network configuration time, starting
your ppp daemon in automatic mode. If you have a LAN for which this
machine is a gateway, you may also wish to use the
switch. Refer to the manual page for
further details.Set the router program to NO with the
line
router_enable=NO (/etc/rc.conf)
router=NO (/etc/sysconfig)It is important that the routed daemon is not
started (it's started by default) as routed tends
to delete the default routing table entries created by
ppp.It is probably worth your while ensuring that the
sendmail_flags line does not include the
option, otherwise sendmail will
attempt to do a network lookup every now and then, possibly causing
your machine to dial out. You may try:
sendmail_flags="-bd"The upshot of this is that you must force
sendmail to re-examine the mail queue whenever the
ppp link is up by typing:&prompt.root; /usr/sbin/sendmail -qYou may wish to use the !bg command in
ppp.linkup to do this automatically:
1 provider:
2 delete ALL
3 add 0 0 HISADDR
4 !bg sendmail -bd -q30mIf you don't like this, it is possible to set up a
“dfilter” to block SMTP traffic. Refer to the sample
files for further details.All that is left is to reboot the machine.After rebooting, you can now either type&prompt.root; pppand then dial provider to start the PPP
session, or, if you want ppp to establish sessions
automatically when there is outbound traffic (and you haven't created
the start_if.tun0 script), type&prompt.root; ppp -auto providerSummaryTo recap, the following steps are necessary when setting up ppp
for the first time:Client side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/ppp/ppp.conf.
The pmdemand example should suffice for most
ISPs.If you have a dynamic IP address, create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.Create a start_if.tun0 script if you
require demand dialing.Server side:Ensure that the tun device is built
into your kernel.Ensure that the
tunX device file
is available in the /dev directory.Create an entry in /etc/passwd (using the
&man.vipw.8; program).Create a profile in this users home directory that runs
ppp -direct direct-server or similar.Create an entry in /etc/ppp/ppp.conf.
The direct-server example should
suffice.Create an entry in
/etc/ppp/ppp.linkup.Update your /etc/rc.conf (or
sysconfig) file.AcknowledgmentsThis section of the handbook was last updated on Monday Aug 10,
1998 by &a.brian;Thanks to the following for their input, comments &
suggestions:&a.nik;&a.dirkvangulik;&a.pjc;Setting up Kernel PPPContributed by &a.gena;.Before you start setting up PPP on your machine make sure that
pppd is located in /usr/sbin and
directory /etc/ppp exists.pppd can work in two modes:as a “client”, i.e. you want to connect your machine
to outside world via PPP serial connection or modem line.as a “server”, i.e. your machine is located on the
network and used to connect other computers using PPP.In both cases you will need to set up an options file
(/etc/ppp/options or ~/.ppprc
if you have more then one user on your machine that uses PPP).You also will need some modem/serial software (preferably kermit) so
you can dial and establish connection with remote host.Working as a PPP clientI used the following /etc/ppp/options to
connect to CISCO terminal server PPP line.
crtscts # enable hardware flow control
modem # modem control line
noipdefault # remote PPP server must supply your IP address.
# if the remote host doesn't send your IP during IPCP
# negotiation , remove this option
passive # wait for LCP packets
domain ppp.foo.com # put your domain name here
:<remote_ip> # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be your
# default routerTo connect:Dial to the remote host using kermit (or other modem program)
enter your user name and password (or whatever is needed to enable
PPP on the remote host)Exit kermit (without hanging up the line).enter:&prompt.root; /usr/src/usr.sbin/pppd.new/pppd /dev/tty0119200Use the appropriate speed and device name.Now your computer is connected with PPP. If the connection fails
for some reasons you can add the option to the
/etc/ppp/options file and check messages on the
console to track the problemFollowing /etc/ppp/pppup script will make all
3 stages automatically:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.dial
pppd /dev/tty01 19200/etc/ppp/kermit.dial is kermit script that
dials and makes all necessary authorization on the remote host.
(Example of such script is attached to the end of this
document)Use the following /etc/ppp/pppdown script to
disconnect the PPP line:
#!/bin/sh
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill -TERM ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
/sbin/ifconfig ppp0 down
/sbin/ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.hup
/etc/ppp/ppptestCheck if PPP is still running
(/usr/etc/ppp/ppptest):
#!/bin/sh
pid=`ps ax| grep pppd |grep -v grep|awk '{print $1;}'`
if [ X${pid} != "X" ] ; then
echo 'pppd running: PID=' ${pid-NONE}
else
echo 'No pppd running.'
fi
set -x
netstat -n -I ppp0
ifconfig ppp0Hangs up modem line
(/etc/ppp/kermit.hup):
set line /dev/tty01 ; put your modem device here
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
echo \13
exitHere is an alternate method using chat instead
of kermit.Contributed by &a.rhuff;.The following two files are sufficient to accomplish a pppd
connection./etc/ppp/options:
/dev/cuaa1 115200
crtscts # enable hardware flow control
modem # modem control line
connect "/usr/bin/chat -f /etc/ppp/login.chat.script"
noipdefault # remote PPP serve must supply your IP address.
# if the remote host doesn't send your IP during
# IPCP negotiation, remove this option
passive # wait for LCP packets
domain <your.domain> # put your domain name here
: # put the IP of remote PPP host here
# it will be used to route packets via PPP link
# if you didn't specified the noipdefault option
# change this line to <local_ip>:<remote_ip>
defaultroute # put this if you want that PPP server will be
# your default router/etc/ppp/login.chat.script:(This should actually go into a single line.)
ABORT BUSY ABORT 'NO CARRIER' "" AT OK ATDT<phone.number>
CONNECT "" TIMEOUT 10 ogin:-\\r-ogin: <login-id>
TIMEOUT 5 sword: <password>Once these are installed and modified correctly, all you need to
do is&prompt.root; pppdThis sample based primarily on information provided by: Trev
Roydhouse <Trev.Roydhouse@f401.n711.z3.fidonet.org> and used by
permission.Working as a PPP server/etc/ppp/options:
crtscts # Hardware flow control
netmask 255.255.255.0 # netmask ( not required )
192.114.208.20:192.114.208.165 # ip's of local and remote hosts
# local ip must be different from one
# you assigned to the ethernet ( or other )
# interface on your machine.
# remote IP is ip address that will be
# assigned to the remote machine
domain ppp.foo.com # your domain
passive # wait for LCP
modem # modem lineFollowing /etc/ppp/pppserv script will enable
ppp server on your machine:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
# reset ppp interface
ifconfig ppp0 down
ifconfig ppp0 delete
# enable autoanswer mode
kermit -y /etc/ppp/kermit.ans
# run ppp
pppd /dev/tty01 19200Use this /etc/ppp/pppservdown script to stop
ppp server:
#!/bin/sh
ps ax |grep pppd |grep -v grep
pid=`ps ax |grep pppd |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing pppd, PID=' ${pid}
kill ${pid}
fi
ps ax |grep kermit |grep -v grep
pid=`ps ax |grep kermit |grep -v grep|awk '{print $1;}'`
if [ "X${pid}" != "X" ] ; then
echo 'killing kermit, PID=' ${pid}
kill -9 ${pid}
fi
ifconfig ppp0 down
ifconfig ppp0 delete
kermit -y /etc/ppp/kermit.noansFollowing kermit script will enable/disable autoanswer mode on
your modem (/etc/ppp/kermit.ans):
set line /dev/tty01
set speed 19200
set file type binary
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
pau 1
out +++
inp 5 OK
out ATH0\13
inp 5 OK
echo \13
out ATS0=1\13 ; change this to out ATS0=0\13 if you want to disable
; autoanswer mod
inp 5 OK
echo \13
exitThis /etc/ppp/kermit.dial script is used for
dialing and authorizing on remote host. You will need to customize it
for your needs. Put your login and password in this script, also you
will need to change input statement depending on responses from your
modem and remote host.
;
; put the com line attached to the modem here:
;
set line /dev/tty01
;
; put the modem speed here:
;
set speed 19200
set file type binary ; full 8 bit file xfer
set file names literal
set win 8
set rec pack 1024
set send pack 1024
set block 3
set term bytesize 8
set command bytesize 8
set flow none
set modem hayes
set dial hangup off
set carrier auto ; Then SET CARRIER if necessary,
set dial display on ; Then SET DIAL if necessary,
set input echo on
set input timeout proceed
set input case ignore
def \%x 0 ; login prompt counter
goto slhup
:slcmd ; put the modem in command mode
echo Put the modem in command mode.
clear ; Clear unread characters from input buffer
pause 1
output +++ ; hayes escape sequence
input 1 OK\13\10 ; wait for OK
if success goto slhup
output \13
pause 1
output at\13
input 1 OK\13\10
if fail goto slcmd ; if modem doesn't answer OK, try again
:slhup ; hang up the phone
clear ; Clear unread characters from input buffer
pause 1
echo Hanging up the phone.
output ath0\13 ; hayes command for on hook
input 2 OK\13\10
if fail goto slcmd ; if no OK answer, put modem in command mode
:sldial ; dial the number
pause 1
echo Dialing.
output atdt9,550311\13\10 ; put phone number here
assign \%x 0 ; zero the time counter
:look
clear ; Clear unread characters from input buffer
increment \%x ; Count the seconds
input 1 {CONNECT }
if success goto sllogin
reinput 1 {NO CARRIER\13\10}
if success goto sldial
reinput 1 {NO DIALTONE\13\10}
if success goto slnodial
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 60 goto look
else goto slhup
:sllogin ; login
assign \%x 0 ; zero the time counter
pause 1
echo Looking for login prompt.
:slloop
increment \%x ; Count the seconds
clear ; Clear unread characters from input buffer
output \13
;
; put your expected login prompt here:
;
input 1 {Username: }
if success goto sluid
reinput 1 {\255}
if success goto slhup
reinput 1 {\127}
if success goto slhup
if < \%x 10 goto slloop ; try 10 times to get a login prompt
else goto slhup ; hang up and start again if 10 failures
:sluid
;
; put your userid here:
;
output ppp-login\13
input 1 {Password: }
;
; put your password here:
;
output ppp-password\13
input 1 {Entering SLIP mode.}
echo
quit
:slnodial
echo \7No dialtone. Check the telephone line!\7
exit 1
; local variables:
; mode: csh
; comment-start: "; "
; comment-start-skip: "; "
; end:Setting up a SLIP ClientContributed by &a.asami; 8 Aug 1995.The following is one way to set up a FreeBSD machine for SLIP on a
static host network. For dynamic hostname assignments (i.e., your
address changes each time you dial up), you probably need to do
something much fancier.First, determine which serial port your modem is connected to. I
have a symbolic link to /dev/modem from
/dev/cuaa1, and only use the modem name in my
configuration files. It can become quite cumbersome when you need to
fix a bunch of files in /etc and
.kermrc's all over the system!/dev/cuaa0 is COM1,
cuaa1 is COM2,
etc.Make sure you have
pseudo-device sl 1
in your kernel's config file. It is included in the
GENERIC kernel, so this will not be a problem
unless you deleted it.Things you have to do only onceAdd your home machine, the gateway and nameservers to your
/etc/hosts file. Mine looks like
this:
127.0.0.1 localhost loghost
136.152.64.181 silvia.HIP.Berkeley.EDU silvia.HIP silvia
136.152.64.1 inr-3.Berkeley.EDU inr-3 slip-gateway
128.32.136.9 ns1.Berkeley.edu ns1
128.32.136.12 ns2.Berkeley.edu ns2By the way, silvia is the name of the car that I had when I
was back in Japan (it is called 2?0SX here in U.S.).Make sure you have before
in your /etc/host.conf.
Otherwise, funny things may happen.Edit the file /etc/rc.conf. Note that
you should edit the file /etc/sysconfig
instead if you are running FreeBSD previous to version
2.2.2.Set your hostname by editing the line that says:
hostname=myname.my.domainYou should give it your full Internet hostname.Add sl0 to the list of network interfaces by changing the
line that says:
network_interfaces="lo0"to:
network_interfaces="lo0 sl0"Set the startup flags of sl0 by adding a line:
ifconfig_sl0="inet ${hostname} slip-gateway netmask 0xffffff00 up"Designate the default router by changing the line:
defaultrouter=NOto:
defaultrouter=slip-gatewayMake a file /etc/resolv.conf which
contains:
domain HIP.Berkeley.EDU
nameserver 128.32.136.9
nameserver 128.32.136.12As you can see, these set up the nameserver hosts. Of course,
the actual domain names and addresses depend on your
environment.Set the password for root and toor (and any other accounts
that does not have a password). Use passwd, do not edit the
/etc/passwd or
/etc/master.passwd files!Reboot your machine and make sure it comes up with the correct
hostname.Making a SLIP connectionDial up, type slip at the prompt, enter
your machine name and password. The things you need to enter
depends on your environment. I use kermit, with a script like
this:
# kermit setup
set modem hayes
set line /dev/modem
set speed 115200
set parity none
set flow rts/cts
set terminal bytesize 8
set file type binary
# The next macro will dial up and login
define slip dial 643-9600, input 10 =>, if failure stop, -
output slip\x0d, input 10 Username:, if failure stop, -
output silvia\x0d, input 10 Password:, if failure stop, -
output ***\x0d, echo \x0aCONNECTED\x0a(of course, you have to change the hostname and password to
fit yours). Then you can just type slip from
the kermit prompt to get connected.Leaving your password in plain text anywhere in the
filesystem is generally a BAD idea. Do it at your own risk. I
am just too lazy.Leave the kermit there (you can suspend it by
z) and as root, type:&prompt.root; slattach -h -c -s 115200 /dev/modemIf you are able to ping hosts on the other
side of the router, you are connected! If it does not work, you
might want to try instead of
as an argument to slattach.How to shutdown the connectionType
&prompt.root; kill -INT `cat /var/run/slattach.modem.pid`
(as root) to kill slattach. Then go back to kermit
(fg if you suspended it) and exit from it
(q).The slattach man page says you have to use ifconfig sl0
down to mark the interface down, but this does not seem to
make any difference for me. (ifconfig sl0 reports
the same thing.)Some times, your modem might refuse to drop the carrier (mine
often does). In that case, simply start kermit and quit it again. It
usually goes out on the second try.TroubleshootingIf it does not work, feel free to ask me. The things that people
tripped over so far:Not using or in
slattach (I have no idea why this can be fatal, but adding this
flag solved the problem for at least one person)Using instead of
(might be hard to see the difference on some fonts).Try ifconfig sl0 to see your interface
status. I get:&prompt.root; ifconfig sl0
sl0: flags=10<POINTOPOINT>
inet 136.152.64.181 --> 136.152.64.1 netmask ffffff00Also, netstat -r will give the routing
table, in case you get the "no route to host" messages from ping.
Mine looks like:&prompt.root; netstat -r
Routing tables
Destination Gateway Flags Refs Use IfaceMTU Rtt Netmasks:
(root node)
(root node)
Route Tree for Protocol Family inet:
(root node) =>
default inr-3.Berkeley.EDU UG 8 224515 sl0 - -
localhost.Berkel localhost.Berkeley UH 5 42127 lo0 - 0.438
inr-3.Berkeley.E silvia.HIP.Berkele UH 1 0 sl0 - -
silvia.HIP.Berke localhost.Berkeley UGH 34 47641234 lo0 - 0.438
(root node)(this is after transferring a bunch of files, your numbers
should be smaller).Setting up a SLIP ServerContributed by &a.ghelmer;. v1.0, 15 May
1995.This document provides suggestions for setting up SLIP Server
services on a FreeBSD system, which typically means configuring your
system to automatically startup connections upon login for remote SLIP
clients. The author has written this document based on his experience;
however, as your system and needs may be different, this document may
not answer all of your questions, and the author cannot be responsible
if you damage your system or lose data due to attempting to follow the
suggestions here.This guide was originally written for SLIP Server services on a
FreeBSD 1.x system. It has been modified to reflect changes in the
pathnames and the removal of the SLIP interface compression flags in
early versions of FreeBSD 2.X, which appear to be the only major changes
between FreeBSD versions. If you do encounter mistakes in this
document, please email the author with enough information to help
correct the problem.PrerequisitesThis document is very technical in nature, so background knowledge
is required. It is assumed that you are familiar with the TCP/IP
network protocol, and in particular, network and node addressing,
network address masks, subnetting, routing, and routing protocols,
such as RIP. Configuring SLIP services on a dial-up server requires a
knowledge of these concepts, and if you are not familiar with them,
please read a copy of either Craig Hunt's TCP/IP Network
Administration published by O'Reilly & Associates,
Inc. (ISBN Number 0-937175-82-X), or Douglas Comer's books on the
TCP/IP protocol.It is further assumed that you have already setup your modem(s)
and configured the appropriate system files to allow logins through
your modems. If you have not prepared your system for this yet,
please see the tutorial for configuring dialup services; if you have a
World-Wide Web browser available, browse the list of tutorials at
http://www.freebsd.org/;
otherwise, check the place where you found this document for a
document named dialup.txt or something similar.
You may also want to check the manual pages for
&man.sio.4; for information on the serial port device driver and
&man.ttys.5;, &man.gettytab.5;, &man.getty.8;, & &man.init.8;
for information relevant to configuring the system to accept logins on
modems, and perhaps &man.stty.1; for information on setting serial
port parameters (such as clocal for
directly-connected serial interfaces).Quick OverviewIn its typical configuration, using FreeBSD as a SLIP server works
as follows: a SLIP user dials up your FreeBSD SLIP Server system and
logs in with a special SLIP login ID that uses
/usr/sbin/sliplogin as the special user's shell.
The sliplogin program browses the file
/etc/sliphome/slip.hosts to find a matching line
for the special user, and if it finds a match, connects the serial
line to an available SLIP interface and then runs the shell script
/etc/sliphome/slip.login to configure the SLIP
interface.An Example of a SLIP Server LoginFor example, if a SLIP user ID were
Shelmerg, Shelmerg's entry
in /etc/master.passwd would look something like
this (except it would be all on one line):
Shelmerg:password:1964:89::0:0:Guy Helmer - SLIP:/usr/users/Shelmerg:/usr/sbin/sliploginWhen Shelmerg logs in,
sliplogin will search
/etc/sliphome/slip.hosts for a line that had a
matching user ID; for example, there may be a line in
/etc/sliphome/slip.hosts that reads:
Shelmerg dc-slip sl-helmer 0xfffffc00 autocompsliplogin will find that matching line, hook
the serial line into the next available SLIP interface, and then
execute /etc/sliphome/slip.login like
this:
/etc/sliphome/slip.login 0 19200 Shelmerg dc-slip sl-helmer 0xfffffc00 autocompIf all goes well, /etc/sliphome/slip.login
will issue an ifconfig for the SLIP interface to
which sliplogin attached itself (slip interface
0, in the above example, which was the first parameter in the list
given to slip.login) to set the local IP
address (dc-slip), remote IP address
(sl-helmer), network mask for the SLIP interface
(0xfffffc00), and any additional
flags (autocomp). If something goes wrong,
sliplogin usually logs good informational
messages via the daemon syslog facility, which
usually goes into /var/log/messages (see the
manual pages for &man.syslogd.8; and
&man.syslog.conf.5, and perhaps check
/etc/syslog.conf to see to which files
syslogd is logging).OK, enough of the examples — let us dive into setting up
the system.Kernel ConfigurationFreeBSD's default kernels usually come with two SLIP interfaces
defined (sl0 and
sl1); you can use netstat
-i to see whether these interfaces are defined in your
kernel.Sample output from netstat -i:Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll
ed0 1500 <Link>0.0.c0.2c.5f.4a 291311 0 174209 0 133
ed0 1500 138.247.224 ivory 291311 0 174209 0 133
lo0 65535 <Link> 79 0 79 0 0
lo0 65535 loop localhost 79 0 79 0 0
sl0* 296 <Link> 0 0 0 0 0
sl1* 296 <Link> 0 0 0 0 0The sl0 and sl1
interfaces shown in netstat -i's output indicate
that there are two SLIP interfaces built into the kernel. (The
asterisks after the sl0 and sl1
indicate that the interfaces are “down”.)However, FreeBSD's default kernels do not come configured to
forward packets (ie, your FreeBSD machine will not act as a router)
due to Internet RFC requirements for Internet hosts (see RFC's 1009
[Requirements for Internet Gateways], 1122 [Requirements for Internet
Hosts — Communication Layers], and perhaps 1127 [A Perspective
on the Host Requirements RFCs]), so if you want your FreeBSD SLIP
Server to act as a router, you will have to edit the
/etc/rc.conf file (called
/etc/sysconfig in FreeBSD releases prior to
2.2.2) and change the setting of the gateway
variable to . If you have an older system which
predates even the /etc/sysconfig file, then add
the following command:
sysctl -w net.inet.ip.forwarding = 1
to your /etc/rc.local file.You will then need to reboot for the new settings to take
effect.You will notice that near the end of the default kernel
configuration file (/sys/i386/conf/GENERIC) is a
line that reads:
pseudo-device sl 2This is the line that defines the number of SLIP devices available
in the kernel; the number at the end of the line is the maximum number
of SLIP connections that may be operating simultaneously.Please refer to Configuring the
FreeBSD Kernel for help in reconfiguring your kernel.Sliplogin ConfigurationAs mentioned earlier, there are three files in the
/etc/sliphome directory that are part of the
configuration for /usr/sbin/sliplogin (see
&man.sliplogin.8; for the actual manual page for
sliplogin): slip.hosts, which
defines the SLIP users & their associated IP addresses;
slip.login, which usually just configures the
SLIP interface; and (optionally) slip.logout,
which undoes slip.login's effects when the serial
connection is terminated.slip.hosts Configuration/etc/sliphome/slip.hosts contains lines
which have at least four items, separated by whitespace:SLIP user's login IDLocal address (local to the SLIP server) of the SLIP
linkRemote address of the SLIP linkNetwork maskThe local and remote addresses may be host names (resolved to IP
addresses by /etc/hosts or by the domain name
service, depending on your specifications in
/etc/host.conf), and I believe the network mask
may be a name that can be resolved by a lookup into
/etc/networks. On a sample system,
/etc/sliphome/slip.hosts looks like
this:
#
# login local-addr remote-addr mask opt1 opt2
# (normal,compress,noicmp)
#
Shelmerg dc-slip sl-helmerg 0xfffffc00 autocompAt the end of the line is one or more of the options. — no header compression — compress headers — compress headers if the
remote end allows it — disable ICMP packets (so any
“ping” packets will be dropped instead of using up
your bandwidth)Note that sliplogin under early releases of
FreeBSD 2 ignored the options that FreeBSD 1.x recognized, so the
options , ,
, and had no effect
until support was added in FreeBSD 2.2 (unless your
slip.login script included code to make use of
the flags).Your choice of local and remote addresses for your SLIP links
depends on whether you are going to dedicate a TCP/IP subnet or if
you are going to use “proxy ARP” on your SLIP server (it
is not “true” proxy ARP, but that is the terminology
used in this document to describe it). If you are not sure which
method to select or how to assign IP addresses, please refer to the
TCP/IP books referenced in the slips-prereqs section and/or
consult your IP network manager.If you are going to use a separate subnet for your SLIP clients,
you will need to allocate the subnet number out of your assigned IP
network number and assign each of your SLIP client's IP numbers out
of that subnet. Then, you will probably either need to configure a
static route to the SLIP subnet via your SLIP server on your nearest
IP router, or install gated on your FreeBSD SLIP
server and configure it to talk the appropriate routing protocols to
your other routers to inform them about your SLIP server's route to
the SLIP subnet.Otherwise, if you will use the “proxy ARP” method,
you will need to assign your SLIP client's IP addresses out of your
SLIP server's Ethernet subnet, and you will also need to adjust your
/etc/sliphome/slip.login and
/etc/sliphome/slip.logout scripts to use
&man.arp.8; to manage the proxy-ARP entries in the SLIP server's
ARP table.slip.login ConfigurationThe typical /etc/sliphome/slip.login file
looks like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6This slip.login file merely
ifconfig's the appropriate SLIP interface with
the local and remote addresses and network mask of the SLIP
interface.If you have decided to use the “proxy ARP” method
(instead of using a separate subnet for your SLIP clients), your
/etc/sliphome/slip.login file will need to look
something like this:
#!/bin/sh -
#
# @(#)slip.login 5.1 (Berkeley) 7/1/90
#
# generic login file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 inet $4 $5 netmask $6
# Answer ARP requests for the SLIP client with our Ethernet addr
/usr/sbin/arp -s $5 00:11:22:33:44:55 pubThe additional line in this slip.login,
arp -s $5 00:11:22:33:44:55 pub, creates an
ARP entry in the SLIP server's ARP table. This ARP entry causes the
SLIP server to respond with the SLIP server's Ethernet MAC address
whenever a another IP node on the Ethernet asks to speak to the SLIP
client's IP address.When using the example above, be sure to replace the Ethernet
MAC address (00:11:22:33:44:55) with the
MAC address of your system's Ethernet card, or your “proxy
ARP” will definitely not work! You can discover your SLIP
server's Ethernet MAC address by looking at the results of running
netstat -i; the second line of the output should
look something like:ed0 1500 <Link>0.2.c1.28.5f.4a 191923 0 129457 0 116This indicates that this particular system's Ethernet MAC
address is 00:02:c1:28:5f:4a — the
periods in the Ethernet MAC address given by netstat
-i must be changed to colons and leading zeros should be
added to each single-digit hexadecimal number to convert the address
into the form that
&man.arp.8; desires; see the manual page on &man.arp.8; for
complete information on usage.When you create /etc/sliphome/slip.login
and /etc/sliphome/slip.logout, the
“execute” bit (ie, chmod 755
/etc/sliphome/slip.login /etc/sliphome/slip.logout)
must be set, or sliplogin will be unable to
execute it.slip.logout Configuration/etc/sliphome/slip.logout is not strictly
needed (unless you are implementing “proxy ARP”), but if
you decide to create it, this is an example of a basic
slip.logout script:
#!/bin/sh -
#
# slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 downIf you are using “proxy ARP”, you will want to have
/etc/sliphome/slip.logout remove the ARP entry
for the SLIP client:
#!/bin/sh -
#
# @(#)slip.logout
#
# logout file for a slip line. sliplogin invokes this with
# the parameters:
# 1 2 3 4 5 6 7-n
# slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
/sbin/ifconfig sl$1 down
# Quit answering ARP requests for the SLIP client
/usr/sbin/arp -d $5The arp -d $5 removes the ARP entry that
the “proxy ARP” slip.login added
when the SLIP client logged in.It bears repeating: make sure
/etc/sliphome/slip.logout has the execute
bit set for after you create it (ie, chmod
755 /etc/sliphome/slip.logout).Routing ConsiderationsIf you are not using the “proxy ARP” method for
routing packets between your SLIP clients and the rest of your network
(and perhaps the Internet), you will probably either have to add
static routes to your closest default router(s) to route your SLIP
client subnet via your SLIP server, or you will probably need to
install and configure gated on your FreeBSD SLIP
server so that it will tell your routers via appropriate routing
protocols about your SLIP subnet.Static RoutesAdding static routes to your nearest default routers can be
troublesome (or impossible, if you do not have authority to do
so...). If you have a multiple-router network in your organization,
some routers, such as Cisco and Proteon, may not only need to be
configured with the static route to the SLIP subnet, but also need
to be told which static routes to tell other routers about, so some
expertise and troubleshooting/tweaking may be necessary to get
static-route-based routing to work.Running gatedAn alternative to the headaches of static routes is to install
gated on your FreeBSD SLIP server and configure
it to use the appropriate routing protocols (RIP/OSPF/BGP/EGP) to
tell other routers about your SLIP subnet. You can use
gated from the ports
collection or retrieve and build it yourself from the
GateD anonymous ftp site; I believe the current version as
of this writing is gated-R3_5Alpha_8.tar.Z,
which includes support for FreeBSD “out-of-the-box”.
Complete information and documentation on gated
is available on the Web starting at the Merit GateD
Consortium. Compile and install it, and then write a
/etc/gated.conf file to configure your gated;
here is a sample, similar to what the author used on a FreeBSD SLIP
server:
#
# gated configuration file for dc.dsu.edu; for gated version 3.5alpha5
# Only broadcast RIP information for xxx.xxx.yy out the ed Ethernet interface
#
#
# tracing options
#
traceoptions "/var/tmp/gated.output" replace size 100k files 2 general ;
rip yes {
interface sl noripout noripin ;
interface ed ripin ripout version 1 ;
traceoptions route ;
} ;
#
# Turn on a bunch of tracing info for the interface to the kernel:
kernel {
traceoptions remnants request routes info interface ;
} ;
#
# Propagate the route to xxx.xxx.yy out the Ethernet interface via RIP
#
export proto rip interface ed {
proto direct {
xxx.xxx.yy mask 255.255.252.0 metric 1; # SLIP connections
} ;
} ;
#
# Accept routes from RIP via ed Ethernet interfaces
import proto rip interface ed {
all ;
} ;The above sample gated.conf file broadcasts
routing information regarding the SLIP subnet
xxx.xxx.yy via RIP onto the Ethernet; if
you are using a different Ethernet driver than the
ed driver, you will need to change the
references to the ed interface
appropriately. This sample file also sets up tracing to
/var/tmp/gated.output for debugging
gated's activity; you can certainly turn off the
tracing options if gated works OK for you. You
will need to change the xxx.xxx.yy's into
the network address of your own SLIP subnet (be sure to change the
net mask in the proto direct clause as
well).When you get gated built and installed and
create a configuration file for it, you will need to run
gated in place of routed on
your FreeBSD system; change the routed/gated
startup parameters in /etc/netstart as
appropriate for your system. Please see the manual page for
gated for information on
gated's command-line parameters.AcknowledgmentsThanks to these people for comments and advice regarding this
tutorial:&a.wilko;Piero SeriniPiero@Strider.Inet.IT
diff --git a/en_US.ISO_8859-1/books/porters-handbook/book.sgml b/en_US.ISO_8859-1/books/porters-handbook/book.sgml
index 113749797a..0ddc65b4b4 100644
--- a/en_US.ISO_8859-1/books/porters-handbook/book.sgml
+++ b/en_US.ISO_8859-1/books/porters-handbook/book.sgml
@@ -1,4501 +1,4501 @@
Installing Applications: The Ports collectionContributed by &a.jraynard;.The FreeBSD Ports collection allows you to compile and install a very
wide range of applications with a minimum of effort.For all the hype about open standards, getting a program to work on
different versions of Unix in the real world can be a tedious and tricky
business, as anyone who has tried it will know. You may be lucky enough
to find that the program you want will compile cleanly on your system,
install itself in all the right places and run flawlessly “out of
the box”, but this is unfortunately rather rare. With most
programs, you will find yourself doing a fair bit of head-scratching, and
there are quite a few programs that will result in premature greying, or
even chronic alopecia...Some software distributions have attacked this problem by providing
configuration scripts. Some of these are very clever, but they have an
unfortunate tendency to triumphantly announce that your system is
something you have never heard of and then ask you lots of questions that
sound like a final exam in system-level Unix programming (Does
your system's gethitlist function return a const pointer to a fromboz or
a pointer to a const fromboz? Do you have Foonix style unacceptable
exception handling? And if not, why not?).Fortunately, with the Ports collection, all the hard work involved has
already been done, and you can just type make install
and get a working program.Why Have a Ports Collection?The base FreeBSD system comes with a very wide range of tools and
system utilities, but a lot of popular programs are not in the base
system, for good reasons:-Programs that some people cannot live without and other people
cannot stand, such as a certain Lisp-based editor.Programs which are too specialised to put in the base system
(CAD, databases).Programs which fall into the “I must have a look at that
when I get a spare minute” category, rather than
system-critical ones (some languages, perhaps).Programs that are far too much fun to be supplied with a serious
operating system like FreeBSD ;-)However many programs you put in the base system, people will
always want more, and a line has to be drawn somewhere (otherwise
FreeBSD distributions would become absolutely enormous).Obviously it would be unreasonable to expect everyone to port their
favourite programs by hand (not to mention a tremendous amount of
duplicated work), so the FreeBSD Project came up with an ingenious way
of using standard tools that would automate the process.Incidentally, this is an excellent illustration of how “the
Unix way” works in practice by combining a set of simple but very
flexible tools into something very powerful.How Does the Ports Collection Work?Programs are typically distributed on the Internet as a tarball consisting of a Makefile and
the source code for the program and usually some instructions (which are
unfortunately not always as instructive as they could be), with perhaps
a configuration script.The standard scenario is that you FTP down the tarball, extract it
somewhere, glance through the instructions, make any changes that seem
necessary, run the configure script to set things up and use the
standard make program to compile and install the
program from the source.FreeBSD ports still use the tarball mechanism, but use a skeleton to hold the
"knowledge" of how to get the program working on FreeBSD,
rather than expecting the user to be able to work it out. They also
supply their own customised Makefile, so that almost every port
can be built in the same way.If you look at a port skeleton (either on your FreeBSD
system or the
FTP site) and expect to find all sorts of pointy-headed rocket
science lurking there, you may be disappointed by the one or two rather
unexciting-looking files and directories you find there. (We will
discuss in a minute how to go about Getting a port).“How on earth can this do anything?” I hear you cry.
“There is no source code there!”Fear not, gentle reader, all will become clear (hopefully). Let's
see what happens if we try and install a port. I have chosen
ElectricFence, a useful tool for developers,
as the skeleton is more straightforward than most.If you are trying this at home, you will need to be root.&prompt.root; cd /usr/ports/devel/ElectricFence
&prompt.root; make install
>> Checksum OK for ElectricFence-2.0.5.tar.gz.
===> Extracting for ElectricFence-2.0.5
===> Patching for ElectricFence-2.0.5
===> Applying FreeBSD patches for ElectricFence-2.0.5
===> Configuring for ElectricFence-2.0.5
===> Building for ElectricFence-2.0.5
[lots of compiler output...]
===> Installing for ElectricFence-2.0.5
===> Warning: your umask is "0002". If this is not desired, set it to
an appropriate value and install this port again by ``make reinstall''.
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.a /usr/local/lib
install -c -o bin -g bin -m 444 /usr/ports/devel/ElectricFence/work/ElectricFence-2.0.5/libefence.3 /usr/local/man/man3
===> Compressing manual pages for ElectricFence-2.0.5
===> Registering installation for ElectricFence-2.0.5To avoid confusing the issue, I have completely removed the build
output.If you tried this yourself, you may well have got something like
this at the start:-&prompt.root; make install
>> ElectricFence-2.0.5.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://ftp.doc.ic.ac.uk/Mirrors/sunsite.unc.edu/pub/Linux/devel/lang/c/.The make program has noticed that you did not
have a local copy of the source code and tried to FTP it down so it
could get the job done. I already had the source handy in my example,
so it did not need to fetch it.Let's go through this and see what the make
program was doing.Locate the source code tarball. If it is not available
locally, try to grab it from an FTP site.Run a checksum test on the
tarball to make sure it has not been tampered with, accidentally
truncated, downloaded in ASCII mode, struck by neutrinos while in
transit, etc.Extract the tarball into a temporary work directory.Apply any patches needed to
get the source to compile and run under FreeBSD.Run any configuration script required by the build process and
correctly answer any questions it asks.(Finally!) Compile the code.Install the program executable and other supporting files, man
pages, etc. under the /usr/local hierarchy,
where they will not get mixed up with system programs. This also
makes sure that all the ports you install will go in the same place,
instead of being flung all over your system.Register the installation in a database. This means that, if
you do not like the program, you can cleanly remove all traces of it from your
system.Scroll up to the make output and see if you can
match these steps to it. And if you were not impressed before, you
should be by now!Getting a FreeBSD PortThere are two ways of getting hold of the FreeBSD port for a
program. One requires a FreeBSD CDROM,
the other involves using an Internet
Connection.Compiling ports from CDROMAssuming that your FreeBSD CDROM is in the drive and mounted on
/cdrom (and the mount point
must be /cdrom), you should
then be able to build ports just as you normally do and the port
collection's built in search path should find the tarballs in
/cdrom/ports/distfiles/ (if they exist there)
rather than downloading them over the net.Another way of doing this, if you want to just use the port
skeletons on the CDROM, is to set these variables in
/etc/make.conf:
PORTSDIR= /cdrom/ports
DISTDIR= /tmp/distfiles
WRKDIRPREFIX= /tmpSubstitute /tmp for any place you have enough
free space. Then, just cd to the appropriate
subdirectory under /cdrom/ports and type
make install as usual.
WRKDIRPREFIX will cause the port to be build under
/tmp/cdrom/ports; for instance,
games/oneko will be built under
/tmp/cdrom/ports/games/oneko.There are some ports for which we cannot provide the original
source in the CDROM due to licensing limitations. In that case, you
will need to look at the section on Compiling ports using an Internet
connection.Compiling ports from the InternetIf you do not have a CDROM, or you want to make sure you get the
very latest version of the port you want, you will need to download
the skeleton for the port. Now
this might sound like rather a fiddly job full of pitfalls, but it is
actually very easy.First, if you are running a release version of FreeBSD, make sure
you get the appropriate “upgrade kit” for your release
from the ports web
page. These packages include files that have been updated
since the release that you may need to compile new ports.The key to the skeletons is that the FreeBSD FTP server can create
on-the-fly tarballs for you.
Here is how it works, with the gnats program in the databases
directory as an example (the bits in square brackets are comments. Do
not type them in if you are trying this yourself!):-&prompt.root; cd /usr/ports
&prompt.root; mkdir databases
&prompt.root; cd databases
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports/databases>get gnats.tar
[tars up the gnats skeleton for us]
>quit
&prompt.root; tar xf gnats.tar
[extract the gnats skeleton]
&prompt.root; cd gnats
&prompt.root; make install
[build and install gnats]What happened here? We connected to the FTP server in the usual
way and went to its databases sub-directory.
When we gave it the command get gnats.tar, the FTP
server tarred up the gnats
directory for us.We then extracted the gnats skeleton and went into the gnats
directory to build the port. As we explained earlier, the make process noticed we
did not have a copy of the source locally, so it fetched one before
extracting, patching and building it.Let's try something more ambitious now. Instead of getting a
single port skeleton, let's get a whole sub-directory, for example all
the database skeletons in the ports collection. It looks almost the
same:-&prompt.root; cd /usr/ports
&prompt.root; ftp ftp.freebsd.org
[log in as `ftp' and give your email address when asked for a
password. Remember to use binary (also known as image) mode!]
>cd /pub/FreeBSD/ports/ports>get databases.tar
[tars up the databases directory for us]
>quit
&prompt.root; tar xf databases.tar
[extract all the database skeletons]
&prompt.root; cd databases
&prompt.root; make install
[build and install all the database ports]With half a dozen straightforward commands, we have now got a set
of database programs on our FreeBSD machine! All we did that was
different from getting a single port skeleton and building it was that
we got a whole directory at once, and compiled everything in it at
once. Pretty impressive, no?If you expect to be installing many ports, it is probably worth
downloading all the ports directories.SkeletonsA team of compulsive hackers who have forgotten to eat in a frantic
attempt to make a deadline? Something unpleasant lurking in the FreeBSD
attic? No, a skeleton here is a minimal framework that supplies
everything needed to make the ports magic work.MakefileThe most important component of a skeleton is the Makefile. This
contains various statements that specify how the port should be
compiled and installed. Here is the Makefile for
ElectricFence:-
# New ports collection makefile for: Electric Fence
# Version required: 2.0.5
# Date created: 13 November 1997
# Whom: jraynard
#
# $Id$
#
DISTNAME= ElectricFence-2.0.5
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= devel/lang/c
MAINTAINER= jraynard@freebsd.org
MAN3= libefence.3
do-install:
${INSTALL_DATA} ${WRKSRC}/libefence.a ${PREFIX}/lib
${INSTALL_MAN} ${WRKSRC}/libefence.3 ${PREFIX}/man/man3
.include <bsd.port.mk>The lines beginning with a "#" sign are comments for the
benefit of human readers (as in most Unix script files).DISTNAME specifies the name of the tarball, but without the
extension.CATEGORIES states what kind of program this is.
In this case, a utility for developers. See the categories section of this
handbook for a complete list.MASTER_SITES is the URL(s) of the master FTP
site, which is used to retrieve the tarball if it is not available on the
local system. This is a site which is regarded as reputable, and is
normally the one from which the program is officially distributed (in
so far as any software is "officially" distributed on the
Internet).MAINTAINER is the email address of the person
who is responsible for updating the skeleton if, for example a new
version of the program comes out.Skipping over the next few lines for a minute, the line
.include <bsd.port.mk> says that the other
statements and commands needed for this port are in a standard file
called bsd.port.mk. As these are the same for
all ports, there is no point in duplicating them all over the place,
so they are kept in a single standard file.This is probably not the place to go into a detailed examination
of how Makefiles work; suffice it to say that the line starting with
MAN3 ensures that the ElectricFence man page is
compressed after installation, to help conserve your precious disk
space. The original port did not provide an
install target, so the three lines from
do-install ensure that the files produced by
this port are placed in the correct destination.The files directoryThe file containing the checksum for the port is called
md5, after the MD5 algorithm used for ports
checksums. It lives in a directory with the slightly confusing name
of files.This directory can also contain other miscellaneous files that are
required by the port and do not belong anywhere else.The patches directoryThis directory contains the patches needed to make everything work
properly under FreeBSD.The pkg directoryThis program contains three quite useful files:-COMMENT — a one-line description of
the program.DESCR — a more detailed
description.PLIST — a list of all the files
that will be created when the program is installed.What to do when a port does not work.Oh. You can do one of four (4) things :Fix it yourself. Technical details on how ports work can be
found in Porting applications.Gripe. This is done by e-mail only! Send
such e-mail to the &a.ports; and please include the name/version of
the port, where you got both the port source & distfile(s) from,
and what the text of the error was.Forget it. This is the easiest for most — very few of the
programs in ports can be classified as essential!Grab the pre-compiled package from a ftp server. The
“master” package collection is on FreeBSD's FTP server
in the packages
directory, though check your local mirror first, please!
These are more likely to work (on the whole) than trying to compile
from source and a lot faster besides! Use the &man.pkg.add.1;
program to install a package file on your
system.Some Questions and AnswersQ. I thought this was going to be a discussion about
modems??!A. Ah. You must be thinking of the serial ports on the back of
your computer. We are using “port” here to mean the
result of “porting” a program from one version of Unix
to another. (It is an unfortunate bad habit of computer people to
use the same word to refer to several completely different
things).Q. I thought you were supposed to use packages to install extra
programs?A. Yes, that is usually the quickest and easiest way of doing
it.Q. So why bother with ports then?A. Several reasons:-The licensing conditions on some software distributions
require that they be distributed as source code, not
binaries.Some people do not trust binary distributions. At least
with source code you can (in theory) read through it and look
for potential problems yourself.If you have some local patches, you will need the source to
add them yourself.You might have opinions on how a program should be compiled
that differ from the person who did the package — some
people have strong views on what optimisation setting should be
used, whether to build debug versions and then strip them or
not, etc. etc.Some people like having code around, so they can read it if
they get bored, hack around with it, borrow from it (licence
terms permitting, of course!) and so on.If you ain't got the source, it ain't software! ;-) Q. What is a patch?A. A patch is a small (usually) file that specifies how to go
from one version of a file to another. It contains text that says,
in effect, things like “delete line 23”, “add
these two lines after line 468” or “change line 197 to
this”. Also known as a “diff”, since it is
generated by a program of that name. Q. What is all this about
tarballs?A. It is a file ending in .tar or
.tar.gz (with variations like
.tar.Z, or even .tgz if
you are trying to squeeze the names into a DOS filesystem).Basically, it is a directory tree that has been archived into a
single file (.tar) and optionally compressed
(.gz). This technique was originally used for
Tape ARchives (hence the
name tar), but it is a widely used way of
distributing program source code around the Internet.You can see what files are in them, or even extract them
yourself, by using the standard Unix tar program, which comes with
the base FreeBSD system, like this:-&prompt.user; tar tvzf foobar.tar.gz
&prompt.user; tar xzvf foobar.tar.gz
&prompt.user; tar tvf foobar.tar
&prompt.user; tar xvf foobar.tar Q. And a checksum?A. It is a number generated by adding up all the data in the
file you want to check. If any of the characters change, the
checksum will no longer be equal to the total, so a simple
comparison will allow you to spot the difference. (In practice, it
is done in a more complicated way to spot problems like
position-swapping, which will not show up with a simplistic
addition).Q. I did what you said for compiling
ports from a CDROM and it worked great until I tried to
install the kermit port:-&prompt.root; make install
>> cku190.tar.gz doesn't seem to exist on this system.
>> Attempting to fetch from ftp://kermit.columbia.edu/kermit/archives/.Why can it not be found? Have I got a dud CDROM?A. The licensing terms for kermit do not allow us to put the
tarball for it on the CDROM, so you will have to fetch it by hand
— sorry! The reason why you got all those error messages was
because you were not connected to the Internet at the time. Once
you have downloaded it from any of the sites above, you can re-start
the process (try and choose the nearest site to you, though, to save
your time and the Internet's bandwidth).Q. I did that, but when I tried to put it into
/usr/ports/distfiles I got some error about not
having permission.A. The ports mechanism looks for the tarball in
/usr/ports/distfiles, but you will not be able
to copy anything there because it is sym-linked to the CDROM, which
is read-only. You can tell it to look somewhere else by
doing&prompt.root; make DISTDIR=/where/you/put/it installQ. Does the ports scheme only work if you have everything in
/usr/ports? My system administrator says I must
put everything under
/u/people/guests/wurzburger, but it does not
seem to work.A. You can use the PORTSDIR and
PREFIX variables to tell the ports mechanism to
use different directories. For instance,&prompt.root; make PORTSDIR=/u/people/guests/wurzburger/ports installwill compile the port in
/u/people/guests/wurzburger/ports and install
everything under /usr/local.&prompt.root; make PREFIX=/u/people/guests/wurzburger/local installwill compile it in /usr/ports and install
it in /u/people/guests/wurzburger/local.And of course&prompt.root; make PORTSDIR=.../ports PREFIX=.../local installwill combine the two (it is too long to fit on the page if I
write it in full, but I am sure you get the idea).If you do not fancy typing all that in every time you install a
port (and to be honest, who would?), it is a good idea to put these
variables into your environment.Q. I do not have a FreeBSD CDROM, but I would like to have all
the tarballs handy on my system so I do not have to wait for a
download every time I install a port. Is there an easy way to get
them all at once?A. To get every single tarball for the ports collection,
do&prompt.root; cd /usr/ports
&prompt.root; make fetchFor all the tarballs for a single ports directory, do&prompt.root; cd /usr/ports/directory
&prompt.root; make fetchand for just one port — well, I think you have guessed
already.Q. I know it is probably faster to fetch the tarballs from one
of the FreeBSD mirror sites close by. Is there any way to tell the
port to fetch them from servers other than ones listed in the
MASTER_SITES?A. Yes. If you know, for example, ftp.FreeBSD.ORG is much closer than sites
listed in MASTER_SITES, do as following
example.&prompt.root; cd /usr/ports/directory
&prompt.root; make MASTER_SITE_OVERRIDE=ftp://ftp.FreeBSD.ORG/pub/FreeBSD/ports/distfiles/ fetchQ. I want to know what files make is going to need before it
tries to pull them down.A. make fetch-list will display a list of
the files needed for a port.Q. Is there any way to stop the port from compiling? I want to
do some hacking on the source before I install it, but it is a bit
tiresome having to watch it and hit control-C every time.A. Doing make extract will stop it after it
has fetched and extracted the source code.Q. I am trying to make my own port and I want to be able to
stop it compiling until I have had a chance to see if my patches
worked properly. Is there something like make
extract, but for patches?A. Yep, make patch is what you want. You
will probably find the PATCH_DEBUG option useful
as well. And by the way, thank you for your efforts!Q. I have heard that some compiler options can cause bugs. Is
this true? How can I make sure that I compile ports with the right
settings?A. Yes, with version 2.6.3 of gcc (the
version shipped with FreeBSD 2.1.0 and 2.1.5), the
option could result in buggy code unless you
used the option as well.
(Most of the ports don't use ). You
should be able to specify the compiler options
used by something like&prompt.root; make CFLAGS='-O2 -fno-strength-reduce' installor by editing /etc/make.conf, but
unfortunately not all ports respect this. The surest way is to do
make configure, then go into the source directory
and inspect the Makefiles by hand, but this can get tedious if the
source has lots of sub-directories, each with their own
Makefiles.Q. There are so many ports it is hard to find the one I want.
Is there a list anywhere of what ports are available?A. Look in the INDEX file in
/usr/ports. If you would like to search the
ports collection for a keyword, you can do that too. For example,
you can find ports relevant to the LISP programming language
using:&prompt.user; cd /usr/ports
&prompt.user; make search key=lispQ. I went to install the foo port but the
system suddenly stopped compiling it and starting compiling the
bar port. What's going on?A. The foo port needs something that is
supplied with bar — for instance, if
foo uses graphics, bar might
have a library with useful graphics processing routines. Or
bar might be a tool that is needed to compile the
foo port. Q. I installed the
grizzle program from the ports and frankly it is
a complete waste of disk space. I want to delete it but I do not
know where it put all the files. Any clues?A. No problem, just do&prompt.root; pkg_delete grizzle-6.5
Q. Hang on a minute, you have to know the version number to use
that command. You do not seriously expect me to remember that, do
you??A. Not at all, you can find it out by doing&prompt.root; pkg_info -a | grep grizzle
Information for grizzle-6.5:
grizzle-6.5 - the combined piano tutorial, LOGO interpreter and shoot 'em up arcade game.Q. Talking of disk space, the ports directory seems to be
taking up an awful lot of room. Is it safe to go in there and
delete things?A. Yes, if you have installed the program and are fairly
certain you will not need the source again, there is no point in
keeping it hanging around. The best way to do this is&prompt.root; cd /usr/ports
&prompt.root; make cleanwhich will go through all the ports subdirectories and delete
everything except the skeletons for each port.Q. I tried that and it still left all those tarballs or
whatever you called them in the distfiles
directory. Can I delete those as well?A. Yes, if you are sure you have finished with them, those can
go as well.Q. I like having lots and lots of programs to play with. Is
there any way of installing all the ports in one go?A. Just do&prompt.root; cd /usr/ports
&prompt.root; make installQ. OK, I tried that, but I thought it would take a very long
time so I went to bed and left it to get on with it. When I looked
at the computer this morning, it had only done three and a half
ports. Did something go wrong?A. No, the problem is that some of the ports need to ask you
questions that we cannot answer for you (eg “Do you want to
print on A4 or US letter sized paper?”) and they need to have
someone on hand to answer them.Q. I really do not want to spend all day staring at the
monitor. Any better ideas?A. OK, do this before you go to bed/work/the local
park:-&prompt.root cd /usr/ports
&prompt.root; make -DBATCH installThis will install every port that does not
require user input. Then, when you come back, do&prompt.root; cd /usr/ports
&prompt.root; make -DIS_INTERACTIVE installto finish the job.Q. At work, we are using frobble, which is
in your ports collection, but we have altered it quite a bit to get
it to do what we need. Is there any way of making our own packages,
so we can distribute it more easily around our sites?A. No problem, assuming you know how to make patches for your
changes:-&prompt.root; cd /usr/ports/somewhere/frobble
&prompt.root; make extract
&prompt.root; cd work/frobble-2.8
[Apply your patches]
&prompt.root; cd ../..
&prompt.root; make packageQ. This ports stuff is really clever. I am desperate to find
out how you did it. What is the secret?A. Nothing secret about it at all, just look at the
bsd.ports.mk and
bsd.ports.subdir.mk files in your makefiles
directory.Readers with an aversion to intricate shell-scripts are
advised not to follow this link...)Making a port yourselfContributed by &a.jkh;, &a.gpalmer;, &a.asami; &a.obrien;
and &a.hoek;. 28 August 1996.So, now you are interested in making your own port? Great!What follows are some guidelines for creating a new port for
FreeBSD. The bulk of the work is done by
/usr/ports/Mk/bsd.port.mk, which all port Makefiles
include. Please refer to that file for more details on the inner
workings of the ports collection. Even if you don't hack Makefiles
daily, it is well commented, and you will still gain much knowledge from
it.Only a fraction of the overridable variables
(VAR) are mentioned in
this document. Most (if not all) are documented at the start of
bsd.port.mk. This file users a non-standard tab
setting. Emacs and
Vim should recognise the setting on loading
the file. vi or ex can be set
to use the correct value by typing :set tabstop=4
once the file has been loaded.Quick PortingThis section tells you how to do a quick port. In many cases, it
is not enough, but we will see.First, get the original tarball and put it into
DISTDIR, which defaults to
/usr/ports/distfiles.The following assumes that the software compiled out-of-the-box,
i.e., there was absolutely no change required for the port to work
on your FreeBSD box. If you needed to change something, you will
have to refer to the next section too.Writing the MakefileThe minimal Makefile would look something
like this:
# New ports collection makefile for: oneko
# Version required: 1.1b
# Date created: 5 December 1994
# Whom: asami
#
# $Id$
#
DISTNAME= oneko-1.1b
CATEGORIES= games
MASTER_SITES= ftp://ftp.cs.columbia.edu/archives/X11R5/contrib/
MAINTAINER= asami@FreeBSD.ORG
MAN1= oneko.1
MANCOMPRESSED= yes
USE_IMAKE= yes
.include <bsd.port.mk>See if you can figure it out. Do not worry about the contents
of the $Id$ line, it will be filled in
automatically by CVS when the port is imported to our main ports
tree. You can find a more detailed example in the sample Makefile section.Writing the description filesThere are three description files that are required for any
port, whether they actually package or not. They are
COMMENT, DESCR, and
PLIST, and reside in the
pkg subdirectory.COMMENTThis is the one-line description of the port.
Please do not include the package name (or
version number of the software) in the comment. Here is an
example:
A cat chasing a mouse all over the screen.DESCRThis is a longer description of the port. One to a few
paragraphs concisely explaining what the port does is
sufficient.This is not a manual or an in-depth
description on how to use or compile the port! Please
be careful if you are copying from the
README or manpage; too often
they are not a concise description of the port or are in an
awkward format (e.g., manpages have justified spacing). If the
ported software has an official WWW homepage, you should list it
here. Prefix one of the websites with
WWW: so that automated tools will work
correctly.It is recommended that you sign your name at the end of this
file, as in:
This is a port of oneko, in which a cat chases a poor mouse all over
the screen.
:
(etc.)
WWW: http://www.oneko.org/
- Satoshi
asami@cs.berkeley.eduPLISTThis file lists all the files installed by the port. It is
also called the “packing list” because the package is
generated by packing the files listed here. The pathnames are
relative to the installation prefix (usually
/usr/local or
/usr/X11R6). If you are using the
MANn variables (as
you should be), do not list any manpages here.Here is a small example:
bin/oneko
lib/X11/app-defaults/Oneko
lib/X11/oneko/cat1.xpm
lib/X11/oneko/cat2.xpm
lib/X11/oneko/mouse.xpm
@dirrm lib/X11/onekoRefer to the &man.pkg.create.1; man page for details on the
packing list.You should list all the files, but not the name directories,
in the list. Also, if the port creates directories for itself
during installtion, make sure to add @dirrm
lines as necessary to remove them when the port is
deleted.It is recommended that you keep all the filenames in this
file sorted alphabetically. It will make verifying the changes
when you upgrade the port much easier.Creating the checksum fileJust type make makesum. The ports make rules
will automatically generate the file
files/md5.Testing the portYou should make sure that the port rules do exactly what you
want it to do, including packaging up the port. These are the
important points you need to verify.PLIST does not contain anything not
installed by your portPLIST contains everything that is
installed by your portYour port can be installed multiple times using the
reinstall targetYour port cleans up
after itself upon deinstallRecommended test orderingmake installmake packagemake deinstallpkg_add `make package-name`make deinstallmake reinstallmake packageMake sure that there aren't any warnings issued in any of the
package and
deinstall stages, After step 3, check to
see if all the new directories are correctly deleted. Also, try
using the software after step 4, to ensure that is works correctly
when installed from a package.Checking your port with portlintPlease use portlint to see if your port
conforms to our guidelines. The portlint program
is part of the ports collection. In particular, your may want to
check if the Makefile is in
the right shape and the package is named
appropriately.Submitting the portFirst, make sure you have read the Do's and Dont's section.Now that you are happy with your port, the only thing remaining
is to put it in the main FreeBSD ports tree and make everybody else
happy about it too. We do not need your work
directory or the pkgname.tgz package, so delete
them now. Next, simply include the output of shar `find
port_dir` in a bug report and send it with the
&man.send-pr.1; program (see Bug
Reports and General Commentary for more information about
&man.send-pr.1;. If the uncompressed port is larger than 20KB,
you should compress it into a tarfile and use &man.uuencode.1;
before including it in the bug report (uuencoded tarfiles are
acceptable even if the bug report is smaller than 20KB but are not
preferred). Be sure to classify the bug report as category
ports and class
change-request. (Do not mark the report
confidential!)One more time, do not include the original source
distfile, the work directory, or the package
you built with make package.In the past, we asked you to upload new port submissions in
our ftp site (ftp.freebsd.org). This
is no longer recommended as read access is turned off on that
incoming/ directory of that site due to the
large amount of pirated software showing up there.We will look at your port, get back to you if necessary, and put
it in the tree. Your name will also appear in the list of
“Additional FreeBSD contributors” on the FreeBSD
Handbook and other files. Isn't that great?!? :)Slow PortingOk, so it was not that simple, and the port required some
modifications to get it to work. In this section, we will explain,
step by step, how to modify it to get it to work with the ports
paradigm.How things workFirst, this is the sequence of events which occurs when the user
first types make in your port's directory, and
you may find that having bsd.port.mk in another
window while you read this really helps to understand it.But do not worry if you do not really understand what
bsd.port.mk is doing, not many people do...
:>The fetch target is run. The
fetch target is responsible for making
sure that the tarball exists locally in
DISTDIR. If fetch
cannot find the required files in DISTDIR it
will look up the URL MASTER_SITES, which is
set in the Makefile, as well as our main ftp site at ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/,
where we put sanctioned distfiles as backup. It will then
attempt to fetch the named distribution file with
FETCH, assuming that the requesting site has
direct access to the Internet. If that succeeds, it will save
the file in DISTDIR for future use and
proceed.The extract target is run. It
looks for your port's distribution file (typically a gzip'd
tarball) in DISTDIR and unpacks it into a
temporary subdirectory specified by WRKDIR
(defaults to work).The patch target is run. First,
any patches defined in PATCHFILES are
applied. Second, if any patches are found in
PATCHDIR (defaults to the
patches subdirectory), they are applied at
this time in alphabetical order.The configure target is run. This
can do any one of many different things.If it exists, scripts/configure is
run.If HAS_CONFIGURE or
GNU_CONFIGURE is set,
WRKSRC/configure is
run.If USE_IMAKE is set,
XMKMF (default: xmkmf
-a) is run.The build target is run. This is
responsible for descending into the port's private working
directory (WRKSRC) and building it. If
USE_GMAKE is set, GNU make
will be used, otherwise the system make will
be used.The above are the default actions. In addition, you can define
targets
pre-something or
post-something,
or put scripts with those names, in the scripts
subdirectory, and they will be run before or after the default
actions are done.For example, if you have a post-extract
target defined in your Makefile, and a file
pre-build in the scripts
subdirectory, the post-extract target will
be called after the regular extraction actions, and the
pre-build script will be executed before the
default build rules are done. It is recommended that you use
Makefile targets if the actions are simple
enough, because it will be easier for someone to figure out what
kind of non-default action the port requires.The default actions are done by the
bsd.port.mk targets
do-something.
For example, the commands to extract a port are in the target
do-extract. If you are not happy with the
default target, you can fix it by redefining the
do-something
target in your Makefile.The “main” targets (e.g.,
extract,
configure, etc.) do nothing more than
make sure all the stages up to that one are completed and call
the real targets or scripts, and they are not intended to be
changed. If you want to fix the extraction, fix
do-extract, but never ever touch
extract!Now that you understand what goes on when the user types
make, let us go through the recommended steps to
create the perfect port.Getting the original sourcesGet the original sources (normally) as a compressed tarball
(foo.tar.gz or
foo.tar.Z) and copy
it into DISTDIR. Always use
mainstream sources when and where you
can.If you cannot find a ftp/http site that is well-connected to the
net, or can only find sites that have irritatingly non-standard
formats, you might want to put a copy on a reliable ftp or http
server that you control (e.g., your home page). Make sure you set
MASTER_SITES to reflect your choice.If you cannot find somewhere convenient and reliable to put the
distfile (if you are a FreeBSD committer, you can just put it in
your public_html/ directory on
freefall), we can “house” it ourselves
by putting it on
ftp://ftp.freebsd.org/pub/FreeBSD/ports/distfiles/LOCAL_PORTS/
as the last resort. Please refer to this location as
MASTER_SITE_LOCAL. Send mail to the &a.ports;if
you are not sure what to do.If your port's distfile changes all the time for no good reason,
consider putting the distfile in your home page and listing it as
the first MASTER_SITES. This will prevent users
from getting checksum mismatch errors, and
also reduce the workload of maintainers of our ftp site. Also, if
there isonly one master site for the port, it is recommended that
you house a backup at your site and list it as the second
MASTER_SITES.If your port requires some additional `patches' that are
available on the Internet, fetch them too and put them in
DISTDIR. Do not worry if they come from a site
other than where you got the main source tarball, we have a way to
handle these situations (see the description of PATCHFILES below).Modifying the portUnpack a copy of the tarball in a private directory and make
whatever changes are necessary to get the port to compile properly
under the current version of FreeBSD. Keep careful
track of everything you do, as you will be automating
the process shortly. Everything, including the deletion, addition
or modification of files should be doable using an automated script
or patch file when your port is finished.If your port requires significant user interaction/customization
to compile or install, you should take a look at one of Larry Wall's
classic Configure scripts and perhaps do
something similar yourself. The goal of the new ports collection is
to make each port as “plug-and-play” as possible for the
end-user while using a minimum of disk space.Unless explicitly stated, patch files, scripts, and other
files you have created and contributed to the FreeBSD ports
collection are assumed to be covered by the standard BSD copyright
conditions.PatchingIn the preparation of the port, files that have been added or
changed can be picked up with a recursive diff for later feeding to
patch. Each set of patches you wish to apply should be collected
into a file named
patch-xx where
xx denotes the sequence in which the
patches will be applied — these are done in
alphabetical order, thus aa
first, ab second and so on. These files should
be stored in PATCHDIR, from where they will be
automatically applied. All patches should be relative to
WRKSRC (generally the directory your port's
tarball unpacks itself into, that being where the build is done).
To make fixes and upgrades easier, you should avoid having more than
one patch fix the same file (e.g., patch-aa and
patch-ab both changing
WRKSRC/foobar.c).ConfiguringInclude any additional customization commands to your
configure script and save it in the
scripts subdirectory. As mentioned above, you
can also do this as Makefile targets and/or
scripts with the name pre-configure or
post-configure.Handling user inputIf your port requires user input to build, configure or install,
then set IS_INTERACTIVE in your Makefile. This
will allow “overnight builds” to skip your port if the
user sets the variable BATCH in his environment (and
if the user sets the variable INTERACTIVE, then
only those ports requiring interaction are
built).It is also recommended that if there are reasonable default
answers to the questions, you check the
PACKAGE_BUILDING variable and turn off the
interactive script when it is set. This will allow us to build the
packages for CD-ROMs and ftp.Configuring the MakefileConfiguring the Makefile is pretty simple, and again we suggest
that you look at existing examples before starting. Also, there is a
sample Makefile in this
handbook, so take a look and please follow the ordering of variables
and sections in that template to make your port easier for others to
read.Now, consider the following problems in sequence as you design
your new Makefile:The original sourceDoes it live in DISTDIR as a standard gzip'd
tarball? If so, you can go on to the next step. If not, you should
look at overriding any of the EXTRACT_CMD,
EXTRACT_BEFORE_ARGS,
EXTRACT_AFTER_ARGS,
EXTRACT_SUFX, or DISTFILES
variables, depending on how alien a format your port's distribution
file is. (The most common case is
EXTRACT_SUFX=.tar.Z, when the tarball is
condensed by regular compress, not gzip.)In the worst case, you can simply create your own
do-extract target to override the default,
though this should be rarely, if ever, necessary.DISTNAMEYou should set DISTNAME to be the base name
of your port. The default rules expect the distribution file list
(DISTFILES) to be named
DISTNAMEEXTRACT_SUFX which, if
it is a normal tarball, is going to be something like
foozolix-1.0.tar.gz for a setting of
DISTNAME=foozolix-1.0.The default rules also expect the tarball(s) to extract into a
subdirectory called
work/DISTNAME, e.g.
work/foozolix-1.0/.All this behavior can be overridden, of course; it simply
represents the most common time-saving defaults. For a port
requiring multiple distribution files, simply set
DISTFILES explicitly. If only a subset of
DISTFILES are actual extractable archives, then
set them up in EXTRACT_ONLY, which will override
the DISTFILES list when it comes to extraction,
and the rest will be just left in DISTDIR for
later use.PKGNAMEIf DISTNAME does not conform to our guidelines for a good package
name, you should set the PKGNAME
variable to something better. See the abovementioned guidelines for
more details.CATEGORIESWhen a package is created, it is put under
/usr/ports/packages/All and links are made from
one or more subdirectories of
/usr/ports/packages. The names of these
subdirectories are specified by the variable
CATEGORIES. It is intended to make life easier
for the user when he is wading through the pile of packages on the
ftp site or the CD-ROM. Please take a look at the existing categories and pick the ones
that are suitable for your port.This list also determines where in the ports tree the port is
imported. If you put more than one category here, it is assumed
that the port files will be put in the subdirectory with the name in
the first category. See the categories section for more
discussion about how to pick the right categories.If you port truly belongs to something that is different from
all the existing ones, you can even create a new category name. In
that case, please send mail to the &a.ports; to propose a new
category.There is no error checking for category names. make
package will happily create a new directory if you
mustype the category name, so be careful!MASTER_SITESRecord the directory part of the ftp/http-URL pointing at the
original tarball in MASTER_SITES. Do not forget
the trailing slash (/)!The make macros will try to use this
specification for grabbing the distribution file with
FETCH if they cannot find it already on the
system.It is recommended that you put multiple sites on this list,
preferably from different continents. This will safeguard against
wide-area network problems, and we are even planning to add support
for automatically determining the closest master site and fetching
from there!If the original tarball is part of one of the following popular
archives: X-contrib, GNU, Perl CPAN, TeX CTAN, or Linux Sunsite, you
refer to those sites in an easy compact form using
MASTER_SITE_XCONTRIB,
MASTER_SITE_GNU,
MASTER_SITE_PERL_CPAN,
MASTER_SITE_TEX_CTAN, and
MASTER_SITE_SUNSITE. Simply set
MASTER_SITE_SUBDIR to the path with in the
archive. Here is an example:
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applicationsThe user can also set the MASTER_SITE_*
variables in /etc/make.conf to override our
choices, and use their favorite mirrors of these popular archives
instead.PATCHFILESIf your port requires some additional patches that are available
by ftp or http, set PATCHFILES to the names of
the files and PATCH_SITES to the URL of the
directory that contains them (the format is the same as
MASTER_SITES).If the patch is not relative to the top of the source tree
(i.e., WKRSRC) because it contains some extra
pathnames, set PATCH_DIST_STRIP accordingly. For
instance, if all the pathnames in the patch have an extra
foozolix-1.0/ in front of the filenames, then set
PATCH_DIST_STRIP=-p1.Do not worry if the patches are compressed, they will be
decompressed automatically if the filenames end with
.gz or .Z.If the patch is distributed with some other files, such as
documentation, in a gzip'd tarball, you can't just use
PATCHFILES. If that is the case, add the name
and the location of the patch tarball to
DISTFILES and MASTER_SITES.
Then, from the pre-patch target, apply the
patch either by running the patch command from there, or copying the
patch file into the PATCHDIR directory and
calling it
patch-xx.Note the tarball will have been extracted alongside the
regular source by then, so there is no need to explicitly extract
it if it is a regular gzip'd or compress'd tarball. If you do the
latter, take extra care not to overwrite something that already
exists in that directory. Also do not forget to add a command to
remove the copied patch in the pre-clean
target.MAINTAINERSet your mail-address here. Please. :)For detailed description of the responsibility of maintainers,
refer to MAINTAINER on
Makefiles section.DependenciesMany ports depend on other ports. There are five variables that
you can use to ensure that all the required bits will be on the
user's machine. There are also some pre-supported dependency
variables for common cases, plus a few more to control the behaviour
of dependencies.LIB_DEPENDSThis variable specifies the shared libraries this port depends
on. It is a list of
lib:dir:target
tuples where lib is the name of the
shared library, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. For example, LIB_DEPENDS=
jpeg\\.9\\.:${PORTSDIR}/graphics/jpeg:install
will check for a shared jpeg library with major version 9, and
descend into the graphics/jpeg subdirectory
of your ports tree to build and install it if it is not found.
The target part can be omitted if it is
equal to DEPENDS_TARGET (which defaults to
install).The lib part is an argument given
to ldconfig -r | grep -wF. There shall be no
reqular expressions in this variable.The dependency is checked twice, once from within the
extract target and then from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system.RUN_DEPENDSThis variable specifies executables or files this port depends
on during run-time. It is a list of
path:dir:target
tuples where path is the name of the
executable or file, and dir is the
directory in which to find it in case it is not available, and
target is the target to call in that
directory. If path starts with a slash
(/), it is treated as a file and its existence
is tested with test -e; otherwise, it is
assumed to be an executable, and which -s is
used to determine if the program exists in the user's search
path.For example,
RUN_DEPENDS= ${PREFIX}/etc/innd:${PORTSDIR}/news/inn \
wish8.0:${PORTSDIR}/x11-toolkits/tk80will check if the file or directory
/usr/local/etc/innd exists, and build and
install it from the news/inn subdirectory of
the ports tree if it is not found. It will also see if an
executable called wish8.0 is in your search
path, and descend into the x11-toolkits/tk80
subdirectory of your ports tree to build and install it if it is
not found.In this case, innd is actually an
executable; if an executable is in a place that is not expected
to be in a normal user's search path, you should use the full
pathname.The dependency is checked from within the
install target. Also, the name of the
dependency is put in to the package so that
pkg_add will automatically install it if it is
not on the user's system. The target
part can be omitted if it is the same
DEPENDS_TARGET.BUILD_DEPENDSThis variable specifies executables or files this port
requires to build. Like RUN_DEPENDS, it is a
list of
path:dir:target
tuples. For example, BUILD_DEPENDS=
unzip:${PORTSDIR}/archivers/unzip will check
for an executable called unzip, and descend
into the archivers/unzip subdirectory of your
ports tree to build and install it if it is not found.“build” here means everything from extracting to
compilation. The dependency is checked from within the
extract target. The
target part can be omitted if it is
the same as DEPENDS_TARGETFETCH_DEPENDSThis variable specifies executables or files this port
requires to fetch. Like the previous two, it is a list of
path:dir:target
tuples. For example, FETCH_DEPENDS=
ncftp2:${PORTSDIR}/net/ncftp2 will check for an
executable called ncftp2, and descend into the
net/ncftp2 subdirectory of your ports tree to
build and install it if it is not found.The dependency is checked from within the
fetch target. The
target part can be omitted if it is the
same as DEPENDS_TARGET.DEPENDSIf there is a dependency that does not fall into either of the
above four categories, or your port requires to have the source of
the other port extracted in addition to having them installed,
then use this variable. This is a list of
dir:target,
as there is nothing to check, unlike the previous four. The
target part can be omitted if it is the
same as DEPENDS_TARGET.Common dependency variablesDefine USE_XLIB=yes if your port requires
the X Window System to be installed (it is implied by
USE_IMAKE). Define
USE_GMAKE=yes if your port requires GNU
make instead of BSD make.
Define USE_AUTOCONF=yes if your port requires
GNU autoconf to be run. Define USE_QT=yes if
your port uses the latest qt toolkit. Use
USE_PERL5=yes if your port requires version 5
of the perl language. (The last is especially important since
some versions of FreeBSD has perl5 as part of the base system
while others don't.)Notes on dependenciesAs mentioned above, the default target to call when a
dependency is required is DEPENDS_TARGET.
It defaults to install. This is a user
variable; is is never defined in a port's
Makefile. If your port needs a special way
to handle a dependency, use the :target part of
the *_DEPENDS variables instead of redefining
DEPENDS_TARGET.When you type make clean, its dependencies
are automatically cleaned too. If you do not wish this to happen,
define the variable NOCLEANDEPENDS in your
environment.To depend on another port unconditionally, it is customary to
use the string nonexistent as the first field
of BUILD_DEPENDS or
RUN_DEPENDS. Use this only when you need to
the to get to the source of the other port. You can often save
compilation time by specifying the target too. For
instance
BUILD_DEPENDS= /nonexistent:${PORTSDIR}/graphics/jpeg:extract
will always descend to the JPEG port and extract it.Do not use DEPENDS unless there is no other
way the behaviour you want can be accomplished. It will cause the
other port to be always build (and installed, by default), and the
dependency will go into the packages as well. If this is really
what you need, I recommend you write it as
BUILD_DEPENDS and
RUN_DEPENDS instead—at least the
intention will be clear.Building mechanismsIf your package uses GNU make, set
USE_GMAKE=yes. If your package uses
configure, set
HAS_CONFIGURE=yes. If your package uses GNU
configure, set
GNU_CONFIGURE=yes (this implies
HAS_CONFIGURE). If you want to give some extra
arguments to configure (the default argument list
--prefix=${PREFIX} for GNU
configure and empty for non-GNU
configure), set those extra arguments in
CONFIGURE_ARGS. If your package uses GNU
autoconf, set
USE_AUTOCONF=yes. This implies
GNU_CONFIGURE, and will cause
autoconf to be run before
configure.If your package is an X application that creates
Makefiles from Imakefiles
using imake, then set
USE_IMAKE=yes. This will cause the configure
stage to automatically do an xmkmf -a. If the
flag is a problem for your port, set
XMKMF=xmkmf. If the port uses
imake but does not understand the
install.man target,
NO_INSTALL_MANPAGES=yes should be set. In
addition, the author of the original port should be shot. :>If your port's source Makefile has
something else than all as the main build
target, set ALL_TARGET accordingly. Same goes
for install and
INSTALL_TARGET.Special considerationsThere are some more things you have to take into account when you
create a port. This section explains the most common of those.ldconfigIf your port installs a shared library, add a
post-install target to your
Makefile that runs ${LDCONFIG}
-m on the directory where the new library is installed
(usually PREFIX/lib) to
register it into the shared library cache.Also, add a matching @exec /sbin/ldconfig -m
and @unexec /sbin/ldconfig -R pair to your
pkg/PLIST file so that a user who installed the
- package can start using teh shared libraru immediately and
+ package can start using the shared library immediately and
deinstallation will not cause the system to still believe the
library is there. These lines should immediately follow the line
for the shared library itself, as in:
lib/libtvl80.so.1
@exec /sbin/ldconfig -m %D/lib
@unexec /sbin/ldconfig -RNever, ever, ever add a line that says
ldconfig without any arguments to your
Makefile or pkg/PLIST.
- This will reset the shared libraru cache to the contents of
+ This will reset the shared library cache to the contents of
/usr/lib only, and will royally screw up the
user's machine ("Help, xinit does not run anymore after I install
this port!"). Anybody who does this will be shot and cut in 65,536
pieces by a rusty knife and have is liver chopped out by a bunch of
crows and will eternally rot to death in the deepest bowels of hell
(not necessarily in that order…)ELF supportSince FreeBSD is moving to ELF shortly after 3.0-RELEASE, we need
to convert many ports that build shared libraries to support ELF.
Complicating this task is that a 3.0 system can run as both ELF and
a.out, and we wish to unofficially support the 2.2 as long as
possible. Below are the guidelines on how to convert a.out only ports
to support both a.out and ELF compilation.Some part of this list is only applicable during the conversion,
but will be left here for awhile for reference in case you have come
across some old port you wish to upgrade.Moving a.out libraries out of the wayA.out libraries should be moved out of
/usr/local/lib and similar to an
aout subdirectory. (If you don't move them out
of the way, ELF ports will happily overwrite a.out libraries.) The
move-aout-libs target in the 3.0-CURRENT
src/Makefile (called from
aout-to-elf) will do this for you. It will
only move a.out libs so it is safe to call it on a system with both
ELF and a.out libs in the standard directories.FormatThe ports tree will build packages in the format the machine is
in. This means a.out for 2.2 and a.out or ELF for 3.0 depending on
what `objformat` returns. Also, once users move
a.out libraries to a subdirectory, building a.out libraries will be
unsupported. (I.e., it may still work if you know what you are
doing, but you are on your own.)If a port only works for a.out, set
BROKEN_ELF to a string describing the reason
why. Such ports will be skipped during a build on an ELF
system.PORTOBJFORMATbsd.port.mk will set
PORTOBJFORMAT to aout or
elf and export it in the environments
CONFIGURE_ENV, SCRIPTS_ENV and
MAKE_ENV. (It's always going to be
aout in 2.2-STABLE). It is also passed to
PLIST_SUB as
PORTOBJFORMAT=${PORTOBJFORMAT}. (See comment on
ldconfig lines below.)The variable is set using this line in
bsd.port.mk:
PORTOBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aoutPorts' make processes should use this variable to decide what to
do. However, if the port's configure script
already automatically detects an ELF system, it is not necessary to
refer to PORTOBJFORMAT.Building shared librariesThe following are differences in handling shared libraries for
a.out and ELF.Shared library versionsAn ELF shared library should be called
libfoo.so.M
where M is the single version number,
and an a.out library should be called
libfoo.so.M.N
where M is the major version and
N is the the minor version number.
Do not mix those; never install an ELF
shared library called
libfoo.so.N.M
or an a.out shared library (or symlink) called
libfoo.so.N.Linker command linesAssuming cc -shared is used rather than
ld directly, the only difference is that you
need to add
on the command line for ELF.You need to install a symlink from
libfoo.so to
libfoo.so.N to make
ELF linkers happy. Since it should be listed in
PLIST too, and it won't hurt in the a.out case
(some ports even require the link for dynamic loading), you should
just make this link regardless of the setting of
PORTOBJFORMAT.LIB_DEPENDSAll port Makefiles are edited to remove minor numbers from
LIB_DEPENDS, and also to have the regexp support
removed. (E.g., foo\\.1\\.\\(33|40\\) becomes
foo.2.) They will be matched using grep
-wF.PLISTPLIST should contain the short (ELF) shlib
names if the a.out minor number is zero, and the long (a.out) names
otherwise. bsd.port.mk will automatically add
.0 to the end of short shlib lines if
PORTOBJFORMAT equals aout, and
will delete the minor number from long shlib names if
PORTOBJFORMAT equals
elf.In cases where you really need to install shlibs with two
versions on an ELF system or those with one version on an a.out
system (for instance, ports that install compatibility libraries for
other operating systems), define the variable
NO_FILTER_SHLIBS. This will turn off the editing
of PLIST mentioned in the previous
paragraph.ldconfigThe ldconfig line in Makefiles should
read:
${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m ....In PLIST it should read;
@exec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -m ...
@unexec /usr/bin/env OBJFORMAT=%%PORTOBJFORMAT%% /sbin/ldconfig -RThis is to ensure that the correct ldconfig
will be called depending on the format of the package, not the
default format of the system.MASTERDIRIf your port needs to build slightly different versions of
packages by having a variable (for instance, resolution, or paper
size) take different values, create one subdirectory per package to
make it easier forusers to see what to do, but try to share as many
files as possible between ports. Typically you only need a very short
Makefile in all but one of the directories if you
use variables cleverly. In the sole Makefiles,
you can use MASTERDIR to specify the directory
where the rest of the files are. Also, use a variable as part of
PKGNAME so
the packages will have different names.This will be best demonstrated by an example. This is part of
japanese/xdvi300/Makefile;
PKGNAME= ja-xdvi${RESOLUTION}-17
:
# default
RESOLUTION?= 300
.if ${RESOLUTION} != 118 && ${RESOLUTION} != 240 && \
${RESOLUTION} != 300 && ${RESOLUTION} != 400
@${ECHO} "Error: invalid value for RESOLUTION: \"${RESOLUTION}\""
@${ECHO} "Possible values are: 118, 240, 300 (default) and 400."
@${FALSE}
.endifjapanese/xdvi300 also has all the regular
patches, package files, etc. If you type make
there, it will take the default value for the resolution (300) and
build the port normally.As for other resolutions, this is the entirexdvi118/Makefile;
RESOLUTION= 118
MASTERDIR= ${.CURDIR}/../xdvi300
.include ${MASTERDIR}/Makefile(xdvi240/Makefile and
xdvi400/Makefile are similar). The
MASTERDIR definition tells
bsd.port.mk that the refulat set of
subdirectories like PATCHDIR and
PKGDIR are to be found under
xdvi300. The RESOLUTION=118
line will override the RESOLUTION=300 line in
xdvi300/Makefile and the port will be built with
resolution set to 118.Shared library versionsFirst, please read our policy on
shared library versioning to understand what to do with
shared library versions in general. Do not blindly assume software
authors know what they are doing; many of them do not. It is very
important that these details are carefully considered, as we have
quite a unique situation where we are trying to have dozens of
potentially incompatible software pairs co-exist. Careless port
imports have caused great trouble regarding shared libraries in the
past (ever wondered why the port jpeg-6b has a
shared library version of 9.0?). If in doubt, send a message to the
&a.ports;. Most of the time, your job ends by determining the right
shared library version and making appropriate patches to implement
it.However, if there is a port which is a different version of the
same software already in the tree, the situation is much more complex.
In short, the FreeBSD implementation does not allow the user to
specify to the linker which version of shared library to link against
(the linker will always pick the highest numbered version). This
means, if there is a libfoo.so.3.2 and
libfoo.so.4.0 in the system, there is no way to
tell the linker to link a particular application to
libfoo.so.3.2. It is essentially completely
overshadowed in terms of compilation-time linkage. In this case, the
only solution is to rename the base part of the
shared library. For instance, change
libfoo.so.4.0 to
libfoo4.so.1.0 so both version 3.2 and 4.0 can be
linked from other ports.ManpagesThe MAN[1-9LN] variables will automatically add
any manpages to pkg/PLIST (this means you must
not list manpages in the
PLIST—see generating PLIST for more). It also
makes the install stage automatically compress or uncompress manpages
depending on the setting of NOMANCOMPRESS in
/etc/make.conf.To specify whether the manpages are compressed upon installation,
use the MANCOMPRESSED variable. This variable can
take three values, yes, no and
maybe. yes means manpages are
already installed compressed, no means they are
not, and maybe means the software already respects
the value of NOMANCOMPRESS so
bsd.port.mk does not have to do anything
special.MANCOMPRESSED is automatically set to
yes if USE_IMAKE is set and
NO_INSTALL_MANPAGES is not set, and to
no otherwise. You don't have to explicitly define
it unless the default is not suitable for your port.If your port anchors its man tree somewhere other than
PREFIX, you can use the
MANPREFIX to set it. Also, if only manpages in
certain sections go in a non-standard place, such as some Perl modules
ports, you can set individual man paths using
MANsectPREFIX (where
sect is one of 1-9,
L or N).If your manpages go to language-specific subdirectories, set the
name of the languages to MANLANG. The value of
this variable defaults to "" (i.e., English
only).Here is an example that puts it all together.
MAN1= foo.1
MAN3= bar.3
MAN4= baz.4
MANLANG= "" ja
MAN3PREFIX= ${PREFIX}/share/foobar
MANCOMPRESSED= yesThis states that six files are installed by this port;
${PREFIX}/man/man1/foo.1.gz
${PREFIX}/man/ja/man1/foo.1.gz
${PREFIX}/share/foobar/man/man3/bar.3.gz
${PREFIX}/share/foobar/man/ja/man3/bar.3.gz
${PREFIX}/man/man4/baz.4.gz
${PREFIX}/man/ja/man4/baz.4.gzPorts that require MotifThere are many programs that require a Motif library (available
from several commercial vendors, while there is a free clone reported
to be able to run many applications in
x11-toolkits/lesstif) to compile. Since it is a
popular toolkit and their licenses usually permit redistribution of
statically linked binaries, we have made special provisions for
handling ports that require Motif in a way that we can easily compile
binaries linked either dynamically (for people who are compiling from
the port) or statically (for people who distribute packages).REQUIRES_MOTIFIf your port requires Motif, define this variable in the
Makefile. This will prevent people who don't own a copy of Motif
from even attempting to build it.MOTIFLIBThis variable will be set by bsd.port.mk to
be the appropriate reference to the Motif library. Please patch the
source to use this wherever the Motif library is referenced in the
Makefile or
Imakefile.There are two common cases:If the port refers to the Motif library as
-lXm in its Makefile or
Imakefile, simply substitute
${MOTIFLIB} for it.If the port uses XmClientLibs in its
Imakefile, change it to
${MOTIFLIB} ${XTOOLLIB}
${XLIB}.Note that MOTIFLIB (usually) expands to
-L/usr/X11R6/lib -lXm or
/usr/X11R6/lib/libXm.a, so there is no need to
add -L or -l in front.X11 fontsIf your port installs fonts for the X Window system, put them in
X11BASE/lib/X11/fonts/local.
This directory is new to XFree86 release 3.3.3. If it does not exist,
please create it, and print out a message urging the user to update
their XFree86 to 3.3.3 or newer, or at least add this directory to the
font path in /etc/XF86Config.Info filesThe new version of texinfo (included in 2.2.2-RELEASE and onwards)
contains a utility called install-info to add and
delete entries to the dir file. If your port
installs any info documents, please follow this instructions so your
port/package will correctly update the user's
PREFIX/info/dir file. (Sorry
for the length of this section, but is it imperative to weave all the
info files together. If done correctly, it will produce a
beautiful listing, so please bear with me!First, this is what you (as a porter) need to know&prompt.user; install-info --help
install-info [OPTION]... [INFO-FILE [DIR-FILE]]
Install INFO-FILE in the Info directory file DIR-FILE.
Options:
--delete Delete existing entries in INFO-FILE;
don't insert any new entries.
:
--entry=TEXT Insert TEXT as an Info directory entry.
:
--section=SEC Put this file's entries in section SEC of the directory. :This program will not actually install info
files; it merely inserts or deletes entries in the
dir file.Here's a seven-step procedure to convert ports to use
install-info. I will use
editors/emacs as an example.Look at the texinfo sources and make a patch to insert
@dircategory and @direntry
statements to files that don't have them. This is part of my
patch:
--- ./man/vip.texi.org Fri Jun 16 15:31:11 1995
+++ ./man/vip.texi Tue May 20 01:28:33 1997
@@ -2,6 +2,10 @@
@setfilename ../info/vip
@settitle VIP
+@dircategory The Emacs editor and associated tools
+@direntry
+* VIP: (vip). A VI-emulation for Emacs.
+@end direntry
@iftex
@finalout
:The format should be self-explanatory. Many authors leave a
dir file in the source tree that contains all
the entries you need, so look around before you try to write your
own. Also, make sure you look into related ports and make the
section names and entry indentations consistent (we recommend that
all entry text start at the 4th tab stop).Note that you can put only one info entry per file because
of a bug in install-info --delete that
deletes only the first entry if you specify multiple entries in
the @direntry section.You can give the dir entries to
install-info as arguments
( and ) instead
of patching the texinfo sources. I do not think this is a good
idea for ports because you need to duplicate the same information
in three places
(Makefile and
@exec/@unexec of
PLIST; see below). However, if you have a
Japanese (or other multibyte encoding) info files, you will have
to use the extra arguments to install-info
because makeinfo can't handle those texinfo
sources. (See Makefile and
PLIST of japanese/skk
for examples on how to do this).Go back to the port directory and do a make clean;
make and verify that the info files are regenerated
from the texinfo sources. Since the texinfo sources are newer than
the info files, they should be rebuilt when you type
make; but many Makefiles
don't include correct dependencies for info files. In
emacs' case, I had to patch the main
Makefile.in so it will descend into the
man subdirectory to rebuild the info
pages.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Tue Apr 15 00:15:28 1997
@@ -184,7 +184,7 @@
# Subdirectories to make recursively. `lisp' is not included
# because the compiled lisp files are part of the distribution
# and you cannot remake them without installing Emacs first.
-SUBDIR = lib-src src
+SUBDIR = lib-src src man
# The makefiles of the directories in $SUBDIR.
SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile
--- ./man/Makefile.in.org Thu Jun 27 15:27:19 1996
+++ ./man/Makefile.in Tue Apr 15 00:29:52 1997
@@ -66,6 +66,7 @@
${srcdir}/gnu1.texi \
${srcdir}/glossary.texi
+all: info
info: $(INFO_TARGETS)
dvi: $(DVI_TARGETS)The second hunk was necessary because the default target in
the man subdir is called
info, while the main
Makefile wants to call
all. I also deleted the installation of
the info info file because we already have
one with the same name in /usr/share/info
(that patch is not shown here).If there is a place in the Makefile that
is installing the dir file, delete it. Your
port may not be doing it. Also, remove any commands that are
otherwise mucking around with the dir
file.
--- ./Makefile.in.org Mon Aug 19 21:12:19 1996
+++ ./Makefile.in Mon Apr 14 23:38:07 1997
@@ -368,14 +368,8 @@
if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
then \
(cd ${infodir}; \
- if [ -f dir ]; then \
- if [ ! -f dir.old ]; then mv -f dir dir.old; \
- else mv -f dir dir.bak; fi; \
- fi; \
cd ${srcdir}/info ; \
- (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
- (cd $${thisdir}; chmod a+r ${infodir}/dir); \
for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
(cd $${thisdir}; \
${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
chmod a+r ${infodir}/$$f); \(This step is only necessary if you are modifying an existing
port.) Take a look at pkg/PLIST and delete
anything that is trying to patch up info/dir.
They may be in pkg/INSTALL or some other
file, so search extensively.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/04/15 06:32:12
@@ -15,9 +15,6 @@
man/man1/emacs.1.gz
man/man1/etags.1.gz
man/man1/ctags.1.gz
-@unexec cp %D/info/dir %D/info/dir.bak
-info/dir
-@unexec cp %D/info/dir.bak %D/info/dir
info/cl
info/cl-1
info/cl-2Add a post-install target to the
Makefile to create a dir
file if it is not there. Also, call
install-info with the installed info
files.
Index: Makefile
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/Makefile,v
retrieving revision 1.26
diff -u -r1.26 Makefile
--- Makefile 1996/11/19 13:14:40 1.26
+++ Makefile 1997/05/20 10:25:09 1.28
@@ -20,5 +20,11 @@
post-install:
.for file in emacs-19.34 emacsclient etags ctags b2m
strip ${PREFIX}/bin/${file}
.endfor
+ if [ ! -f ${PREFIX}/info/dir ]; then \
+ ${SED} -ne '1,/Menu:/p' /usr/share/info/dir > ${PREFIX}/info/dir; \
+ fi
+.for info in emacs vip viper forms gnus mh-e cl sc dired-x ediff ccmode
+ install-info ${PREFIX}/info/${info} ${PREFIX}/info/dir
+.endfor
.include <bsd.port.mk>Do not use anything other than
/usr/share/info/dir and the above command to
create a new info file. In fact, I'd add the first three lines of
the above patch to bsd.port.mk if you (the
porter) wouldn't have to do it in PLIST by
yourself anyway.Edit PLIST and add equivalent
@exec statements and also
@unexec for pkg_delete. You
do not need to delete info/dir with
@unexec.
Index: pkg/PLIST
===================================================================
RCS file: /usr/cvs/ports/editors/emacs/pkg/PLIST,v
retrieving revision 1.15
diff -u -r1.15 PLIST
--- PLIST 1997/03/04 08:04:00 1.15
+++ PLIST 1997/05/20 10:25:12 1.17
@@ -16,7 +14,15 @@
man/man1/etags.1.gz
man/man1/ctags.1.gz
+@unexec install-info --delete %D/info/emacs %D/info/dir
:
+@unexec install-info --delete %D/info/ccmode %D/info/dir
info/cl
info/cl-1
@@ -87,6 +94,18 @@
info/viper-3
info/viper-4
+@exec [ -f %D/info/dir ] || sed -ne '1,/Menu:/p' /usr/share/info/dir > %D/info/dir
+@exec install-info %D/info/emacs %D/info/dir
:
+@exec install-info %D/info/ccmode %D/info/dir
libexec/emacs/19.34/i386--freebsd/cvtmail
libexec/emacs/19.34/i386--freebsd/digest-docThe @unexec install-info --delete
commands have to be listed before the info files themselves so
they can read the files. Also, the @exec
install-info commands have to be after the info
files and the @exec command that creates the
the dir file.Test and admire your
work. :). Check the
dir file before and after each step.The pkg/ subdirectoryThere are some tricks we haven't mentioned yet about the
pkg/ subdirectory that come in handy
sometimes.MESSAGEIf you need to display a message to the installer, you may place
the message in pkg/MESSAGE. This capability is
often useful to display additional installation steps to be taken
after a pkg_add or to display licensing
information.The pkg/MESSAGE file does not need to be
added to pkg/PLIST. Also, it will not get
automatically printed if the user is using the port, not the
package, so you should probably display it from the
post-install target yourself.INSTALLIf your port needs to execute commands when the binary package
is installed with pkg_add you can do this via the
pkg/INSTALL script. This script will
automatically be added to the package, and will be run twice by
pkg_add. The first time will as INSTALL
${PKGNAME} PRE-INSTALL and the second time as
INSTALL ${PKGNAME} POST-INSTALL.
$2 can be tested to determine which mode
the script is being run in. The PKG_PREFIX
environmental variable will be set to the package installation
directory. See &man.pkg.add.1; for
additional information.This script is not run automatically if you install the port
with make install. If you are depending on it
being run, you will have to explicitly call it from your port's
Makefile.REQIf your port needs to determine if it should install or not, you
can create a pkg/REQ “requirements”
script. It will be invoked automatically at
installation/deinstallation time to determine whether or not
installation/deinstallation should proceed.Changing PLIST based on make
variablesSome ports, particularly the p5- ports, need to change their
PLIST depending on what options they are
configured with (or version of perl, in the case of p5- ports). To
make this easy, any instances in the PLIST of
%%OSREL%%, %%PERL_VER%%, and
%%PERL_VERSION%% will be substituted for
appropriately. The value of %%OSREL%% is the
numeric revision of the operating system (e.g.,
2.2.7). %%PERL_VERSION%% is
the full version number of perl (e.g., 5.00502)
and %%PERL_VER%% is the perl version number minus
the patchlevel (e.g., 5.005).If you need to make other substitutions, you can set the
PLIST_SUB variable with a list of
VAR=VALUE
pairs and instances of
%%VAR%%' will be
substituted with VALUE in the
PLIST.For instance, if you have a port that installs many files in a
version-specific subdirectory, you can put something like
OCTAVE_VERSION= 2.0.13
PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION}
in the Makefile and use
%%OCTAVE_VERSION%% wherever the version shows up
in PLIST. That way, when you upgrade the port,
you will not have to change dozens (or in some cases, hundreds) of
lines in the PLIST.This substitution (as well as addition of any man pages) will be done between
the do-install and
post-install targets, by reading from
PLIST and writing to TMPPLIST
(default:
WRKDIR/.PLIST.mktmp). So if
your port builds PLIST on the fly, do so in or
before do-install. Also, if your port
needs to edit the resulting file, do so in
post-install to a file named
TMPPLIST.Changing the names of files in the
pkg subdirectoryAll the filenames in the pkg subdirectory
are defined using variables so you can change them in your
Makefile if need be. This is especially useful
when you are sharing the same pkg subdirectory
among several ports or have to write to one of the above files (see
writing to places other than
WRKDIR for why it is a bad idea to write
directly in to the pkg subdirectory.Here is a list of variable names and their default
values.VariableDefault valueCOMMENT${PKGDIR}/DESCRDESCR${PKGDIR}/DESCRPLIST${PKGDIR}/PLISTPKGINSTALL${PKGDIR}/PKGINSTALLPKGDEINSTALL${PKGDIR}/PKGDEINSTALLPKGREQ${PKGDIR}/REQPKGMESSAGE${PKGDIR}/MESSAGEPlease change these variables rather than overriding
PKG_ARGS. If you change
PKG_ARGS, those files will not correctly be
installed in /var/db/pkg upon install from a
port.Licensing ProblemsSome software packages have restrictive licenses or can be in
violation to the law (PKP's patent on public key crypto, ITAR (export
of crypto software) to name just two of them). What we can do with
them varies a lot, depending on the exact wordings of the respective
licenses.It is your responsibility as a porter to read the licensing
terms of the software and make sure that the FreeBSD project will
not be held accountable of violating them by redistributing the
source or compiled binaries either via ftp or CD-ROM. If in doubt,
please contact the &a.ports;.There are two variables you can set in the Makefile to handle the
situations that arise frequently:If the port has a “do not sell for profit” type of
license, set the variable NO_CDROM to a string
describing the reason why. We will make sure such ports won't go
into the CD-ROM come release time. The distfile and package will
still be available via ftp.If the resulting package needs to be built uniquely for each
site, or the resulting binary package can't be distributed due to
licensing; set the variable NO_PACKAGE to a
string describing the reason why. We will make sure such packages
won't go on the ftp site, nor into the CD-ROM come release time.
The distfile will still be included on both however.If the port has legal restrictions on who can use it (e.g.,
crypto stuff) or has a “no commercial use” license,
set the variable RESTRICTED to be the string
describing the reason why. For such ports, the distfiles/packages
will not be available even from our ftp sites.The GNU General Public License (GPL), both version 1 and 2,
should not be a problem for ports.If you are a committer, make sure you update the
ports/LEGAL file too.UpgradingWhen you notice that a port is out of date compared to the latest
version from the original authors, first make sure you have the latest
port. You can find them in the
ports/ports-current directory of the ftp mirror
sites.The next step is to send a mail to the maintainer, if one is
listed in the port's Makefile. That person may
already be working on an upgrade, or have a reason to not upgrade the
port right now (because of, for example, stability problems of the new
version).If the maintainer asks you to do the upgrade or there isn't any
such person to begin with, please make the upgrade and send the
recursive diff (either unified or context diff is fine, but port
committers appear to prefer unified diff more) of the new and old
ports directories to us (e.g., if your modified port directory is
called superedit and the original as in our tree
is superedit.bak, then send us the result of
diff -ruN superedit.bak superedit). Please examine
the output to make sure all the changes make sense. The best way to
send us the diff is by including it to &man.send-pr.1; (category
ports). Please mention any added or deleted files
in the message, as they have to be explicitly specified to CVS when
doing a commit. If the diff is more than about 20KB, please compress
and uuencode it; otherwise, just include it in as is in the PR.Once again, please use &man.diff.1; and not &man.shar.1; to send
updates to ports.Do's and Dont'sHere is a list of common do's and dont's that you encounter during
the porting process.You should check your own port against this list,
but you can also check ports in the PR database that others have
submitted. Submit any comments on ports you check as described in
Bug Reports and General
Commentary. Checking ports in the PR database will both make
it faster for us to commit them, and prove that you know what you are
doing.Strip BinariesDo strip binaries. If the original source already strips the
binaries, fine; otherwise you should add a
post-install rule to to it yourself. Here is an
example;
post-install:
strip ${PREFIX}/bin/xdlUse the &man.file.1; command on the installed executable to
check whether the binary is stripped or not. If it does not say
not stripped, it is stripped.INSTALL_* macrosDo use the macros provided in bsd.port.mk
to ensure correct modes and ownership of files in your own
*-install targets. They are:INSTALL_PROGRAM is a command to install
binary executables.INSTALL_SCRIPT is a command to install
executable scripts.INSTALL_DATA is a command to install
sharable data.INSTALL_MAN is a command to install
manpages and other documentation (it doesn't compress
anything).These are basically the install command with
all the appropriate flags. See below for an example on how to use
them.WRKDIRDo not write anything to files outside
WRKDIR. WRKDIR is the only
place that is guaranteed to be writable during the port build (see
compiling ports from CDROM for an
example of building ports from a read-only tree). If you need to
modigy some file in PKGDIR, do so by redefining a variable, not by
writing over it.WRKDIRPREFIXMake sure your port honors WRKDIRPREFIX.
Most ports don't have to worry about this. In particular, if you
are referring to a WRKDIR of another port, note
that the correct location is
WRKDIRPREFIXPORTSDIR/subdir/name/work not PORTSDIR/subdir/name/work or .CURDIR/../../subdir/name/work or some such.Also, if you are defining WRKDIR yourself,
make sure you prepend
${WKRDIRPREFIX}${.CURDIR} in the
front.Differentiating operating systems and OS versionsYou may come across code that needs modifications or conditional
compilation based upon what version of UNIX it is running under. If
you need to make such changes to the code for conditional
compilation, make sure you make the changes as general as possible
so that we can back-port code to FreeBSD 1.x systems and cross-port
to other BSD systems such as 4.4BSD from CSRG, BSD/386, 386BSD,
NetBSD, and OpenBSD.The preferred way to tell 4.3BSD/Reno (1990) and newer versions
of the BSD code apart is by using the BSD macro
defined in <sys/param.h>. Hopefully that
file is already included; if not, add the code:
#if (defined(__unix__) || defined(unix)) && !defined(USG)
#include <sys/param.h>
#endifto the proper place in the .c file. We
believe that every system that defines these two symbols has
sys/param.h. If you find a system that
doesn't, we would like to know. Please send mail to the
&a.ports;.Another way is to use the GNU Autoconf style of doing
this:
#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h>
#endifDon't forget to add -DHAVE_SYS_PARAM_H to the
CFLAGS in the Makefile for
this method.Once you have sys/param.h included, you may
use:
#if (defined(BSD) && (BSD >= 199103))to detect if the code is being compiled on a 4.3 Net2 code base
or newer (e.g. FreeBSD 1.x, 4.3/Reno, NetBSD 0.9, 386BSD, BSD/386
1.1 and below).Use:
#if (defined(BSD) && (BSD >= 199306))to detect if the code is being compiled on a 4.4 code base or
newer (e.g. FreeBSD 2.x, 4.4, NetBSD 1.0, BSD/386 2.0 or
above).The value of the BSD macro is
199506 for the 4.4BSD-Lite2 code base. This is
stated for informational purposes only. It should not be used to
distinguish between versions of FreeBSD based only on 4.4-Lite vs.
versions that have merged in changes from 4.4-Lite2. The
__FreeBSD__ macro should be used instead.Use sparingly:__FreeBSD__ is defined in all versions of
FreeBSD. Use it if the change you are making
only affects FreeBSD. Porting gotchas like
the use of sys_errlist[] vs
strerror() are Berkeleyisms, not FreeBSD
changes.In FreeBSD 2.x, __FreeBSD__ is defined to
be 2. In earlier versions, it is
1. Later versions will bump it to match
their major version number.If you need to tell the difference between a FreeBSD 1.x
system and a FreeBSD 2.x or 3.x system, usually the right answer
is to use the BSD macros described above. If
there actually is a FreeBSD specific change (such as special
shared library options when using ld) then it
is OK to use __FreeBSD__ and #if
__FreeBSD__ > 1 to detect a FreeBSD 2.x and later
system. If you need more granularity in detecting FreeBSD
systems since 2.0-RELEASE you can use the following:
#if __FreeBSD__ >= 2
#include <osreldate.h>
# if __FreeBSD_version >= 199504
/* 2.0.5+ release specific code here */
# endif
#endifRelease__FreeBSD_version2.0-RELEASE1194112.1-CURRENTs199501, 1995032.0.5-RELEASE1995042.2-CURRENT before 2.11995082.1.0-RELEASE1995112.2-CURRENT before 2.1.51995122.1.5-RELEASE1996072.2-CURRENT before 2.1.61996082.1.6-RELEASE1996122.1.7-RELEASE1996122.2-RELEASE2200002.2.1-RELEASE220000 (no change)2.2-STABLE after 2.2.1-RELEASE220000 (no change)2.2-STABLE after texinfo-3.92210012.2-STABLE after top2210022.2.2-RELEASE2220002.2-STABLE after 2.2.2-RELEASE2220012.2.5-RELEASE2250002.2-STABLE after 2.2.5-RELEASE2250012.2-STABLE after ldconfig -R merge2250022.2.6-RELEASE2260002.2.7-RELEASE2270002.2-STABLE after 2.2.7-RELEASE2270012.2-STABLE after semctl(2) change2270022.2.8-RELEASE2280002.2-STABLE after 2.2.8-RELEASE2280013.0-CURRENT before mount(2) change3000003.0-CURRENT after mount(2) change3000013.0-CURRENT after semctl(2) change3000023.0-CURRENT after ioctl arg changes3000033.0-CURRENT after ELF conversion3000043.0-RELEASE3000053.0-CURRENT after 3.0-RELEASE3000063.0-STABLE after 3/4 branch3000073.1-RELEASE3100003.1-STABLE after 3.1-RELEASE3100014.0-CURRENT after 3/4 branch400000Note that 2.2-STABLE sometimes identifies itself as
“2.2.5-STABLE” after the 2.2.5-RELEASE. The pattern
used to be year followed by the month, but we decided to change it
to a more straightforward major/minor system starting from 2.2.
This is because the parallel development on several branches made
it infeasible to classify the releases simply by their real
release dates. If you are making a port now, you don't have to
worry about old -CURRENTs; they are listed here just for your
reference.In the hundreds of ports that have been done, there have only
been one or two cases where __FreeBSD__ should
have been used. Just because an earlier port screwed up and used it
in the wrong place does not mean you should do so too.Writing something after
bsd.port.mkDo not write anything after the .include
<bsd.port.mk> line. it usually can be avoided by
including bsd.port.pre.mk somewhere in the
middle of your Makefile and
bsd.port.post.mk at the end.You need to include either the
pre.mk/post.mk pair or
bsd.port.mk only; don't mix these two.bsd.port.pre.mk only defines a few
variables, which can be used in tests in the
Makefile, bsd.port.post.mk
defines the rest.Here are some important variables defined in
bsd.port.pre.mk (this is not the complete list,
please read bsd.port.mk for the complete
list).VariableDescriptionARCHThe architecture as returned by uname
-m (e.g., i386)OPSYSThe operating system type, as returned by
uname -s (e.g.,
FreeBSD)OSRELThe release version of the operating system (e.g.,
2.1.5 or
2.2.7)OSVERSIONThe numeric version of the operating system, same as
__FreeBSD_version.PORTOBJFORMATThe object format of the system
(aout or elfLOCALBASEThe base of the “local” tree (e.g.,
/usr/local/)X11BASEThe base of the “X11” tree (e.g.,
/usr/X11R6)PREFIXWhere the port installs itself (see more on
PREFIX).If you have to define the variables
USE_IMAKE, USE_X_PREFIX, or
MASTERDIR, do so before including
bsd.port.pre.mk.Here are some examples of things you can write after
bsd.port.pre.mk;
# no need to compile lang/perl5 if perl5 is already in system
.if ${OSVERSION} > 300003
BROKEN= perl is in system
.endif
# only one shlib version number for ELF
.if ${PORTOBJFORMAT} == "elf"
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}
.else
TCL_LIB_FILE= ${TCL_LIB}.${SHLIB_MAJOR}.${SHLIB_MINOR}
.endif
# software already makes link for ELF, but not for a.out
post-install:
.if ${PORTOBJFORMAT} == "aout"
${LN} -sf liblinpack.so.1.0 ${PREFIX}/lib/liblinpack.so
.endifInstall additional documentationIf your software has some documentation other than the standard
man and info pages that you think is useful for the user, install it
under PREFIX/share/doc.
This can be done, like the previous item, in the
post-install target.Create a new directory for your port. The directory name should
reflect what the port is. This usually means
PKGNAME minus the version part. However, if you
think the user might want different versions of the port to be
installed at the same time, you can use the whole
PKGNAME.Make the installation dependent to the variable
NOPORTDOCS so that users can disable it in
/etc/make.conf, like this:
post-install:
.if !defined(NOPORTDOCS)
${MKDIR}${PREFIX}/share/doc/xv
${INSTALL_MAN} ${WRKSRC}/docs/xvdocs.ps ${PREFIX}/share/doc/xv
.endifDo not forget to add them to pkg/PLIST too!
(Do not worry about NOPORTDOCS here; there is
currently no way for the packages to read variables from
/etc/make.conf.)Also you can use the pkg/MESSAGE file to
display messages upon installation. See the using
pkg/MESSAGE section for
details.MESSAGE does not need to be added to
pkg/PLIST).DIST_SUBDIRDo not let your port clutter
/usr/ports/distfiles. If your port requires a
lot of files to be fetched, or contains a file that has a name that
might conflict with other ports (e.g.,
Makefile), set DIST_SUBDIR
to the name of the port (PKGNAME without the
version part should work fine). This will change
DISTDIR from the default
/usr/ports/distfiles to
/usr/ports/distfiles/DIST_SUBDIR,
and in effect puts everything that is required for your port into
that subdirectory.It will also look at the subdirectory with the same name on the
backup master site at ftp.freebsd.org.
(Setting DISTDIR explicitly in your
Makefile will not accomplish this, so please use
DIST_SUBDIR.)This does not affect the MASTER_SITES you
define in your Makefile.Package informationDo include package information, i.e.
COMMENT, DESCR, and
PLIST, in pkg.Note that these files are not used only for packaging anymore,
and are mandatory now, even if
NO_PACKAGE is set.RCS stringsDo not put RCS strings in patches. CVS will mangle them when we
put the files into the ports tree, and when we check them out again,
they will come out different and the patch will fail. RCS strings
are surrounded by dollar ($) signs, and
typically start with $Id or
$RCS.Recursive diffUsing the recurse () option to
diff to generate patches is fine, but please take
a look at the resulting patches to make sure you don't have any
unnecessary junk in there. In particular, diffs between two backup
files, Makefiles when the port uses
Imake or GNU configure, etc.,
are unnecessary and should be deleted. If you had to edit
configure.in and run
autoconf to regenerate
configure, do not take the diffs of
configure (it often grows to a few thousand
lines!); define USE_AUTOCONF=yes and take the
diffsof configure.in.Also, if you had to delete a file, then you can do it in the
post-extract target rather than as part of
the patch. Once you are happy with the resulting diff, please split
it up into one source file per patch file.PREFIXDo try to make your port install relative to
PREFIX. (The value of this variable will be set
to LOCALBASE (default
/usr/local), unless
USE_X_PREFIX or USE_IMAKE is
set, in which case it will be X11BASE (default
/usr/X11R6).)Not hard-coding /usr/local or
/usr/X11R6 anywhere in the source will make the
port much more flexible and able to cater to the needs of other
sites. For X ports that use imake, this is
automatic; otherwise, this can often be done by simply replacing the
occurrences of /usr/local (or
/usr/X11R6 for X ports that do not use imake)
in the various scripts/Makefiles in the port to read
PREFIX, as this variable is automatically passed
down to every stage of the build and install processes.Do not set USE_X_PREFIX unless your port
truly require it (i.e., it links against X libs or it needs to
reference files in X11BASE).The variable PREFIX can be reassigned in your
Makefile or in the user's environment.
However, it is strongly discouraged for individual ports to set this
variable explicitly in the Makefiles.Also, refer to programs/files from other ports with the
variables mentioned above, not explicit pathnames. For instance, if
your port requires a macro PAGER to be the full
pathname of less, use the compiler flag:
-DPAGER=\"${PREFIX}/bin/less\"
or
-DPAGER=\"${LOCALBASE}/bin/less\"
if this is an X port, instead of
-DPAGER=\"/usr/local/bin/less\". This way it will
have a better chance of working if the system administrator has
moved the whole `/usr/local' tree somewhere else.SubdirectoriesTry to let the port put things in the right subdirectories of
PREFIX. Some ports lump everything and put it in
the subdirectory with the port's name, which is incorrect. Also,
many ports put everything except binaries, header files and manual
pages in the a subdirectory of lib, which does
not bode well with the BSD paradigm. Many of the files should be
moved to one of the following: etc
(setup/configuration files), libexec
(executables started internally), sbin
(executables for superusers/managers), info
(documentation for info browser) or share
(architecture independent files). See man &man.hier.7; for details,
the rules governing
/usr pretty much apply to
/usr/local too. The exception are ports
dealing with USENET “news”. They may use
PREFIX/news as a destination
for their files.Cleaning up empty directoriesDo make your ports clean up after themselves when they are
deinstalled. This is usually accomplished by adding
@dirrm lines for all directories that are
specifically created by the port. You need to delete subdirectories
before you can delete parent directories.
:
lib/X11/oneko/pixmaps/cat.xpm
lib/X11/oneko/sounds/cat.au
:
@dirrm lib/X11/oneko/pixmals
@dirrm lib/X11/oneko/sounds
@dirrm lib/X11/onekoHowever, sometimes @dirrm will give you
errors because other ports also share the same subdirectory. You
can call rmdir from @unexec to
remove only empty directories without warning.
@unexec rmdir %D/share/doc/gimp 2>/dev/null || trueThis will neither print any error messages nor cause
pkg_delete to exit abnormally even if
PREFIX/share/doc/gimp is not
empty due to other ports installing some files in there.UIDsIf your port requires a certain user to be on the installed
system, let the pkg/INSTALL script call
pw to create it automatically. Look at
net/cvsup-mirror for an example.If your port must use the same user/group ID number when it is
installed a binarypackage as when it was compiled, then you mus
choose a free UID from 50 to 99 and register it below. Look at
japanese/Wnn for an example.Make sure you don't use a UID already used by the system or
other ports. This is the current list of UIDs between 50 and
99.
majordom:*:54:54:Majordomo Pseudo User:/usr/local/majordomo:/nonexistent
cyrus:*:60:60:the cyrus mail server:/nonexistent:/nonexistent
gnats:*:61:1:GNATS database owner:/usr/local/share/gnats/gnats-db:/bin/sh
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/nonexistent
pop:*:68:6:Post Office Owner (popper):/nonexistent:/nonexistent
wnn:*:69:7:Wnn:/nonexistent:/nonexistent
ifmail:*:70:66:Ifmail user:/nonexistent:/nonexistent
pgsql:*:70:70:PostgreSQL pseudo-user:/usr/local/pgsql:/bin/sh
ircd:*:72:72:IRCd hybrid:/nonexistent:/nonexistent
alias:*:81:81:QMail user:/var/qmail/alias:/nonexistent
qmaill:*:83:81:QMail user:/var/qmail:/nonexistent
qmaild:*:82:81:QMail user:/var/qmail:/nonexistent
qmailq:*:85:82:QMail user:/var/qmail:/nonexistent
qmails:*:87:82:QMail user:/var/qmail:/nonexistent
qmailp:*:84:81:QMail user:/var/qmail:/nonexistent
qmailr:*:86:82:QMail user:/var/qmail:/nonexistent
msql:*:87:87:mSQL-2 pseudo-user:/var/db/msqldb:/bin/shPlease include a notice when you submit a port (or an upgrade)
that reserves a new UID or GID in this range. This allows us to
keep the list of reserved IDs up to date.Do things rationallyThe Makefile should do things simply and
reasonably. If you can make it a couple of lines shorter or more
readable, then do so. Examples include using a make
.if construct instead of a shell
if construct, not redefining
do-extract if you can redefine
EXTRACT* instead, and using
GNU_CONFIGURE instead of CONFIGURE_ARGS
+= --prefix=${PREFIX}.Respect CFLAGSThe port should respect the CFLAGS variable.
If it doesn't, please add NO_PACKAGE=ignores
cflags to the Makefile.Configuration filesIf your port requires some configuration files in
PREFIX/etc, do
not just install them and list them in
pkg/PLIST. That will cause
pkg_delete to delete files carefully edited by
the user and a new installation to wipe them out.Instead, install sample files with a suffix
(filename.sample
will work well) and print out a message pointing out that the
user has to copy and edit the file before the software can be made
to work.PortlintDo check your work with portlint
before you submit or commit it.FeedbackDo send applicable changes/patches to the original
author/maintainer for inclusion in next release of the code. This
will only make your job that much easier for the next
release.MiscellaneaThe files pkg/DESCR,
pkg/COMMENT, and pkg/PLIST
should each be double-checked. If you are reviewing a port and feel
they can be worded better, do so.Don't copy more copies of the GNU General Public License into
our system, please.Please be careful to note any legal issues! Don't let us
illegally distribute software!If you are stuck…Do look at existing examples and the
bsd.port.mk file before asking us questions!
;)Do ask us questions if you have any trouble! Do not just beat
your head against a wall! :)A Sample MakefileHere is a sample Makefile that you can use to
create a new port. Make sure you remove all the extra comments (ones
between brackets)!It is recommended that you follow this format (ordering of
variables, empty lines between sections, etc.). This format is
designed so that the most important information is easy to locate. We
recommend that you use portlint to check the
Makefile.
[the header...just to make it easier for us to identify the ports.]
# New ports collection makefile for: xdvi
[the version required header should updated when upgrading a port.]
# Version required: pl18 [things like "1.5alpha" are fine here too]
[this is the date when the first version of this Makefile was created.
Never change this when doing an update of the port.]
# Date created: 26 May 1995
[this is the person who did the original port to FreeBSD, in particular, the
person who wrote the first version of this Makefile. Remember, this should
not be changed when upgrading the port later.]
# Whom: Satoshi Asami <asami@FreeBSD.ORG>
#
# $Id$
[ ^^^^ This will be automatically replaced with RCS ID string by CVS
when it is committed to our repository.]
#
[section to describe the port itself and the master site - DISTNAME
is always first, followed by PKGNAME (if necessary), CATEGORIES,
and then MASTER_SITES, which can be followed by MASTER_SITE_SUBDIR.
After those, one of EXTRACT_SUFX or DISTFILES can be specified too.]
DISTNAME= xdvi
PKGNAME= xdvi-pl18
CATEGORIES= print
[do not forget the trailing slash ("/")!
if you aren't using MASTER_SITE_* macros]
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= applications
[set this if the source is not in the standard ".tar.gz" form]
EXTRACT_SUFX= .tar.Z
[section for distributed patches -- can be empty]
PATCH_SITES= ftp://ftp.sra.co.jp/pub/X11/japanese/
PATCHFILES= xdvi-18.patch1.gz xdvi-18.patch2.gz
[maintainer; *mandatory*! This is the person (preferably with commit
privileges) who a user can contact for questions and bug reports - this
person should be the porter or someone who can forward questions to the
original porter reasonably promptly. If you really do not want to have
your address here, set it to "ports@FreeBSD.ORG".]
MAINTAINER= asami@FreeBSD.ORG
[dependencies -- can be empty]
RUN_DEPENDS= gs:${PORTSDIR}/print/ghostscript
LIB_DEPENDS= Xpm.5:${PORTSDIR}/graphics/xpm
[this section is for other standard bsd.port.mk variables that do not
belong to any of the above]
[If it asks questions during configure, build, install...]
IS_INTERACTIVE= yes
[If it extracts to a directory other than ${DISTNAME}...]
WRKSRC= ${WRKDIR}/xdvi-new
[If the distributed patches were not made relative to ${WRKSRC}, you
may need to tweak this]
PATCH_DIST_STRIP= -p1
[If it requires a "configure" script generated by GNU autoconf to be run]
GNU_CONFIGURE= yes
[If it requires GNU make, not /usr/bin/make, to build...]
USE_GMAKE= yes
[If it is an X application and requires "xmkmf -a" to be run...]
USE_IMAKE= yes
[et cetera.]
[non-standard variables to be used in the rules below]
MY_FAVORITE_RESPONSE= "yeah, right"
[then the special rules, in the order they are called]
pre-fetch:
i go fetch something, yeah
post-patch:
i need to do something after patch, great
pre-install:
and then some more stuff before installing, wow
[and then the epilogue]
.include <bsd.port.mk>Package NamesThe following are the conventions you should follow in naming your
packages. This is to have our package directory easy to scan, as
there are already lots and lots of packages and users are going to
turn away if they hurt their eyes!The package name should look like
language-name-compiled.specifics-version.numbers.If your DISTNAME doesn't look like that, set
PKGNAME to something in that format.FreeBSD strives to support the native language of its users.
The language- part should be a two
letter abbreviation of the natural language defined by ISO-639 if
the port is specific to a certain language. Examples are
ja for Japanese, ru for
Russian, vi for Vietnamese,
zh for Chinese, ko for
Korean and de for German.The name part should be all lowercases,
except for a really large package (with lots of programs in it).
Things like XFree86 (yes there really is a port of it, check it
out) and ImageMagick fall into this category. Otherwise, convert
the name (or at least the first letter) to lowercase. If the
capital letters are important to the name (for example, with
one-letter names like R or
V) you may use capital letters at your
discretion. There is a tradition of naming Perl 5 modules by
prepending p5- and converting the double-colon
separator to a hyphen; for example, the
Data::Dumper module becomes
p5-Data-Dumper. If the software in question
has numbers, hyphens, or underscores in its name, you may include
them as well (like kinput2).If the port can be built with different hardcoded defaults (usually
part of the directory name in a family of ports), the
-compiled.specifics part should state
the compiled-in defaults (the hyphen is optional). Examples are
papersize and font units.The version string should be a period-separated list of
integers and single lowercase alphabetics. The only exception is
the string pl (meaning `patchlevel'), which can
be used only when there are no major and
minor version numbers in the software.Here are some (real) examples on how to convert a
DISTNAME into a suitable
PKGNAME:Distribution NamePackage NameReasonmule-2.2.2.mule-2.2.2No changes requiredXFree86-3.1.2XFree86-3.1.2No changes requiredEmiClock-1.0.2emiclock-1.0.2No uppercase names for single programsgmod1.4gmod-1.4Need a hyphen before version numbersxmris.4.0.2xmris-4.0.2Need a hyphen before version numbersrdist-1.3alphardist-1.3aNo strings like alpha
allowedes-0.9-beta1es-0.9b1No strings like beta
allowedv3.3beta021.srctiff-3.3What the heck was that anyway?tvtwmtvtwm-pl11Version string always requiredpiewmpiewm-1.0Version string always requiredxvgr-2.10pl1xvgr-2.10.1pl allowed only when no
major/minor version numbersgawk-2.15.6ja-gawk-2.15.6Japanese language versionpsutils-1.13psutils-letter-1.13Papersize hardcoded at package build timepkfontspkfonts300-1.0Package for 300dpi fontsIf there is absolutely no trace of version information in the
original source and it is unlikely that the original author will ever
release another version, just set the version string to
1.0 (like the piewm example above). Otherwise, ask
the original author or use the date string
(yy.mm.dd) as the version.CategoriesAs you already know, ports are classified in several categories.
But for this to wor, it is important that porters and users understand
what each category and how we deicde what to put in each
category.Current list of categoriesFirst, this is the current list of port categories. Those
marked with an asterisk (*) are
virtual categories—those that do not have
a corresponding subdirectory in the ports tree.For non-virtual categories, you will find a one-line
description in the pkg/COMMENT file in that
subdirectory (e.g.,
archivers/pkg/COMMENT).CategoryDescriptionafterstep*Ports to support AfterStep window managerarchiversArchiving tools.astroAstronomical ports.audioSound support.benchmarksBenchmarking utilities.biologyBiology-related software.cadComputer aided design tools.chineseChinese language support.commsCommunication software. Mostly software to talk to
your serial port.convertersCharacter code converters.databasesDatabases.deskutilsThings that used to be on the desktop before
computers were invented.develDevelopment utilities. Do not put libraries here just
because they are libraries—unless they truly don't
belong to anywhere else, they shouldn't be in this
category.editorsGeneral editors. Specialized editors go in the section
for those tools (e.g., a mathematical-formula editor will go
in math).elispEmacs-lisp ports.emulatorsEmulators for other operating systems. Terminal
emulators do not belong
here—X-based ones should go to
x11 and text-based ones to either
comms or misc,
depending on the exact functionality.gamesGames.germanGerman language support.graphicsGraphics utilities.japaneseJapanese language support.kde*Ports that form the K Desktop Environment
(kde).koreanKorean language support.langProgramming languages.mailMail software.mathNumerical computation software and other utilities
for mathematics.mboneMBone applications.miscMiscellaneous utilities—basically things that
doesn't belong to anywhere else. This is the only category
that should not appear with any other non-virtual category.
If you have misc with something else in
your CATEGORIES line, that means you can
safely delete misc and just put the port
in that other subdirectory!netMiscellaneous networking software.newsUSENET news software.offix*Ports from the OffiX suite.palmSoftware support for the 3Com Palm(tm) series.perl5*Ports that require perl version 5 to run.plan9*Various programs from Plan9.printPrinting software. Desktop publishing tools
(previewers, etc.) belong here too.python*Software written in python.russianRussian language support.securitySecurity utilities.shellsCommand line shells.sysutilsSystem utilities.tcl75*Ports that use tcl version 7.5 to run.tcl76*Ports that use tcl version 7.6 to run.tcl80*Ports that use tcl version 8.0 to run.tcl81*Ports that use tcl version 8.1 to run.textprocText processing utilities. It does not include
desktop publishing tools, which go to print/.tk41*Ports that use tk version 4.1 to run.tk42*Ports that use tk version 4.2 to run.tk80*Ports that use tk version 8.0 to run.tk81*Ports that use tk version 8.1 to run.vietnameseVietnamese language support.windowmaker*Ports to support the WindowMaker window
managerwwwSoftware related to the World Wide Web. HTML language
support belong here too.x11The X window system and friends. This category is only
for software that directly support the window system. Do not
put regular X applications here. If your port is an X
application, define USE_XLIB (implied by
USE_IMAKE) and put it in appropriate
categories. Also, many of them go into other
x11-* categories (see below).x11-clocksX11 clocks.x11-fmX11 file managers.x11-fontsX11 fonts and font utilities.x11-toolkitsX11 toolkits.x11-wmX11 window managers.Choosing the right categoryAs many of the categories overlap, you often have to choose
which of the categories should be the primary category of your port.
There are several rules that govern this usse. Here is the list of
priorities, in decreasing order of precedence.Language specific categories alwasys come first. For
example, if your port installs Japanese X11 fonts, then your
CATEGORIES line would read japanese
x11.Specific categories win over less-specific ones. For
instance, an HTML editor should be listed as www
editors, not the other way around. Also, you don't
need to list net when the port belongs to
either of mail, mbone,
news, security, or
www.x11 is used as a secondary category only
when the primary category is a natural language. In particular,
you should not put x11 in the category line
for X applications.If your port truly does not belong anywhere else, put it in
misc.If you are not sure about the category, please put a comment to
that effect in your send-pr submission so we can
discuss it before import it. (If you are a committer, send a note
&a.ports; so we can discuss it first—too often new ports are
imported to a wrong category only to be moved right away.)Changes to this document and the ports systemIf you maintain a lot of ports, you should consider following the
&a.ports;. Important changes to the way ports work will be announced
there. You can always find more detailed information on the latest
changes by looking at the
bsd.port.mk CVS log.That is It, Folks!Boy, this sure was a long tutorial, wasn't it? Thanks for
following us to here, really.Well, now that you know how to do a port, let us go at it and
convert everything in the world into ports! That is the easiest way to
start contributing to the FreeBSD Project! :)