summaryrefslogtreecommitdiff
path: root/system/perl-lwp-mediatypes/APKBUILD
blob: b1042949d2fa893899061ab0e93712806edb3d1c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Adélie Perl Team <adelie-perl@lists.adelielinux.org>
pkgname=perl-lwp-mediatypes
_realname=LWP-MediaTypes
_author1=O
_author2=${_author1}A
_author=${_author2}LDERS
pkgver=6.04
pkgrel=0
pkgdesc="Perl module - guess media type for a file or a URL"
url="https://metacpan.org/release/LWP-MediaTypes"
arch="noarch"
license="GPL-2.0-only OR Artistic-1.0-Perl"
depends="perl"
makedepends="perl-dev"
checkdepends="perl-test-fatal"
install=
replaces="perl-libwww"
subpackages="$pkgname-doc"
source="https://search.cpan.org/CPAN/authors/id/$_author1/$_author2/$_author/$_realname-$pkgver.tar.gz"
builddir="$srcdir/$_realname-$pkgver"

build() {
	cd "$builddir"
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
	make
}

check() {
	cd "$builddir"
	make test
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
	# creates file collision among perl modules
	find "$pkgdir" -name perllocal.pod -delete
}

sha512sums="0610627ef3efdfde3c89bad273931c9cbde5c6da0bd782d59ce26dc4445cd538be9041d722f08206d96d69d5e3643b15150ef29b9e92e3968833f2ae1b6dc53f  LWP-MediaTypes-6.04.tar.gz"