Commit 29bf8029 authored by Timothy Legge's avatar Timothy Legge Committed by Natanael Copa

apkbuild-cpan.in: Update licenses to spdx format and remove redundant directory change

parent 77746a0c
...@@ -14,8 +14,9 @@ use Module::CoreList; ...@@ -14,8 +14,9 @@ use Module::CoreList;
use JSON; use JSON;
my $license_mappings = { my $license_mappings = {
"perl_5" => "GPL PerlArtistic", "perl_5" => "GPL-1.0-or-later Artistic-1.0-Perl",
"artistic_2" => "Artistic-2", "artistic_2" => "Artistic-2.0",
"gpl_3" => "GPL-3.0-only",
}; };
my $package_mappings = { my $package_mappings = {
...@@ -33,7 +34,7 @@ pkgrel=0 ...@@ -33,7 +34,7 @@ pkgrel=0
pkgdesc="Perl module for [% pkgreal %]" pkgdesc="Perl module for [% pkgreal %]"
url="https://metacpan.org/release/[% pkgreal %]/" url="https://metacpan.org/release/[% pkgreal %]/"
arch="noarch" arch="noarch"
license="GPL PerlArtistic" license="GPL-1.0-or-later Artistic-1.0-Perl"
cpandepends="" cpandepends=""
cpanmakedepends="" cpanmakedepends=""
cpancheckdepends="" cpancheckdepends=""
...@@ -173,7 +174,6 @@ sub update_functions { ...@@ -173,7 +174,6 @@ sub update_functions {
if (-e "$metaprefix/Build.PL" ) { if (-e "$metaprefix/Build.PL" ) {
$build_func = <<'EOF'; $build_func = <<'EOF';
build() { build() {
cd "$builddir"
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}') export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
perl Build.PL installdirs=vendor perl Build.PL installdirs=vendor
./Build ./Build
...@@ -181,21 +181,18 @@ build() { ...@@ -181,21 +181,18 @@ build() {
EOF EOF
$package_func = <<'EOF'; $package_func = <<'EOF';
package() { package() {
cd "$builddir"
./Build install destdir="$pkgdir" ./Build install destdir="$pkgdir"
find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete
} }
EOF EOF
$check_func = <<'EOF'; $check_func = <<'EOF';
check() { check() {
cd "$builddir"
./Build test ./Build test
} }
EOF EOF
} else { } else {
$build_func = <<'EOF'; $build_func = <<'EOF';
build() { build() {
cd "$builddir"
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}') export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
PERL_MM_USE_DEFAULT=1 perl -I. Makefile.PL INSTALLDIRS=vendor PERL_MM_USE_DEFAULT=1 perl -I. Makefile.PL INSTALLDIRS=vendor
make make
...@@ -203,14 +200,12 @@ build() { ...@@ -203,14 +200,12 @@ build() {
EOF EOF
$package_func = <<'EOF'; $package_func = <<'EOF';
package() { package() {
cd "$builddir"
make DESTDIR="$pkgdir" install make DESTDIR="$pkgdir" install
find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete
} }
EOF EOF
$check_func = <<'EOF'; $check_func = <<'EOF';
check() { check() {
cd "$builddir"
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}') export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
make test make test
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment