From d9a33058fc14d3ff659864b3f494b82f095aa894 Mon Sep 17 00:00:00 2001
From: Manoj Srivastava
Every package must be accompanied by a verbatim copy of
its copyright and distribution license in the file
- /usr/share/doc/<package>/copyright
+ /usr/share/doc/package/copyright
(see for further details).
@@ -1027,7 +1027,7 @@
@@ -1054,19 +1054,20 @@
belonging to another package without consulting the
maintainer of that package first.
All packages which supply an instance of a common command
name (or, in general, filename) should generally use
- The include file
Debian packages should be patched to use
-
The version number format is:
- &lsqbepoch:]upstream_version[-debian_revision]
+ [epoch:]upstream_version[-debian_revision]
@@ -2310,13 +2311,12 @@ Package: libc6
@@ -4632,14 +4632,14 @@ test -f program-executed-later-in-script || exit 0
the burden on the system administrator, such configurable
values should not be placed directly in the script.
Instead, they should be placed in a file in
- /etc/default, which typically will have the same
+ /etc/default, which typically will have thesame
base name as the init.d script. This extra file
should be sourced by the script when the script runs. It
must contain only variable settings and comments in POSIX
@@ -5351,21 +5351,22 @@ exec /usr/lib/foo/foo "$@"
Two different packages must not install programs with
- different functionality but with the same filenames. (The
+ different functionality but with the same filenames. (The
case of two programs having the same functionality but
- different implementations is handled via `alternatives.')
- If this case happens, one of the programs must be
- renamed. The maintainers should report this to the
- developers' mailing and try to find a consensus about
- which package will have to be renamed. If a consensus can
- not be reached, both programs must be
- renamed.
Generally the following compilation parameters should be used:
@@ -5385,61 +5386,41 @@ install -s # (or use strip on the files in debian/tmp)
package.
- The -N flag should not be used. On a.out systems
- it may have been useful for some very small binaries, but
- for ELF it has no good effect.
Debugging symbols are useful for error diagnosis,
investigation of core dumps (which may be submitted by users
- in bug reports), or testing and developing the
- software. Therefore it is recommended to support building
- the package with debugging information through the following
- interface: If the environment variable
- DEB_BUILD_OPTIONS contains the string
- debug, compile the software with debugging
- information (usually this involves adding the -g
- flag to CFLAGS). This allows the generation of a
- build tree with debugging information. If the environment
- variable DEB_BUILD_OPTIONS contains the string
- nostrip, do not strip the files at installation
- time. This allows one to generate a package with debugging
- information included. The following makefile snippet is only
- an example of how one may test for either condition:
+ in bug reports), or testing and developing the software.
+ Therefore it is recommended to support building the package
+ with debugging information through the following interface:
+ If the environment variable DEB_BUILD_OPTIONS
+ contains the string debug, compile the software
+ with debugging information (usually this involves adding the
+ -g flag to CFLAGS). This allows the
+ generation of a build tree with debugging information. If
+ the environment variable DEB_BUILD_OPTIONS contains
+ the string nostrip, do not strip the files at
+ installation time. This allows one to generate a package
+ with debugging information included.
- Rationale: Building by default with -g causes more
- wasted CPU cycles since the information is stripped away
- anyway. The package can by default build without -g if
- it also provides a mechanism to easily be rebuilt with
- debugging information. This can be done by providing a
- "build-debug" make target, or allowing the user to
- specify "DEB_BUILD_OPTIONS=debug" in the environment while
- compiling that package.
- Now this has several added benefits:
-
- It is actually easier to build debugging bins and
- libraries this way (no more editing debian/rules
- or similar) since it provides a documented way of
- getting this type of build.
- There will be much less wasted CPU time for the
- autobuilders since not having debugging
- information (and hence also not having to strip
- it) will increase the speed of compiles. This
- skips an entire pass of the compiler.
-
-
+ Rationale: Using -g by default causes wasted
+ CPU cycles since the information is stripped away
+ anyway; this can have a significant impact on the
+ efficiency of the autobuilders. Having a standard way
+ to build a debugging variant also makes it easier to
+ build debugging bins and libraries since it provides a
+ documented way of getting this type of build; one does
+ not have to manually edit debian/rules or
+ Makefiles.
@@ -5479,11 +5455,12 @@ endif
- All libraries must have a shared version in the lib - package and a static version in the lib-dev package. The - shared version must be compiled with -fPIC, and - the static version must not be. In other words, each - *.c file will need to be compiled twice.
+ All libraries must have a shared version in the + lib* package and a static version in the + lib*-dev package. The shared version must be + compiled with -fPIC, and the static version must + not be. In other words, each *.c file will need to + be compiled twice.
You must specify the gcc option -D_REENTRANT
@@ -5494,14 +5471,24 @@ endif
Note that all installed shared libraries should be
stripped with
+ You might also want to use the options + --remove-section=.comment and + --remove-section=.note on both shared libraries + and executables, and --strip-debug on static + libraries. +
+Note that under some circumstances it may be useful to @@ -5510,38 +5497,43 @@ strip --strip-unneeded <your-lib>
- An ever increasing number of packages are using libtool to - do their linking. The latest GNU libtools (>= 1.3a) can take - advantage of the metadata in the installed libtool archive - files (`*.la'). The main advantage of libtool's .la files is - that it allows libtool to store and subsequently access - metadata with respect to the libraries it builds. libtool - will search for those files, which contain a lot of useful - information about a library (e.g. dependency libraries for - static linking). Also, they're essential for - programs using libltdl. -
- -
- Certainly libtool is fully capable of linking against shared
- libraries which don't have .la files, but being a mere shell
- script it can add considerably to the build time of a
- libtool using package if that shell-script has to derive all
- this information from first principles for each library every
- time it is linked. With the advent of libtool-1.4 (and to a
- lesser extent libtool-1.3), the .la files will also store
- information about inter-library dependencies which cannot
- necessarily be derived after the .la file is deleted.
+ An ever increasing number of packages are using
+
+ Although
- Packages that use libtool to create shared libraries should
- include the .la files in the -dev
- packages, with the exception that if the package relies on
- libtool's libltdl library, in which case the .la
- files must go in the run-time library package. This is a
- good idea in general, and especially for static linking
- issues.
+ Packages that use
@@ -5554,7 +5546,6 @@ strip --strip-unneeded <your-lib>
-+ The soname is the shared object name: it's the thing + that has to match exactly between building an executable + and running it for the dynamic linker to be able run the + program. For example, if the soname of the library is + libfoo.so.6, the library package would be + called libfoo6. +
+
If you prefer only to support one development version at a
time you may name the development package
- libraryname-dev; otherwise you may
- wish to use
Packages which use the shared library should have a dependency on the name of the shared library package, - librarynamesoname. When - the soname changes you can have both versions - of the library installed while moving from the old library - to the new.
+ librarynamesoversion. When + the soname changes you can have both versions of the library + installed while migrating from the old library to the new. +- If your package has some run-time support programs which - use the shared library you must not put them in - the shared library package. If you do that then you won't - be able to install several versions of the shared library - without getting filename clashes. Instead, either create - a third package for the runtime binaries (this package - might typically be named - libraryname-runtime; note the absence - of the soname in the package name) or if the - development package is small include them in there.
+ If your package has some run-time support programs which use + the shared library you must not put them in the shared + library package. If you do that then you won't be able to + install several versions of the shared library without + getting filename clashes. Instead, either create a third + package for the runtime binaries (this package might + typically be named libraryname-runtime; + note the absence of the soversion in the package + name), or if the development package is small you may + include them in there. +If you have several shared libraries built from the same source tree you may lump them all together into a single - shared library package, provided that you change all their - sonames at once (so that you don't get filename + shared library package, provided that you change all of + their sonames at once (so that you don't get filename clashes if you try to install different versions of the - combined shared libraries package).
- -- You should follow the directions in the Debian Packaging - Manual (or other documentation of the Debian - packaging tools) for putting the shared library in its - package, and you must include a shlibs control area - file with details of the dependencies for packages which use - the library.
+ combined shared libraries package). +
- Shared libraries should not be installed
- executable, since
- The standard shell interpreter `/bin/sh' can be a
+ The standard shell interpreter /bin/sh can be a
symbolic link to any POSIX compatible shell, if echo
- -n does not generate a newline.
+ -n does not generate a newline.
- Debian policy specifies POSIX behavior for /bin/sh, but
- echo -n has widespread use in the Linux community
- (including especially debian policy, the linux kernel
- source, many debian scripts, etc.). This echo -n
- mechanism is valid but not required under POSIX, hence
- this explicit addition. Also, rumour has it that this
- shall be mandated under the LSB anyway.
+ Debian policy specifies POSIX behavior for
+ /bin/sh, but echo -n has widespread
+ use in the Linux community (in particular including this
+ policy, the Linux kernel source, many Debian scripts,
+ etc.). This echo -n mechanism is valid but not
+ required under POSIX, hence this explicit addition.
+ Also, rumour has it that this shall be mandated under
+ the LSB anyway.
- You may wish to restrict your script to POSIX features when possible so
- that it may use /bin/sh as its interpreter. If
- your script works with
Perl scripts should check for errors when making any system calls, including open, print, - close, rename and system.
+ close, rename and system. +
-
+ It can also be found on
+
Any scripts which create files in world-writeable @@ -5722,27 +5726,27 @@ strip --strip-unneeded <your-lib> should be relative, and symbolic links pointing from one top-level directory into another should be absolute. (A top-level directory is a sub-directory of the root - directory `/'.)
+ directory /.)- In addition, symbolic links should be specified as short - as possible, i.e., link targets like `foo/../bar' are + In addition, symbolic links should be specified as short as + possible, i.e., link targets like foo/../bar are deprecated.
Note that when creating a relative link using
For example, in your
- A symbolic link pointing to a compressed file should - always have the same file extension as the referenced - file. (For example, if a file `foo.gz' is - referenced by a symbolic link, the filename of the link - has to end with `.gz' too, as in - `bar.gz.')
- Note, that we don't want to use `<arch>-debian-linux' - to apply to the rule `architecture-vendor-os' since this - would make our programs incompatible to other Linux - distributions. Also note, that we don't use - `<arch>-unknown-linux', since the `unknown' does not - look very good.
+ Note, that we don't want to use + arch-debian-linux to apply to the rule + `architecture-vendor-os' since this would make our programs + incompatible with other Linux distributions. Also note that + we don't use arch-unknown-linux, since + the unknown does not look very good. +
+Cgi-bin executable files are installed in the
directory
Web Applications should try to avoid storing files in
the Web Document Root. Instead they should use the
- /usr/share/doc/<package> directory for documents and
- register the Web Application via the menu package. If
- access to the web-root is unavoidable then use
+ /usr/share/doc/package directory for
+ documents and register the Web Application via the
+ menu package. If access to the web-root is unavoidable
+ then use
Every package must be accompanied by a verbatim copy of its copyright and distribution license in the file - /usr/share/doc/<package>/copyright. This file must + /usr/share/doc/package/copyright. This file must neither be compressed nor be a symbolic link.
@@ -7105,7 +7115,7 @@ fi
- /usr/share/doc/<package> may be a symbolic link to a + /usr/share/doc/package may be a symbolic link to a directory in /usr/share/doc only if two packages both come from the same source and the first package has a "Depends" relationship on the second. These rules are important diff --git a/upgrading-checklist.html b/upgrading-checklist.html index 7e27c66..8ea7413 100644 --- a/upgrading-checklist.html +++ b/upgrading-checklist.html @@ -53,6 +53,13 @@ picking your way through this list.
+3.5.5.0 May 01 + + - [Clarified note in 3.5.3.0 upgrading checklist regarding + examples and templates: this refers only to those examples used + by scripts; see section 11.7.3 for the whole story] + + 3.5.4.0 Apr 01 - The system-wide mail directory is now /var/mail, no longer @@ -96,7 +103,7 @@ picking your way through this list. - Daemon startup scripts in /etc/init.d/ should not contain modifiable parameters; these should be moved to a file in - /etc/default/; see [10.3.2] for details + /etc/default/; see [10.3.2] for details - Files in /usr/share/doc must not be referenced by any program. If such files are needed, they must be placed in /usr/share/<package>/, and symbolic links created as required -- 2.39.2