OS Manuals

/usr/bin/dpkg-source

headers for dpkg

From dpkg-dev 1.23.11-r3 (os), captured 2026-11-05 by running dpkg-source --help (exit 0). permalink

Usage: dpkg-source [<option>...] <command>

Commands:
  -x, --extract <filename>.dsc [<output-dir>]
          Extract source package.
  -b, --build <dir>
          Build source package.
      --print-format <dir>
          Print the format to be used for the source package.
      --before-build <dir>
          Run the corresponding source package format hook.
      --after-build <dir>
          Run the corresponding source package format hook.
      --commit [<dir> [<patch-name>]]
          Store upstream changes in a new patch.

Build options:
  -c<control-file>
          Get control information from this file.
  -l<changelog-file>
          Get per-version changelog information from this file.
  -F<changelog-format>
          Force changelog format.
      --format=<source-format>
          Set the format to be used for the source package.
  -T<substvars-file>
          Read substitution variables from this file.
  -V<name>=<value>
          Set a substitution variable.
  -D<field>=<value>
          Override or add a .dsc field and value.
  -U<field>
          Remove a field.
  -i, --diff-ignore[=<regex>]
          Filter out files to ignore diffs of.
          [default: (?:^|/).*~$|(?:^|/)\.#.*$|(?:^|/)\..*\.sw.$|(?:^|/),,.*(?:$|/.*$)|(?:^|/)(?:DEADJOE|\.arch-inventory|\.(?:bzr|cvs|hg|git|mtn-)ignore)$|(?:^|/)(?:CVS|RCS|\.deps|\{arch\}|\.arch-ids|\.svn|\.hg(?:tags|sigs)?|_darcs|\.git(?:attributes|modules|review)?|\.mailmap|\.shelf|_MTN|\.be|\.bzr(?:\.backup|tags)?)(?:$|/.*$)]
  -I, --tar-ignore[=<pattern>]
          Filter out files when building tarballs.
          [default: -I*.a -I*.la -I*.o -I*.so -I.*.sw? -I*/*~ -I,,* -I.[#~]* -I.arch-ids -I.arch-inventory -I.be -I.bzr -I.bzr.backup -I.bzr.tags -I.bzrignore -I.cvsignore -I.deps -I.git -I.gitattributes -I.gitignore -I.gitmodules -I.gitreview -I.hg -I.hgignore -I.hgsigs -I.hgtags -I.mailmap -I.mtn-ignore -I.shelf -I.svn -ICVS -IDEADJOE -IRCS -I_MTN -I_darcs -I{arch}]
  -Z, --compression=<compression>
          Select compression to use (supported are: bzip2, gzip, lzma, xz).
          [default: xz]
  -z, --compression-level=<level>
          Compression level to use (supported are: '1'-'9', 'best', 'fast').
          [default: 6]

Extract options:
      --no-copy
          Do not copy original source tarballs.
      --no-check
          Do not check signature and checksums on extraction.
      --no-overwrite-dir
          Do not overwrite directory on extraction.
      --no-vendor-certs
          Do not use vendor specific certificate keyrings.
      --signer-certs=<keyring>
          Use a signer certificates keyring.
      --require-valid-signature
          Abort if the package does not have a valid signature.
      --require-strong-checksums
          Abort if the package contains no strong checksums.
      --ignore-bad-version
          Allow bad source package versions.

Build format 1.0 options:
  -sa
          Auto select original source.
  -sk
          Use packed original source (unpack and keep).
  -sp
          Use packed original source (unpack and remove).
  -su
          Use unpacked original source (pack and keep).
  -sr
          Use unpacked original source (pack and remove).
  -ss
          Trust packed and unpacked original sources are same.
  -sn
          There is no diff, do main tarfile only.
  -sA, -sK, -sP, -sU, -sR
          Like -sa, -sk, -sp, -su, -sr but may overwrite.
      --abort-on-upstream-changes
          Abort if generated diff has upstream files changes.

Extract format 1.0 options:
  -sp
          Leave original source packed in current directory.
  -su
          Do not copy original source to current directory.
  -sn
          Unpack original source tree too.
      --skip-debianization
          Do not apply debian diff to upstream sources.

General options:
      --threads-max=<threads>
          Use at most <threads> with compressor.
  -q
          Enable quiet mode, minimal output.
  -?, --help
          Show this help message.
      --version
          Show the version.

Source format specific build and extract options are available;
use --format with --help to see them.
Options (46)
OptionDescriptionSource
-b, --build dirBuild source package.help
--print-format dirPrint the format to be used for the source package.help
--before-build dirRun the corresponding source package format hook.help
--after-build dirRun the corresponding source package format hook.help
-c control-fileGet control information from this file.help
-l changelog-fileGet per-version changelog information from this file.help
-F changelog-formatForce changelog format.help
--format source-formatUse the given format for building the source package.help + man
-T substvars-fileRead substitution variables from this file.help
-V name>=<valueSet a substitution variable.help
-D field>=<valueOverride or add a .dsc field and value.help
-U fieldRemove a field.help
-i, --diff-ignore regexFilter out files to ignore diffs of.help
-I, --tar-ignore patternFilter out files when building tarballs.help
-Z, --compression, -Zcompression compressionSpecify the compression to use for created tarballs and diff files.help + man
-z, --compression-level, -zlevel levelCompression level to use (supported are: '1'-'9', 'best', 'fast').help + man
--no-copyDo not copy original tarballs near the extracted source package.help + man
--no-checkDo not check signatures and checksums before unpackinghelp + man
--no-overwrite-dirDo not overwrite the extraction directory if it already exists.help + man
--no-vendor-certsDo not use the vendor specific certificate keyrings.help + man
--signer-certs keyringUse this keyring containing signer certificates during signature verification of source packages.help + man
--require-valid-signatureRefuse to unpack the source package if it doesn't contain an OpenPGP signature that can be verified either with the user supplied --signer-certs keyrings, or one of the vendor-specific keyrings,…help + man
--require-strong-checksumsRefuse to unpack the source package if it does not contain any strong checksums.help + man
--ignore-bad-versionTurns the bad source package version check into a non-fatal warning.help + man
-saAuto select original source.help
-skUse packed original source (unpack and keep).help
-spUse packed original source (unpack and remove).help
-suUse unpacked original source (pack and keep).help
-srUse unpacked original source (pack and remove).help
-ssTrust packed and unpacked original sources are same.help
-snThere is no diff, do main tarfile only.help
-sA, -sK, -sP, -sU, -sRLike -sa, -sk, -sp, -su, -sr but may overwrite.help
--abort-on-upstream-changesAbort if generated diff has upstream files changes.help
--skip-debianizationDo not apply debian diff to upstream sources.help
--threads-max threadsSets the maximum number of threads allowed for compressors that support multi-threaded operations.help + man
-qSets quiet mode to suppress warnings.help + man
-?, --helpShow this help message.help
--versionShow the version.help
-ccontrol-fileSpecifies the main source control file to read information from. (in the manual page but not in --help)man
-lchangelog-fileSpecifies the changelog file to read information from. (in the manual page but not in --help)man
-Fchangelog-formatSpecifies the format of the changelog. (in the manual page but not in --help)man
-Vname valueSet an output substitution variable. (in the manual page but not in --help)man
-Tsubstvars-fileRead substitution variables in substvars-file; (in the manual page but not in --help)man
-Dfield valueOverride or add an output control file field. (in the manual page but not in --help)man
-UfieldRemove an output control file field. (in the manual page but not in --help)man
--extend-diff-ignore regexThe perl regular expression specified will extend the default value used by --diff-ignore and its current value, if set. (in the manual page but not in --help)man

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.