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

I'm flummoxed by how you create META.yml with Module::Build. ./Build dist returns "Could not create MYMETA files" and I haven't been able to find a solution in the docs.

If I create a META.yml file and add it to the MANIFEST, when I run ./Build dist, I get "Can't copy('META.yml', 'Keele-Utilities-Database-0.02/META.yml')"

This is as vanilla as I would guess, build with module-starter and I don't know what to check next.

Any suggestions?

perl -e 'print qq(Just another Perl Hacker\n)' # where's the irony switch?

Replies are listed 'Best First'.
Re: creating META.yml with Module::Build
by Anonymous Monk on Jan 23, 2012 at 16:43 UTC

    What? Upgrade upgrade upgrade?

    $ module-starter --mb --module=Junk --author=name --email=email Created starter directories and files $ cd Junk $ perl Build.PL Created MYMETA.yml and MYMETA.json Creating new 'Build' script for 'Junk' version '0.01' $ perl Build dist Creating Makefile.PL Module::Build was not found in configure_requires! Adding it now automatically as: configure_requires => { 'Module::Build' => 0.38 } Created META.yml and META.json Creating Junk-0.01 Creating Junk-0.01.tar.gz $ tar -zxvf Junk-0.01.tar.gz Junk-0.01 Junk-0.01/Build.PL Junk-0.01/Changes Junk-0.01/Makefile.PL Junk-0.01/MANIFEST Junk-0.01/META.json Junk-0.01/META.yml Junk-0.01/README Junk-0.01/lib Junk-0.01/lib/Junk.pm Junk-0.01/t Junk-0.01/t/00-load.t Junk-0.01/t/manifest.t Junk-0.01/t/pod-coverage.t Junk-0.01/t/pod.t $ pmvers Module::Build ExtUtils::MakeMaker Module::Build: 0.38 ExtUtils::MakeMaker: 6.62

    And oh yeah, Module::Build is junk, it uses MakeMaker to generate META

      I've got:
      • Module::Build 0.38
      • ExtUtils::MakeMaker 6.55_02
      which is what comes bundled with Fedora 13. Upgrading to ExtUtils-MakeMaker-6.62 with CPAN and META.yml and META.json appear when I ./Build dist.

      Now that you've solved the problem, tell me what's your favourite module creation tool. I chose Module::Build over Module::Install (IIRC) for some reason I can't remember, I think because it was pure Perl.

      best,

      perl -e 'print qq(Just another Perl Hacker\n)' # where's the irony switch?

        Well, use what works for you, I simply don't see why the Module::Build maintainers could not write a META file, they invented it

        I do like Module::Install, and yes, it is built on top of Module::Build