Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 242524 - dev-perl/perlmenu getcap() doesn't work without file modifications
Summary: dev-perl/perlmenu getcap() doesn't work without file modifications
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: AMD64 Linux
: High minor (vote)
Assignee: Gentoo Perl team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-18 00:23 UTC by Matt Rechkemmer
Modified: 2010-07-24 20:00 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Ebuild with new SRC_URI and getcap patch (perlmenu-4.0-r1.ebuild,781 bytes, text/plain)
2010-05-07 15:42 UTC, Horst Prote
Details
getcap patch (perlmenu-4.0-getcap.patch,962 bytes, patch)
2010-05-07 15:43 UTC, Horst Prote
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Matt Rechkemmer 2008-10-18 00:23:25 UTC
perlmenu fails with apps that try to use getcap():
Curses function 'getcap' is not defined by your vendor at /usr/lib64/perl5/vendor_perl/5.8.8/perlmenu.pm line 382.

To workaround this, you can edit /usr/lib64/perl5/vendor_perl/5.8.8/perlmenu.pm and uncomment the Perl 5 broken getcap() section.

Reproducible: Always

Steps to Reproduce:
1.  Install dev-perl/perlmenu
2.  Extract the demo program from the package
3.  Comment out line 25 (require "./menuutil.pl"; ...); it's not required for this test
4.  Run the demo program.  Pipe it to cat -v to see the error.

N.B.: The above will corrupt your terminal requiring a 'reset'.
Actual Results:  
The error message was produced.

Expected Results:  
The demo menu program should have ran.

There's a workaround and that's to uncomment this section in perlmenu.pm:

# PERL5 ONLY (GETCAP PROBLEMS)
# Uncomment these statements if you DON'T have "getcap()" OR
# if the demo doesn't appear to work (there's a bug in some getcap's).
# if ($] >= 5.001) {                      # Perl5 ONLY!
# package Perl5::Menu_PL::Compat; # Don't pollute perlmenu.pm namespace
# require Term::Cap;                      # Get Tgetent package
# $term = Tgetent Term::Cap { OSPEED => 9600 };      # Define entry
# sub perlmenu::getcap { $term->{"_" . shift()} };  # Define local subroutine
# }
Comment 1 Torsten Veller (RETIRED) gentoo-dev 2010-04-23 11:02:40 UTC
I am going to remove perlmenu. It's not used by any package. Can't find it in CPAN.
Comment 2 Horst Prote 2010-05-07 15:40:39 UTC
(In reply to comment #1)
> I am going to remove perlmenu. It's not used by any package. Can't find it in
> CPAN.
> 
I have no problem with the removal but have some notes and questions to the package-masked-message when trying "emerge -p perlmenu":
  - dev-perl/perlmenu-4.0 (masked by: package.mask)
  /usr/portage/profiles/package.mask:
  # Torsten Veller <tove@gentoo.org> (20 Apr 2010)
  # Bundles a copy of libsqlite (#258464)
  # Tests fail (#294218)
I can't see a bundled libsqlite or any connection to the dev-perl/DBD-SQLite2 package of bugs #258464 and #294218. A bug in portage or wrong syntax in /usr/portage/profiles/package.mask?
  # (23 Apr 2010)
  # Requested but never used (#136223)
  # and does not work (#242524), HOMEPAGE dead
Yes the HOMEPAGE seems dead but the source is still in cpan archive:
http://backpan.perl.org/authors/id/S/SK/SKUNZ/perlmenu.v4.0.tar.gz

As I use perlmenu in some of my scripts I created an ebuild and a patch for the getcap problem in my local overlay. For those interested I'll attach them below.
Comment 3 Horst Prote 2010-05-07 15:42:23 UTC
Created attachment 230709 [details]
Ebuild with new SRC_URI and getcap patch
Comment 4 Horst Prote 2010-05-07 15:43:12 UTC
Created attachment 230711 [details, diff]
getcap patch
Comment 5 Torsten Veller (RETIRED) gentoo-dev 2010-05-07 16:37:48 UTC
(In reply to comment #2)

> I have no problem with the removal but have some notes and questions to the
> package-masked-message when trying "emerge -p perlmenu":
>   - dev-perl/perlmenu-4.0 (masked by: package.mask)
>   /usr/portage/profiles/package.mask:
>   # Torsten Veller <tove@gentoo.org> (20 Apr 2010)
>   # Bundles a copy of libsqlite (#258464)
>   # Tests fail (#294218)
> I can't see a bundled libsqlite or any connection to the dev-perl/DBD-SQLite2
> package of bugs #258464 and #294218. A bug in portage or wrong syntax in
> /usr/portage/profiles/package.mask?

My fault. I was adding all the perl package removals to one entry. he first two lines belong to the DBD-SQLite2 removal. I wasn't aware that it doesn't work as expected.

I'll never do it again. Thanks


> As I use perlmenu in some of my scripts I created an ebuild and a patch for the
> getcap problem in my local overlay. For those interested I'll attach them
> below.

Thanks again.
Comment 6 Torsten Veller (RETIRED) gentoo-dev 2010-07-24 20:00:31 UTC
Gone.