wolis has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks,

is there a nice simple (I cant find one yet) description of all of these folders (perl site lib auto) containing apparently duplicate stuff?

If I were ruler of the universe I would have one folder call lib and all modules live there (shrug).

I have been told that I can create my own stuff.pm and put in the same folder as my app.pl and just use stuff; without having to have it installed.. whats the deal with installing anyhow?

I also saw (in the poetry section) someone defining a module within the script itself (I'm a lumberjack..) but when I tried to run it to see If I could come to terms with all of this potential it failed :-(

PS Im a Win9x users so my world view may be slightly different :-)
 ___
/\__\ "What is the world coming to?"
\/__/ www.wolispace.com

Replies are listed 'Best First'.
Re: perl site lib auto what?
by PodMaster (Abbot) on Sep 03, 2003 at 00:42 UTC
    Stuff in perl/lib are CORE modules (Module::Corelist), stuff in site/lib are modules you installed yourself, and as for auto yada yada yada, it's for .DLLs etc etc (see ExtUtils::MakeMaker)... don't worry about it. If you plan on installing your custom modules, make proper cpan distributions(Tutorials), otherwise use lib qw[yoda];.

    A module is a file ending in .pm which may or may not have magic associated with it (the appropriate /auto directory...) that declares an appropriate package (as in strict.pm is located in @INC and it declares the package strict;, it's considered a module, given it compiles of course ;D).

    You may also wish to look into ExtUtils::ModuleMaker and h2xs.

    The perl tree can take all kind of shape depending on how you configured perl during install (so if you're further curious, you need to read the various READMEs included with the perl source, and actually compile/install perl yourself so you can see what goes on)

    PS -- kindly avoid fancy colorin in your html lest you know what you're doing (perl monks approved html), because perlmonks has many themes

    MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
    I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
    ** The third rule of perl club is a statement of fact: pod is sexy.

      Thanks for that, it all makes sense.

      I can see now the modules I have installed only appear under site.. along with a bunch of others I assume ActivePerl installed form me (so thoughtful).

      Id like to have a really nice tiny cut-down c:\perl folder so armed with this info I'll try some careful pruning :-)

      PS -- reviewing what I had orginally posted I belive my mistakes:

      <br> not <br /> not using quotes around the attributes of <font color=#c0c0c0>
      These are both issues as I understand relating HTMLX or trying to make HTML more XMLish.. not made that obvious in the approved html docs.

      If I did anything else wrong please let me know and if I didnt get this one right I'll give up! :-)

      ___ /\__\ "what is the world coming to?" \/__/ www.wolispace.com