From a2d61eb86a3d449a0301b295b8c316a18d0b430d Mon Sep 17 00:00:00 2001 From: Ceri Davies Date: Fri, 17 Oct 2003 17:33:38 +0000 Subject: [PATCH] Round one of updates: style fixes. PR: docs/53420 Submitted by: linimon --- .../books/porters-handbook/book.sgml | 128 +++++++++--------- 1 file changed, 64 insertions(+), 64 deletions(-) diff --git a/en_US.ISO8859-1/books/porters-handbook/book.sgml b/en_US.ISO8859-1/books/porters-handbook/book.sgml index b6f51ca96d..44049d3c67 100644 --- a/en_US.ISO8859-1/books/porters-handbook/book.sgml +++ b/en_US.ISO8859-1/books/porters-handbook/book.sgml @@ -69,8 +69,8 @@ This file uses a non-standard tab setting. Emacs and Vim should recognize the setting on - loading the file. Both vi and - ex can be set to use the correct value by + loading the file. Both &man.vi.1; and + &man.ex.1; can be set to use the correct value by typing :set tabstop=4 once the file has been loaded. @@ -472,7 +472,7 @@ lib/X11/oneko/mouse.xpm actions are done. For example, if you have a post-extract - target defined in your Makefile, and a file + 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 @@ -583,8 +583,8 @@ lib/X11/oneko/mouse.xpm Patching In 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 + changed can be picked up with a recursive &man.diff.1; for later feeding to + &man.patch.1;. Each set of patches you wish to apply should be collected into a file named patch-* where * denotes the sequence in which the @@ -611,10 +611,10 @@ lib/X11/oneko/mouse.xpm $RCS. Using the recurse () option to - diff to generate patches is fine, but please take + &man.diff.1; to generate patches is fine, but please take a look at the resulting patches to make sure you do not have any unnecessary junk in there. In particular, diffs between two backup - files, Makefiles when the port uses + 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 @@ -645,7 +645,7 @@ lib/X11/oneko/mouse.xpm Handling user input If your port requires user input to build, configure, or install, - then set IS_INTERACTIVE in your Makefile. This + 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 @@ -663,7 +663,7 @@ lib/X11/oneko/mouse.xpm Configuring the Makefile - Configuring the Makefile is pretty simple, and again we suggest + Configuring 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 @@ -671,7 +671,7 @@ lib/X11/oneko/mouse.xpm read. Now, consider the following problems in sequence as you design - your new Makefile: + your new Makefile: The original source @@ -728,7 +728,7 @@ lib/X11/oneko/mouse.xpm affects the content or structure of the derived package. - Examples of when PORTREVISION should be bumped: + Examples of when PORTREVISION should be bumped: @@ -738,7 +738,7 @@ lib/X11/oneko/mouse.xpm - Changes to the port makefile to enable or disable + Changes to the port Makefile to enable or disable compile-time options in the package. @@ -810,7 +810,7 @@ lib/X11/oneko/mouse.xpm enhancement, fix, or by virtue that the new package will actually work for them). If yes, the PORTREVISION should be bumped so that - automated tools (e.g. pkg_version) + automated tools (e.g. &man.pkg.version.1;) will highlight the fact that a new package is available. @@ -864,8 +864,8 @@ lib/X11/oneko/mouse.xpm Example of <makevar>PORTREVISION</makevar> and <makevar>PORTEPOCH</makevar> usage - The gtkmumble port, version 0.10, is committed to the - ports collection. + The gtkmumble port, version 0.10, is committed to the + ports collection: PORTNAME= gtkmumble PORTVERSION= 0.10 @@ -895,7 +895,7 @@ PORTREVISION= 1 force the new package to be detected as newer. Since it is a new vendor release of the code, PORTREVISION is reset to 0 (or removed - from the makefile). + from the Makefile). PORTNAME= gtkmumble PORTVERSION= 0.2 @@ -918,8 +918,8 @@ PORTEPOCH= 1 If PORTEPOCH were reset to 0 with this upgrade, someone who had - installed the gtkmumble-0.10_1 package would not detect - the gtkmumble-0.3 package as newer, since + installed the gtkmumble-0.10_1 package would not detect + the gtkmumble-0.3 package as newer, since 3 is still numerically less than 10. @@ -941,7 +941,7 @@ PORTEPOCH= 1 hyphen (-) in PORTVERSION. Also, if the package name has the language- or the - compiled.specifics part, use + -compiled.specifics part, use PKGNAMEPREFIX and PKGNAMESUFFIX, respectively. Do not make them part of PORTNAME. @@ -987,7 +987,7 @@ PORTEPOCH= 1 should be lowercase. (The rest of the name can contain capital letters, so use your own discretion when you are converting a software name that has some capital letters in it.) - There is a tradition of naming Perl 5 modules by + 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 @@ -1004,7 +1004,7 @@ PORTEPOCH= 1 the compiled-in defaults (the hyphen is optional). Examples are papersize and font units. - The compiled.specifics part + The -compiled.specifics part should be set in the PKGNAMESUFFIX variable. @@ -1182,7 +1182,7 @@ PORTEPOCH= 1 If 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 + 1.0 (like the piewm example above). Otherwise, ask the original author or use the date string (yyyy.mm.dd) as the version. @@ -1500,7 +1500,7 @@ PORTEPOCH= 1 perl5* - Ports that require perl version 5 to run. + Ports that require perl version 5 to run. @@ -1641,7 +1641,7 @@ PORTEPOCH= 1 windowmaker* Ports to support the WindowMaker window - manager + manager. @@ -2608,7 +2608,7 @@ PATCHFILES= patch1:test This does not affect the MASTER_SITES you - define in your Makefile. + define in your Makefile. @@ -2680,7 +2680,7 @@ PATCHFILES= patch1:test extract target and then from within the install target. Also, the name of the dependency is put into the package so that - pkg_add will automatically install it if it is + &man.pkg.add.1; will automatically install it if it is not on the user's system. @@ -2725,7 +2725,7 @@ PATCHFILES= patch1:test The dependency is checked from within the install target. Also, the name of the dependency is put into the package so that - pkg_add will automatically install it if it is + &man.pkg.add.1; will automatically install it if it is not on the user's system. The target part can be omitted if it is the same as DEPENDS_TARGET. @@ -2829,9 +2829,9 @@ PATCHFILES= patch1:test USE_PERL5 - The port requires Perl 5 to build and install. See + The port requires perl 5 to build and install. See for additional variables that - can be set relating to Perl. + can be set relating to perl. @@ -2903,8 +2903,8 @@ PATCHFILES= patch1:test 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 have perl5 as part of the base system + of the perl language. (The last is especially important since + some versions of FreeBSD have perl5 as part of the base system while others do not.) @@ -2935,7 +2935,7 @@ PATCHFILES= patch1:test BUILD_DEPENDS= ${NONEXISTENT}:${PORTSDIR}/graphics/jpeg:extract - will always descend to the JPEG port and extract it. + will always descend to the jpeg port and extract it. Do not use DEPENDS unless there is no other way the behavior you want can be accomplished. It will cause the @@ -3219,10 +3219,10 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar - Using Perl + Using <literal>perl</literal> - Variables for ports that use Perl + Variables for ports that use <literal>perl</literal> @@ -3237,7 +3237,7 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar USE_PERL5 - Says that the port uses Perl 5 to build and run. + Says that the port uses perl 5 to build and run. @@ -3260,28 +3260,28 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar PERL_VERSION - The full version of Perl installed (e.g., + The full version of perl installed (e.g., 5.00503). PERL_VER - The short version of Perl installed (e.g., + The short version of perl installed (e.g., 5.005). PERL_LEVEL - The installed Perl version as an integer of the form MNNNPP + The installed perl version as an integer of the form MNNNPP (e.g., 500503). PERL_ARCH - Where Perl stores architecture dependent libraries. + Where perl stores architecture dependent libraries. Defaults to ${ARCH}-freebsd. @@ -3751,7 +3751,7 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar <makevar>LIB_DEPENDS</makevar> - All port Makefiles are edited to remove minor numbers from + All 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 @@ -3782,7 +3782,7 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar <literal>ldconfig</literal> - The ldconfig line in Makefiles should + The ldconfig line in Makefiles should read: ${SETENV} OBJFORMAT=${PORTOBJFORMAT} ${LDCONFIG} -m .... @@ -3809,7 +3809,7 @@ LDCONFIG_DIRS= %%PREFIX%%/lib/foo %%PREFIX%%/lib/bar make it easier for users 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, + use variables cleverly. In the sole Makefile, you can use MASTERDIR to specify the directory where the rest of the files are. Also, use a variable as part of PKGNAMESUFFIX so @@ -3932,7 +3932,7 @@ MASTERDIR= ${.CURDIR}/../xdvi300 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 + 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, @@ -3986,7 +3986,7 @@ ${PREFIX}/man/ja/man4/baz.4.gz <makevar>USE_MOTIF</makevar> If your port requires Motif, define this variable in the - Makefile. This will prevent people who do not own a copy of Motif + Makefile. This will prevent people who do not own a copy of Motif from even attempting to build it. @@ -4059,7 +4059,7 @@ ${PREFIX}/man/ja/man4/baz.4.gz If 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 + after a &man.pkg.add.1; or to display licensing information. @@ -4075,10 +4075,10 @@ ${PREFIX}/man/ja/man4/baz.4.gz <filename>pkg-install</filename> If your port needs to execute commands when the binary package - is installed with pkg_add you can do this via the + is installed with &man.pkg.add.1; 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 as + &man.pkg.add.1;. The first time as ${SH} pkg-install ${PKGNAME} PRE-INSTALL and the second time as ${SH} pkg-install ${PKGNAME} POST-INSTALL. @@ -4119,7 +4119,7 @@ ${PREFIX}/man/ja/man4/baz.4.gz installation/deinstallation should proceed. The script will be run at installation time by - pkg_add as + &man.pkg.add.1; as pkg-req ${PKGNAME} INSTALL. At deinstallation time it will be run by &man.pkg.delete.1; as @@ -4130,17 +4130,17 @@ ${PREFIX}/man/ja/man4/baz.4.gz Changing <filename>pkg-plist</filename> based on make variables - Some ports, particularly the p5- ports, need to change their + Some ports, particularly the p5- ports, need to change their pkg-plist depending on what options they are - configured with (or version of perl, in the case of p5- ports). To + configured with (or version of perl, in the case of p5- ports). To make this easy, any instances in the pkg-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 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 @@ -4280,7 +4280,7 @@ PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION} 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 + 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. @@ -4308,7 +4308,7 @@ PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION} 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. + variable explicitly in the Makefiles. Also, refer to programs/files from other ports with the variables mentioned above, not explicit pathnames. For instance, if @@ -4324,7 +4324,7 @@ PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION} 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. + moved the whole /usr/local tree somewhere else. @@ -4337,11 +4337,11 @@ PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION} testing of your commits. If you wish to use this service, all you need is a FreshPorts - account. If your registered email address is @FreeBSD.org, + account. If your registered email address is @FreeBSD.org, you'll see the opt-in link on the right hand side of the webpages. For those of you who already have a FreshPorts account, but are not - using your @FreeBSD.org email address, just change your email to - @FreeBSD.org, subscribe, then change it back again. + using your @FreeBSD.org email address, just change your email to + @FreeBSD.org, subscribe, then change it back again. @@ -5597,8 +5597,8 @@ PLIST_SUB= OCTAVE_VERSION=${OCTAVE_VERSION} You need to include either the - pre.mk/post.mk pair or - bsd.port.mk only; do not mix these two. + bsd.port.pre.mk/bsd.port.post.mk pair or + bsd.port.mk only; do not mix these two usages. bsd.port.pre.mk only defines a few @@ -5785,7 +5785,7 @@ post-install: (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, + (architecture independent files). See &man.hier.7; for details; the rules governing /usr pretty much apply to /usr/local too. The exception are ports @@ -5819,7 +5819,7 @@ lib/X11/oneko/sounds/cat.au @unexec rmdir %D/share/doc/gimp 2>/dev/null || true This will neither print any error messages nor cause - pkg_delete to exit abnormally even if + &man.pkg.delete.1; to exit abnormally even if PREFIX/share/doc/gimp is not empty due to other ports installing some files in there. @@ -5962,7 +5962,7 @@ drweb:*:426:426:Dr.Web Mail Scanner:/nonexistent:/sbin/nologin PREFIX/etc, do not just install them and list them in pkg-plist. That will cause - pkg_delete to delete files carefully edited by + &man.pkg.delete.1; to delete files carefully edited by the user and a new installation to wipe them out. Instead, install sample files with a suffix @@ -6007,7 +6007,7 @@ drweb:*:426:426:Dr.Web Mail Scanner:/nonexistent:/sbin/nologin Please use the correct make variable as each make variable conveys radically different meanings to both users, and to automated systems that parse - Makefiles. + Makefiles.