Dpkg::BuildDriver3perl
Drive the build of a debian package
Overview
This class is used by dpkg-buildpackage to drive the build of a Debian package.
Note: This is a private module, its API can change at any time.
Methods
- $bd = Dpkg::BuildDriver->new(%opts)
-
Create a new Dpkg::BuildDriver object. It will load a build driver module as requested in the
Build-Driversfield in the$opts{ctrl} Dpkg::Control::Info object or if not present, it will fall back to load the defaultdebian-rulesdriver.Options:
ctrl(required)-
A Dpkg::Control::Info object.
root_cmd-
A string with the gain-root-command to use when needing to execute a command with root-like rights. If needed and unset, it will default to fakeroot if it is available or the module will error out.
as_root-
A boolean to force debian/rules target calls as root-like, even if they would normally not require to be executed as root-like. This option is applied to all targets globally.
Note: This option is only relevant for drivers that use debian/rules.
debian_rules-
An array containing the command to execute the debian/rules file and any additional arguments. It defaults to
debian/rules.Note: This option is only relevant for drivers that use debian/rules.
rrr_override-
A string that overrides the
Rules-Requires-Rootfield value.Note: This option is only relevant for drivers that use debian/rules.
- $bd->
pre_check() -
Perform build driver specific checks, before anything else.
This will run after the
inithook, and before"dpkg-source --before-build".Note: This is an optional method that can be omitted from the driver implementation.
- $bool = $bd->need_build_task($build_task, binary_task)
-
Returns whether we need to use the build task.
Note: This method is needed as long as we support building as root-like. Once that is not needed this method will be deprecated.
- $bd->run_build_task($build_task, $binary_task)
-
Executes the build task for the build.
Note: This is an optional method needed as long as we support building as root-like. Once that is not needed this method will be deprecated.
- $bd->run_task($task)
-
Executes the given task for the build.
Changes
Version 0.xx
This is a private module.
Releases
2 releases since Debian 13 (Trixie); the text changed 1 time.