[aur-general] Perl PKGBUILD review

Andrew Crerar andrew at crerar.io
Sat Dec 2 21:23:22 UTC 2017


Hi François!

Would it be possible for you to upload the PKGBUILD to a pastebin service (e.g. 
https://ptpb.pw/) and provide the link? Or better yet, does your package [1] 
have the latest changes? It looks like it does. Asking because the formatting 
was destroyed in your email.

Regards,

Andrew

[1] https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=pgbadger


On 12/2/17 4:02 PM, François Freitag wrote:
> Hi all,
> 
> I'm new to Perl packaging. I wrote my first PKGBUILD [1] following the
> wiki [2].
> I would be very grateful if somebody could give it a read and suggest
> improvements? namcap does not emit any warning.
> 
> |# Maintainer: François Freitag <mail at franek dot fr> # Contributor:
> Victor van den Elzen <victor.vde at gmail dot com> pkgname=pgbadger
> pkgver=9.2 pkgrel=4 pkgdesc="A fast PostgreSQL Log Analyzer"
> arch=("any") url="https://github.com/dalibo/pgbadger"
> license=("custom:Dalibo") depends=('perl>=5.10.0') optdepends=(
> "perl-text-csv-xs: parse PostgreSQL CSV log files" "perl-json-xs: export
> statistics as JSON file" ) options=('!emptydirs')
> source=("https://github.com/dalibo/pgbadger/archive/v${pkgver}.tar.gz")
> sha256sums=('2107466309a409fb9e40f11bb77cac1f9ba7910d5328e7b2e08eb7a1c6d760ec')
> prepare() { # Override perl command line options we don't want. Source:
> # https://wiki.archlinux.org/index.php/Perl_Policy#Vendor export
> PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps \
> PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
> PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \ PERL5LIB=""
> PERL_LOCAL_LIB_ROOT="" \ MODULEBUILDRC=/dev/null } build() { cd
> "${srcdir}/pgbadger-${pkgver}" /usr/bin/perl Makefile.PL make }
> package() { cd "${srcdir}/pgbadger-${pkgver}" install -Dm644 LICENSE -t
> "${pkgdir}/usr/share/licenses/${pkgname}" make pure_vendor_install
> INSTALLDIRS=vendor DESTDIR="${pkgdir}" # Remove perllocal.pod and
> .packlist find "${pkgdir}" \( -name .packlist -o -name perllocal.pod \)
> -delete } |
> 
> 
> Thank you for your time,
> François
> 
> [1] https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=pgbadger
> [2] https://wiki.archlinux.org/index.php/Perl_Policy#Vendor
> 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.archlinux.org/pipermail/aur-general/attachments/20171202/2f05515d/attachment.asc>


More information about the aur-general mailing list