mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-12 01:24:37 +08:00
48 lines
1.2 KiB
Bash
48 lines
1.2 KiB
Bash
# $Id$
|
|
# Maintainer: Antonio Rojas <arojas@archlinux.org>
|
|
|
|
pkgname=sympow
|
|
pkgver=1.018.1
|
|
pkgrel=2
|
|
pkgdesc="A a package to compute special values of symmetric power elliptic
|
|
curve L-functions"
|
|
arch=('i686' 'x86_64')
|
|
url="http://www.sagemath.org"
|
|
license=('GPL')
|
|
depends=('glibc')
|
|
makedepends=('pari')
|
|
source=("http://www.sagemath.org/packages/upstream/$pkgname/$pkgname-$pkgver.tar.bz2")
|
|
md5sums=('b6cbb7488870d70d92d11176049cb91b')
|
|
|
|
prepare() {
|
|
cd $pkgname-$pkgver
|
|
|
|
# fix segfault
|
|
sed -e 's|"datafiles/param_data"|"/usr/lib/sympow/datafiles/param_data"|' -i disk.c -i generate.c
|
|
sed -e 's|"datafiles/P"; int dl=9;|"/usr/lib/sympow/datafiles/P"; int dl=25;|' \
|
|
-e 's|"datafiles/H"; int dl=9;|"/usr/lib/sympow/datafiles/H"; int dl=25;|' -i disk.c
|
|
}
|
|
|
|
build() {
|
|
cd $pkgname-$pkgver
|
|
|
|
./Configure
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd $pkgname-$pkgver
|
|
|
|
mkdir -p "$pkgdir"/usr/lib/sympow
|
|
mv sympow *.gp new_data datafiles "$pkgdir"/usr/lib/sympow
|
|
|
|
cd "$pkgdir"/usr/lib/sympow/datafiles
|
|
|
|
for file in *.txt; do
|
|
../sympow -txt2bin "$(grep -c AT $file)" <$file ${file/txt/bin}
|
|
done
|
|
|
|
mkdir -p "$pkgdir"/usr/bin
|
|
ln -s /usr/lib/sympow/sympow "$pkgdir"/usr/bin/sympow
|
|
}
|