• [gentoo-dev] [PATCH] metadata/install-qa-check.d: add 60libtool-la (che

    From Sam James@21:1/5 to All on Fri Apr 15 10:50:01 2022
    Signed-off-by: Sam James <sam@gentoo.org>
    ---
    metadata/install-qa-check.d/60libtool-la | 45 ++++++++++++++++++++++++
    1 file changed, 45 insertions(+)
    create mode 100644 metadata/install-qa-check.d/60libtool-la

    diff --git a/metadata/install-qa-check.d/60libtool-la b/metadata/install-qa-check.d/60libtool-la
    new file mode 100644
    index 000000000000..fd21ec8406d3
    --- /dev/null
    +++ b/metadata/install-qa-check.d/60libtool-la
    @@ -0,0 +1,45 @@
    +# Check if we're installing .la files unnecessarily
    +# https://projects.gentoo.org/qa/policy-guide/installed-files.html#pg0303
    +
    +libtool_la_check() {
    + if [[ ${CATEGORY}/${PN} == dev-libs/libltdl ]] ; then
    + # bug #293921
    + return
    + fi
    +
    + # Bail out if there aren't any .la files being installed
    + local files=$(find "${ED}"/usr/lib* -name '*.la' -print 2>/dev/null)
    + [[ -n "${files[@]}" ]] || return
    +
    + if grep -q "dev-libs/libltdl" <<<${RDEPEND}; then
    + # Nothing to do here
    + return
    + fi
    +
    + # Iterate over all the .la files we are installing to verify there's
    + # a corresponding
  • From Michael Orlitzky@21:1/5 to Sam James on Fri Apr 15 16:40:01 2022
    On Fri, 2022-04-15 at 09:40 +0100, Sam James wrote:
    +
    +       if grep -q "dev-libs/libltdl" <<<${RDEPEND}; then +               # Nothing to do here +               return
    +       fi

    We should probably have delimiters around that atom to future-proof it
    against (say) dev-libs/libltdl2. Would "has" suffice?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)