Gentoo Archives: gentoo-dev

From: Matthias Bethke <matthias@×××××××.de>
To: gentoo-dev@l.g.o
Cc: perl@g.o
Subject: [gentoo-dev] Perl: please don't delete packlists
Date: Sun, 09 Sep 2012 03:55:22
Message-Id: 20120909035351.GD3270@dennis.towiski.de
1 I just tried (and failed) to pack a script with App::FatPacker and
2 noticed Gentoo follows the bad example of most other distributions in
3 removing all .packlist files from Perl module installations.
4
5 These files are the only system-independent way of determining which
6 modules belong together as part of a CPAN distribution, e.g. to find
7 that Template::Parser belongs to the Template Toolkit proper while
8 Template::Timer is an external add-on. FatPacker needs them to determine
9 which modules to pack into the archive that makes a standalone script
10 not requiring any external non-core modules, and so do various other
11 bits such as Module::Installed.
12
13 Can we please keep these? It's not like a handful of files with a couple
14 hundred bytes per installed module at worst made any significant
15 difference in either disk use or search times, but removing them is a
16 Bad Idea that probably came from Debian and needlessly breaks stuff.
17
18 I solved my problem by
19
20 a) removing the patches to ExtUtils::MakeMaker that delete packlist
21 creation from the perl and vendor targets in generated makefiles, and
22
23 b) modifying perl-module.eclass so it removes only empty *.bs files:
24
25 --- /usr/portage/eclass/perl-module.eclass.orig 2012-09-01 08:26:44.245212715 -0600
26 +++ /usr/portage/eclass/perl-module.eclass 2012-09-01 10:22:10.308419665 -0600
27 @@ -123,7 +123,7 @@
28 --installdirs=vendor \
29 --libdoc= \
30 --destdir="${D}" \
31 - --create_packlist=0 \
32 + --create_packlist=1 \
33 "${myconf_local[@]}"
34 einfo "perl Build.PL" "$@"
35 perl Build.PL "$@" <<< "${pm_echovar}" \
36 @@ -341,8 +341,7 @@
37 debug-print-function $FUNCNAME "$@"
38 perl_set_version
39 if [[ -d ${D}/${VENDOR_ARCH} ]] ; then
40 - find "${D}/${VENDOR_ARCH}" -type f -a \( -name .packlist \
41 - -o \( -name '*.bs' -a -empty \) \) -delete
42 + find "${D}/${VENDOR_ARCH}" -type f -a \( -name '*.bs' -a -empty \) -delete
43 find "${D}" -depth -mindepth 1 -type d -empty -delete
44 fi
45 }
46
47 The perl_delete_packlist() function should probably not be called that any more
48 as it only deals with DynaLoader files now but that would require changing a
49 few ebuilds as well:
50
51 dev-libs/libprelude
52 www-apache/mod_perl
53 net-analyzer/rrdtool
54
55 I think Gentoo of all distributions should aim to provide software as
56 "original" as possible. If there are any reasons that I have ignored so
57 far why people would want the current behavior, how about I make this
58 patch conditional on a new use flag?
59
60 cheers,
61 Matthias

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-dev] Perl: please don't delete packlists Kent Fredric <kentfredric@×××××.com>