diff options
author | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:36 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:47 +0000 |
commit | 36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2 (patch) | |
tree | b3faaf573407b32aa645237a4d16b82778a39a92 /nixpkgs/pkgs/applications/science/math/pari/default.nix | |
parent | 4e31070265257dc67d120c27e0f75c2344fdfa9a (diff) | |
parent | abf060725d7614bd3b9f96764262dfbc2f9c2199 (diff) | |
download | nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.gz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.bz2 nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.lz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.xz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.zst nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.zip |
Add 'nixpkgs/' from commit 'abf060725d7614bd3b9f96764262dfbc2f9c2199'
git-subtree-dir: nixpkgs git-subtree-mainline: 4e31070265257dc67d120c27e0f75c2344fdfa9a git-subtree-split: abf060725d7614bd3b9f96764262dfbc2f9c2199
Diffstat (limited to 'nixpkgs/pkgs/applications/science/math/pari/default.nix')
-rw-r--r-- | nixpkgs/pkgs/applications/science/math/pari/default.nix | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/applications/science/math/pari/default.nix b/nixpkgs/pkgs/applications/science/math/pari/default.nix new file mode 100644 index 000000000000..32e4d81acec0 --- /dev/null +++ b/nixpkgs/pkgs/applications/science/math/pari/default.nix @@ -0,0 +1,77 @@ +{ stdenv, fetchurl +, gmp, readline, libX11, tex, perl +, withThread ? true, libpthreadstubs +}: + +assert withThread -> libpthreadstubs != null; + +stdenv.mkDerivation rec { + + name = "pari-${version}"; + version = "2.11.1"; + + src = fetchurl { + url = "https://pari.math.u-bordeaux.fr/pub/pari/unix/${name}.tar.gz"; + sha256 = "1jfax92jpydjd02fwl30r6b8kfzqqd6sm4yx94gidyz9lqjb7a94"; + }; + + buildInputs = [ + gmp + readline + libX11 + tex + perl + ] ++ stdenv.lib.optionals withThread [ + libpthreadstubs + ]; + + configureScript = "./Configure"; + configureFlags = [ + "--with-gmp=${gmp.dev}" + "--with-readline=${readline.dev}" + ] ++ stdenv.lib.optional stdenv.isDarwin "--host=x86_64-darwin" + ++ stdenv.lib.optional withThread "--mt=pthread"; + + preConfigure = '' + export LD=$CC + ''; + + postConfigure = stdenv.lib.optionalString stdenv.isDarwin '' + echo 'echo x86_64-darwin' > config/arch-osname + ''; + + makeFlags = [ "all" ]; + + meta = with stdenv.lib; { + description = "Computer algebra system for high-performance number theory computations"; + longDescription = '' + PARI/GP is a widely used computer algebra system designed for fast + computations in number theory (factorizations, algebraic number theory, + elliptic curves...), but also contains a large number of other useful + functions to compute with mathematical entities such as matrices, + polynomials, power series, algebraic numbers etc., and a lot of + transcendental functions. PARI is also available as a C library to allow + for faster computations. + + Originally developed by Henri Cohen and his co-workers (Université + Bordeaux I, France), PARI is now under the GPL and maintained by Karim + Belabas with the help of many volunteer contributors. + + - PARI is a C library, allowing fast computations. + - gp is an easy-to-use interactive shell giving access to the + PARI functions. + - GP is the name of gp's scripting language. + - gp2c, the GP-to-C compiler, combines the best of both worlds + by compiling GP scripts to the C language and transparently loading + the resulting functions into gp. (gp2c-compiled scripts will typically + run 3 or 4 times faster.) gp2c currently only understands a subset + of the GP language. + ''; + homepage = http://pari.math.u-bordeaux.fr; + downloadPage = http://pari.math.u-bordeaux.fr/download.html; + license = licenses.gpl2Plus; + maintainers = with maintainers; [ ertes raskin AndersonTorres ]; + platforms = platforms.linux ++ platforms.darwin; + updateWalker = true; + }; +} |