dh_auto_configure - Linux
Overview
dh_auto_configure
is a tool used in Debian packaging to analyze the source code of a package and generate a debian/rules
file based on the analysis. This file specifies the build process for the Debian package. dh_auto_configure
is particularly useful when the source code uses the configure
script for configuration.
Syntax
dh_auto_configure [options] source-directory [debian/rules]
Options/Flags
- -v, –verbose: Verbose output.
- -d, –delete: Delete the specified debian/rules file if one already exists.
- –buildsys: Specify the build system. Possible values are:
autotools
,cmake
,meson
,pkgconfig
,m4
,perl
,python
,guile
,portage
,scons
, andwaf
. - –build-options=OPTIONS: Set build options to be passed to the build system.
- –host-options=OPTIONS: Set host options to be passed to the build system.
- –install-options=OPTIONS: Set install options to be passed to the build system.
- –no-autobuild: Don’t run the build system after generating the debian/rules file.
- –fix-autotools-deps: Fix autotools dependencies if possible.
- –deep: Analyze dependencies recursively.
- –build: Build the package using the generated debian/rules file.
- –install: Install the package using the generated debian/rules file.
- –make-conf: Create a make conf file for the package.
- –true: Set the result to true.
- –false: Set the result to false.
- –help: Show help.
Examples
To generate a debian/rules
file for a package that uses the configure
script:
dh_auto_configure
To generate a debian/rules
file and build the package:
dh_auto_configure --build
To generate a debian/rules
file and install the package:
dh_auto_configure --install
Common Issues
- If the source code does not use the
configure
script,dh_auto_configure
may not be able to generate adebian/rules
file. - If the
configure
script is not properly configured,dh_auto_configure
may not be able to generate a correctdebian/rules
file.
Integration
dh_auto_configure
can be integrated with other Debian packaging tools such as dh_make
and dpkg-buildpackage
.
Related Commands
dh_make
– Create a Debian source package.dpkg-buildpackage
– Build a Debian binary package.dh_installdeb
– Install a Debian binary package.