Skip to content

Commit

Permalink
🚿 CHORE: Begin tidying PKGBUILD etc
Browse files Browse the repository at this point in the history
On branch master
- Changes to be committed:
  - new file:   .SRCINFO
  - modified:   PKGBUILD
  • Loading branch information
rossclarkartist committed Jun 10, 2022
1 parent ee76f61 commit d14a09f
Show file tree
Hide file tree
Showing 2 changed files with 59 additions and 12 deletions.
22 changes: 22 additions & 0 deletions .SRCINFO
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
pkgbase = perl-net-freedb
pkgdesc = Net::FreeDB is an oo-based module to interface with FreeDB servers
pkgver = 0.10
pkgrel = 2
url = https://metacpan.org/release/Net-FreeDB
arch = any
license = GPL
license = PerlArtistic
depends = perl
depends = perl-http-message
depends = perl-io-socket-inet6
depends = perl-libwww
depends = perl-mailtools
depends = perl-moo
depends = perl-test-most
depends = perl-cddb-file
options = !emptydirs
options = purge
source = https://cpan.metacpan.org/authors/id/D/DS/DSHULTZ/Net-FreeDB-0.10.tar.gz
sha512sums = b1b249dfb81128645e6e3481f93d914fc11ecf931b91f6a21a065fa2fde8674f9c8b5466b3112be4f4f28556c0ec899cf8723e60adaaf26b5165e61d61445368

pkgname = perl-net-freedb
49 changes: 37 additions & 12 deletions PKGBUILD
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash

# Based on the original PKGBUILD by outopos <spaceflorent at aol.com>

# Disable various shellcheck rules that produce false positives in this file.
# Repository rules should be added to the .shellcheckrc file located in the
# repository root directory, see https://github.com/koalaman/shellcheck/wiki
Expand All @@ -12,14 +14,20 @@
# Maintainer: Ross Clark <archiv8@artisteducator.com>
# Contributor: Ross Clark <archiv8@artisteducator.com>

pkgname=perl-net-freedb
_relname="Net-FreeDB"

pkgname="perl-net-freedb"
pkgver=0.10
pkgrel=1
pkgrel=2
pkgdesc="Net::FreeDB is an oo-based module to interface with FreeDB servers"
_dist=Net-FreeDB
arch=("any")
arch=(
"any"
)
url="https://metacpan.org/release/Net-FreeDB"
license=("GPL" "PerlArtistic")
license=(
"GPL"
"PerlArtistic"
)
depends=(
# Arch Linux official packages
"perl"
Expand All @@ -33,29 +41,46 @@ depends=(
# Archiv8 / AUR packages
"perl-cddb-file"
)
options=("!emptydirs" purge)
options=(
"!emptydirs" purge
)
_tarname="${_relname}-${pkgver}"
source=(
"https://cpan.metacpan.org/authors/id/D/DS/DSHULTZ/$_dist-$pkgver.tar.gz"
"https://cpan.metacpan.org/authors/id/D/DS/DSHULTZ/${_tarname}.tar.gz"
)
sha512sums=(
"b1b249dfb81128645e6e3481f93d914fc11ecf931b91f6a21a065fa2fde8674f9c8b5466b3112be4f4f28556c0ec899cf8723e60adaaf26b5165e61d61445368"
)
sha512sums=("b1b249dfb81128645e6e3481f93d914fc11ecf931b91f6a21a065fa2fde8674f9c8b5466b3112be4f4f28556c0ec899cf8723e60adaaf26b5165e61d61445368")

build() {
cd "$srcdir/$_dist-$pkgver"

cd "${srcdir}/${_tarname}"

unset PERL5LIB PERL_MM_OPT PERL_LOCAL_LIB_ROOT

export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps

/usr/bin/perl Makefile.PL

make
}

check() {
cd "$srcdir/$_dist-$pkgver"

cd "${srcdir}/${_tarname}"

unset PERL5LIB PERL_MM_OPT PERL_LOCAL_LIB_ROOT

export PERL_MM_USE_DEFAULT=1

make test
}

package() {
cd "$srcdir/$_dist-$pkgver"

cd "${srcdir}/${_tarname}"

unset PERL5LIB PERL_MM_OPT PERL_LOCAL_LIB_ROOT
make install INSTALLDIRS=vendor DESTDIR="$pkgdir"

make install INSTALLDIRS=vendor DESTDIR="${pkgdir}"
}

0 comments on commit d14a09f

Please sign in to comment.