diff options
author | yar | 2017-04-12 12:06:31 -0700 |
---|---|---|
committer | yar | 2017-04-12 12:06:31 -0700 |
commit | 5371326b29d541ce677753df8be2d2b75b89e4ad (patch) | |
tree | 40b6529d66327060791ad27ff31212e7a513d44a | |
parent | d373e0db4085de26f67b0696c54340c73d71ac10 (diff) | |
download | aur-5371326b29d541ce677753df8be2d2b75b89e4ad.tar.gz |
use vars for cpan links
don't hardcode this shit. what even are variables?
-rw-r--r-- | PKGBUILD | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -1,7 +1,9 @@ # Contributor: Anonymous # Generator : CPANPLUS::Dist::Arch 1.25 -pkgname='perl-regexp-reggrp' +cpaname=Regexp-RegGrp +cpanauthor=NEVESENIN +pkgname=perl-regexp-reggrp pkgver='1.002001' pkgrel='1' pkgdesc="Groups a regular expressions collection" @@ -10,11 +12,10 @@ license=('PerlArtistic' 'GPL') options=('!emptydirs') depends=('perl>=5.8.9') makedepends=('perl-extutils-makemaker>=6.6302') -url='http://search.cpan.org/dist/Regexp-RegGrp' -source=('http://search.cpan.org/CPAN/authors/id/N/NE/NEVESENIN/Regexp-RegGrp-1.002001.tar.gz') +url='http://search.cpan.org/dist/${cpaname}' +source=("http://search.cpan.org/CPAN/authors/id/${cpanauthor::1}/${cpanauthor::2}/${cpanauthor}/${cpaname}-${pkgver}.tar.gz") md5sums=('796ff413bc7563b7185e6a185a00afef') sha512sums=('0525e02b686616bc073de784df1e5b792c09ec033db2fe322308d40352a3a9ebd4bdafc270b4253fa29bd90cd78312bb9831aef96f55298005b7f1d1b1299ee6') -_distdir="Regexp-RegGrp-1.002001" build() { ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \ @@ -23,21 +24,21 @@ build() { PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \ MODULEBUILDRC=/dev/null - cd "$srcdir/$_distdir" + cd "${srcdir}/${cpaname}-${pkgver}" /usr/bin/perl Makefile.PL make ) } check() { - cd "$srcdir/$_distdir" + cd "${srcdir}/${cpaname}-${pkgver}" ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" make test ) } package() { - cd "$srcdir/$_distdir" + cd "${srcdir}/${cpaname}-${pkgver}" make install find "$pkgdir" -name .packlist -o -name perllocal.pod -delete } |