diff options
author | Kent Fredric <kentfredric@gmail.com> | 2014-08-25 00:29:14 +1200 |
---|---|---|
committer | Kent Fredric <kentfredric@gmail.com> | 2014-08-25 00:29:14 +1200 |
commit | 2b3eb8fa5687ff501687e12d1c133eccc6e3670e (patch) | |
tree | d8c4a4f7376e3c85cfc5ace12f7a29869f9c2e77 /eclass/perl-module.eclass | |
parent | [fixup] dev-perl/Catalyst-Authentication-Store-Htpasswd Migrate to EAPI5 and ... (diff) | |
download | perl-overlay-2b3eb8fa5687ff501687e12d1c133eccc6e3670e.tar.gz perl-overlay-2b3eb8fa5687ff501687e12d1c133eccc6e3670e.tar.bz2 perl-overlay-2b3eb8fa5687ff501687e12d1c133eccc6e3670e.zip |
add perl_rm_files function to perl-module.eclass ( bug #520756 )
Diffstat (limited to 'eclass/perl-module.eclass')
-rw-r--r-- | eclass/perl-module.eclass | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/eclass/perl-module.eclass b/eclass/perl-module.eclass index b1d4c2e0b..6f7b5f41f 100644 --- a/eclass/perl-module.eclass +++ b/eclass/perl-module.eclass @@ -426,6 +426,36 @@ perl_remove_temppath() { done } +# @FUNCTION: perl_rm_files +# @USAGE: perl_rm_files "file_1" "file_2" +# @DESCRIPTION: +# Remove certain files from a Perl release and remove them from the MANIFEST +# while we're there. +# +# Most useful in src_prepare for nuking bad tests, and is highly recommended +# for any tests like 'pod.t', 'pod-coverage.t' or 'kwalitee.t', as what they +# test is completely irrelevant to end users, and frequently fail simply +# because the authors of Test::Pod... changed their recommendations, and thus +# failures are only useful feedback to Authors, not users. +# +# Removing from MANIFEST also avoids needless log messages warning +# users about files "missing from their kit". +perl_rm_files() { + debug-print-function $FUNCNAME "$@" + local skipfile=${S}/.gentoo_makefile_skip + local manifile=${S}/MANIFEST + local manitemp=${S}/.gentoo_manifest_temp + for filename in "$@"; do + einfo "Removing un-needed ${filename}"; + # Remove the file + rm ${S}/$filename + echo ${filename} >> ${skipfile} + done + grep -v -F -f $skipfile $manifile > $manitemp + mv $manitemp $manifile + rm $skipfile; +} + perl_link_duallife_scripts() { debug-print-function $FUNCNAME "$@" if [[ ${CATEGORY} != perl-core ]] || ! has_version ">=dev-lang/perl-5.8.8-r8" ; then |