FS#16488 - [perl] 5.10.1-3 missing perldoc docs

Attached to Project: Arch Linux
Opened by Alex Hunsaker (badalex) - Tuesday, 06 October 2009, 17:51 GMT
Last edited by Francois Charette (Firmicus) - Thursday, 08 October 2009, 13:33 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Kevin Piche (kpiche)
Francois Charette (Firmicus)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description: core perldoc docs went missing int the 5.10.1 bump :(

$ perldoc -f sprintf
No documentation found for "perlfunc".

Seems to be due to the default PURGE_TARGETS=(... *.pod) in makepkg.conf

Additional info:
Tried both 5.10.1-3 and 5.10.1-4 (in testing)
This task depends upon

Closed by  Francois Charette (Firmicus)
Thursday, 08 October 2009, 13:33 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in 5.10.1-5 (now in testing)
Comment by Francois Charette (Firmicus) - Wednesday, 07 October 2009, 11:59 GMT
Yep, that's a bit stupid :)
(Note than "man perlfunc" does work ... but then of course you have to search for the function name manually within your $PAGER).
However, building with option '!purge' keeps ALL pod files, which is not what we want.
Perhaps we should only keep those under /usr/share/perl5/core_perl/pod/, which includes the file perlfunc.pod (which perldoc parses when called with option -f).
Opinions?
Comment by Alex Hunsaker (badalex) - Wednesday, 07 October 2009, 16:33 GMT
Huh, call me crazy but imho unless you have !docs I would think you would want the pods...

Anyway is /usr/share/perl5/core_perl/pod/ where perlre, perlfaq, perldelta and friends live (a quick look says yes it is)? If so that would get my vote :)

I guess if some people really hate pods maybe a perl-doc package like d*bi*n (name censored to protect the innocent) would be in order?
Comment by Francois Charette (Firmicus) - Wednesday, 07 October 2009, 20:27 GMT
Well, I think it's simpler to include them in the core perl package. They don't take that much space.
I have added these lines to the PKGBUILD (besides the option '!purge') and I think that will do it:

# Remove all pod files *except* those under /usr/share/perl5/core_perl/pod/
rm -f $pkgdir/usr/share/perl5/core_perl/*.pod
for d in $pkgdir/usr/share/perl5/core_perl/*; do
if [ -d $d -a $(basename $d) != "pod" ]; then
find $d -name *.pod -delete
fi
done
find $pkgdir/usr/lib -name *.pod -delete
find $pkgdir -name .packlist -delete

Not committed yet. Comments welcome ;)
Comment by Alex Hunsaker (badalex) - Wednesday, 07 October 2009, 21:01 GMT
Tried it out yep, that works. I dont like the !purge... Is it less ugly than something like the below? i dunno

for f in $pkgdir/usr/share/perl5/core_perl/pod/*.pod; do
mv $f $f.keeppod
done

# somewere off in a postinst
for f in $pkgdir/usr/share/perl5/core_perl/pod/*.keeppod; do
mv $f `basename $f .keeppod`
done
Comment by Francois Charette (Firmicus) - Thursday, 08 October 2009, 09:55 GMT
Nope, that is a very bad idea, because pacman would register the .keeppod files, and know nothing about the .pod ones!

The ugly thing is the default purge. !purge just turns this off.

Loading...