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

Hello Monks,

I use the following DOS command to create a Build.PL file:

module-starter --distro=Sudoku-Preset --builder=Module::Build --module=Games::Sudoku::Preset --ignore=manifest --license=perl --author="Klaus Wittrock" --email=Wittrock#cpan.org

Note: Since I don't know how to continue a DOS command on the next line, I actually entered this on a single line.

No config file is used.

The license line in the created Build.PL reads

    license             => 'Perl_5',

When I then run

cd Sudoku-Preset perl Build.PL

I get this message:

Nothing to enter for 'provides' field in metafile. Could not get valid metadata. Error is: Invalid metadata structure. Er +rors: License 'Perl_5' is invalid (license) [Validation: 1.4] at E:/P +rogramme(x86)/ActivePerl/lib/Module/Build/Base.pm line 4571. Could not create MYMETA files

What did I wrong? Everything works if I manually change in Build.PL

    license             => 'perl',

but I would prefer to do things right from the beginning

Windows 7 Prof

ActivePerl v5.16.3

Module::Starter v1.62

Module::Build v0.4003

Any hint is welcome. Thanks for your kind help.

Replies are listed 'Best First'.
Re: [Module::Starter] question for option --license
by ateague (Monk) on May 21, 2014 at 14:09 UTC
    Note: Since I don't know how to continue a DOS command on the next line, I actually entered this on a single line.
    FYI the line continuation character in windows CMD is "^". e.g.:
    dir ^ /b ^ *.pdf

      Thank you for this information. It's good to know particularly for commands with many parameters, to keep them readable.

Re: [Module::Starter] question for option --license
by Anonymous Monk on May 21, 2014 at 11:32 UTC
    error message says ... Module/Build ... so, upgrade Module::Build :)

      Thank you for your reply. I did as suggested, now I have Module::Build v0.4205. Unfortunately the error is still there, only the message has changed slightly. Old:

      License 'Perl_5' is invalid (license) [Validation: 1.4] at E:/P+rogramme(x86)/ActivePerl/lib/Module/Build Base.pm line 4571.

      New:

      License 'Perl_5' is invalid (license -> Perl_5) [Validation: 2] at E:/Programme(x86)/ActivePerl/site/lib/Module/Build/Base.pm line 4555.
        Unfortunately the error is still there

        I *think* that it might be the fault of Module::Starter.
        I found a couple of Build.PL files that specify "license" => "perl", and I speculate that's what it needs to be. (META.json files specify "perl_5", but everywhere else that I've seen specifies simply "perl".)

        Cheers,
        Rob
        When you upgraded Module::Build, did you do the same for the prerequisites ... like Software::License? Should have happened automatically I think :/