summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2016-04-08 15:53:47 +0200
committerErich Eckner <git@eckner.net>2016-04-11 11:29:20 +0200
commitd42631ab885d479c03a62a7a797701a3f40801a9 (patch)
treec39996442ce3cce4c70edfc1417d83c42bdea879
parent0530fa5be488e872f66fc0660fc09e6964fdd5cd (diff)
downloadarchlinuxewe.git.save-d42631ab885d479c03a62a7a797701a3f40801a9.tar.xz
perl-pdl neu
-rw-r--r--perl-pdl/PKGBUILD50
-rw-r--r--perl-pdl/gsl_sf_ellint.pd.diff38
2 files changed, 88 insertions, 0 deletions
diff --git a/perl-pdl/PKGBUILD b/perl-pdl/PKGBUILD
new file mode 100644
index 00000000..9f19865e
--- /dev/null
+++ b/perl-pdl/PKGBUILD
@@ -0,0 +1,50 @@
+pkgname=perl-pdl
+_pkgname='PDL'
+pkgver=2.015
+pkgrel=1
+pkgdesc="the Perl Data Language"
+arch=('x86_64' 'i686')
+url="http://pdl.perl.org/"
+license=('GPL' 'PerlArtistic')
+depends=('perl-devel-checklib' 'perl-astro-fits-header'
+'perl-convert-uu' 'perl-file-map' 'perl-inline-c' 'perl-module-compile'
+'hdf4' 'perl-gd')
+makedepends=('perl-extutils-f77' 'perl-test-exception' 'perl-test-warn' 'perl-test-deep' 'perl-file-map')
+options=('!emptydirs')
+source=("http://search.cpan.org/CPAN/authors/id/C/CH/CHM/${_pkgname}-${pkgver}.tar.gz"
+ "gsl_sf_ellint.pd.diff")
+sha256sums=('0b7ef32e443e62c62569b8092f507f1a035d990430c80bdcb263dc7a2e85b684'
+ '54f2096547bf2518ad4f8390897c81cc8b904a407b5cd07c8f8387a8a6a4c3fb')
+
+prepare() {
+
+ cd ${srcdir}/${_pkgname}-${pkgver}/Lib/GSL/SF/ellint
+ patch -p0 < ${srcdir}/gsl_sf_ellint.pd.diff
+
+}
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ make test
+ )
+}
+
+package() {
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+ make pure_install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
diff --git a/perl-pdl/gsl_sf_ellint.pd.diff b/perl-pdl/gsl_sf_ellint.pd.diff
new file mode 100644
index 00000000..9203d9df
--- /dev/null
+++ b/perl-pdl/gsl_sf_ellint.pd.diff
@@ -0,0 +1,38 @@
+--- gsl_sf_ellint.pd_orig 2015-11-15 10:46:20 +1100
++++ gsl_sf_ellint.pd 2015-11-15 10:54:47 +1100
+@@ -82,6 +82,10 @@
+ Doc =>'Legendre form of incomplete elliptic integrals P(phi,k,n) = Integral[(1 + n Sin[t]^2)^(-1)/Sqrt[1 - k^2 Sin[t]^2], {t, 0, phi}]'
+ );
+
++my $v = `gsl-config --version`;
++
++if($v < 2.0) {
++
+ pp_def('gsl_sf_ellint_D',
+ GenericTypes => [D],
+ Pars=>'double phi(); double k(); double n();
+@@ -95,6 +99,24 @@
+ Doc =>'Legendre form of incomplete elliptic integrals D(phi,k,n)'
+ );
+
++}
++else {
++
++pp_def('gsl_sf_ellint_D',
++ GenericTypes => [D],
++ Pars=>'double phi(); double k();
++ double [o]y(); double [o]e()',
++ Code =>'
++gsl_sf_result r;
++GSLERR(gsl_sf_ellint_D_e,($phi(),$k(),GSL_PREC_DOUBLE,&r))
++$y() = r.val;
++$e() = r.err;
++',
++ Doc =>'Legendre form of incomplete elliptic integrals D(phi,k)'
++ );
++
++}
++
+ pp_def('gsl_sf_ellint_RC',
+ GenericTypes => [D],
+ Pars=>'double x(); double yy(); double [o]y(); double [o]e()',