Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??
Michael Schwern, maintainer of ExtUtils::MakeMaker, also called it broken and said he wanted to fix it at some point.

While these days I just grab my default module template from my code repository, since at least 5.8 you get a sensible default layout with h2xs:

% h2xs --use-new-tests -AXn Foo::Bar::Ni Defaulting to backwards compatibility with perl 5.8.3 If you intend this module to be compatible with earlier perl versions, + please specify a minimum perl version with the -b option. Writing Foo-Bar-Ni/lib/Foo/Bar/Ni.pm Writing Foo-Bar-Ni/Makefile.PL Writing Foo-Bar-Ni/README Writing Foo-Bar-Ni/t/Foo-Bar-Ni.t Writing Foo-Bar-Ni/Changes Writing Foo-Bar-Ni/MANIFEST % ls Foo-Bar-Ni/ Changes Makefile.PL lib MANIFEST README t % ls -lR Foo-Bar-Ni/lib total 0 drwxrwxr-x 3 adrianh staff 102 30 Mar 12:52 Foo Foo-Bar-Ni/lib/Foo: total 0 drwxrwxr-x 3 adrianh staff 102 30 Mar 12:52 Bar Foo-Bar-Ni/lib/Foo/Bar: total 8 -rw-rw-r-- 1 adrianh staff 1756 30 Mar 12:52 Ni.pm
Either you have to keep installing it every time you edit the file, or you mess with @INC and edit it within the blib/ directory (where it goes when you do the make) and then copy it back into place when you finish. It's even worse if you have multiple modules in your distribution with different namespaces (i.e. Foo::Something and Bar::Something).

h2xs now puts things in DIST/lib so the old default layout problems you mention are simple to overcome with PERL5LIB and PERL5OPT.


In reply to Re^4: In praise of h2xs: A tool you gotta have by adrianh
in thread In praise of h2xs: A tool you gotta have by talexb

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!
  • 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, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            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.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others musing on the Monastery: (11)
    As of 2014-09-30 15:14 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      How do you remember the number of days in each month?











      Results (375 votes), past polls