Chapter C. Source packages (from old Packaging Manual)
1 Untar the tarfile, which will create a
2 Rename the
3 Create the subdirectory
at the top of the source tree.
4 Apply the diff using
5 Untar the tarfile again if you want a copy of the original source code alongside the De
It is not possible to generate a valid Debian source archive without using
particular, attempting to use
directly to generate the
file will not work.
C.4.1 Restrictions on objects in source packages
The source package may not contain any hard links
, device special files, sockets or setuid
or setgid files.
The source packaging tools manage the changes between the original and Debianised source
. Turning the original source tree as included in the
into the debianised source must not involve any changes which cannot be handled by these
tools. Problematic changes which cause
to halt with an error when building
the source package are:
Adding or removing symbolic links, sockets or pipes.
Changing the targets of symbolic links.
Creating directories, other than
Changes to the contents of binary files.
Changes which cause
to print a warning but continue anyway are:
Removing files, directories or symlinks.
Changed text files which are missing the usual final newline (either in the original or the
modified source tree).
Changes which are not represented, but which are not detected by
Changing the permissions of files (other than
) and directories.
are handled specially by
applying the changes it will create the
directory, and afterwards it will make
This is not currently detected when building source packages, but only when extracting them.
Hard links may be permitted at some point in the future, but would require a fair amount of work.
Setgid directories are allowed.
Renaming a file is not treated specially it is seen as the removal of the old file (which generates a warning,
but is otherwise ignored), and the creation of the new one.