ltprune.eclass

Name

ltprune.eclass -- Smart .la file pruning

Description

A function to locate and remove unnecessary .la files.

Discouraged. Whenever possible, please use much simpler:

find "${ED}" -type f -name '*.la' -delete || die

Deprecated

Replacement: none

Supported EAPIs

0 1 2 3 4 5 6

Functions

prune_libtool_files [--all|--modules]

Locate unnecessary libtool files (.la) and libtool static archives (.a) and remove them from installation image.

By default, .la files are removed whenever the static linkage can either be performed using pkg-config or doesn't introduce additional flags.

If '--modules' argument is passed, .la files for modules (plugins) are removed as well. This is usually useful when the package installs plugins and the plugin loader does not use .la files.

If '--all' argument is passed, all .la files are removed without performing any heuristic on them. You shouldn't ever use that, and instead report a bug in the algorithm instead.

The .a files are only removed whenever corresponding .la files state that they should not be linked to, i.e. whenever these files correspond to plugins.

Note: if your package installs both static libraries and .pc files which use variable substitution for -l flags, you need to add pkg-config to your DEPEND.

Maintainers

Michał Górny <mgorny@gentoo.org>

Reporting Bugs

Please report bugs via https://bugs.gentoo.org/