Hi pg,

gathering from your nick name, if not you who else should be familiar with the inards of pagers ;-)

n.b. @ perlmonks' moderators, sorry for using the <pre> tag once again. When I logged in I just noticed for a second your request on my first posting here to refrain from using this tag. I'm afraid, I still will have to read your FAQs on formatting guidelines. I have been too impatient to reply to my post's responders, and didn't know for now how else to avoid the clutter.

Now back to pg.
Of course I felt that setting $ENV{PAGER} within the debug session was at a too late stage. That's why I already tried the shell's (i.e. HP-UX's standard shell which is a POSIX Bourne type) way of giving processes an environment by invocating the Perl debugger like this:

$ PAGER=/usr/local/bin/less /usr/bin/perl -de ./my_buggy_script.pl
(of course one could have also used the Unix "env" command)

and I also tried the even better way (like you mentioned) of explicitly exporting PAGER:

$ export PAGER=/usr/local/bin/less $ printenv PAGER /usr/local/bin/less $ perl -de my_buggy_script.pl
Then in the debugger I did this:
'time' => 1039509243 '/var/spool/sw' => HASH(0x4033aca0) 'basetype' => 'vxfs' 'bavail' => 262045 'bfree' => 279512 'blocks' => 512000 'bsize' => 8192 'favail' => 69876 'ffree' => 69876 'files' => 73740 'flag' => 0 'frsize' => 1024 'fsid' => 1073741834 'fstr' => '/var/spool/sw' 'namemax' => 255 'size' => 512000 'time' => 1037307204 DB<4> H 3: x \%mnt 2: |x \%mnt 1: o pager? DB<4> !1 o pager? pager = '|/usr/local/bin/less' DB<5>
n.b. the hash %mnt is a lol with mount points as keys and as values the results of statvfs syscalls on these as a hashref (retrieved through the wonderful Filesys::Statvfs CPAN module).

By the debugger history above I just wanted to show that "|x \%mnt" fails (i.e. displays nothing), whereas "x \%mnt" scrolls over the screen (I only copied the last key's value here).

This only happens with my Perl builds of "new" releases > 5.6.0 On the boxes where I still have Perl <= 5.6.0 the debugger works as expected, and honours preset PAGER settings.

Looks to me as if there is a bug in the Perl port for HP-UX 11.X 64Bit.

Btw, have you tried to build a Perl 5.8.X on HP-UX (in case you have access to this platform)? Maybe the Configure routine is broken for this platform. I can tell you how long I struggled to get DBD::Oracle working on this platform. Maybe I miss some library, patch, or the linking was insufficient after Configure and make (e.g. PIC etc.)

Would be nice to here from someone who uses the Perl debugger on HP-UX if they encounter similar strangenesses.

Anyway, many thanks for pointing me to the involved Perl code.

Edit by tye (replace PRE with formatting)


In reply to Re: Re: Perl 5.8.0 debugger annoyances by SIGSEGV
in thread Perl 5.8.0 debugger annoyances by SIGSEGV

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.