// vim:set filetype=asciidoc:
[[patches]]
=== *debian/patches/** files

As demonstrated in "`<<alt-patch>>`", the *debian/patches/* directory holds

* __patch-file-name__**.patch** files providing *-p1* patches and
* the *series* file which defines how these patches are applied.

See how these files are used in:

* "`<<dpkg-source-b>>`" to build the Debian source package
* "`<<dpkg-source-x>>`" to extract source files from the Debian source package

NOTE: Header texts of these patches should conform to "`https://dep-team.pages.debian.net/deps/dep3/[DEP-3]`".

NOTE: If you want to use VCS tools such as *git*, *gbp* and *dgit* to create and manage these patches after learning basics here, please refer to later in "`<<git-packaging>>`".

// The *-p1* patches residing in the *debian/patches/* directory of Debian source packages are applied in the sequence defined in the *debian/patches/series* file to the upstream source tree when "`*dpkg-source -x*`" extracts files from the Debian source package for the Debian binary package building.

[[include-binaries]]
=== *debian/source/include-binaries* file

The "`**dpkg-source --commit**`" command functions like *dquilt* but has one advantage over the *dquilt* command. While the *dquilt* command can't handle modified binary files, the "`**dpkg-source --commit**`" command detects modified binary files and lists them in the *debian/source/include-binaries* file to include them in the Debian tarball as a part of the Debian source package.
