[libsoftware-license-perl] 04/08: refreshed add_or_later_clause patch
dod at debian.org
dod at debian.org
Sun Dec 1 17:56:30 UTC 2013
This is an automated email from the git hooks/post-receive script.
dod pushed a commit to branch master
in repository libsoftware-license-perl.
commit 0b90eccadaa1cedaf3f9bc064edb722c714b7c8c
Author: Dominique Dumont <dod at debian.org>
Date: Sun Dec 1 18:38:00 2013 +0100
refreshed add_or_later_clause patch
---
debian/patches/add_or_later_clause | 47 +++++++++++++++++++++++---------------
1 file changed, 28 insertions(+), 19 deletions(-)
diff --git a/debian/patches/add_or_later_clause b/debian/patches/add_or_later_clause
index be3356a..485a1ba 100644
--- a/debian/patches/add_or_later_clause
+++ b/debian/patches/add_or_later_clause
@@ -16,26 +16,35 @@ Description: add or_later license parameter
}
--- a/lib/Software/LicenseUtils.pm
+++ b/lib/Software/LicenseUtils.pm
-@@ -123,12 +123,19 @@
+@@ -137,6 +137,13 @@
+ 'Artistic' => 'Software::License::Artistic_1_0',
+ 'Artistic-1' => 'Software::License::Artistic_1_0',
+ 'Artistic-2' => 'Software::License::Artistic_2_0',
++ 'GPL-1+' => [ 'Software::License::GPL_1', or_later => 1 ],
++ 'GPL-2+' => [ 'Software::License::GPL_2', or_later => 1 ],
++ 'GPL-3+' => [ 'Software::License::GPL_3', or_later => 1 ],
++ 'LGPL-2+' => [ 'Software::License::LGPL_2', or_later => 1 ],
++ 'LGPL-2.1+' => [ 'Software::License::LGPL_2_1', or_later => 1 ],
++ 'LGPL-3+' => [ 'Software::License::LGPL_3_0', or_later => 1 ],
++ 'LGPL-3.0+' => [ 'Software::License::LGPL_3_0', or_later => 1 ],
+ );
- my %short_name = (
- 'GPL-1' => [ 'GPL_1' ],
-+ 'GPL-1+' => [ 'GPL_1', or_later => 1 ],
- 'GPL-2' => [ 'GPL_2' ],
-+ 'GPL-2+' => [ 'GPL_2', or_later => 1 ],
- 'GPL-3' => [ 'GPL_3' ],
-+ 'GPL-3+' => [ 'GPL_3', or_later => 1 ],
- 'LGPL-2' => [ 'LGPL_2' ],
-+ 'LGPL-2+' => [ 'LGPL_2', or_later => 1 ],
- 'LGPL-2.1' => [ 'LGPL_2_1' ],
-+ 'LGPL-2.1+' => [ 'LGPL_2_1', or_later => 1 ],
- 'LGPL-3' => [ 'LGPL_3_0' ],
- 'LGPL-3.0' => [ 'LGPL_3_0' ],
-+ 'LGPL-3+' => [ 'LGPL_3_0', or_later => 1 ],
-+ 'LGPL-3.0+' => [ 'LGPL_3_0', or_later => 1 ],
- 'Artistic' => [ 'Artistic_1_0' ],
- 'Artistic-1' => [ 'Artistic_1_0' ],
- 'Artistic-2' => [ 'Artistic_2_0' ],
+
+@@ -149,10 +156,12 @@
+ Carp::croak "Unknow license with short name $short"
+ unless $short_name{$short};
+
+- my $lic_file = my $lic_class = $short_name{$short} ;
++ my $info = $short_name{$short} ;
++ my @infos = ref $info ? @$info : ($info);
++ my $lic_file = my $lic_class = shift @infos;
+ $lic_file =~ s!::!/!g;
+ require "$lic_file.pm";
+- return $lic_class->new( $arg );
++ return $lic_class->new( { %$arg, @infos } );
+ }
+
+ 1;
--- a/t/summary.t
+++ b/t/summary.t
@@ -2,7 +2,7 @@
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libsoftware-license-perl.git
More information about the Pkg-perl-cvs-commits
mailing list