1 # PKGBUILD generated by pacpan
2 pkgname=perl-math-matrix
6 pkgdesc="Multiply and invert Matrices in Perl"
9 url="http://search.cpan.org/~ulpfr/Math-Matrix-0.5/Matrix.pm"
14 provides=('math-matrix=0.5' 'Math::Matrix=0.5' 'perl-math-matrix=0.5')
16 source=(http://search.cpan.org/CPAN/authors/id/U/UL/ULPFR/Math-Matrix-0.5.tar.gz)
19 _expected_dir="${srcdir}/${_realname}-${pkgver}"
20 if [ -d "$_expected_dir" ]; then
23 _expected_dir="${srcdir}/$(bsdtar -t -f $(basename $source) | head -n1)"
24 if [ -d "$_expected_dir" ]; then
27 _makefile=$(find $srcdir -iname Makefile.PL)
28 if [ ! -z "$_makefile" ]; then
29 _expected_dir=$(dirname $_makefile)
30 if [ -d "$_expected_dir" ]; then
33 echo "
\e[1;31mERROR
\e[0m unable to detect source directory"
34 echo "
\e[1;34m-->
\e[0m this is often due to CPAN's lack of standard naming conventions"
35 echo "
\e[1;34m-->
\e[0m it may be possible to fix this by adjusting the build function in the PKGBUILD"
40 # install module in vendor directories.
41 PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor || return 1
43 make install DESTDIR=${pkgdir} || return 1
45 # remove perllocal.pod and .packlist
46 find ${pkgdir} -name perllocal.pod -delete
47 find ${pkgdir} -name .packlist -delete
49 md5sums=('840a9ef812ad12bd1798752f1e90cf41')