open (MANIFEST, "../MANIFEST") or die $!;
@MANIFEST = grep !m</(?:t|demo)/>, <MANIFEST>;
-push @MANIFEST, 'lib/Config.pm', 'lib/Errno.pm';
+push @MANIFEST, 'lib/Config.pod', 'lib/Errno.pm', 'lib/lib.pm',
+ 'lib/DynaLoader.pm', 'lib/XSLoader.pm';
for (@MANIFEST) {
my $filename;
next unless s|^lib/|| or m|^ext/|;
- ($filename) = m|^(\S+)|;
+ my ($origfilename) = ($filename) = m|^(\S+)|;
$filename =~ s|^[^/]+/|| if $filename =~ s|^ext/||;
next unless $filename =~ m!\.p(m|od)$!;
- next unless open (MOD, "../lib/$filename");
+ unless (open (MOD, "../lib/$filename")) {
+ unless (open (MOD, "../$origfilename")) {
+ warn "Couldn't open ../$origfilename: $!";
+ next;
+ }
+ $filename = $origfilename;
+ }
my ($name, $thing);
close MOD;
my $perlname = $filename;
+ $perlname =~ s!^.*\b(ext|lib)/!!;
$perlname =~ s!\.p(m|od)$!!;
+ $perlname =~ s!\b(\w+)/\1\b!$1!;
$perlname =~ s!/!::!g;
($name, $thing) = split / --? /, $title, 2;
perlmodlib - constructing new Perl modules and finding existing ones
-=head1 DESCRIPTION
-
=head1 THE PERL MODULE LIBRARY
-Many modules are included the Perl distribution. These are described
+Many modules are included in the Perl distribution. These are described
below, and all end in F<.pm>. You may discover compiled library
-file (usually ending in F<.so>) or small pieces of modules to be
+files (usually ending in F<.so>) or small pieces of modules to be
autoloaded (ending in F<.al>); these were automatically generated
by the installation process. You may also discover files in the
library directory that end in either F<.pl> or F<.ph>. These are
manner with respect to namespace pollution because they use the
Exporter module. See their own documentation for details.
+It's possible that not all modules listed below are installed on your
+system. For example, the GDBM_File module will not be installed if you
+don't have the gdbm library.
+
=over 12
EOF
To find out I<all> modules installed on your system, including
those without documentation or outside the standard release,
-just do this:
+just use the following command (under the default win32 shell,
+double quotes should be used instead of single quotes).
- % find `perl -e 'print "@INC"'` -name '*.pm' -print
+ % perl -MFile::Find=find -MFile::Spec::Functions -Tlwe \
+ 'find { wanted => sub { print canonpath $_ if /\.pm\z/ },
+ no_chdir => 1 }, @INC'
+(The -T is here to prevent '.' from being listed in @INC.)
They should all have their own documentation installed and accessible
via your system man(1) command. If you do not have a B<find>
program, you can use the Perl B<find2perl> program instead, which
to fix your manpath. See L<perl> for details. If you have no
system B<man> command, you might try the B<perldoc> program.
+Note also that the command C<perldoc perllocal> gives you a (possibly
+incomplete) list of the modules that have been further installed on
+your system. (The perllocal.pod file is updated by the standard MakeMaker
+install process.)
+
=head2 Extension Modules
Extension modules are written in C (or a mix of Perl and C). They
for adequate testing and configuration across the multitude of
platforms on which Perl was beta-tested. You are encouraged to
look for them on CPAN (described below), or using web search engines
-like Alta Vista or Deja News.
+like Alta Vista or Google.
=head1 CPAN
The general mechanism is to assert your Copyright and then make
a declaration of how others may copy/use/modify your work.
-Perl, for example, is supplied with two types of licence: The GNU
-GPL and The Artistic Licence (see the files README, Copying, and
-Artistic). Larry has good reasons for NOT just using the GNU GPL.
+Perl, for example, is supplied with two types of licence: The GNU GPL
+and The Artistic Licence (see the files README, Copying, and Artistic,
+or L<perlgpl> and L<perlartistic>). Larry has good reasons for NOT
+just using the GNU GPL.
My personal recommendation, out of respect for Larry, Perl, and the
Perl community at large is to state something simply like: