build::...n32_MSVC(3)

πŸ“¦
version 0.9932 Β· 3 versions
, in fedora 43

πŸŽ€ build::...n32_MSVC β€” User Contributed Perl Documentation πŸ’…

okay bestie so this page lives on the User Contributed Perl Documentation shelf, in section 3 of the manual (that's the library-calls aisle, iykyk), filed under the name build::...n32_MSVC(3). πŸ¦‹

and like… that is genuinely the entire page. no SYNOPSIS, no OPTIONS, no SEE ALSO, no DESCRIPTION β€” it's one of those man pages that just serves you the source code raw. two Perl subs, chillin', no context. not me showing up expecting an essay and getting a snack 😭 but it's a good snack, so let's read it together. πŸ“


✨ THE WHOLE ENTIRE CONTENT ✨

here it is, verbatim, no cap, nothing skipped:

sub post_initialize {
    my( $self ) = @_;

           $self->{PERL_LIB} = 'C:\Programmi\Devel\Perl\ActivePerl\588.817\xlib\wince-arm-pocket-wce300';
           $self->{PERL_ARCHLIB} = 'C:\Programmi\Devel\Perl\ActivePerl\588.817\xlib\wince-arm-pocket-wce300';
           $self->{PERL_INC} = $self->catdir( $self->{PERL_LIB}, "CORE" );

           return '';
       }

       sub tool_xsubpp {
           my( $self ) = @_;

           package MY;
           local $self->{PERL_LIB} = 'C:\Programmi\Devel\Perl\ActivePerl\588.817\lib';
           return $self->SUPER::tool_xsubpp;
       }

🧚 what's even happening here

first up, post_initialize. it grabs $self off the argument list, then sets three keys on it:

  • $self->{PERL_LIB} β€” gets set to C:\Programmi\Devel\Perl\ActivePerl\588.817\xlib\wince-arm-pocket-wce300 πŸ’–
  • $self->{PERL_ARCHLIB} β€” gets set to that exact same string, C:\Programmi\Devel\Perl\ActivePerl\588.817\xlib\wince-arm-pocket-wce300
  • $self->{PERL_INC} β€” gets built with $self->catdir( $self->{PERL_LIB}, "CORE" ), so it's PERL_LIB with CORE glued on the end

and then it returns the empty string ''. that's it, that's the whole sub. humble. understated. iconic. πŸ‘‘

then tool_xsubpp. also takes $self. it declares package MY; (yes, inside the sub, right there in the middle, we love a dramatic entrance πŸ’€), then local-izes $self->{PERL_LIB} to a different path this time β€” C:\Programmi\Devel\Perl\ActivePerl\588.817\lib, note the missing xlib\wince-arm-pocket-wce300 tail, she's got range β€” and finally returns $self->SUPER::tool_xsubpp. so the local only sticks around for the duration of that super call, and then everything snaps back. periodt. 🌈

heads up bestie: local here is scoped to the enclosing block, so the PERL_LIB swap is temporary. don't go assuming it sticks around after tool_xsubpp returns. 🫢

πŸ’œ the sign-off

this absolute little gem ships with perl v5.42.0 and it's dated 2025-07-28. that's the source and the date, right there at the bottom of the page, and now you know them. go forth and build something, main character. πŸŒΈπŸ’…βœ¨

πŸ“¦ where this page comes from