summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Paul Pelteret <jppelteret@gmail.com>2020-10-15 16:03:12 +0200
committerGitHub <noreply@github.com>2020-10-15 16:03:12 +0200
commitc1f2d6a73b2ddb6520e2bfc46d232c4467a8c82f (patch)
tree3260b3195d5e1c85f69f0b96027d57c7ae66b51c
parentd034d622c015cf857f74b55d3f2aebacba269d1f (diff)
downloadspack-c1f2d6a73b2ddb6520e2bfc46d232c4467a8c82f.tar.gz
spack-c1f2d6a73b2ddb6520e2bfc46d232c4467a8c82f.tar.bz2
spack-c1f2d6a73b2ddb6520e2bfc46d232c4467a8c82f.tar.xz
spack-c1f2d6a73b2ddb6520e2bfc46d232c4467a8c82f.zip
GiNaC: added new package at v1.7.11, updated cln (#15730)
-rw-r--r--var/spack/repos/builtin/packages/cln/package.py52
-rw-r--r--var/spack/repos/builtin/packages/ginac/package.py31
2 files changed, 82 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/cln/package.py b/var/spack/repos/builtin/packages/cln/package.py
index e6374ecaf5..4d1e731080 100644
--- a/var/spack/repos/builtin/packages/cln/package.py
+++ b/var/spack/repos/builtin/packages/cln/package.py
@@ -6,6 +6,8 @@
from spack import *
+import os
+
class Cln(AutotoolsPackage):
"""CLN is a library for efficient computations with all kinds of numbers
@@ -14,8 +16,10 @@ class Cln(AutotoolsPackage):
more."""
homepage = "https://www.ginac.de/CLN/"
- git = "git://www.ginac.de/cln.git"
+ url = "https://www.ginac.de/CLN/cln-1.3.6.tar.bz2"
+ git = "git://www.ginac.de/cln.git"
+ version('master', branch='master')
version('1.3.6', commit='d4ba1cc869be2c647c4ab48ac571b1fc9c2021a9')
version('1.3.5', commit='b221c033c082b462455502b7e63702a9c466aede')
version('1.3.4', commit='9b86a7fc69feb1b288469982001af565f73057eb')
@@ -27,7 +31,53 @@ class Cln(AutotoolsPackage):
version('1.2.1', commit='567378ab4cbfd443c3d82d810599860c769251fe')
version('1.2.0', commit='679a0a8927f011fb32411f8a31070c77a9901094')
+ variant('gmp', default=True, description='Enable GMP multiprecision library')
+
depends_on('autoconf', type='build')
depends_on('automake', type='build')
depends_on('libtool', type='build')
depends_on('m4', type='build')
+ depends_on('gmp@4.1:', when='+gmp')
+
+ # Dependencies required to define macro AC_LIB_LINKFLAGS_FROM_LIBS
+ depends_on('gettext', type='build')
+
+ def autoreconf(self, spec, prefix):
+ autoreconf_args = ['-i']
+
+ aclocal_pkg_list = ['gettext']
+ aclocal_path = os.path.join('share', 'aclocal')
+
+ for pkg in aclocal_pkg_list:
+ autoreconf_args += ['-I',
+ os.path.join(spec[pkg].prefix, aclocal_path)]
+
+ autoreconf = which('autoreconf')
+ autoreconf(*autoreconf_args)
+
+ @run_before('autoreconf')
+ def force_config_rpath(self):
+ source_directory = self.stage.source_path
+ build_aux_directory = os.path.join(source_directory, 'build-aux')
+
+ mkdir = which('mkdir')
+ mkdir(build_aux_directory)
+
+ touch = which('touch')
+ touch(os.path.join(build_aux_directory, 'config.rpath'))
+
+ def configure_args(self):
+ spec = self.spec
+
+ configure_args = []
+
+ if '+gmp' in spec:
+ configure_args.append(
+ '--with-gmp={0}'.format(spec['gmp'].prefix)
+ )
+ else:
+ configure_args.append(
+ '--without-gmp'
+ )
+
+ return configure_args
diff --git a/var/spack/repos/builtin/packages/ginac/package.py b/var/spack/repos/builtin/packages/ginac/package.py
new file mode 100644
index 0000000000..71c0c1a2ee
--- /dev/null
+++ b/var/spack/repos/builtin/packages/ginac/package.py
@@ -0,0 +1,31 @@
+# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack import *
+
+
+class Ginac(CMakePackage):
+ """GiNaC is a C++ library. It is designed to allow the creation of
+ integrated systems that embed symbolic manipulations together with more
+ established areas of computer science (like computation-intense numeric
+ applications, graphical interfaces, etc.) under one roof."""
+
+ homepage = "https://www.ginac.de/"
+ url = "https://www.ginac.de/ginac-1.7.8.tar.bz2"
+ git = "git://www.ginac.de/ginac.git"
+
+ version('1.7.11', sha256='96529ddef6ae9788aca0093f4b85fc4e34318bc6704e628e6423ab5a92dfe929')
+ version('1.7.9', sha256='67cdff43a4360da997ee5323cce27cf313a5b17ba58f02e8f886138c0f629821')
+ version('1.7.8', sha256='0c86501aa6c72efd5937fce42c5e983fc9f05dadb65b4ebdb51ee95c9f6a7067')
+
+ variant('ginsh', default=True, description='Build ginsh, the GiNaC interactive shell')
+
+ depends_on('cmake@2.8:', type='build')
+
+ depends_on('cln')
+ depends_on('python@3:', type=('build', 'run'))
+ depends_on('bison@2.3:', type=('build'), when='+ginsh')
+ depends_on('flex@2.5.33:', type=('build'), when='+ginsh')
+ depends_on('readline@4.3:', type=('link'), when='+ginsh')