Manpages

NAME

dh-exec-subst - Debhelper executable file substition scripts

SYNOPSIS

#! /usr/bin/dh-exec
src/libfoo-*.so.* debian/foo-plugins/usr/lib/foo/${DEB_HOST_MULTIARCH}/

DESCRIPTION

Being a sub-command of dh-exec(1), this program must not be ran directly, but through dh-exec, which automatically runs all available sub-commands if run bare; or explicitly with dh-exec --with=subst.

It is a wrapper around the various other substitution helpers, and will pipe the input file through all the available substitution helpers. It is up to these scripts to do the actual work.

When a helper fails to expand a variable within its input, it will leave it as-is, so that later in the pipeline it can perhaps be expanded by another program.

SCRIPTS

dh-exec-subst-env

Substitutes any of the available, exported environment variables into its input. It does not do any kind of filtering: whatever is available in the environment, will be available for substitution, however unsafe that may be.

${FOO} and ${env:FOO} both will expand to the environment variable FOO. Only the env form will error if the variable is unset, in keeping with debhelper(7) convention.

Introduced in version 0.1, with the env: format added in 0.29.

dh-exec-subst-multiarch

Attempts to expand any of the variables known to dpkg-architecture(1), mostly useful for multi-arch support.

The command will query dpkg-architecture(1) directly, and does not rely on environment variables set (as the called program will prefer already set environment variables anyway).

Introduced in version 0.1.

ENVIRONMENT

DH_EXEC_SCRIPTDIR

Indicates which directory the command-specific scripts should be sought for. If not specified, scripts will be searched for in /usr/share/dh-exec/.

FILES

$DH_EXEC_SCRIPTDIR/dh-exec-subst-*

The various scripts for the higher-level program.

VERSIONS

The sub-command was introduced in dh-exec version 0.1.

SEE ALSO

dh-exec(1), dpkg-architecture(1), debhelper(7)