From 9c8d38af94b07714ff5530004365dffd340b46ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BE=9D=E7=91=AA=E8=B2=93?= Date: Mon, 8 Feb 2021 10:51:20 +0800 Subject: [PATCH] Added the CPAN distribution metadata to Makefile.PL and Build.PL. --- Build.PL | 15 +++++++++++++++ Makefile.PL | 24 ++++++++++++++++-------- 2 files changed, 31 insertions(+), 8 deletions(-) diff --git a/Build.PL b/Build.PL index cffb144..0b9e9b6 100755 --- a/Build.PL +++ b/Build.PL @@ -302,6 +302,21 @@ my $build = Module::Build->new( "Module::Signature" => 0, }, add_to_cleanup => [ "t/Config.pm", "TAGS" ], + + meta_merge => { + "meta-spec" => { version => 2 }, + resources => { + homepage => "https://metacpan.org/release/DbFramework", + repository => { + type => "git", + url => "git://github.com/imacat/DbFramework.git", + web => "https://github.com/imacat/DbFramework", + }, + bugtracker => { + "web" => "https://github.com/imacat/DbFramework/issues" + } + }, + }, ); $build->create_build_script; diff --git a/Makefile.PL b/Makefile.PL index f6ea994..e803a4a 100755 --- a/Makefile.PL +++ b/Makefile.PL @@ -284,19 +284,12 @@ CREATE TABLE c_table ( } } -# LICENSE is only availabe since ExtUtils::MakeMaker 6.30_01 -use vars qw(%license $eummver); -%license = qw(); -$eummver = $ExtUtils::MakeMaker::VERSION; -$eummver =~ s/_//; -%license = (LICENSE => "perl") if $eummver > 6.30; - WriteMakefile( NAME => "DbFramework", VERSION => "1.12", ABSTRACT => "Classes for Manipulating DBI Databases, Based on the CDIF Data Model Subject Area", AUTHOR => "imacat ", - %license, + LICENSE => "perl", PREREQ_PM => { "Alias" => 0, "DBI" => 1.06, @@ -315,4 +308,19 @@ WriteMakefile( clean => { FILES => "t/Config.pm TAGS", }, + + META_MERGE => { + "meta-spec" => { version => 2 }, + resources => { + homepage => "https://metacpan.org/release/DbFramework", + repository => { + type => "git", + url => "git://github.com/imacat/DbFramework.git", + web => "https://github.com/imacat/DbFramework", + }, + bugtracker => { + "web" => "https://github.com/imacat/DbFramework/issues" + } + }, + }, );