deb-src-control - Linux


deb-src-control extracts and processes information from Debian source packages, providing a succinct overview of their contents. It is particularly valuable for managing and analyzing the source packages of Debian-based distributions.


deb-src-control [options] <source-package-file>


  • -a, –arch : Specify the target architecture for the extracted control file. Default: any.
  • -t, –template : Specify the template file to use for formatting the output. Default: control.sample.yaml.
  • -y, –stdout: Send the output to stdout instead of a file.
  • -v, –verbose: Increase verbosity level.
  • -d, –debug: Enable debug output.
  • -h, –help: Print usage information and exit.


Extract control file information for a package:

deb-src-control -a amd64 python3-defaults

Use a custom template file:

deb-src-control -t custom.yaml -a arm64 linux-image

Send output to stdout:

deb-src-control -y -a armhf firmware-linux-nonfree

Common Issues

  • Missing dependencies: Ensure that all dependencies required for extracting the package’s control file are installed.


Combine with dpkg: Extract control file info before dpkg operations:

deb-src-control -y -a amd64 python3-venv | dpkg-query -s -

Use with apt-get: Generate a list of dependencies before installing:

deb-src-control -y -a arm64 linux-image | grep Depends | cut -d: -f2 | sed 's/,/ /g'

Related Commands

  • dpkg-query – Retrieves package information from installed packages.
  • apt-get – Manages and installs software packages.
  • dpkg – Installs, removes, and manages Debian packages.