Well personally I use Module::Install (where no_index is also mostly
undocumented too, but exists). It's what all the Cool Kids(tm) use these
days. For example here's my Makefile.PL for Class::Autouse.
-----------------------------------------------------------------
use inc::Module::Install;
name ( 'Class-Autouse' );
abstract ( 'Run-time class loading on first method call' );
author ( 'Adam Kennedy<[EMAIL PROTECTED]>' );
version_from ( 'lib/Class/Autouse.pm' );
license ( 'perl' );
requires ( 'perl' => '5.005' );
requires ( 'Carp' => '0' );
requires ( 'File::Spec' => '0.82' );
requires ( 'List::Util' => '1.11' );
build_requires( 'Test::More' => '0.47' );
# Requested by clkao to make installation of svk in some
# situations easier and not fail.
include ( 'ExtUtils::AutoInstall' );
# Our test directories contain valid looking modules.
# Make sure they don't get indexed.
no_index ( directory => 'modules' );
auto_install();
&WriteAll;
----------------------------------------------------------------
In Class::Autouse, the directory "modules" contains a whoooole bunch of
files for testing the autoloading weird cases. Things like...
A.pm
A/B.pm
C.pm
J.pm
T.pm
T/A.pm
T/B.pm
T/B/G.pm
and so on... about 20 something total.
The no_index command results in a no_index entry being added to the
META.yml file, but only in that being added with no other effects.
I'm afraid I have no knowledge of how to do it in vanilla MakeMaker, if
Module::Build supports it. Perhaps someone needs to file a "doesn't
support no_index" bug against Module::Build? :)
Adam K
Ivan Tubert-Brohman wrote:
Adam Kennedy wrote:
Only the libraries (and .pod docs) in your dist should be indexed)
things in inc/ and t/ and examples/ etc should NOT be indexed. Thus,
there should be a no_index entry in the meta.yml for all of these
directories (if they have .pm files in them).
Sorry for my ignorance, but I had never even heard of this option. I
don't find any way of setting it via MakeMaker or Module::Build. Do I
have to edit META.yml by hand? Would it get overritten by 'make dist'?
Ivan