debuild(1)
Build a Debian package from source, handling dependencies and package creation automatically.
Synopsis
debuild [OPTION]... [-- dpkg-buildpackage-options]Description
debuild is a wrapper around dpkg-buildpackage that automates Debian package building. It sets up the build environment, installs build dependencies, runs the build process, and signs the resulting changes file. It is the standard tool for Debian developers to build packages locally.
debuild reads the debian/changelog file to determine the package version and distribution, then invokes dpkg-buildpackage with appropriate options. It can automatically install build-depends and build-conflicts packages, and handles source-only builds, binary-only builds, and full builds.
Common options
| Flag | What it does |
|---|---|
-S | build source-only package (creates .dsc and .tar.gz, no binaries) |
-b | build binary package only (skip source package creation) |
-A | build architecture-independent packages only |
-B | build architecture-dependent packages only |
-us | do not sign source package (.dsc file) |
-uc | do not sign changes file (.changes file) |
-i | ignore debian/changelog when checking source package pristineness |
-d | skip installing build dependencies (assume they are already installed) |
--lintian-opts=OPTS | pass additional options to lintian checks after build |
--no-lintian | skip lintian checks after build completion |
Examples
build complete Debian package (source and binary), installing build deps, signing output
debuildbuild source package only for upload to Debian archive or PPA
debuild -Sbuild binary package without signing, useful for local testing
debuild -b -uc -usbuild binary package assuming build dependencies are already installed
debuild -d -bbuild architecture-dependent packages only, skipping lintian checks
debuild -B --no-lintianbuild architecture-independent packages without signing
debuild -A -us -uc