dh_installmodules - Linux
Overview
dh_installmodules is a Debian packaging tool that assists in installing binary packages. It is primarily used within Debian package build scripts to create package-specific directories and install files into them.
Syntax
dh_installmodules [OPTIONS] [MODULE1, ...]
Options/Flags
--sourcedir=DIR: Specify the directory containing the source files (default:debian/)--destdir=DIR: Specify the directory where the binary packages will be installed (default:debian/tmp/)--incl-subdir=SUBDIR: Include an additional subdirectory to search for modules--type=TYPE: Specify the type of modules to install (default:common)--force-multi-arch: Force installation of multi-arch support--no-multi-arch: Disable installation of multi-arch support--warn-multi-arch: Warn about missing multi-arch support--help: Display this help message and exit
Examples
Install common modules:
dh_installmodules
Install modules from a specific directory:
dh_installmodules --sourcedir=custom-dir common
Install multiple module types:
dh_installmodules --type=common,examples,tests
Common Issues
- Missing multi-arch support: Ensure that the package build environment supports multi-arch if necessary.
- Permission errors: Verify that the user has sufficient permissions to install files in the target directory.
Integration
Integration with dh_prep: dh_installmodules should be used after dh_prep has unpacked the source files.
Using in scripts: dh_installmodules can be incorporated into Debian package build scripts to automate module installation.
Related Commands
dh_builddeb: Builds Debian binary packagesdh_prep: Prepares Debian packages for buildingdebhelper: Contains various helper tools for Debian package management