repo_name
stringlengths 6
97
| path
stringlengths 3
341
| text
stringlengths 8
1.02M
|
|---|---|---|
player1537-forks/spack
|
var/spack/repos/builtin/packages/eagle/package.py
|
<filename>var/spack/repos/builtin/packages/eagle/package.py
# Copyright 2013-2022 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 Eagle(MakefilePackage):
"""EAGLE: Explicit Alternative Genome Likelihood Evaluator"""
homepage = "https://github.com/tony-kuo/eagle"
url = "https://github.com/tony-kuo/eagle/archive/v1.1.2.tar.gz"
version('1.1.2', sha256='afe967560d1f8fdbd0caf4b93b5f2a86830e9e4d399fee4a526140431343045e')
depends_on('curl')
depends_on('zlib')
depends_on('lzma')
depends_on('htslib')
def edit(self, spec, prefix):
# remove unused gcc flags
filter_file('$(LFLAGS) $(INCLUDES)', '', 'Makefile', string=True)
# drop static link to htslib
filter_file('$(LIBS)', '', 'Makefile', string=True)
# don't try to build htslib.
filter_file('all: UTIL HTSLIB', 'all: UTIL',
'Makefile', string=True)
# add htslib link to ldflags
filter_file('-lcurl', '-lcurl -lhts', 'Makefile', string=True)
# use spack C compiler
filter_file('CC=.*', 'CC={0}'.format(spack_cc), 'Makefile')
# remove march=native %fj
if self.spec.satisfies('%fj'):
filter_file('-march=native', '', 'Makefile', string=True)
def install(self, spec, prefix):
mkdirp(prefix.bin)
bins = [
'eagle',
'eagle-rc',
'eagle-nm',
]
for b in bins:
install(b, prefix.bin)
|
player1537-forks/spack
|
var/spack/repos/builtin.mock/packages/both-link-and-build-dep-a/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 BothLinkAndBuildDepA(Package):
"""
Structure where c occurs as a build dep down the line and as a direct
link dep. Useful for testing situations where you copy the parent spec
just with link deps, and you want to make sure b is not part of that.
a <--build-- b <-link-- c
a <--link--- c
"""
homepage = "http://www.example.com"
url = "http://www.example.com/1.0.tar.gz"
version('1.0', '0123456789abcdef0123456789abcdef')
depends_on('both-link-and-build-dep-b', type='build')
depends_on('both-link-and-build-dep-c', type='link')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/xhmm/package.py
|
<filename>var/spack/repos/builtin/packages/xhmm/package.py<gh_stars>10-100
# Copyright 2013-2022 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 Xhmm(MakefilePackage):
"""The XHMM C++ software suite was written to
call copy number variation (CNV) from next-generation
sequencing projects, where exome capture was used
(or targeted sequencing, more generally)."""
homepage = "http://atgu.mgh.harvard.edu/xhmm/index.shtml"
git = "https://bitbucket.org/statgen/xhmm.git"
version('20160104', commit='<PASSWORD>')
depends_on('lapack')
def edit(self, spec, prefix):
filter_file('GCC', 'CC', 'sources/hmm++/config_rules.Makefile')
filter_file('GCC =gcc', '', 'sources/hmm++/config_defs.Makefile')
def build(self, spec, prefix):
make('LAPACK_LIBS=%s' % ''.join(spec['lapack'].libs.names))
def install(self, spec, prefix):
mkdir(prefix.bin)
install('xhmm', prefix.bin)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/op2-dsl/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2021 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 Op2Dsl(MakefilePackage, CudaPackage):
"""OP2 is a high-level embedded domain specific language for writing
unstructured mesh algorithms with automatic parallelisation on multi-core
and many-core architectures."""
homepage = "https://op-dsl.github.io/"
git = "https://github.com/OP-DSL/OP2-Common.git"
maintainers = ['gihanmudalige', 'reguly', 'bozbez']
version('master', branch='master')
version('1.1.0', tag='v1.1.0')
build_directory = 'op2'
variant('mpi', default=False, description='Enable MPI support')
variant('parmetis', default=True, when='+mpi',
description='Enable ParMETIS partitioning support')
variant('scotch', default=True, when='+mpi',
description='Enable PT-Scotch partitioning support')
depends_on('mpi', when='+mpi')
depends_on('parmetis', when='+parmetis')
depends_on('scotch', when='+scotch')
depends_on('hdf5+fortran+mpi', when='+mpi')
depends_on('hdf5+fortran~mpi', when='~mpi')
def edit(self, spec, prefix):
compiler_map = {
'gcc': 'gnu',
'cce': 'cray',
'intel': 'intel',
'nvhpc': 'nvhpc',
'xl': 'xl',
}
if self.spec.compiler.name in compiler_map:
env['OP2_COMPILER'] = compiler_map[self.spec.compiler.name]
if '+cuda' in self.spec and spec.variants['cuda_arch'].value[0] != 'none':
env['CUDA_GEN'] = ','.join(spec.variants['cuda_arch'].value)
def install(self, spec, prefix):
install_tree('op2/lib', prefix.lib)
install_tree('op2/include', prefix.include)
install_tree('op2/mod', prefix.mod)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-reproducible/package.py
|
# Copyright 2013-2022 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 RReproducible(RPackage):
"""A Set of Tools that Enhance Reproducibility Beyond Package Management.
Collection of high-level, machine- and OS-independent tools for making
deeply reproducible and reusable content in R. The two workhorse functions
are Cache and prepInputs; these allow for: nested caching, robust to
environments, and objects with environments (like functions); and data
retrieval and processing in continuous workflow environments. In all cases,
efforts are made to make the first and subsequent calls of functions have
the same result, but vastly faster at subsequent times by way of checksums
and digesting. Several features are still under active development,
including cloud storage of cached objects, allowing for sharing between
users. Several advanced options are available, see ?reproducibleOptions."""
cran = "reproducible"
maintainers = ['dorton21']
version('1.2.8', sha256='6f453016404f6a2a235cb4d951a29aa7394dc3bd0b9cfc338dc85fb3d5045dd5')
version('1.2.4', sha256='0525deefa6a0713c3fe2da8bfc529f62d6352bebf2ef08866503b4853412f149')
depends_on('r@3.5:', type=('build', 'run'))
depends_on('r@3.6:', type=('build', 'run'), when='@1.2.8:')
depends_on('r-data-table@1.10.4:', type=('build', 'run'))
depends_on('r-dbi', type=('build', 'run'))
depends_on('r-digest', type=('build', 'run'))
depends_on('r-fpcompare', type=('build', 'run'))
depends_on('r-gdalutilities', type=('build', 'run'), when='@1.2.8:')
depends_on('r-glue', type=('build', 'run'))
depends_on('r-magrittr', type=('build', 'run'))
depends_on('r-require', type=('build', 'run'))
depends_on('r-raster', type=('build', 'run'))
depends_on('r-rsqlite', type=('build', 'run'))
depends_on('r-rlang', type=('build', 'run'))
depends_on('r-sp@1.4-2:', type=('build', 'run'))
depends_on('unrar', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-tensor/package.py
|
# Copyright 2013-2022 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 RTensor(RPackage):
"""Tensor product of arrays.
The tensor product of two arrays is notionally an outer product of the
arrays collapsed in specific extents by summing along the appropriate
diagonals."""
cran = "tensor"
version('1.5', sha256='e1dec23e3913a82e2c79e76313911db9050fb82711a0da227f94fc6df2d3aea6')
version('1.4', sha256='6f1643da018d58a0aaa27260df6fdf687fc36f4cd1964931b3180b7df8c0e642')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/lwm2/package.py
|
# Copyright 2013-2022 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 Lwm2(AutotoolsPackage):
"""LWM2: Light Weight Measurement Module. This is a PMPI module
that can collect a number of time-sliced MPI and POSIX I/O
measurements from a program.
"""
homepage = "https://jay.grs.rwth-aachen.de/redmine/projects/lwm2"
hg = "https://jay.grs.rwth-aachen.de/hg/lwm2"
version('torus', revision='torus')
depends_on("papi")
depends_on("mpi")
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-leafpop/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 RLeafpop(RPackage):
"""Include Tables, Images and Graphs in Leaflet Pop-Ups.
Creates 'HTML' strings to embed tables, images or graphs in pop-ups of
interactive maps created with packages like 'leaflet' or 'mapview'. Handles
local images located on the file system or via remote URL. Handles graphs
created with 'lattice' or 'ggplot2' as well as interactive plots created
with 'htmlwidgets'."""
cran = "leafpop"
version('0.1.0', sha256='6e546886e1db4ad93a038de6d1e8331c0d686e96a0d3f0694e7575471f7d9db1')
version('0.0.6', sha256='3d9ca31d081ce8540a87790786840bde5f833543af608c53a26623c7874e722f')
depends_on('r-base64enc', type=('build', 'run'))
depends_on('r-brew', type=('build', 'run'))
depends_on('r-htmltools', type=('build', 'run'))
depends_on('r-htmlwidgets', type=('build', 'run'))
depends_on('r-sf', type=('build', 'run'))
depends_on('r-svglite', type=('build', 'run'))
depends_on('r-uuid', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/scorec-core/package.py
|
# Copyright 2013-2022 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 ScorecCore(CMakePackage):
"""The SCOREC Core is a set of C/C++ libraries for unstructured mesh
simulations on supercomputers.
"""
homepage = 'https://www.scorec.rpi.edu/'
git = 'https://github.com/SCOREC/core.git'
version('develop')
depends_on('mpi')
depends_on('zoltan')
depends_on('cmake@3.0:', type='build')
def cmake_args(self):
options = []
options.append('-DCMAKE_C_COMPILER=%s' % self.spec['mpi'].mpicc)
options.append('-DCMAKE_CXX_COMPILER=%s' % self.spec['mpi'].mpicxx)
options.append('-DENABLE_ZOLTAN=ON')
if self.compiler.name == 'xl':
options.append('-DSCOREC_EXTRA_CXX_FLAGS=%s' % '-qminimaltoc')
return options
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/cvs/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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)
import re
from spack import *
class Cvs(AutotoolsPackage, GNUMirrorPackage):
"""CVS a very traditional source control system"""
homepage = "https://www.nongnu.org/cvs/"
gnu_mirror_path = "non-gnu/cvs/source/feature/1.12.13/cvs-1.12.13.tar.bz2"
version('1.12.13', sha256='78853613b9a6873a30e1cc2417f738c330e75f887afdaf7b3d0800cb19ca515e')
# To avoid the problem: The use of %n in format strings in writable memory
# may crash the program on glibc2 systems from 2004-10-18 or newer.
patch('https://gentoofan.org/gentoo/poly-c_overlay/dev-vcs/cvs/files/cvs-1.12.13.1-fix-gnulib-SEGV-vasnprintf.patch',
sha256='e13db2acebad3ca5be5d8e0fa97f149b0f9661e4a9a731965c8226290c6413c0', when='@1.12.13')
tags = ['build-tools']
parallel = False
executables = [r'^cvs$']
@classmethod
def determine_version(cls, exe):
output = Executable(exe)('--version', output=str, error=str)
match = re.search(r'\(CVS\)\s+([\d\.]+)', output)
return match.group(1) if match else None
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/docbook-xsl/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 DocbookXsl(Package):
"""DocBook XSLT 1.0 Stylesheets."""
homepage = "https://github.com/docbook/xslt10-stylesheets"
url = "https://github.com/docbook/xslt10-stylesheets/releases/download/release%2F1.79.2/docbook-xsl-1.79.2.tar.bz2"
version('1.79.2', sha256='316524ea444e53208a2fb90eeb676af755da96e1417835ba5f5eb719c81fa371')
version('1.78.1', sha256='c98f7296ab5c8ccd2e0bc07634976a37f50847df2d8a59bdb1e157664700b467', url='https://sourceforge.net/projects/docbook/files/docbook-xsl/1.78.1/docbook-xsl-1.78.1.tar.bz2')
depends_on('docbook-xml')
depends_on('libxml2', type='build')
patch('docbook-xsl-1.79.2-stack_fix-1.patch', when='@1.79.2')
def install(self, spec, prefix):
install_tree('.', prefix)
@property
def catalog(self):
return join_path(self.prefix, 'catalog')
@run_after('install')
def config_docbook(self):
catalog = self.catalog
version = self.version
xml_xsd = join_path(prefix, 'slides', 'schema', 'xsd', 'xml.xsd')
xmlcatalog = which('xmlcatalog')
# create catalog
xmlcatalog('--noout', '--create', catalog)
xmlcatalog('--noout', '--add', 'system',
'https://www.w3.org/2001/xml.xsd', xml_xsd, catalog)
xmlcatalog('--noout', '--add', 'system',
'https://www.w3.org/2009/01/xml.xsd', xml_xsd, catalog)
xmlcatalog('--noout', '--add', 'uri',
'https://www.w3.org/2001/xml.xsd', xml_xsd, catalog)
xmlcatalog('--noout', '--add', 'uri',
'https://www.w3.org/2009/01/xml.xsd', xml_xsd, catalog)
docbook_urls = ['docbook.sourceforge.net', 'cdn.docbook.org']
docbook_rewrites = ['rewriteSystem', 'rewriteURI']
docbook_versions = ['current', version]
for docbook_url in docbook_urls:
for docbook_rewrite in docbook_rewrites:
for docbook_version in docbook_versions:
xmlcatalog('--noout', '--add', docbook_rewrite,
'http://{0}/release/xsl/{1}'.format(docbook_url,
docbook_version),
prefix, catalog)
def setup_run_environment(self, env):
catalog = self.catalog
env.prepend_path('XML_CATALOG_FILES', catalog, separator=' ')
def setup_dependent_build_environment(self, env, dependent_spec):
catalog = self.catalog
env.prepend_path("XML_CATALOG_FILES", catalog, separator=' ')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-rcppeigen/package.py
|
# Copyright 2013-2022 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 RRcppeigen(RPackage):
"""'Rcpp' Integration for the 'Eigen' Templated Linear Algebra Library.
R and 'Eigen' integration using 'Rcpp'. 'Eigen' is a C++ template library
for linear algebra: matrices, vectors, numerical solvers and related
algorithms. It supports dense and sparse matrices on integer, floating
point and complex numbers, decompositions of such matrices, and solutions
of linear systems. Its performance on many algorithms is comparable with
some of the best implementations based on 'Lapack' and level-3 'BLAS'. The
'RcppEigen' package includes the header files from the 'Eigen' C++ template
library (currently version 3.2.8). Thus users do not need to install
'Eigen' itself in order to use 'RcppEigen'. Since version 3.1.1, 'Eigen' is
licensed under the Mozilla Public License (version 2); earlier version were
licensed under the GNU LGPL version 3 or later. 'RcppEigen' (the 'Rcpp'
bindings/bridge to 'Eigen') is licensed under the GNU GPL version 2 or
later, as is the rest of 'Rcpp'."""
cran = "RcppEigen"
version('0.3.3.9.1', sha256='8a0486249b778a4275a1168fc89fc7fc49c2bb031cb14b50a50089acae7fe962')
version('0.3.3.5.0', sha256='e5c6af17770c5f57b7cf2fba04ad1a519901b446e8138bfff221952458207f05')
version('0.3.3.4.0', sha256='11020c567b299b1eac95e8a4d57abf0315931286907823dc7b66c44d0dd6dad4')
version('0.3.3.3.1', sha256='14fdd2cb764d0a822e11b8f09dcf1c3c8580d416f053404732064d8f2b176f24')
version('0.3.2.9.0', sha256='25affba9065e3c12d67b1934d1ce97a928a4011a7738f7b90f0e9830409ec93b')
version('0.3.2.8.1', sha256='ceccb8785531c5c23f9232b594e5372c214a114a08ec759115e946badd08d681')
depends_on('r-matrix@1.1-0:', type=('build', 'run'))
depends_on('r-rcpp@0.11.0:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/sniffles/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 Sniffles(CMakePackage):
"""Structural variation caller using third generation sequencing."""
homepage = "https://github.com/fritzsedlazeck/Sniffles/wiki"
url = "https://github.com/fritzsedlazeck/Sniffles/archive/v1.0.5.tar.gz"
version('1.0.7', sha256='03fa703873bdf9c32055c584448e1eece45f94b4bc68e60c9624cf3841e6d8a9')
version('1.0.5', sha256='386c6536bdaa4637579e235bac48444c08297337c490652d1e165accd34b258f')
depends_on('zlib', type='link')
depends_on('bamtools', type='link')
patch('unused_libs.patch')
def cmake_args(self):
i = self.spec['bamtools'].prefix.include.bamtools
return ['-DCMAKE_CXX_FLAGS=-I{0}'.format(i)]
# the build process doesn't actually install anything, do it by hand
def install(self, spec, prefix):
mkdir(prefix.bin)
src = "bin/sniffles-core-{0}".format(spec.version.dotted)
binaries = ['sniffles', 'sniffles-debug']
for b in binaries:
install(join_path(src, b), join_path(prefix.bin, b))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/psimd/package.py
|
# Copyright 2013-2022 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 Psimd(CMakePackage):
"""Portable 128-bit SIMD intrinsics."""
homepage = "https://github.com/Maratyszcza/psimd"
git = "https://github.com/Maratyszcza/psimd.git"
version('master', branch='master')
version('2020-05-17', commit='<PASSWORD>') # py-torch@1.6:1.9
version('2019-12-26', commit='<PASSWORD>') # py-torch@1.5
version('2018-09-06', commit='<PASSWORD>') # py-torch@1.0:1.4
version('2017-10-26', commit='<KEY>') # py-torch@0.4
depends_on('cmake@2.8.12:', type='build')
depends_on('ninja', type='build')
generator = 'Ninja'
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/libjpeg-turbo/package.py
|
<filename>var/spack/repos/builtin/packages/libjpeg-turbo/package.py
# Copyright 2013-2022 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 LibjpegTurbo(Package):
"""libjpeg-turbo is a fork of the original IJG libjpeg which uses SIMD to
accelerate baseline JPEG compression and decompression.
libjpeg is a library that implements JPEG image encoding, decoding and
transcoding.
"""
# https://github.com/libjpeg-turbo/libjpeg-turbo/blob/master/BUILDING.md
homepage = "https://libjpeg-turbo.org/"
url = "https://github.com/libjpeg-turbo/libjpeg-turbo/archive/2.0.3.tar.gz"
version('2.1.0', sha256='d6b7790927d658108dfd3bee2f0c66a2924c51ee7f9dc930f62c452f4a638c52')
version('2.0.6', sha256='005aee2fcdca252cee42271f7f90574dda64ca6505d9f8b86ae61abc2b426371')
version('2.0.5', sha256='b3090cd37b5a8b3e4dbd30a1311b3989a894e5d3c668f14cbc6739d77c9402b7')
version('2.0.4', sha256='7777c3c19762940cff42b3ba4d7cd5c52d1671b39a79532050c85efb99079064')
version('2.0.3', sha256='a69598bf079463b34d45ca7268462a18b6507fdaa62bb1dfd212f02041499b5d')
version('2.0.2', sha256='b45255bd476c19c7c6b198c07c0487e8b8536373b82f2b38346b32b4fa7bb942')
version('1.5.90', sha256='cb948ade92561d8626fd7866a4a7ba3b952f9759ea3dd642927bc687470f60b7')
version('1.5.3', sha256='1a17020f859cb12711175a67eab5c71fc1904e04b587046218e36106e07eabde', deprecated=True)
version('1.5.0', sha256='232280e1c9c3e6a1de95fe99be2f7f9c0362ee08f3e3e48d50ee83b9a2ed955b', deprecated=True)
version('1.3.1', sha256='5008aeeac303ea9159a0ec3ccff295434f4e63b05aed4a684c9964d497304524', deprecated=True)
provides('jpeg')
# Can use either of these. But in the current version of the package
# only nasm is used. In order to use yasm an environmental variable
# NASM must be set.
# TODO: Implement the selection between two supported assemblers.
# depends_on('yasm', type='build')
depends_on('nasm', type='build')
depends_on('autoconf', type='build', when='@1.3.1:1.5.3')
depends_on('automake', type='build', when='@1.3.1:1.5.3')
depends_on('libtool', type='build', when='@1.3.1:1.5.3')
depends_on('cmake', type='build', when='@1.5.90:')
@property
def libs(self):
return find_libraries('libjpeg*', root=self.prefix, recursive=True)
def flag_handler(self, name, flags):
if self.spec.satisfies('@1.5.90:'):
return (None, None, flags)
else:
# compiler flags for earlier version are injected into the
# spack compiler wrapper
return (flags, None, None)
def flags_to_build_system_args(self, flags):
# This only handles cflags, other flags are discarded
cmake_flag_args = []
if 'cflags' in flags and flags['cflags']:
cmake_flag_args.append('-DCMAKE_C_FLAGS={0}'.format(
' '.join(flags['cflags'])))
self.cmake_flag_args = cmake_flag_args
@when('@1.3.1:1.5.3')
def install(self, spec, prefix):
autoreconf('-ifv')
configure('--prefix=%s' % prefix)
make()
make('install')
@when('@1.5.90:')
def install(self, spec, prefix):
cmake_args = ['-GUnix Makefiles']
if hasattr(self, 'cmake_flag_args'):
cmake_args.extend(self.cmake_flag_args)
cmake_args.extend(std_cmake_args)
with working_dir('spack-build', create=True):
cmake('..', *cmake_args)
make()
make('install')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-mcmcglmm/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 RMcmcglmm(RPackage):
"""MCMC Generalised Linear Mixed Models.
Fits Multivariate Generalised Linear Mixed Models (and related models)
using Markov chain Monte Carlo techniques (Hadfield 2010 J. Stat.
Soft.)."""
cran = "MCMCglmm"
version('2.33', sha256='b56d72e799f8ed5fa2a05ecc743e5b8051f9cc2de57ad3e6de2dcb1c1715d4fc')
version('2.32', sha256='a9156e1e0d0f912f2f239476dc8765dc61c480f903381be7ec5db05bd6d3f0b3')
version('2.30', sha256='714250fe6ebdd1bd3dc284f7fcb92326de1273b0c34d31e71dc825312527e042')
version('2.29', sha256='13ba7837ea2049e892c04e7ec5c83d5b599a7e4820b9d875f55ec40fc2cc67b4')
version('2.28', sha256='7d92e6d35638e5e060a590b92c3b1bfc02a11386276a8ab99bceec5d797bfc2a')
version('2.25', sha256='3072316bf5c66f6db5447cb488395ff019f6c47122813467384474f340643133')
depends_on('r-matrix', type=('build', 'run'))
depends_on('r-coda', type=('build', 'run'))
depends_on('r-ape', type=('build', 'run'))
depends_on('r-corpcor', type=('build', 'run'))
depends_on('r-tensora', type=('build', 'run'))
depends_on('r-cubature', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/ufs-weather-model/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 UfsWeatherModel(CMakePackage):
"""The Unified Forecast System (UFS) Weather Model (WM) is a prognostic
model that can be used for short- and medium-range research and
operational forecasts, as exemplified by its use in the operational Global
Forecast System (GFS) of the National Oceanic and Atmospheric
Administration (NOAA)."""
homepage = "https://ufs-weather-model.readthedocs.io/en/latest/"
url = "https://github.com/ufs-community/ufs-weather-model/archive/refs/tags/ufs-v1.1.0.tar.gz"
git = "https://github.com/ufs-community/ufs-weather-model.git"
maintainers = ['t-brown']
version('2.0.0', tag='ufs-v2.0.0', submodules=True)
version('1.1.0', tag='ufs-v1.1.0', submodules=True)
variant('32bit', default=True, description='Enable 32-bit single precision arithmetic in dycore')
variant('avx2', default=False, description='Enable AVX2 instructions')
variant('ccpp', default=True, description='Enable the Common Community Physics Package (CCPP))')
variant('ccpp_suites', default='FV3_GFS_v15p2,FV3_RRFS_v1alpha',
description='CCPP suites to compile',
values=('FV3_GFS_v15p2',
'FV3_RRFS_v1alpha',
'FV3_GFS_v15p2,FV3_RRFS_v1alpha'),
multi=True)
variant('inline_post', default=False, description='Compile post processing inline')
variant('multi_gases', default=False, description='Enable multi gases in physics routines')
variant('openmp', default=True, description='Enable OpenMP')
variant('parallel_netcdf', default=True, description='Enable parallel I/O in netCDF')
variant('quad_precision', default=False,
description='Enable quad precision for certain grid metric terms in dycore')
variant('simdmultiarch', default=False, description='Enable multi-target SIMD instruction sets')
depends_on('bacio')
depends_on('esmf@:8.0.0')
depends_on('mpi')
depends_on('nemsio')
depends_on('netcdf-c')
depends_on('netcdf-fortran')
depends_on('sp')
depends_on('w3emc')
depends_on('w3nco')
def setup_build_environment(self, env):
spec = self.spec
env.set('CMAKE_C_COMPILER', spec['mpi'].mpicc)
env.set('CMAKE_CXX_COMPILER', spec['mpi'].mpicxx)
env.set('CMAKE_Fortran_COMPILER', spec['mpi'].mpifc)
env.set('ESMFMKFILE', join_path(spec['esmf'].prefix.lib, 'esmf.mk'))
env.set('CCPP_SUITES', ','.join(
[x for x in spec.variants['ccpp_suites'].value if x]))
if spec.platform == 'linux' and spec.satisfies('%intel'):
env.set('CMAKE_Platform', 'linux.intel')
elif spec.platform == 'linux' and spec.satisfies('%gcc'):
env.set('CMAKE_Platform', 'linux.gnu')
elif spec.platform == 'darwin' and spec.satisfies('%gcc'):
env.set('CMAKE_Platform', 'macosx.gnu')
else:
msg = "The host system {0} and compiler {0} "
msg += "are not supported by UFS."
raise InstallError(msg.format(spec.platform, self.compiler.name))
def cmake_args(self):
from_variant = self.define_from_variant
args = [from_variant('32BIT', '32bit'),
from_variant('AVX2', 'avx2'),
from_variant('CCPP', 'ccpp'),
from_variant('INLINE_POST', 'inline_post'),
from_variant('MULTI_GASES', 'multi_gases'),
from_variant('OPENMP', 'openmp'),
from_variant('PARALLEL_NETCDF', 'parallel_netcdf'),
from_variant('QUAD_PRECISION', 'quad_precision'),
from_variant('SIMDMULTIARCH', 'simdmultiarch'),
]
return args
@run_after('install')
def install_additional_files(self):
mkdirp(prefix.bin)
ufs_src = join_path(self.build_directory, 'NEMS.exe')
ufs_dst = join_path(prefix.bin, "ufs_weather_model")
install(ufs_src, ufs_dst)
set_executable(ufs_dst)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-colorio/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 PyColorio(PythonPackage):
"""Tools for color research"""
homepage = "https://github.com/nschloe/colorio"
pypi = "colorio/colorio-0.11.2.tar.gz"
version('0.11.2', sha256='aa45d8e0a2e506c4019d4fb488d34a107d7f803c8e8ff355e2e57c01f6f1cd81')
depends_on('python@3.7:', type=('build', 'run'))
depends_on('py-flit-core@3.2:3.6', type='build')
depends_on('py-numpy@1.20:', type=('build', 'run'))
depends_on('py-matplotlib', type=('build', 'run'))
depends_on('py-npx', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/cnmem/package.py
|
# Copyright 2013-2022 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 Cnmem(CMakePackage):
"""CNMem mempool for CUDA devices"""
homepage = "https://github.com/NVIDIA/cnmem"
git = "https://github.com/NVIDIA/cnmem.git"
version('git', branch='master')
depends_on('cmake@2.8.8:', type='build')
|
player1537-forks/spack
|
lib/spack/spack/container/images.py
|
<filename>lib/spack/spack/container/images.py<gh_stars>1-10
# Copyright 2013-2022 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)
"""Manages the details on the images used in the various stages."""
import json
import os.path
import sys
import llnl.util.filesystem as fs
import llnl.util.tty as tty
import spack.util.executable as executable
#: Global variable used to cache in memory the content of images.json
_data = None
def data():
"""Returns a dictionary with the static data on the images.
The dictionary is read from a JSON file lazily the first time
this function is called.
"""
global _data
if not _data:
json_dir = os.path.abspath(os.path.dirname(__file__))
json_file = os.path.join(json_dir, 'images.json')
with open(json_file) as f:
_data = json.load(f)
return _data
def build_info(image, spack_version):
"""Returns the name of the build image and its tag.
Args:
image (str): image to be used at run-time. Should be of the form
<image_name>:<image_tag> e.g. "ubuntu:18.04"
spack_version (str): version of Spack that we want to use to build
Returns:
A tuple with (image_name, image_tag) for the build image
"""
# Don't handle error here, as a wrong image should have been
# caught by the JSON schema
image_data = data()["images"][image]
build_image = image_data.get('build', None)
if not build_image:
return None, None
# Translate version from git to docker if necessary
build_tag = image_data['build_tags'].get(spack_version, spack_version)
return build_image, build_tag
def os_package_manager_for(image):
"""Returns the name of the OS package manager for the image
passed as argument.
Args:
image (str): image to be used at run-time. Should be of the form
<image_name>:<image_tag> e.g. "ubuntu:18.04"
Returns:
Name of the package manager, e.g. "apt" or "yum"
"""
name = data()["images"][image]["os_package_manager"]
return name
def all_bootstrap_os():
"""Return a list of all the OS that can be used to bootstrap Spack"""
return list(data()['images'])
def commands_for(package_manager):
"""Returns the commands used to update system repositories, install
system packages and clean afterwards.
Args:
package_manager (str): package manager to be used
Returns:
A tuple of (update, install, clean) commands.
"""
info = data()["os_package_managers"][package_manager]
return info['update'], info['install'], info['clean']
def bootstrap_template_for(image):
return data()["images"][image]["bootstrap"]["template"]
def _verify_ref(url, ref, enforce_sha):
# Do a checkout in a temporary directory
msg = 'Cloning "{0}" to verify ref "{1}"'.format(url, ref)
tty.info(msg, stream=sys.stderr)
git = executable.which('git', required=True)
with fs.temporary_dir():
git('clone', '-q', url, '.')
sha = git('rev-parse', '-q', ref + '^{commit}',
output=str, error=os.devnull, fail_on_error=False)
if git.returncode:
msg = '"{0}" is not a valid reference for "{1}"'
raise RuntimeError(msg.format(sha, url))
if enforce_sha:
ref = sha.strip()
return ref
def checkout_command(url, ref, enforce_sha, verify):
"""Return the checkout command to be used in the bootstrap phase.
Args:
url (str): url of the Spack repository
ref (str): either a branch name, a tag or a commit sha
enforce_sha (bool): if true turns every
verify (bool):
"""
url = url or 'https://github.com/spack/spack.git'
ref = ref or 'develop'
enforce_sha, verify = bool(enforce_sha), bool(verify)
# If we want to enforce a sha or verify the ref we need
# to checkout the repository locally
if enforce_sha or verify:
ref = _verify_ref(url, ref, enforce_sha)
command = 'git clone {0} . && git checkout {1} '.format(url, ref)
return command
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-saga-python/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 PySagaPython(PythonPackage):
"""A light-weight access layer for distributed computing infrastructure.
DEPRECATED (Please use `py-radical-saga`)"""
homepage = 'https://radical-cybertools.github.io'
pypi = 'saga-python/saga-python-0.41.3.tar.gz'
maintainers = ['andre-merzky']
version('0.41.3', sha256='b30961e634f32f6008e292aa1fe40560f257d5294b0cda95baac1cf5391feb5d', deprecated=True)
depends_on('py-radical-utils@:0.45', type=('build', 'run'))
depends_on('py-apache-libcloud', type=('build', 'run'))
depends_on('py-setuptools', type='build')
|
player1537-forks/spack
|
lib/spack/spack/cmd/gc.py
|
<filename>lib/spack/spack/cmd/gc.py
# Copyright 2013-2022 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)
import llnl.util.tty as tty
import spack.cmd.common.arguments
import spack.cmd.uninstall
import spack.environment as ev
import spack.store
description = "remove specs that are now no longer needed"
section = "build"
level = "short"
def setup_parser(subparser):
spack.cmd.common.arguments.add_common_arguments(subparser, ['yes_to_all'])
def gc(parser, args):
specs = spack.store.db.unused_specs
# Restrict garbage collection to the active environment
# speculating over roots that are yet to be installed
env = ev.active_environment()
if env:
msg = 'Restricting the garbage collection to the "{0}" environment'
tty.msg(msg.format(env.name))
env.concretize()
roots = [s for s in env.roots()]
all_hashes = set([s.dag_hash() for r in roots for s in r.traverse()])
lr_hashes = set([s.dag_hash() for r in roots
for s in r.traverse(deptype=('link', 'run'))])
maybe_to_be_removed = all_hashes - lr_hashes
specs = [s for s in specs if s.dag_hash() in maybe_to_be_removed]
if not specs:
msg = "There are no unused specs. Spack's store is clean."
tty.msg(msg)
return
if not args.yes_to_all:
spack.cmd.uninstall.confirm_removal(specs)
spack.cmd.uninstall.do_uninstall(None, specs, force=False)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-llnl-sina/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 PyLlnlSina(PythonPackage):
"""Sina allows codes to store, query, and visualize their data through an
easy-to-use Python API. Data that fits its recognized schema can be ingested
into one or more supported backends.
Sina's API is independent of backend and gives users the benefits of a database
without requiring knowledge of one, allowing queries to be expressed in pure
Python. Visualizations are also provided through Python.
Sina is intended especially for use with run metadata,
allowing users to easily and efficiently find simulation runs that match some
criteria.
"""
homepage = "https://github.com/LLNL/Sina"
git = "https://github.com/LLNL/Sina.git"
# notify when the package is updated.
maintainers = [
'HaluskaR',
'estebanpauli',
'murray55',
'doutriaux1',
]
version('1.11.0', tag="v1.11.0")
version('1.10.0', tag="v1.10.0")
# let's remove dependency on orjson
patch('no_orjson.patch')
depends_on('py-setuptools', type='build')
depends_on('py-enum34', when='^python@:3.3', type=('build', 'run'))
depends_on('py-ujson', type=('build', 'run'))
depends_on("py-sqlalchemy", type=("build", "run"))
depends_on("py-six", type=("build", "run"))
build_directory = 'python'
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/comd/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 Comd(MakefilePackage):
"""CoMD is a reference implementation of classical molecular dynamics
algorithms and workloads as used in materials science. It is created and
maintained by The Exascale Co-Design Center for Materials in Extreme
Environments (ExMatEx). The code is intended to serve as a vehicle for
co-design by allowing others to extend and/or reimplement it as needed to
test performance of new architectures, programming models, etc. New
versions of CoMD will be released to incorporate the lessons learned from
the co-design process."""
tags = ['proxy-app']
homepage = "http://www.exmatex.org/comd.html"
url = "https://github.com/ECP-copa/CoMD/archive/v1.1.tar.gz"
git = "https://github.com/ECP-copa/CoMD.git"
version('develop', branch='master')
version('1.1', sha256='4e85f86f043681a1ef72940fc24a4c71356a36afa45446f7cfe776abad6aa252')
variant('mpi', default=True, description='Build with MPI support')
variant('openmp', default=False, description='Build with OpenMP support')
variant('precision', default=True, description='Toggle Precesion Options')
variant('graphs', default=False, description='Enable graph visuals')
depends_on('mpi', when='+mpi')
depends_on('graphviz', when='+graphs')
conflicts('+openmp', when='+mpi')
def edit(self, spec, prefix):
with working_dir('src-mpi') or working_dir('src-openmp'):
copy('Makefile.vanilla', 'Makefile')
@property
def build_targets(self):
targets = []
cflags = ' -std=c99 '
optflags = ' -g -O5 '
clib = ' -lm '
comd_variant = 'CoMD'
cc = spack_cc
if '+openmp' in self.spec:
targets.append('--directory=src-openmp')
comd_variant += '-openmp'
cflags += ' -fopenmp '
if '+mpi' in self.spec:
comd_variant += '-mpi'
targets.append('CC = {0}'.format(self.spec['mpi'].mpicc))
else:
targets.append('CC = {0}'.format('spack_cc'))
else:
targets.append('--directory=src-mpi')
if '~mpi' in self.spec:
comd_variant += '-serial'
targets.append('CC = {0}'.format(cc))
else:
comd_variant += '-mpi'
targets.append('CC = {0}'.format(self.spec['mpi'].mpicc))
if '+mpi' in self.spec:
cflags += '-DDO_MPI'
targets.append(
'INCLUDES = {0}'.format(self.spec['mpi'].prefix.include))
if '+precision' in self.spec:
cflags += ' -DDOUBLE '
else:
cflags += ' -DSINGLE '
targets.append('CoMD_VARIANT = {0}'.format(comd_variant))
targets.append('CFLAGS = {0}'.format(cflags))
targets.append('OPTFLAGS = {0}'.format(optflags))
targets.append('C_LIB = {0}'.format(clib))
return targets
def install(self, spec, prefix):
install_tree('bin', prefix.bin)
install_tree('examples', prefix.examples)
install_tree('pots', prefix.pots)
mkdirp(prefix.doc)
install('README.md', prefix.doc)
install('LICENSE.md', prefix.doc)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/qgraf/package.py
|
# Copyright 2013-2022 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 Qgraf(Package):
"""Qgraf is a computer program that generates Feynman diagrams
for various types of QFT models"""
homepage = "http://cfif.ist.utl.pt/~paulo/qgraf.html"
url = "http://anonymous:<EMAIL>/v3.4/qgraf-3.4.2.tgz"
tags = ['hep']
version('3.4.2', sha256='cfc029fb871c78943865ef8b51ebcd3cd4428448b8816714b049669dfdeab8aa')
def install(self, spec, prefix):
fortran = Executable(spack_fc)
fortran('qgraf-{0}.f'.format(self.spec.version), '-o', 'qgraf')
install_tree('.', prefix)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-httpcore/package.py
|
# Copyright 2013-2022 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 PyHttpcore(PythonPackage):
"""The HTTP Core package provides a minimal low-level HTTP client,
which does one thing only. Sending HTTP requests."""
homepage = "https://github.com/encode/httpcore"
pypi = "httpcore/httpcore-0.11.0.tar.gz"
version('0.11.0', sha256='35ffc735d746b83f8fc6d36f82600e56117b9e8adc65d0c0423264b6ebfef7bf')
depends_on('py-setuptools', type='build')
depends_on('py-wheel', type='build')
depends_on('py-sniffio@1.0:')
depends_on('py-h11@0.8:0.9')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/bash/package.py
|
# Copyright 2013-2022 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)
import re
class Bash(AutotoolsPackage, GNUMirrorPackage):
"""The GNU Project's Bourne Again SHell."""
homepage = "https://www.gnu.org/software/bash/"
gnu_mirror_path = "bash/bash-5.0.tar.gz"
maintainers = ['adamjstewart']
version('5.1', sha256='cc012bc860406dcf42f64431bcd3d2fa7560c02915a601aba9cd597a39329baa')
version('5.0', sha256='b4a80f2ac66170b2913efbfb9f2594f1f76c7b1afd11f799e22035d63077fb4d')
version('4.4', sha256='d86b3392c1202e8ff5a423b302e6284db7f8f435ea9f39b5b1b20fd3ac36dfcb')
version('4.3', sha256='afc687a28e0e24dc21b988fa159ff9dbcf6b7caa92ade8645cc6d5605cd024d4')
depends_on('ncurses')
depends_on('readline@5.0:')
depends_on('iconv')
patches = [
('5.1', '001', 'ebb07b3dbadd98598f078125d0ae0d699295978a5cdaef6282fe19adef45b5fa'),
('5.1', '002', '15ea6121a801e48e658ceee712ea9b88d4ded022046a6147550790caf04f5dbe'),
('5.1', '003', '22f2cc262f056b22966281babf4b0a2f84cb7dd2223422e5dcd013c3dcbab6b1'),
('5.1', '004', '9aaeb65664ef0d28c0067e47ba5652b518298b3b92d33327d84b98b28d873c86'),
('5.1', '005', 'cccbb5e9e6763915d232d29c713007a62b06e65126e3dd2d1128a0dc5ef46da5'),
('5.1', '006', '75e17d937de862615c6375def40a7574462210dce88cf741f660e2cc29473d14'),
('5.1', '007', 'acfcb8c7e9f73457c0fb12324afb613785e0c9cef3315c9bbab4be702f40393a'),
('5.1', '008', 'f22cf3c51a28f084a25aef28950e8777489072628f972b12643b4534a17ed2d1'),
('5.0', '001', 'f2fe9e1f0faddf14ab9bfa88d450a75e5d028fedafad23b88716bd657c737289'),
('5.0', '002', '87e87d3542e598799adb3e7e01c8165bc743e136a400ed0de015845f7ff68707'),
('5.0', '003', '4eebcdc37b13793a232c5f2f498a5fcbf7da0ecb3da2059391c096db620ec85b'),
('5.0', '004', '14447ad832add8ecfafdce5384badd933697b559c4688d6b9e3d36ff36c62f08'),
('5.0', '005', '5bf54dd9bd2c211d2bfb34a49e2c741f2ed5e338767e9ce9f4d41254bf9f8276'),
('5.0', '006', 'd68529a6ff201b6ff5915318ab12fc16b8a0ebb77fda3308303fcc1e13398420'),
('5.0', '007', '17b41e7ee3673d8887dd25992417a398677533ab8827938aa41fad70df19af9b'),
('5.0', '008', 'eec64588622a82a5029b2776e218a75a3640bef4953f09d6ee1f4199670ad7e3'),
('5.0', '009', 'ed3ca21767303fc3de93934aa524c2e920787c506b601cc40a4897d4b094d903'),
('5.0', '010', 'd6fbc325f0b5dc54ddbe8ee43020bced8bd589ddffea59d128db14b2e52a8a11'),
('5.0', '011', '2c4de332b91eaf797abbbd6c79709690b5cbd48b12e8dfe748096dbd7bf474ea'),
('5.0', '012', '2943ee19688018296f2a04dbfe30b7138b889700efa8ff1c0524af271e0ee233'),
('5.0', '013', 'f5d7178d8da30799e01b83a0802018d913d6aa972dd2ddad3b927f3f3eb7099a'),
('5.0', '014', '5d6eee6514ee6e22a87bba8d22be0a8621a0ae119246f1c5a9a35db1f72af589'),
('5.0', '015', 'a517df2dda93b26d5cbf00effefea93e3a4ccd6652f152f4109170544ebfa05e'),
('5.0', '016', 'ffd1d7a54a99fa7f5b1825e4f7e95d8c8876bc2ca151f150e751d429c650b06d'),
('5.0', '017', '4cf3b9fafb8a66d411dd5fc9120032533a4012df1dc6ee024c7833373e2ddc31'),
('5.0', '018', '7c314e375a105a6642e8ed44f3808b9def89d15f7492fe2029a21ba9c0de81d3'),
('4.4', '001', '3e28d91531752df9a8cb167ad07cc542abaf944de9353fe8c6a535c9f1f17f0f'),
('4.4', '002', '7020a0183e17a7233e665b979c78c184ea369cfaf3e8b4b11f5547ecb7c13c53'),
('4.4', '003', '51df5a9192fdefe0ddca4bdf290932f74be03ffd0503a3d112e4199905e718b2'),
('4.4', '004', 'ad080a30a4ac6c1273373617f29628cc320a35c8cd06913894794293dc52c8b3'),
('4.4', '005', '221e4b725b770ad0bb6924df3f8d04f89eeca4558f6e4c777dfa93e967090529'),
('4.4', '006', '6a8e2e2a6180d0f1ce39dcd651622fb6d2fd05db7c459f64ae42d667f1e344b8'),
('4.4', '007', 'de1ccc07b7bfc9e25243ad854f3bbb5d3ebf9155b0477df16aaf00a7b0d5edaf'),
('4.4', '008', '86144700465933636d7b945e89b77df95d3620034725be161ca0ca5a42e239ba'),
('4.4', '009', '0b6bdd1a18a0d20e330cc3bc71e048864e4a13652e29dc0ebf3918bea729343c'),
('4.4', '010', '8465c6f2c56afe559402265b39d9e94368954930f9aa7f3dfa6d36dd66868e06'),
('4.4', '011', 'dd56426ef7d7295e1107c0b3d06c192eb9298f4023c202ca2ba6266c613d170d'),
('4.4', '012', 'fac271d2bf6372c9903e3b353cb9eda044d7fe36b5aab52f21f3f21cd6a2063e'),
('4.4', '013', '1b25efacbc1c4683b886d065b7a089a3601964555bcbf11f3a58989d38e853b6'),
('4.4', '014', 'a7f75cedb43c5845ab1c60afade22dcb5e5dc12dd98c0f5a3abcfb9f309bb17c'),
('4.4', '015', 'd37602ecbeb62d5a22c8167ea1e621fcdbaaa79925890a973a45c810dd01c326'),
('4.4', '016', '501f91cc89fadced16c73aa8858796651473602c722bb29f86a8ba588d0ff1b1'),
('4.4', '017', '773f90b98768d4662a22470ea8eec5fdd8e3439f370f94638872aaf884bcd270'),
('4.4', '018', '5bc494b42f719a8b0d844b7bd9ad50ebaae560e97f67c833c9e7e9d53981a8cc'),
('4.4', '019', '27170d6edfe8819835407fdc08b401d2e161b1400fe9d0c5317a51104c89c11e'),
('4.4', '020', '1840e2cbf26ba822913662f74037594ed562361485390c52813b38156c99522c'),
('4.4', '021', 'bd8f59054a763ec1c64179ad5cb607f558708a317c2bdb22b814e3da456374c1'),
('4.4', '022', '45331f0936e36ab91bfe44b936e33ed8a1b1848fa896e8a1d0f2ef74f297cb79'),
('4.4', '023', '4fec236f3fbd3d0c47b893fdfa9122142a474f6ef66c20ffb6c0f4864dd591b6'),
('4.3', '001', 'ecb3dff2648667513e31554b3ad054ccd89fce38e33367c9459ac3a285153742'),
('4.3', '002', 'eee7cd7062ab29a9e4f02924d9c367264dcb8b162703f74ff6eb8f175a91502b'),
('4.3', '003', '000e6eac50cd9053ce0630db01239dcdead04a2c2c351c47e2b51dac1ac1087d'),
('4.3', '004', '5ea0a42c6506720d26e6d3c5c358e9a0d49f6f189d69a8ed34d5935964821338'),
('4.3', '005', '1ac83044032b9f5f11aeca8a344ae3c524ec2156185d3adbb8ad3e7a165aa3fa'),
('4.3', '006', 'a0648ee72d15e4a90c8b77a5c6b19f8d89e28c1bc881657d22fe26825f040213'),
('4.3', '007', '1113e321c59cf6a8648a36245bbe4217cf8acf948d71e67886dad7d486f8f3a3'),
('4.3', '008', '9941a98a4987192cc5ce3d45afe879983cad2f0bec96d441a4edd9033767f95e'),
('4.3', '009', 'c0226d6728946b2f53cdebf090bcd1c01627f01fee03295768605caa80bb40a5'),
('4.3', '010', 'ce05799c0137314c70c7b6ea0477c90e1ac1d52e113344be8e32fa5a55c9f0b7'),
('4.3', '011', '7c63402cdbc004a210f6c1c527b63b13d8bb9ec9c5a43d5c464a9010ff6f7f3b'),
('4.3', '012', '3e1379030b35fbcf314e9e7954538cf4b43be1507142b29efae39eef997b8c12'),
('4.3', '013', 'bfa8ca5336ab1f5ef988434a4bdedf71604aa8a3659636afa2ce7c7446c42c79'),
('4.3', '014', '5a4d6fa2365b6eb725a9d4966248b5edf7630a4aeb3fa8d526b877972658ac13'),
('4.3', '015', '13293e8a24e003a44d7fe928c6b1e07b444511bed2d9406407e006df28355e8d'),
('4.3', '016', '92d60bcf49f61bd7f1ccb9602bead6f2c9946d79dea0e5ec0589bb3bfa5e0773'),
('4.3', '017', '1267c25c6b5ba57042a7bb6c569a6de02ffd0d29530489a16666c3b8a23e7780'),
('4.3', '018', '7aa8b40a9e973931719d8cc72284a8fb3292b71b522db57a5a79052f021a3d58'),
('4.3', '019', 'a7a91475228015d676cafa86d2d7aa9c5d2139aa51485b6bbdebfdfbcf0d2d23'),
('4.3', '020', 'ca5e86d87f178128641fe91f2f094875b8c1eb2de9e0d2e9154f5d5cc0336c98'),
('4.3', '021', '41439f06883e6bd11c591d9d5e9ae08afbc2abd4b935e1d244b08100076520a9'),
('4.3', '022', 'fd4d47bb95c65863f634c4706c65e1e3bae4ee8460c72045c0a0618689061a88'),
('4.3', '023', '9ac250c7397a8f53dbc84dfe790d2a418fbf1fe090bcece39b4a5c84a2d300d4'),
('4.3', '024', '3b505882a0a6090667d75824fc919524cd44cc3bd89dd08b7c4e622d3f960f6c'),
('4.3', '025', '1e5186f5c4a619bb134a1177d9e9de879f3bb85d9c5726832b03a762a2499251'),
('4.3', '026', '2ecc12201b3ba4273b63af4e9aad2305168cf9babf6d11152796db08724c214d'),
('4.3', '027', '1eb76ad28561d27f7403ff3c76a36e932928a4b58a01b868d663c165f076dabe'),
('4.3', '028', 'e8b0dbed4724fa7b9bd8ff77d12c7f03da0fbfc5f8251ef5cb8511eb082b469d'),
('4.3', '029', '4cc4a397fe6bc63ecb97d030a4e44258ef2d4e076d0e90c77782968cc43d6292'),
('4.3', '030', '85434f8a2f379d0c49a3ff6d9ffa12c8b157188dd739e556d638217d2a58385b'),
('4.3', '031', 'cd529f59dd0f2fdd49d619fe34691da6f0affedf87cc37cd460a9f3fe812a61d'),
('4.3', '032', '889357d29a6005b2c3308ca5b6286cb223b5e9c083219e5db3156282dd554f4a'),
('4.3', '033', 'fb2a7787a13fbe027a7335aca6eb3c21cdbd813e9edc221274b6a9d8692eaa16'),
('4.3', '034', 'f1694f04f110defe1330a851cc2768e7e57ddd2dfdb0e3e350ca0e3c214ff889'),
('4.3', '035', '370d85e51780036f2386dc18c5efe996eba8e652fc1973f0f4f2ab55a993c1e3'),
('4.3', '036', 'ac5f82445b36efdb543dbfae64afed63f586d7574b833e9aa9cd5170bc5fd27c'),
('4.3', '037', '33f170dd7400ab3418d749c55c6391b1d161ef2de7aced1873451b3a3fca5813'),
('4.3', '038', 'adbeaa500ca7a82535f0e88d673661963f8a5fcdc7ad63445e68bf5b49786367'),
('4.3', '039', 'ab94dced2215541097691f60c3eb323cc28ef2549463e6a5334bbcc1e61e74ec'),
('4.3', '040', '84bb396b9262992ca5424feab6ed3ec39f193ef5c76dfe4a62b551bd8dd9d76b'),
('4.3', '041', '4ec432966e4198524a7e0cd685fe222e96043769c9613e66742ac475db132c1a'),
('4.3', '042', 'ac219322db2791da87a496ee6e8e5544846494bdaaea2626270c2f73c1044919'),
('4.3', '043', '47a8a3c005b46e25821f4d8f5ccb04c1d653b1c829cb40568d553dc44f7a6180'),
('4.3', '044', '9338820630bf67373b44d8ea68409f65162ea7a47b9b29ace06a0aed12567f99'),
('4.3', '045', 'ba6ec3978e9eaa1eb3fabdaf3cc6fdf8c4606ac1c599faaeb4e2d69864150023'),
('4.3', '046', 'b3b456a6b690cd293353f17e22d92a202b3c8bce587ae5f2667c20c9ab6f688f'),
('4.3', '047', 'c69248de7e78ba6b92f118fe1ef47bc86479d5040fe0b1f908ace1c9e3c67c4a'),
('4.3', '048', '5b8215451c5d096ca1e115307ffe6613553551a70369525a0778f216c3a4dfa2'),
]
# TODO: patches below are not managed by the GNUMirrorPackage base class
for ver, num, checksum in patches:
ver = Version(ver)
patch('https://ftpmirror.gnu.org/bash/bash-{0}-patches/bash{1}-{2}'.format(ver, ver.joined, num),
level=0, when='@{0}'.format(ver), sha256=checksum)
# Modified from:
# https://github.com/macports/macports-ports/blob/master/shells/bash/files/patch-configure.diff
patch('patch-configure.diff', when='@:5.0 %apple-clang@12:')
executables = ['^bash$']
@classmethod
def determine_version(cls, exe):
output = Executable(exe)('--version', output=str, error=str)
match = re.search(r'GNU bash, version ([\d.]+)', output)
return match.group(1) if match else None
def configure_args(self):
spec = self.spec
return [
# https://github.com/Homebrew/legacy-homebrew/pull/23234
# https://trac.macports.org/ticket/40603
'CFLAGS=-DSSH_SOURCE_BASHRC',
'LIBS=' + spec['ncurses'].libs.link_flags,
'--with-curses',
'--enable-readline',
'--with-installed-readline',
'--with-libiconv-prefix={0}'.format(spec['iconv'].prefix),
]
def check(self):
make('tests')
@property
def install_targets(self):
args = ['install']
if self.spec.satisfies('@4.4:'):
args.append('install-headers')
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/hdf5-vol-log/package.py
|
# Copyright 2013-2022 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 Hdf5VolLog(AutotoolsPackage):
"""Log-based VOL - an HDF5 VOL Plugin that stores HDF5 datasets in a log-based
storage layout."""
homepage = 'https://github.com/DataLib-ECP/vol-log-based'
url = 'https://github.com/DataLib-ECP/vol-log-based'
git = 'https://github.com/DataLib-ECP/vol-log-based.git'
maintainers = ['hyoklee']
version('master', commit='<PASSWORD>')
depends_on('hdf5@1.13.0:')
depends_on('autoconf', type='build')
depends_on('automake', type='build')
depends_on('libtool', type='build')
depends_on('m4', type='build')
def configure_args(self):
args = []
args.append('--enable-shared')
args.append('--enable-zlib')
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/fairlogger/package.py
|
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
# Copyright 2020 GSI Helmholtz Centre for Heavy Ion Research GmbH,
# Darmstadt, Germany
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class Fairlogger(CMakePackage):
"""Lightweight and fast C++ Logging Library"""
homepage = 'https://github.com/FairRootGroup/FairLogger'
url = "https://github.com/FairRootGroup/FairLogger/archive/v1.2.0.tar.gz"
git = 'https://github.com/FairRootGroup/FairLogger.git'
maintainers = ['dennisklein', 'ChristianTackeGSI']
# generator = 'Ninja'
version('develop', branch='dev', get_full_repo=True)
version('1.9.0', sha256='13bcaa0d4129f8d4e69a0a2ece8e5b7073760082c8aa028e3fc0c11106503095')
version('1.8.0', sha256='3f0a38dba1411b542d998e02badcc099c057b33a402954fc5c2ab74947a0c42c')
version('1.7.0', sha256='ef467f0a70afc0549442323d70b165fa0b0b4b4e6f17834573ca15e8e0b007e4')
version('1.6.2', sha256='5c6ef0c0029eb451fee71756cb96e6c5011040a9813e8889667b6f3b6b04ed03')
version('1.6.1', sha256='3894580f4c398d724ba408e410e50f70c9f452e8cfaf7c3ff8118c08df28eaa8')
version('1.6.0', sha256='721e8cadfceb2f63014c2a727e098babc6deba653baab8866445a772385d0f5b')
version('1.5.0', sha256='8e74e0b1e50ee86f4fca87a44c6b393740b32099ac3880046bf252c31c58dd42')
version('1.4.0', sha256='75457e86984cc03ce87d6ad37adc5aab1910cabd39a9bbe5fb21ce2475a91138')
version('1.3.0', sha256='5cedea2773f7091d69aae9fd8f724e6e47929ee3784acdd295945a848eb36b93')
version('1.2.0', sha256='bc0e049cf84ceb308132d8679e7f22fcdca5561dda314d5233d0d5fe2b0f8c62')
version('1.1.0', sha256='e185e5bd07df648224f85e765d18579fae0de54adaab9a194335e3ad6d3d29f7')
version('1.0.6', sha256='2fc266a6e494adda40837be406aef8d9838f385ffd64fbfafb1164833906b4e0')
variant('build_type', default='RelWithDebInfo',
values=('Debug', 'Release', 'RelWithDebInfo'),
multi=False,
description='CMake build type')
variant('cxxstd', default='default',
values=('default', '11', '14', '17'),
multi=False,
description='Use the specified C++ standard when building.')
variant('pretty',
default=False,
description='Use BOOST_PRETTY_FUNCTION macro (Supported by 1.4+).')
conflicts('+pretty', when='@:1.3')
depends_on('cmake@3.9.4:', type='build')
depends_on('git', type='build', when='@develop')
depends_on('boost', when='+pretty')
conflicts('^boost@1.70:', when='^cmake@:3.14')
depends_on('fmt@5.3.0:5', when='@1.6.0:1.6.1')
depends_on('fmt@5.3.0:', when='@1.6.2:')
def patch(self):
"""FairLogger gets its version number from git.
But the tarball doesn't have that information, so
we patch the spack version into CMakeLists.txt"""
if not self.spec.satisfies("@develop"):
filter_file(r'(get_git_version\(.*)\)',
r'\1 DEFAULT_VERSION %s)' % self.spec.version,
'CMakeLists.txt')
def cmake_args(self):
args = []
args.append('-DDISABLE_COLOR=ON')
cxxstd = self.spec.variants['cxxstd'].value
if cxxstd != 'default':
args.append('-DCMAKE_CXX_STANDARD=%s' % cxxstd)
if self.spec.satisfies('@1.4:'):
args.append(self.define_from_variant('USE_BOOST_PRETTY_FUNCTION', 'pretty'))
if self.spec.satisfies('@1.6:'):
args.append('-DUSE_EXTERNAL_FMT=ON')
if self.spec.satisfies('^boost@:1.69'):
args.append('-DBoost_NO_BOOST_CMAKE=ON')
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/varscan/package.py
|
# Copyright 2013-2022 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)
import os.path
from spack import *
class Varscan(Package):
"""Variant calling and somatic mutation/CNV detection for next-generation
sequencing data"""
homepage = "https://dkoboldt.github.io/varscan/"
url = "https://github.com/dkoboldt/varscan/releases/download/2.4.2/VarScan.v2.4.2.jar"
version('2.4.2', sha256='34ff6462f91fb6ed3f11e867ab4a179efae5dd8214b97fa261fc616f23d4d031', expand=False)
depends_on('java', type=('build', 'run'))
def install(self, spec, prefix):
mkdirp(prefix.bin)
mkdirp(prefix.jar)
jar_file = 'VarScan.v{v}.jar'.format(v=self.version.dotted)
install(jar_file, prefix.jar)
script_sh = join_path(os.path.dirname(__file__), "varscan.sh")
script = prefix.bin.varscan
install(script_sh, script)
set_executable(script)
java = join_path(self.spec['java'].prefix, 'bin', 'java')
kwargs = {'ignore_absent': False, 'backup': False, 'string': False}
filter_file('^java', java, script, **kwargs)
filter_file('varscan.jar', join_path(prefix.jar, jar_file),
script, **kwargs)
def setup_run_environment(self, env):
env.set('VARSCAN_HOME', self.prefix.jar)
env.set('CLASSPATH', self.prefix.jar)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-biocfilecache/package.py
|
<reponame>player1537-forks/spack<gh_stars>10-100
# Copyright 2013-2022 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 RBiocfilecache(RPackage):
"""Manage Files Across Sessions.
This package creates a persistent on-disk cache of files that the user
can add, update, and retrieve. It is useful for managing resources (such
as custom Txdb objects) that are costly or difficult to create, web
resources, and data files used across sessions."""
bioc = "BiocFileCache"
version('2.2.1', commit='<KEY>')
version('1.14.0', commit='cdcde4b59ae73dda12aa225948dbd0a058d9be6d')
version('1.8.0', commit='<KEY>')
version('1.6.0', commit='c2de6c1cdef6294e5d0adea31e4ebf25865742ba')
version('1.4.0', commit='a2c473d17f78899c7899b9638faea8c30735eb80')
version('1.2.3', commit='<KEY>')
version('1.0.1', commit='dbf4e8dd4d8d9f475066cd033481efe95c56df75')
depends_on('r@3.4.0:', type=('build', 'run'))
depends_on('r-dplyr', type=('build', 'run'))
depends_on('r-dbplyr@1.0.0:', type=('build', 'run'), when='@1.2.3:')
depends_on('r-rsqlite', type=('build', 'run'))
depends_on('r-dbi', type=('build', 'run'))
depends_on('r-rappdirs', type=('build', 'run'))
depends_on('r-filelock', type=('build', 'run'), when='@2.2.1:')
depends_on('r-curl', type=('build', 'run'), when='@1.6.0:')
depends_on('r-httr', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/libxft/package.py
|
# Copyright 2013-2022 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 Libxft(AutotoolsPackage, XorgPackage):
"""X FreeType library.
Xft version 2.1 was the first stand alone release of Xft, a library that
connects X applications with the FreeType font rasterization library. Xft
uses fontconfig to locate fonts so it has no configuration files."""
homepage = "https://cgit.freedesktop.org/xorg/lib/libXft"
xorg_mirror_path = "lib/libXft-2.3.2.tar.gz"
version('2.3.2', sha256='26cdddcc70b187833cbe9dc54df1864ba4c03a7175b2ca9276de9f05dce74507')
depends_on('freetype@2.1.6:')
depends_on('fontconfig@2.5.92:')
depends_on('libx11')
depends_on('libxrender@0.8.2:')
depends_on('pkgconfig', type='build')
depends_on('util-macros', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/arm/package.py
|
<filename>var/spack/repos/builtin/packages/arm/package.py
# Copyright 2013-2022 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)
import re
from spack import *
_os_map = {
'ubuntu18.04': 'Ubuntu-18.04',
'ubuntu20.04': 'Ubuntu-20.04',
'sles15': 'SLES-15',
'centos7': 'RHEL-7',
'centos8': 'RHEL-8',
'amzn2': 'RHEL-7'
}
_versions = {
'21.0': {
'RHEL-7': (
'fa67a4b9c1e562ec73e270aa4ef7a969af99bdd792ce8916b69ee47f7906110b',
'https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/21-0/ACfL/arm-compiler-for-linux_21.0_RHEL-7_aarch64.tar'
),
'RHEL-8': (
'a1bf517fc108100878233610ec5cc9538ee09cd114670bfacab0419bbdef0780',
'https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/21-0/ACfL/arm-compiler-for-linux_21.0_RHEL-8_aarch64.tar'
),
'SLES-15': (
'0307c67425fcf6c2c171c16732353767f79a7dd45e77cd7e4d94675d769cce77',
'https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/21-0/ACfL/arm-compiler-for-linux_21.0_SLES-15_aarch64.tar'
),
'Ubuntu-18.04': (
'f57bd4652ea87282705073ea81ca108fef8e0725eb4bc441240ec2fc51ff5980',
'https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/21-0/ACfL/arm-compiler-for-linux_21.0_Ubuntu-18.04_aarch64.tar'
),
'Ubuntu-20.04': (
'dd93254b9fe9baa802baebb9da5d00e0076a639b47f3515a8645b06742900eea',
'https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/21-0/ACfL/arm-compiler-for-linux_21.0_Ubuntu-20.04_aarch64.tar'
)
}
}
def get_os():
spack_os = spack.platforms.host().default_os
return _os_map.get(spack_os, 'RHEL-7')
def get_acfl_prefix(spec):
acfl_prefix = spec.prefix
return join_path(
acfl_prefix,
'arm-linux-compiler-{0}_Generic-AArch64_{1}_aarch64-linux'.format(
spec.version,
get_os()
)
)
class Arm(Package):
"""Arm Compiler combines the optimized tools and libraries from Arm
with a modern LLVM-based compiler framework.
"""
homepage = "https://developer.arm.com/tools-and-software/server-and-hpc/arm-allinea-studio"
url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-allinea-studio/20-2-1/Ubuntu16.04/arm-compiler-for-linux_20.2.1_Ubuntu-16.04_aarch64.tar"
maintainers = ['OliverPerks']
# Build Versions: establish OS for URL
acfl_os = get_os()
# Build Versions
for ver, packages in _versions.items():
pkg = packages.get(acfl_os)
if pkg:
version(ver, sha256=pkg[0], url=pkg[1])
# Only install for Aarch64
conflicts('target=x86_64:', msg='Only available on Aarch64')
conflicts('target=ppc64:', msg='Only available on Aarch64')
conflicts('target=ppc64le:', msg='Only available on Aarch64')
executables = [r'armclang', r'armclang\+\+', r'armflang']
# Licensing
license_required = True
license_comment = "#"
license_files = ["licences/Licence"]
license_vars = ["ARM_LICENSE_DIR"]
license_url = "https://developer.arm.com/tools-and-software/server-and-hpc/help/help-and-tutorials/system-administration/licensing/arm-licence-server"
# Run the installer with the desired install directory
def install(self, spec, prefix):
exe = Executable('./arm-compiler-for-linux_{0}_{1}.sh'.format(
spec.version, get_os())
)
exe("--accept", "--force", "--install-to", prefix)
@classmethod
def determine_version(cls, exe):
regex_str = r'Arm C\/C\+\+\/Fortran Compiler version ([\d\.]+) '\
r'\(build number (\d+)\) '
version_regex = re.compile(regex_str)
try:
output = spack.compiler.get_compiler_version_output(
exe, '--version'
)
match = version_regex.search(output)
if match:
if match.group(1).count('.') == 1:
return match.group(1) + ".0." + match.group(2)
return match.group(1) + "." + match.group(2)
except spack.util.executable.ProcessError:
pass
except Exception as e:
tty.debug(e)
@classmethod
def determine_variants(cls, exes, version_str):
compilers = {}
for exe in exes:
if 'armclang' in exe:
compilers['c'] = exe
if 'armclang++' in exe:
compilers['cxx'] = exe
if 'armflang' in exe:
compilers['fortran'] = exe
return '', {'compilers': compilers}
@property
def cc(self):
msg = "cannot retrieve C compiler [spec is not concrete]"
assert self.spec.concrete, msg
if self.spec.external:
return self.spec.extra_attributes['compilers'].get('c', None)
return join_path(get_acfl_prefix(self.spec), 'bin', 'armclang')
@property
def cxx(self):
msg = "cannot retrieve C++ compiler [spec is not concrete]"
assert self.spec.concrete, msg
if self.spec.external:
return self.spec.extra_attributes['compilers'].get('cxx', None)
return join_path(get_acfl_prefix(self.spec), 'bin', 'armclang++')
@property
def fortran(self):
msg = "cannot retrieve Fortran compiler [spec is not concrete]"
assert self.spec.concrete, msg
if self.spec.external:
return self.spec.extra_attributes['compilers'].get('fortran', None)
return join_path(get_acfl_prefix(self.spec), 'bin', 'armflang')
def setup_run_environment(self, env):
arm_dir = get_acfl_prefix(self.spec)
env.set("ARM_LINUX_COMPILER_DIR", arm_dir)
env.set("ARM_LINUX_COMPILER_INCLUDES", join_path(arm_dir, 'includes'))
env.prepend_path("LD_LIBRARY_PATH", join_path(arm_dir, 'lib'))
env.prepend_path("PATH", join_path(arm_dir, 'bin'))
env.prepend_path("CPATH", join_path(arm_dir, 'include'))
env.prepend_path("MANPATH", join_path(arm_dir, 'share', 'man'))
env.prepend_path("ARM_LICENSE_DIR", join_path(self.prefix, 'licences'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/intel-ipp/package.py
|
# Copyright 2013-2022 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 IntelIpp(IntelPackage):
"""Intel Integrated Performance Primitives."""
homepage = "https://software.intel.com/en-us/intel-ipp"
version('2020.2.254', sha256='18266ad1eec9b5b17e76da24f1aa9a9147300e5bd345e6bdad58d7187392fa77',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/16846/l_ipp_2020.2.254.tgz')
version('2020.1.217', sha256='0bf8ac7e635e7e602cf201063a1a7dea3779b093104563fdb15e6b7ecf2f00a7',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/16534/l_ipp_2020.1.217.tgz')
version('2020.0.166', sha256='6844007892ba524e828f245355cee44e8149f4c233abbbea16f7bb55a7d6ecff',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/16233/l_ipp_2020.0.166.tgz')
version('2019.5.281', sha256='61d1e1da1a4a50f1cf02a3ed44e87eed05e94d58b64ef1e67a3bdec363bee713',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/15817/l_ipp_2019.5.281.tgz')
version('2019.4.243', sha256='d4f4232323e66b010d8440c75189aeb6a3249966e05035242b21982238a7a7f2',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/15541/l_ipp_2019.4.243.tgz')
version('2019.3.199', sha256='02545383206c1ae4dd66bfa6a38e2e14480ba11932eeed632df8ab798aa15ccd',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/15276/l_ipp_2019.3.199.tgz')
version('2019.2.187', sha256='280e9081278a0db3892fe82474c1201ec780a6f7c8d1f896494867f4b3bd8421',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/15096/l_ipp_2019.2.187.tgz')
version('2019.1.144', sha256='1eb7cd0fba74615aeafa4e314c645414497eb73f1705200c524fe78f00620db3',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/14887/l_ipp_2019.1.144.tgz')
version('2019.0.117', sha256='d552ba49fba58f0e94da2048176f21c5dfd490dca7c5ce666dfc2d18db7fd551',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/13576/l_ipp_2019.0.117.tgz')
version('2018.4.274', sha256='bdc6082c65410c98ccf6daf239e0a6625d15ec5e0ddc1c0563aad42b6ba9063c',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/13726/l_ipp_2018.4.274.tgz')
version('2018.3.222', sha256='bb783c5e6220e240f19136ae598cd1c1d647496495139ce680de58d3d5496934',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/13006/l_ipp_2018.3.222.tgz')
version('2018.2.199', sha256='55cb5c910b2c1e2bd798163fb5019b992b1259a0692e328bb9054778cf01562b',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/12726/l_ipp_2018.2.199.tgz')
version('2018.0.128', sha256='da568ceec1b7acbcc8f666b73d4092788b037b1b03c0436974b82155056ed166',
url='http://registrationcenter-download.intel.com/akdlm/irc_nas/tec/12071/l_ipp_2018.0.128.tgz')
version('2017.3.196', sha256='50d49a1000a88a8a58bd610466e90ae28d07a70993a78cbbf85d44d27c4232b6',
url='http://registrationcenter-download.intel.com/akdlm/irc_nas/tec/11545/l_ipp_2017.3.196.tgz')
version('2017.2.174', sha256='92f866c9dce8503d7e04223ec35f281cfeb0b81cf94208c3becb11aacfda7b99',
url='http://registrationcenter-download.intel.com/akdlm/irc_nas/tec/11307/l_ipp_2017.2.174.tgz')
version('2017.1.132', sha256='2908bdeab3057d4ebcaa0b8ff5b00eb47425d35961a96f14780be68554d95376',
url='http://registrationcenter-download.intel.com/akdlm/irc_nas/tec/11031/l_ipp_2017.1.132.tgz')
version('2017.0.098', sha256='7633d16e2578be64533892336c8a15c905139147b0f74eaf9f281358ad7cdcba',
url='http://registrationcenter-download.intel.com/akdlm/irc_nas/tec/9663/l_ipp_2017.0.098.tgz')
# built from parallel_studio_xe_2016.3.067
version('192.168.127.12', sha256='8ce7bf17f4a0bbf8c441063de26be7f6e0f6179789e23f24eaa8b712632b3cdd',
url='https://registrationcenter-download.intel.com/akdlm/irc_nas/tec/9067/l_ipp_9.0.3.210.tgz')
provides('ipp')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-ggtree/package.py
|
# Copyright 2013-2022 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 RGgtree(RPackage):
"""an R package for visualization of tree and annotation data.
'ggtree' extends the 'ggplot2' plotting system which implemented the
grammar of graphics. 'ggtree' is designed for visualization and annotation
of phylogenetic trees and other tree-like structures with their annotation
data."""
bioc = "ggtree"
version('3.2.1', commit='<PASSWORD>')
depends_on('r@3.5.0:', type=('build', 'run'))
depends_on('r-ape', type=('build', 'run'))
depends_on('r-aplot@0.0.4:', type=('build', 'run'))
depends_on('r-dplyr', type=('build', 'run'))
depends_on('r-ggplot2@3.0.0:', type=('build', 'run'))
depends_on('r-magrittr', type=('build', 'run'))
depends_on('r-purrr', type=('build', 'run'))
depends_on('r-rlang', type=('build', 'run'))
depends_on('r-ggfun', type=('build', 'run'))
depends_on('r-yulab-utils', type=('build', 'run'))
depends_on('r-tidyr', type=('build', 'run'))
depends_on('r-tidytree@0.2.6:', type=('build', 'run'))
depends_on('r-treeio@1.8.0:', type=('build', 'run'))
depends_on('r-scales', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/esys-particle/package.py
|
# Copyright 2013-2022 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 llnl.util.filesystem import find
from spack import *
class EsysParticle(CMakePackage):
"""ESyS-Particle is Open Source software for particle-based numerical
modelling. The software implements the Discrete Element Method (DEM),
a widely used technique for modelling processes involving large
deformations, granular flow and/or fragmentation."""
homepage = "https://launchpad.net/esys-particle"
url = "https://launchpadlibrarian.net/539636757/esys-particle-3.0-alpha.tar.gz"
maintainers = ['snehring']
version('3.0-alpha', sha256='4fba856a95c93991cacb904e6a54a7ded93558f7adc8c3e6da99bc347843a434')
depends_on('mpi')
depends_on('boost@1.71.0+python')
depends_on('python@3.6:')
depends_on('py-setuptools', type='build')
@when('@3.0-alpha')
def patch(self):
files = find('.', 'CMakeLists.txt')
for file in files:
filter_file('PYTHON_LIBRARIES', 'Python_LIBRARIES',
file, string=True)
def setup_run_environment(self, env):
pylibpath = join_path(self.prefix.lib, "python{0}".format(
self.spec["python"].version.up_to(2)))
env.prepend_path('PYTHONPATH', join_path(pylibpath, 'dist-packages'))
|
player1537-forks/spack
|
var/spack/repos/builtin.mock/packages/cumulative-vrange-root/package.py
|
# Copyright 2013-2022 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)
class CumulativeVrangeRoot(Package):
"""Test that creating cumulative version ranges of the
form X.Y:X works and allows for the selection of all the
versions >= X.Y with major == X
"""
homepage = 'https://www.example.org'
url = 'https://example.org/files/v3.4/cmake-3.4.3.tar.gz'
version('1.0', '4cb3ff35b2472aae70f542116d616e63')
depends_on('cumulative-vrange-middle')
depends_on('cumulative-vrange-bottom@:2')
|
player1537-forks/spack
|
lib/spack/external/jinja2/utils.py
|
<filename>lib/spack/external/jinja2/utils.py
# -*- coding: utf-8 -*-
import json
import os
import re
import warnings
from collections import deque
from random import choice
from random import randrange
from string import ascii_letters as _letters
from string import digits as _digits
from threading import Lock
from markupsafe import escape
from markupsafe import Markup
from ._compat import abc
from ._compat import string_types
from ._compat import text_type
from ._compat import url_quote
# special singleton representing missing values for the runtime
missing = type("MissingType", (), {"__repr__": lambda x: "missing"})()
# internal code
internal_code = set()
concat = u"".join
_slash_escape = "\\/" not in json.dumps("/")
def contextfunction(f):
"""This decorator can be used to mark a function or method context callable.
A context callable is passed the active :class:`Context` as first argument when
called from the template. This is useful if a function wants to get access
to the context or functions provided on the context object. For example
a function that returns a sorted list of template variables the current
template exports could look like this::
@contextfunction
def get_exported_names(context):
return sorted(context.exported_vars)
"""
f.contextfunction = True
return f
def evalcontextfunction(f):
"""This decorator can be used to mark a function or method as an eval
context callable. This is similar to the :func:`contextfunction`
but instead of passing the context, an evaluation context object is
passed. For more information about the eval context, see
:ref:`eval-context`.
.. versionadded:: 2.4
"""
f.evalcontextfunction = True
return f
def environmentfunction(f):
"""This decorator can be used to mark a function or method as environment
callable. This decorator works exactly like the :func:`contextfunction`
decorator just that the first argument is the active :class:`Environment`
and not context.
"""
f.environmentfunction = True
return f
def internalcode(f):
"""Marks the function as internally used"""
internal_code.add(f.__code__)
return f
def is_undefined(obj):
"""Check if the object passed is undefined. This does nothing more than
performing an instance check against :class:`Undefined` but looks nicer.
This can be used for custom filters or tests that want to react to
undefined variables. For example a custom default filter can look like
this::
def default(var, default=''):
if is_undefined(var):
return default
return var
"""
from .runtime import Undefined
return isinstance(obj, Undefined)
def consume(iterable):
"""Consumes an iterable without doing anything with it."""
for _ in iterable:
pass
def clear_caches():
"""Jinja keeps internal caches for environments and lexers. These are
used so that Jinja doesn't have to recreate environments and lexers all
the time. Normally you don't have to care about that but if you are
measuring memory consumption you may want to clean the caches.
"""
from .environment import _spontaneous_environments
from .lexer import _lexer_cache
_spontaneous_environments.clear()
_lexer_cache.clear()
def import_string(import_name, silent=False):
"""Imports an object based on a string. This is useful if you want to
use import paths as endpoints or something similar. An import path can
be specified either in dotted notation (``xml.sax.saxutils.escape``)
or with a colon as object delimiter (``xml.sax.saxutils:escape``).
If the `silent` is True the return value will be `None` if the import
fails.
:return: imported object
"""
try:
if ":" in import_name:
module, obj = import_name.split(":", 1)
elif "." in import_name:
module, _, obj = import_name.rpartition(".")
else:
return __import__(import_name)
return getattr(__import__(module, None, None, [obj]), obj)
except (ImportError, AttributeError):
if not silent:
raise
def open_if_exists(filename, mode="rb"):
"""Returns a file descriptor for the filename if that file exists,
otherwise ``None``.
"""
if not os.path.isfile(filename):
return None
return open(filename, mode)
def object_type_repr(obj):
"""Returns the name of the object's type. For some recognized
singletons the name of the object is returned instead. (For
example for `None` and `Ellipsis`).
"""
if obj is None:
return "None"
elif obj is Ellipsis:
return "Ellipsis"
cls = type(obj)
# __builtin__ in 2.x, builtins in 3.x
if cls.__module__ in ("__builtin__", "builtins"):
name = cls.__name__
else:
name = cls.__module__ + "." + cls.__name__
return "%s object" % name
def pformat(obj, verbose=False):
"""Prettyprint an object. Either use the `pretty` library or the
builtin `pprint`.
"""
try:
from pretty import pretty
return pretty(obj, verbose=verbose)
except ImportError:
from pprint import pformat
return pformat(obj)
def urlize(text, trim_url_limit=None, rel=None, target=None):
"""Converts any URLs in text into clickable links. Works on http://,
https:// and www. links. Links can have trailing punctuation (periods,
commas, close-parens) and leading punctuation (opening parens) and
it'll still do the right thing.
If trim_url_limit is not None, the URLs in link text will be limited
to trim_url_limit characters.
If nofollow is True, the URLs in link text will get a rel="nofollow"
attribute.
If target is not None, a target attribute will be added to the link.
"""
trim_url = (
lambda x, limit=trim_url_limit: limit is not None
and (x[:limit] + (len(x) >= limit and "..." or ""))
or x
)
words = re.split(r"(\s+)", text_type(escape(text)))
rel_attr = rel and ' rel="%s"' % text_type(escape(rel)) or ""
target_attr = target and ' target="%s"' % escape(target) or ""
for i, word in enumerate(words):
head, middle, tail = "", word, ""
match = re.match(r"^([(<]|<)+", middle)
if match:
head = match.group()
middle = middle[match.end() :]
# Unlike lead, which is anchored to the start of the string,
# need to check that the string ends with any of the characters
# before trying to match all of them, to avoid backtracking.
if middle.endswith((")", ">", ".", ",", "\n", ">")):
match = re.search(r"([)>.,\n]|>)+$", middle)
if match:
tail = match.group()
middle = middle[: match.start()]
if middle.startswith("www.") or (
"@" not in middle
and not middle.startswith("http://")
and not middle.startswith("https://")
and len(middle) > 0
and middle[0] in _letters + _digits
and (
middle.endswith(".org")
or middle.endswith(".net")
or middle.endswith(".com")
)
):
middle = '<a href="http://%s"%s%s>%s</a>' % (
middle,
rel_attr,
target_attr,
trim_url(middle),
)
if middle.startswith("http://") or middle.startswith("https://"):
middle = '<a href="%s"%s%s>%s</a>' % (
middle,
rel_attr,
target_attr,
trim_url(middle),
)
if (
"@" in middle
and not middle.startswith("www.")
and ":" not in middle
and re.match(r"^\S+@\w[\w.-]*\.\w+$", middle)
):
middle = '<a href="mailto:%s">%s</a>' % (middle, middle)
words[i] = head + middle + tail
return u"".join(words)
def generate_lorem_ipsum(n=5, html=True, min=20, max=100):
"""Generate some lorem ipsum for the template."""
from .constants import LOREM_IPSUM_WORDS
words = LOREM_IPSUM_WORDS.split()
result = []
for _ in range(n):
next_capitalized = True
last_comma = last_fullstop = 0
word = None
last = None
p = []
# each paragraph contains out of 20 to 100 words.
for idx, _ in enumerate(range(randrange(min, max))):
while True:
word = choice(words)
if word != last:
last = word
break
if next_capitalized:
word = word.capitalize()
next_capitalized = False
# add commas
if idx - randrange(3, 8) > last_comma:
last_comma = idx
last_fullstop += 2
word += ","
# add end of sentences
if idx - randrange(10, 20) > last_fullstop:
last_comma = last_fullstop = idx
word += "."
next_capitalized = True
p.append(word)
# ensure that the paragraph ends with a dot.
p = u" ".join(p)
if p.endswith(","):
p = p[:-1] + "."
elif not p.endswith("."):
p += "."
result.append(p)
if not html:
return u"\n\n".join(result)
return Markup(u"\n".join(u"<p>%s</p>" % escape(x) for x in result))
def unicode_urlencode(obj, charset="utf-8", for_qs=False):
"""Quote a string for use in a URL using the given charset.
This function is misnamed, it is a wrapper around
:func:`urllib.parse.quote`.
:param obj: String or bytes to quote. Other types are converted to
string then encoded to bytes using the given charset.
:param charset: Encode text to bytes using this charset.
:param for_qs: Quote "/" and use "+" for spaces.
"""
if not isinstance(obj, string_types):
obj = text_type(obj)
if isinstance(obj, text_type):
obj = obj.encode(charset)
safe = b"" if for_qs else b"/"
rv = url_quote(obj, safe)
if not isinstance(rv, text_type):
rv = rv.decode("utf-8")
if for_qs:
rv = rv.replace("%20", "+")
return rv
class LRUCache(object):
"""A simple LRU Cache implementation."""
# this is fast for small capacities (something below 1000) but doesn't
# scale. But as long as it's only used as storage for templates this
# won't do any harm.
def __init__(self, capacity):
self.capacity = capacity
self._mapping = {}
self._queue = deque()
self._postinit()
def _postinit(self):
# alias all queue methods for faster lookup
self._popleft = self._queue.popleft
self._pop = self._queue.pop
self._remove = self._queue.remove
self._wlock = Lock()
self._append = self._queue.append
def __getstate__(self):
return {
"capacity": self.capacity,
"_mapping": self._mapping,
"_queue": self._queue,
}
def __setstate__(self, d):
self.__dict__.update(d)
self._postinit()
def __getnewargs__(self):
return (self.capacity,)
def copy(self):
"""Return a shallow copy of the instance."""
rv = self.__class__(self.capacity)
rv._mapping.update(self._mapping)
rv._queue.extend(self._queue)
return rv
def get(self, key, default=None):
"""Return an item from the cache dict or `default`"""
try:
return self[key]
except KeyError:
return default
def setdefault(self, key, default=None):
"""Set `default` if the key is not in the cache otherwise
leave unchanged. Return the value of this key.
"""
try:
return self[key]
except KeyError:
self[key] = default
return default
def clear(self):
"""Clear the cache."""
self._wlock.acquire()
try:
self._mapping.clear()
self._queue.clear()
finally:
self._wlock.release()
def __contains__(self, key):
"""Check if a key exists in this cache."""
return key in self._mapping
def __len__(self):
"""Return the current size of the cache."""
return len(self._mapping)
def __repr__(self):
return "<%s %r>" % (self.__class__.__name__, self._mapping)
def __getitem__(self, key):
"""Get an item from the cache. Moves the item up so that it has the
highest priority then.
Raise a `KeyError` if it does not exist.
"""
self._wlock.acquire()
try:
rv = self._mapping[key]
if self._queue[-1] != key:
try:
self._remove(key)
except ValueError:
# if something removed the key from the container
# when we read, ignore the ValueError that we would
# get otherwise.
pass
self._append(key)
return rv
finally:
self._wlock.release()
def __setitem__(self, key, value):
"""Sets the value for an item. Moves the item up so that it
has the highest priority then.
"""
self._wlock.acquire()
try:
if key in self._mapping:
self._remove(key)
elif len(self._mapping) == self.capacity:
del self._mapping[self._popleft()]
self._append(key)
self._mapping[key] = value
finally:
self._wlock.release()
def __delitem__(self, key):
"""Remove an item from the cache dict.
Raise a `KeyError` if it does not exist.
"""
self._wlock.acquire()
try:
del self._mapping[key]
try:
self._remove(key)
except ValueError:
pass
finally:
self._wlock.release()
def items(self):
"""Return a list of items."""
result = [(key, self._mapping[key]) for key in list(self._queue)]
result.reverse()
return result
def iteritems(self):
"""Iterate over all items."""
warnings.warn(
"'iteritems()' will be removed in version 3.0. Use"
" 'iter(cache.items())' instead.",
DeprecationWarning,
stacklevel=2,
)
return iter(self.items())
def values(self):
"""Return a list of all values."""
return [x[1] for x in self.items()]
def itervalue(self):
"""Iterate over all values."""
warnings.warn(
"'itervalue()' will be removed in version 3.0. Use"
" 'iter(cache.values())' instead.",
DeprecationWarning,
stacklevel=2,
)
return iter(self.values())
def itervalues(self):
"""Iterate over all values."""
warnings.warn(
"'itervalues()' will be removed in version 3.0. Use"
" 'iter(cache.values())' instead.",
DeprecationWarning,
stacklevel=2,
)
return iter(self.values())
def keys(self):
"""Return a list of all keys ordered by most recent usage."""
return list(self)
def iterkeys(self):
"""Iterate over all keys in the cache dict, ordered by
the most recent usage.
"""
warnings.warn(
"'iterkeys()' will be removed in version 3.0. Use"
" 'iter(cache.keys())' instead.",
DeprecationWarning,
stacklevel=2,
)
return iter(self)
def __iter__(self):
return reversed(tuple(self._queue))
def __reversed__(self):
"""Iterate over the keys in the cache dict, oldest items
coming first.
"""
return iter(tuple(self._queue))
__copy__ = copy
abc.MutableMapping.register(LRUCache)
def select_autoescape(
enabled_extensions=("html", "htm", "xml"),
disabled_extensions=(),
default_for_string=True,
default=False,
):
"""Intelligently sets the initial value of autoescaping based on the
filename of the template. This is the recommended way to configure
autoescaping if you do not want to write a custom function yourself.
If you want to enable it for all templates created from strings or
for all templates with `.html` and `.xml` extensions::
from jinja2 import Environment, select_autoescape
env = Environment(autoescape=select_autoescape(
enabled_extensions=('html', 'xml'),
default_for_string=True,
))
Example configuration to turn it on at all times except if the template
ends with `.txt`::
from jinja2 import Environment, select_autoescape
env = Environment(autoescape=select_autoescape(
disabled_extensions=('txt',),
default_for_string=True,
default=True,
))
The `enabled_extensions` is an iterable of all the extensions that
autoescaping should be enabled for. Likewise `disabled_extensions` is
a list of all templates it should be disabled for. If a template is
loaded from a string then the default from `default_for_string` is used.
If nothing matches then the initial value of autoescaping is set to the
value of `default`.
For security reasons this function operates case insensitive.
.. versionadded:: 2.9
"""
enabled_patterns = tuple("." + x.lstrip(".").lower() for x in enabled_extensions)
disabled_patterns = tuple("." + x.lstrip(".").lower() for x in disabled_extensions)
def autoescape(template_name):
if template_name is None:
return default_for_string
template_name = template_name.lower()
if template_name.endswith(enabled_patterns):
return True
if template_name.endswith(disabled_patterns):
return False
return default
return autoescape
def htmlsafe_json_dumps(obj, dumper=None, **kwargs):
"""Works exactly like :func:`dumps` but is safe for use in ``<script>``
tags. It accepts the same arguments and returns a JSON string. Note that
this is available in templates through the ``|tojson`` filter which will
also mark the result as safe. Due to how this function escapes certain
characters this is safe even if used outside of ``<script>`` tags.
The following characters are escaped in strings:
- ``<``
- ``>``
- ``&``
- ``'``
This makes it safe to embed such strings in any place in HTML with the
notable exception of double quoted attributes. In that case single
quote your attributes or HTML escape it in addition.
"""
if dumper is None:
dumper = json.dumps
rv = (
dumper(obj, **kwargs)
.replace(u"<", u"\\u003c")
.replace(u">", u"\\u003e")
.replace(u"&", u"\\u0026")
.replace(u"'", u"\\u0027")
)
return Markup(rv)
class Cycler(object):
"""Cycle through values by yield them one at a time, then restarting
once the end is reached. Available as ``cycler`` in templates.
Similar to ``loop.cycle``, but can be used outside loops or across
multiple loops. For example, render a list of folders and files in a
list, alternating giving them "odd" and "even" classes.
.. code-block:: html+jinja
{% set row_class = cycler("odd", "even") %}
<ul class="browser">
{% for folder in folders %}
<li class="folder {{ row_class.next() }}">{{ folder }}
{% endfor %}
{% for file in files %}
<li class="file {{ row_class.next() }}">{{ file }}
{% endfor %}
</ul>
:param items: Each positional argument will be yielded in the order
given for each cycle.
.. versionadded:: 2.1
"""
def __init__(self, *items):
if not items:
raise RuntimeError("at least one item has to be provided")
self.items = items
self.pos = 0
def reset(self):
"""Resets the current item to the first item."""
self.pos = 0
@property
def current(self):
"""Return the current item. Equivalent to the item that will be
returned next time :meth:`next` is called.
"""
return self.items[self.pos]
def next(self):
"""Return the current item, then advance :attr:`current` to the
next item.
"""
rv = self.current
self.pos = (self.pos + 1) % len(self.items)
return rv
__next__ = next
class Joiner(object):
"""A joining helper for templates."""
def __init__(self, sep=u", "):
self.sep = sep
self.used = False
def __call__(self):
if not self.used:
self.used = True
return u""
return self.sep
class Namespace(object):
"""A namespace object that can hold arbitrary attributes. It may be
initialized from a dictionary or with keyword arguments."""
def __init__(*args, **kwargs): # noqa: B902
self, args = args[0], args[1:]
self.__attrs = dict(*args, **kwargs)
def __getattribute__(self, name):
# __class__ is needed for the awaitable check in async mode
if name in {"_Namespace__attrs", "__class__"}:
return object.__getattribute__(self, name)
try:
return self.__attrs[name]
except KeyError:
raise AttributeError(name)
def __setitem__(self, name, value):
self.__attrs[name] = value
def __repr__(self):
return "<Namespace %r>" % self.__attrs
# does this python version support async for in and async generators?
try:
exec("async def _():\n async for _ in ():\n yield _")
have_async_gen = True
except SyntaxError:
have_async_gen = False
def soft_unicode(s):
from markupsafe import soft_unicode
warnings.warn(
"'jinja2.utils.soft_unicode' will be removed in version 3.0."
" Use 'markupsafe.soft_unicode' instead.",
DeprecationWarning,
stacklevel=2,
)
return soft_unicode(s)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/aspera-cli/package.py
|
<filename>var/spack/repos/builtin/packages/aspera-cli/package.py<gh_stars>10-100
# Copyright 2013-2022 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 glob import glob
from spack import *
class AsperaCli(Package):
"""The Aspera CLI client for the Fast and Secure Protocol (FASP)."""
homepage = "https://asperasoft.com"
url = "https://download.asperasoft.com/download/sw/cli/3.7.7/aspera-cli-3.7.7.608.927cce8-linux-64-release.sh"
version('3.7.7', sha256='83efd03b699bdb1cac6c62befb3812342d6122217f4944f732ae7a135d578966',
url='https://download.asperasoft.com/download/sw/cli/3.7.7/aspera-cli-3.7.7.608.927cce8-linux-64-release.sh',
expand=False)
def setup_run_environment(self, env):
env.prepend_path('PATH', self.prefix.cli.bin)
def install(self, spec, prefix):
runfile = glob(join_path(self.stage.source_path, 'aspera-cli*.sh'))[0]
# Update destination path
filter_file('INSTALL_DIR=~/.aspera',
'INSTALL_DIR=%s' % prefix,
runfile,
string=True,
stop_at='__ARCHIVE_FOLLOWS__')
# Install
chmod = which('chmod')
chmod('+x', runfile)
runfile = which(runfile)
runfile()
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/abinit/package.py
|
# Copyright 2013-2022 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)
#
# Author: <NAME> <matteo.giantomassiNOSPAM AT uclouvain.be>
# Date: October 11, 2016
from spack import *
class Abinit(AutotoolsPackage):
"""ABINIT is a package whose main program allows one to find the total
energy, charge density and electronic structure of systems made of
electrons and nuclei (molecules and periodic solids) within
Density Functional Theory (DFT), using pseudopotentials and a planewave
or wavelet basis.
ABINIT also includes options to optimize the geometry according to the
DFT forces and stresses, or to perform molecular dynamics
simulations using these forces, or to generate dynamical matrices,
Born effective charges, and dielectric tensors, based on Density-Functional
Perturbation Theory, and many more properties. Excited states can be
computed within the Many-Body Perturbation Theory (the GW approximation and
the Bethe-Salpeter equation), and Time-Dependent Density Functional Theory
(for molecules). In addition to the main ABINIT code, different utility
programs are provided.
"""
homepage = 'https://www.abinit.org/'
url = 'https://www.abinit.org/sites/default/files/packages/abinit-8.6.3.tar.gz'
version('9.6.1', sha256='b6a12760fd728eb4aacca431ae12150609565bedbaa89763f219fcd869f79ac6')
version('9.4.2', sha256='d40886f5c8b138bb4aa1ca05da23388eb70a682790cfe5020ecce4db1b1a76bc')
version('8.10.3', sha256='ed626424b4472b93256622fbb9c7645fa3ffb693d4b444b07d488771ea7eaa75')
version('8.10.2', sha256='4ee2e0329497bf16a9b2719fe0536cc50c5d5a07c65e18edaf15ba02251cbb73')
version('8.8.2', sha256='15216703bd56a799a249a112b336d07d733627d3756487a4b1cb48ebb625c3e7')
version('8.6.3', sha256='82e8d071088ab8dc1b3a24380e30b68c544685678314df1213180b449c84ca65')
version('8.2.2', sha256='e43544a178d758b0deff3011c51ef7c957d7f2df2ce8543366d68016af9f3ea1')
# Versions before 8.0.8b are not supported.
version('8.0.8b', sha256='37ad5f0f215d2a36e596383cb6e54de3313842a0390ce8d6b48a423d3ee25af2')
variant('mpi', default=True,
description='Builds with MPI support. Requires MPI2+')
variant('openmp', default=False,
description='Enables OpenMP threads. Use threaded FFTW3')
variant('scalapack', default=False,
description='Enables scalapack support. Requires MPI')
variant('wannier90', default=False,
description='Enables the Wannier90 library')
variant('libxml2', default=False,
description='Enable libxml2 support, used by multibinit')
variant('optimization-flavor', default='standard', multi=False,
values=('safe', 'standard', 'aggressive'),
description='Select the optimization flavor to use.')
variant('install-tests', default=False,
description='Install test cases')
# Add dependencies
depends_on('atompaw')
depends_on('blas')
depends_on('lapack')
# Require MPI2+
depends_on('mpi@2:', when='+mpi')
depends_on('scalapack', when='+scalapack+mpi')
depends_on('fftw-api')
depends_on('netcdf-fortran')
depends_on('netcdf-c+mpi', when='+mpi')
depends_on('netcdf-c~mpi', when='~mpi')
depends_on('hdf5+mpi', when='+mpi')
depends_on('hdf5~mpi', when='~mpi')
depends_on("wannier90+shared", when='+wannier90+mpi')
# constrain libxc version
depends_on('libxc')
depends_on('libxc@:2', when='@:8')
# libxml2
depends_on('libxml2', when='@9:+libxml2')
# Cannot ask for +scalapack if it does not depend on MPI
conflicts('+scalapack', when='~mpi')
# Cannot ask for +wannier90 if it does not depend on MPI
conflicts('+wannier90', when='~mpi')
# libxml2 needs version 9 and above
conflicts('+libxml2', when='@:8')
conflicts('%gcc@7:', when='@:8.8')
conflicts('%gcc@9:', when='@:8.10')
# need openmp threading for abinit+openmp
# TODO: The logic here can be reversed with the new concretizer. Instead of
# using `conflicts`, `depends_on` could be used instead.
for fftw in ['amdfftw', 'cray-fftw', 'fujitsu-fftw', 'fftw']:
conflicts('+openmp', when='^{0}~openmp'.format(fftw),
msg='Need to request {0} +openmp'.format(fftw))
mkl_message = 'Need to set dependent variant to threads=openmp'
conflicts('+openmp',
when='^intel-mkl threads=none',
msg=mkl_message)
conflicts('+openmp',
when='^intel-mkl threads=tbb',
msg=mkl_message)
conflicts('+openmp',
when='^intel-parallel-studio +mkl threads=none',
msg=mkl_message)
conflicts('+openmp',
when='^fujitsu-ssl2 ~parallel',
msg='Need to request fujitsu-ssl2 +parallel')
conflicts('~openmp',
when='^fujitsu-ssl2 +parallel',
msg='Need to request fujitsu-ssl2 ~parallel')
patch('rm_march_settings.patch', when='@:8')
patch('rm_march_settings_v9.patch', when='@9:')
# Fix detection of Fujitsu compiler
# Fix configure not to collect the option that causes an error
# Fix intent(out) and unnecessary rewind to avoid compile error
patch('fix_for_fujitsu.patch', when='@:8 %fj')
patch('fix_for_fujitsu.v9.patch', when='@9: %fj')
def configure_args(self):
spec = self.spec
options = []
options += self.with_or_without('libxml2')
oapp = options.append
if '@:8' in spec:
oapp('--enable-optim={0}'
.format(self.spec.variants['optimization-flavor'].value))
else:
oapp('--with-optim-flavor={0}'
.format(self.spec.variants['optimization-flavor'].value))
if '+wannier90' in spec:
if '@:8' in spec:
oapp('--with-wannier90-libs=-L{0}'
.format(spec['wannier90'].prefix.lib + ' -lwannier -lm'))
oapp('--with-wannier90-incs=-I{0}'
.format(spec['wannier90'].prefix.modules))
oapp('--with-wannier90-bins={0}'
.format(spec['wannier90'].prefix.bin))
oapp('--enable-connectors')
oapp('--with-dft-flavor=atompaw+libxc+wannier90')
else:
options.extend([
'WANNIER90_CPPFLAGS=-I{0}'.format(
spec['wannier90'].prefix.modules),
'WANNIER90_LIBS=-L{0} {1}'.format(
spec['wannier90'].prefix.lib, '-lwannier'),
])
else:
if '@:8' in spec:
oapp('--with-dft-flavor=atompaw+libxc')
else:
'--without-wannier90',
if '+mpi' in spec:
oapp('CC={0}'.format(spec['mpi'].mpicc))
oapp('CXX={0}'.format(spec['mpi'].mpicxx))
oapp('FC={0}'.format(spec['mpi'].mpifc))
# MPI version:
# let the configure script auto-detect MPI support from mpi_prefix
if '@:8' in spec:
oapp('--enable-mpi=yes')
else:
oapp('--with-mpi')
else:
if '@:8' in spec:
oapp('--enable-mpi=no')
else:
oapp('--without-mpi')
# Activate OpenMP in Abinit Fortran code.
if '+openmp' in spec:
oapp('--enable-openmp=yes')
else:
oapp('--enable-openmp=no')
# BLAS/LAPACK/SCALAPACK-ELPA
linalg = spec['lapack'].libs + spec['blas'].libs
if '^mkl' in spec:
linalg_flavor = 'mkl'
elif '@9:' in spec and '^openblas' in spec:
linalg_flavor = 'openblas'
elif '@9:' in spec and '^fujitsu-ssl2' in spec:
linalg_flavor = 'openblas'
else:
linalg_flavor = 'custom'
if '+scalapack' in spec:
linalg = spec['scalapack'].libs + linalg
if '@:8' in spec:
linalg_flavor = 'scalapack+{0}'.format(linalg_flavor)
if '@:8' in spec:
oapp('--with-linalg-libs={0}'.format(linalg.ld_flags))
else:
oapp('LINALG_LIBS={0}'.format(linalg.ld_flags))
oapp('--with-linalg-flavor={0}'.format(linalg_flavor))
if '^mkl' in spec:
fftflavor = 'dfti'
else:
if '+openmp' in spec:
fftflavor, fftlibs = 'fftw3-threads', '-lfftw3_omp -lfftw3 -lfftw3f'
else:
fftflavor, fftlibs = 'fftw3', '-lfftw3 -lfftw3f'
oapp('--with-fft-flavor={0}'.format(fftflavor))
if '@:8' in spec:
if '^mkl' in spec:
oapp('--with-fft-incs={0}'.format(spec['fftw-api'].headers.cpp_flags))
oapp('--with-fft-libs={0}'.format(spec['fftw-api'].libs.ld_flags))
else:
options.extend([
'--with-fft-incs={0}'.format(spec['fftw-api'].headers.cpp_flags),
'--with-fft-libs=-L{0} {1}'.format(
spec['fftw-api'].prefix.lib, fftlibs),
])
else:
if '^mkl' in spec:
options.extend([
'FFT_CPPFLAGS={0}'.format(spec['fftw-api'].headers.cpp_flags),
'FFT_LIBs={0}'.format(spec['fftw-api'].libs.ld_flags),
])
else:
options.extend([
'FFTW3_CPPFLAGS={0}'.format(spec['fftw-api'].headers.cpp_flags),
'FFTW3_LIBS=-L{0} {1}'.format(
spec['fftw-api'].prefix.lib, fftlibs),
])
# LibXC library
libxc = spec['libxc:fortran']
if '@:8' in spec:
options.extend([
'--with-libxc-incs={0}'.format(libxc.headers.cpp_flags),
'--with-libxc-libs={0}'.format(libxc.libs.ld_flags + ' -lm')
])
else:
oapp('--with-libxc={0}'.format(libxc.prefix))
# Netcdf4/HDF5
hdf5 = spec['hdf5:hl']
netcdfc = spec['netcdf-c']
netcdff = spec['netcdf-fortran:shared']
if '@:8' in spec:
oapp('--with-trio-flavor=netcdf')
# Since version 8, Abinit started to use netcdf4 + hdf5 and we have
# to link with the high level HDF5 library
options.extend([
'--with-netcdf-incs={0}'.format(
netcdfc.headers.cpp_flags + ' ' +
netcdff.headers.cpp_flags),
'--with-netcdf-libs={0}'.format(
netcdff.libs.ld_flags + ' ' + hdf5.libs.ld_flags
),
])
else:
options.extend([
'--with-netcdf={0}'.format(netcdfc.prefix),
'--with-netcdf-fortran={0}'.format(netcdff.prefix),
])
if self.spec.satisfies('%fj'):
oapp('FCFLAGS_MODDIR=-M{0}'.format(join_path(
self.stage.source_path, 'src/mods')))
return options
def check(self):
"""This method is called after the build phase if tests have been
explicitly activated by user.
"""
make('check')
# the tests directly execute abinit. thus failing with MPI
# TODO: run tests in tests/ via the builtin runtests.py
# requires Python with numpy, pyyaml, pandas
if '~mpi' in self.spec:
make('tests_in')
def install(self, spec, prefix):
make('install')
if '+install-tests' in spec:
install_tree('tests', spec.prefix.tests)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/sst-elements/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 SstElements(AutotoolsPackage):
"""SST Elements implements a range of components for performing
architecture simulation from node-level to system-level using
the SST discrete event core.
"""
homepage = "https://github.com/sstsimulator"
git = "https://github.com/sstsimulator/sst-elements.git"
url = "https://github.com/sstsimulator/sst-elements/releases/download/v11.0.0_Final/sstelements-11.0.0.tar.gz"
maintainers = ['sknigh']
version('11.0.0', sha256="bf265cb25afc041b74422cc5cddc8e3ae1e7c3efa3e37e699dac4e3f7629be6e")
version('10.1.0', sha256="a790561449795dac48a84c525b8e0b09f05d0b0bff1a0da1aa2e903279a03c4a")
version('10.0.0', sha256="ecf28ef97b27ea75be7e64cb0acb99d36773a888c1b32ba16034c62174b02693")
version('9.1.0', sha256="e19b05aa6e59728995fc059840c79e476ba866b67887ccde7eaf52a18a1f52ca")
version('develop', branch='devel')
version('master', branch='master')
# Contact SST developers (https://github.com/sstsimulator)
# if your use case requires support for:
# - balar
# - OTF2
# - stake (riscv simulator)
variant("pin", default=False,
description="Enable the Ariel CPU model")
variant("dramsim2", default=False,
description="Build with DRAMSim2 support")
variant("dramsim3", default=False,
description="Build with DRAMSim3 support")
variant("dumpi", default=False,
description="Build with Dumpi support")
variant("flashdimmsim", default=False,
description="Build with FlashDIMMSim support")
variant("nvdimmsim", default=False,
description="Build with NVDimmSim support")
variant("hybridsim", default=False,
description="Build with HybridSim support")
variant("goblin", default=False,
description="Build with GoblinHMCSim support")
variant("hbm", default=False,
description="Build with HBM DRAMSim2 support")
variant("ramulator", default=False,
description="Build with Ramulator support")
variant("otf", default=False,
description="Build with OTF")
variant("otf2", default=False,
description="Build with OTF2")
depends_on("python", type=('build', 'run'))
depends_on("sst-core")
depends_on("sst-core@develop", when="@develop")
depends_on("sst-core@master", when="@master")
depends_on("intel-pin", when="+pin")
depends_on("dramsim2@2:", when="+dramsim2")
depends_on("dramsim3@master", when="+dramsim3")
depends_on("sst-dumpi@master", when="+dumpi")
depends_on("flashdimmsim", when="+flashdimmsim")
depends_on("hybridsim@2.0.1", when="+hybridsim")
depends_on("dramsim3@master", when="+hybridsim")
depends_on("nvdimmsim@2.0.0", when="+hybridsim")
depends_on("nvdimmsim@2.0.0", when="+nvdimmsim")
depends_on("goblin-hmc-sim", when="+goblin")
depends_on("ramulator@sst", when="+ramulator")
depends_on("hbm-dramsim2", when="+hbm")
depends_on("otf", when="+otf")
depends_on("otf2", when="+otf2")
depends_on("gettext")
depends_on("zlib")
depends_on('autoconf@1.68:', type='build')
depends_on('automake@1.11.1:', type='build')
depends_on('libtool@1.2.4:', type='build')
depends_on('m4', type='build')
conflicts('+dumpi', msg='Dumpi not currently supported, contact SST Developers for help')
conflicts('+otf', msg='OTF not currently supported, contact SST Developers for help')
conflicts('+otf2', msg='OTF2 not currently supported, contact SST Developers for help')
conflicts('~dramsim2', when='+hybridsim', msg='hybridsim requires dramsim2, spec should include +dramsim2')
conflicts('~nvdimmsim', when='+hybridsim', msg='hybridsim requires nvdimmsim, spec should include +nvdimmsim')
# force out-of-source builds
build_directory = 'spack-build'
def autoreconf(self, spec, prefix):
bash = which('bash')
bash('autogen.sh')
def configure_args(self):
spec = self.spec
args = []
if '+pdes_mpi' in spec["sst-core"]:
env['CC'] = spec['mpi'].mpicc
env['CXX'] = spec['mpi'].mpicxx
env['F77'] = spec['mpi'].mpif77
env['FC'] = spec['mpi'].mpifc
if "+pin" in spec:
args.append("--with-pin=%s" % spec["intel-pin"].prefix)
if "+dramsim2" in spec or "+hybridsim" in spec:
args.append("--with-dramsim=%s" % spec["dramsim2"].prefix)
if "+dramsim3" in spec:
args.append("--with-dramsim3=%s" % spec["dramsim3"].prefix)
if "+dumpi" in spec:
args.append("--with-dumpi=%s" % spec["sst-dumpi"].prefix)
if "+flashdimmsim" in spec:
args.append("--with-fdsim=%s" % spec["flashdimmsim"].prefix)
if "+nvdimmsim" in spec or "+hybridsim" in spec:
args.append("--with-nvdimmsim=%s" % spec["nvdimmsim"].prefix)
if "+hybridsim" in spec:
args.append("--with-hybridsim=%s" % spec["hybridsim"].prefix)
if "+goblin" in spec:
args.append("--with-goblin-hmcsim=%s" %
spec["goblin-hmc-sim"].prefix)
if "+hbm" in spec:
args.append("--with-hbmdramsim=%s" %
spec["hbm-dramsim2"].prefix)
if "+ramulator" in spec:
args.append("--with-ramulator=%s" % spec["ramulator"].prefix)
if "+otf2" in spec:
args.append("--with-otf2=%s" % spec["otf2"].prefix)
if "+otf" in spec:
args.append("--with-otf=%s" % spec["otf"].prefix)
args.append("--with-sst-core=%s" % spec["sst-core"].prefix)
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-ctgan/package.py
|
# Copyright 2013-2022 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 PyCtgan(PythonPackage):
"""CTGAN is a collection of Deep Learning based Synthetic
Data Generators for single table data, which are able to
learn from real data and generate synthetic clones with
high fidelity."""
homepage = "https://github.com/sdv-dev/CTGAN"
pypi = "ctgan/ctgan-0.5.0.tar.gz"
version('0.5.0', sha256='b8a5dbf21dab2d2e2690013f13feb0922f5bad13440b15bc031ce9d58c7fb988')
depends_on('python@3.6:', type=('build', 'run'))
depends_on('py-setuptools', type='build')
depends_on('py-packaging@20:21', type=('build', 'run'))
depends_on('py-numpy@1.18:1.19', type=('build', 'run'), when='^python@3.6')
depends_on('py-numpy@1.20:1', type=('build', 'run'), when='^python@3.7:')
depends_on('py-pandas@1.1.3:1', type=('build', 'run'))
depends_on('py-scikit-learn@0.24:1', type=('build', 'run'))
depends_on('py-torch@1.8.0:1', type=('build', 'run'))
depends_on('py-torchvision@0.9:0', type=('build', 'run'))
depends_on('py-rdt@0.6.1:0.6', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/kafka/package.py
|
# Copyright 2013-2022 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 Kafka(Package):
"""
Kafka is used for building real-time data pipelines and streaming apps.
It is horizontally scalable, fault-tolerant, wicked fast, and runs in
production in thousands of companies.
"""
homepage = "https://www-eu.apache.org/dist/kafka"
url = "https://www-eu.apache.org/dist/kafka/2.3.1/kafka_2.12-2.3.1.tgz"
list_url = "https://www-eu.apache.org/dist/kafka/"
list_depth = 1
version('2.13-2.4.0', sha256='c1c5246c7075459687b3160b713a001f5cd1cc563b9a3db189868d2f22aa9110')
version('2.12-2.4.0', sha256='b9582bab0c3e8d131953b1afa72d6885ca1caae0061c2623071e7f396f2ccfee')
version('2.12-2.3.1', sha256='5a3ddd4148371284693370d56f6f66c7a86d86dd96c533447d2a94d176768d2e')
version('2.12-2.3.0', sha256='d86f5121a9f0c44477ae6b6f235daecc3f04ecb7bf98596fd91f402336eee3e7')
version('2.12-2.2.2', sha256='7a1713d2ee929e54b1c889a449d77006513e59afb3032366368b2ebccd9e9ec0')
depends_on('java@8:', type='run')
def url_for_version(self, version):
url = "https://www-eu.apache.org/dist/kafka/{0}/kafka_{1}.tgz"
parent_dir = str(version).split('-')[1]
return url.format(parent_dir, version)
def install(self, spec, prefix):
install_tree('.', prefix)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-fracdiff/package.py
|
<filename>var/spack/repos/builtin/packages/r-fracdiff/package.py
# Copyright 2013-2022 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 RFracdiff(RPackage):
"""Fractionally Differenced ARIMA aka ARFIMA(P,d,q) Models.
Maximum likelihood estimation of the parameters of a fractionally
differenced ARIMA(p,d,q) model (Haslett and Raftery, Appl.Statistics,
1989); including inference and basic methods. Some alternative algorithms
to estimate "H"."""
cran = "fracdiff"
version('1.5-1', sha256='b8103b32a4ca3a59dda1624c07da08ecd144c7a91a747d1f4663e99421950eb6')
version('1.4-2', sha256='983781cedc2b4e3ba9fa020213957d5133ae9cd6710bc61d6225728e2f6e850e')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-nimble/package.py
|
# Copyright 2013-2022 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 RNimble(RPackage):
"""MCMC, Particle Filtering, and Programmable Hierarchical Modeling.
A system for writing hierarchical statistical models largely compatible
with 'BUGS' and 'JAGS', writing nimbleFunctions to operate models and do
basic R-style math, and compiling both models and nimbleFunctions via
custom-generated C++. 'NIMBLE' includes default methods for MCMC, Monte
Carlo Expectation Maximization, and some other tools. The nimbleFunction
system makes it easy to do things like implement new MCMC samplers from R,
customize the assignment of samplers to different parts of a model from R,
and compile the new samplers automatically via C++ alongside the samplers
'NIMBLE' provides. 'NIMBLE' extends the 'BUGS'/'JAGS' language by making it
extensible: New distributions and functions can be added, including as
calls to external compiled code. Although most people think of MCMC as the
main goal of the 'BUGS'/'JAGS' language for writing models, one can use
'NIMBLE' for writing arbitrary other kinds of model-generic algorithms as
well. A full User Manual is available at <https://r-nimble.org>."""
cran = "nimble"
version('0.12.1', sha256='3520f3212a48c8cbe08a6a8e57b3a72180594f7c09f647d1daf417c9857867d8')
version('0.10.1', sha256='11e248fda442f233c3590640efd9381c9b4b2e6fb66dce45a3391db03b70e702')
version('0.9.1', sha256='ad5e8a171193cb0172e68bf61c4f94432c45c131a150101ad1c5c7318c335757')
version('0.9.0', sha256='ebc28fadf933143eea73900cacaf96ff81cb3c2d607405016062b7e93afa5611')
depends_on('r@3.1.2:', type=('build', 'run'))
depends_on('r-igraph', type=('build', 'run'))
depends_on('r-coda', type=('build', 'run'))
depends_on('r-r6', type=('build', 'run'))
depends_on('gmake', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/zig/package.py
|
<reponame>player1537-forks/spack<gh_stars>10-100
# Copyright 2013-2022 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)
class Zig(CMakePackage):
"""A general-purpose programming language and toolchain for maintaining
robust, optimal, and reusable software.
"""
homepage = "https://ziglang.org/"
git = "https://github.com/ziglang/zig.git"
version('0.7.1', tag='0.7.1')
variant(
'build_type', values=('Release', 'RelWithDebInfo', 'MinSizeRel'),
default='Release', description='CMake build type'
)
depends_on('llvm@11.0.0: targets=all')
provides('ziglang')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/ecbuild/package.py
|
# Copyright 2013-2022 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 Ecbuild(CMakePackage):
"""ecBuild is the ECMWF build system. It is built on top of CMake and
consists of a set of macros as well as a wrapper around CMake,"""
homepage = 'https://github.com/ecmwf/ecbuild'
url = 'https://github.com/ecmwf/ecbuild/archive/refs/tags/3.6.1.tar.gz'
maintainers = ['skosukhin']
version('3.6.1', sha256='796ccceeb7af01938c2f74eab0724b228e9bf1978e32484aa3e227510f69ac59')
# Some of the tests (ECBUILD-415 and test_ecbuild_regex_escape) fail with
# cmake@2.20.0 and it is not yet clear why. For now, we simply limit the
# version of cmake to the latest '3.19.x':
depends_on('cmake@3.11:3.19', type=('build', 'run'))
# Some of the installed scripts require running Perl:
depends_on('perl', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-randomfields/package.py
|
# Copyright 2013-2022 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 RRandomfields(RPackage):
"""Simulation and Analysis of Random Fields.
Methods for the inference on and the simulation of Gaussian fields are
provided. Furthermore, methods for the simulation of extreme value random
fields are provided. Main geostatistical parts are based among others on
the books by Christian Lantuejoul <doi:10.1007/978-3-662-04808-5>."""
cran = "RandomFields"
version('3.3.14', sha256='242600b9bf93af9d49a06c00ff2398054a882d644a4653ea348533410c3db930')
version('3.3.13', sha256='dbf82a8a39a79ca1b53665c2375cdd58f7accb38062063bbd9854d13493d3f49')
version('3.3.8', sha256='8a08e2fdae428e354a29fb6818ae781cc56235a6849a0d29574dc756f73199d0')
version('3.3.6', sha256='51b7bfb4e5bd7fd0ce1207c77f428508a6cd3dfc9de01545a8724dfd9c050213')
version('3.3.4', sha256='a340d4f3ba7950d62acdfa19b9724c82e439d7b1a9f73340124038b7c90c73d4')
version('3.1.50', sha256='2d6a07c3a716ce20f9c685deb59e8fcc64fd52c8a50b0f04baf451b6b928e848')
depends_on('r@3.0:', type=('build', 'run'))
depends_on('r@3.5.0:', type=('build', 'run'), when='@3.3.8:')
depends_on('r-sp', type=('build', 'run'))
depends_on('r-randomfieldsutils@0.5.1:', type=('build', 'run'))
depends_on('r-randomfieldsutils@0.5.5:', type=('build', 'run'), when='@3.3.13:')
depends_on('r-randomfieldsutils@1.1:', type=('build', 'run'), when='@3.3.14:')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/mxm/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 Mxm(Package):
"""Mellanox Messaging Accelerator (MXM) provides enhancements to parallel
communication libraries by fully utilizing the underlying networking
infrastructure provided by Mellanox HCA/switch hardware."""
homepage = 'https://www.mellanox.com/products/mxm'
has_code = False
version('3.6.3104')
# MXM needs to be added as an external package to SPACK. For this, the
# config file packages.yaml needs to be adjusted:
#
# packages:
# mxm:
# buildable: False
# externals:
# - spec: mxm@3.6.3104
# prefix: /opt/mellanox/mxm (path to your MXM installation)
def install(self, spec, prefix):
raise InstallError(
self.spec.format('{name} is not installable, you need to specify '
'it as an external package in packages.yaml'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-pygtrie/package.py
|
# Copyright 2013-2022 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 PyPygtrie(PythonPackage):
"""A pure Python implementation of a trie data structure."""
homepage = "https://github.com/mina86/pygtrie"
pypi = "pygtrie/pygtrie-2.4.2.tar.gz"
version('2.4.2', sha256='43205559d28863358dbbf25045029f58e2ab357317a59b11f11ade278ac64692')
version('2.4.0', sha256='77700d2fcaab321ac65e86c2969fb4b64c116796baf52ab12d07de2e1f6cfc5d')
version('2.3.2', sha256='6299cdedd2cbdfda0895c2dbc43efe8828e698c62b574f3ef7e14b3253f80e23')
# pip silently replaces distutils with setuptools
depends_on('py-setuptools', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-enrichplot/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 REnrichplot(RPackage):
"""Visualization of Functional Enrichment Result.
The 'enrichplot' package implements several visualization methods for
interpreting functional enrichment results obtained from ORA or GSEA
analysis. All the visualization methods are developed based on 'ggplot2'
graphics."""
bioc = "enrichplot"
version('1.14.1', commit='ccf3a6d9b7cd9cffd8de6d6263efdffe59d2<PASSWORD>')
version('1.10.2', commit='<PASSWORD>')
version('1.4.0', commit='6<PASSWORD>75bbb<PASSWORD>')
version('1.2.0', commit='2<PASSWORD>3<PASSWORD>8ae7<PASSWORD>')
version('1.0.2', commit='<KEY>')
depends_on('r@3.4.0:', type=('build', 'run'))
depends_on('r@3.5.0:', type=('build', 'run'), when='@1.10.2:')
depends_on('r-aplot', type=('build', 'run'), when='@1.14.1:')
depends_on('r-dose@3.5.1:', type=('build', 'run'))
depends_on('r-dose@3.13.1:', type=('build', 'run'), when='@1.8.1:')
depends_on('r-dose@3.16.0:', type=('build', 'run'), when='@1.12.3:')
depends_on('r-ggplot2', type=('build', 'run'))
depends_on('r-ggraph', type=('build', 'run'))
depends_on('r-igraph', type=('build', 'run'))
depends_on('r-plyr', type=('build', 'run'), when='@1.10.2:')
depends_on('r-purrr', type=('build', 'run'), when='@1.2.0:')
depends_on('r-rcolorbrewer', type=('build', 'run'), when='@1.2.0:')
depends_on('r-reshape2', type=('build', 'run'))
depends_on('r-scatterpie', type=('build', 'run'), when='@1.10.2:')
depends_on('r-shadowtext', type=('build', 'run'), when='@1.10.2:')
depends_on('r-gosemsim', type=('build', 'run'))
depends_on('r-magrittr', type=('build', 'run'), when='@1.10.2:')
depends_on('r-ggtree', type=('build', 'run'), when='@1.14.1:')
depends_on('r-yulab-utils@0.0.4:', type=('build', 'run'), when='@1.14.1:')
depends_on('r-ggridges', type=('build', 'run'), when='@:1.4.0')
depends_on('r-upsetr', type=('build', 'run'), when='@:1.4.0')
depends_on('r-annotationdbi', type=('build', 'run'), when='@:1.4.0')
depends_on('r-europepmc', type=('build', 'run'), when='@1.2.0:1.4.0')
depends_on('r-ggplotify', type=('build', 'run'), when='@1.2.0:1.4.0')
depends_on('r-gridextra', type=('build', 'run'), when='@1.2.0:1.4.0')
depends_on('r-cowplot', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-moviepy/package.py
|
<filename>var/spack/repos/builtin/packages/py-moviepy/package.py
# Copyright 2013-2022 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 PyMoviepy(PythonPackage):
"""MoviePy is a Python module for video editing, which can
be used for basic operations (like cuts, concatenations,
title insertions), video compositing (a.k.a. non-linear
editing), video processing, or to create advanced effects.
It can read and write the most common video formats,
including GIF."""
homepage = "https://zulko.github.io/moviepy/"
pypi = "moviepy/moviepy-1.0.3.tar.gz"
version('1.0.3', sha256='2884e35d1788077db3ff89e763c5ba7bfddbd7ae9108c9bc809e7ba58fa433f5')
version('1.0.1', sha256='9d5b0a0e884c0eb92c431baa110e560059720aab15d2ef3e4cba3892c34cf1ed')
depends_on('py-setuptools', type='build')
depends_on('py-decorator@4.0.2:4', type=('build', 'run'))
depends_on('py-imageio@2.5:2', when='^python@3.4:', type=('build', 'run'))
depends_on('py-imageio@2.0:2.4', when='^python@:3.3', type=('build', 'run'))
depends_on('py-imageio-ffmpeg@0.2.0:', when='^python@3.4:', type=('build', 'run'))
depends_on('py-tqdm@4.11.2:4', type=('build', 'run'))
depends_on('py-numpy', type=('build', 'run'))
depends_on('py-requests@2.8.1:2', type=('build', 'run'))
depends_on('py-proglog@:1.0.0', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/sarus/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2021 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)
import llnl.util.tty as tty
from spack import *
class Sarus(CMakePackage):
"""Sarus is an OCI-compliant container engine for HPC systems."""
homepage = "https://github.com/eth-cscs/sarus"
url = "https://github.com/eth-cscs/sarus/archive/1.3.3.tar.gz"
git = "https://github.com/eth-cscs/sarus.git"
maintainers = ["Madeeks", "t<PASSWORD>aga", "teonnik"]
version("develop", branch="develop")
version("master", branch="master")
version("1.4.1", commit="a73f6ca9cafb768f3132cfcef8c826af34eeff94")
version("1.4.0", commit="c6190faf45d5e0ff5348c70c2d4b1e49b2e01039")
version("1.3.3", commit="f<PASSWORD>")
version("1.3.2", commit="ac6a1b8708ec402bbe810812d8af41d1b7bf1860")
version("1.3.1", commit="5117a0da8d2171c4bf9ebc6835e0dd6b73812930")
version("1.3.0", commit="f52686fa942d5fc2b1302011e9a081865285357b")
version("1.2.0", commit="<PASSWORD>")
version("1.1.0", commit="<PASSWORD>")
version("1.0.1", commit="abb8c314a196207204826f7b60e5064677687405")
version("1.0.0", commit="<PASSWORD>")
variant(
"ssh",
default=False,
description="Build and install the SSH hook and custom SSH software "
"to enable connections inside containers."
"Requires a static version of the glibc libraries "
"(including libcrypt) to be available on the system",
)
depends_on("expat", type="build")
depends_on("squashfs", type=("build", "run"))
depends_on("boost@1.65.0: cxxstd=11")
depends_on("cpprestsdk@2.10.0:")
depends_on("libarchive@3.4.1:")
depends_on("rapidjson@1.2.0-2021-08-13", type="build")
depends_on("runc")
depends_on("tini")
# autoconf is required to build Dropbear for the SSH hook
depends_on("autoconf", type="build")
# Python 3 is used to run integration tests
depends_on("python@3:", type="test", when="@develop")
def cmake_args(self):
spec = self.spec
args = [
"-DCMAKE_TOOLCHAIN_FILE=./cmake/toolchain_files/gcc.cmake",
"-DENABLE_SSH=%s" % ("+ssh" in spec),
]
if "@1.4.1:" in spec:
args.append(self.define("ENABLE_UNIT_TESTS", self.run_tests))
return args
def install(self, spec, prefix):
with working_dir(self.build_directory):
make(*self.install_targets)
mkdirp(prefix.var.OCIBundleDir)
@run_after("install")
def build_perms_script(self):
script_sh = join_path(self.spec.prefix, "configure_installation.sh")
tty.warn(
"""
To complete Sarus's configuration:
1. Make sure sarus and its dependencies (tini, squashfs) are in
PATH, for example do `spack load sarus`.
2. Execute the script {} with root privileges.
The script generates a basic working configuration. For more
details:
https://sarus.readthedocs.io/en/stable/config/basic_configuration.html
For production it is strongly recommended to install with
escalated privileges (sudo/root) in order to comply with Sarus'
internal security checks. For more information on these checks,
see :
https://sarus.readthedocs.io/en/stable/install/post-installation.html#security-related
""".format(
script_sh
)
)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/rocm-debug-agent/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 RocmDebugAgent(CMakePackage):
"""Radeon Open Compute (ROCm) debug agent"""
homepage = "https://github.com/ROCm-Developer-Tools/rocr_debug_agent"
git = "https://github.com/ROCm-Developer-Tools/rocr_debug_agent.git"
url = "https://github.com/ROCm-Developer-Tools/rocr_debug_agent/archive/rocm-4.5.2.tar.gz"
maintainers = ['srekolam', 'arjun-raj-kuppala']
version('4.5.2', sha256='85c7f19485defd9a58716fffdd1a0e065ed7f779c3f124467fca18755bc634a6')
version('4.5.0', sha256='6486b1a8515da4711d3c85f8e41886f8fe6ba37ca2c63664f00c811f6296ac20')
version('4.3.1', sha256='7bee6be6c29883f03f47a8944c0d50b7cf43a6b5eeed734602f521c3c40a18d0')
version('4.3.0', sha256='0cdee5792b808e03b839070da0d1b08dc4078a7d1fc295f0c99c6a5ae7d636a6')
version('4.2.0', sha256='ce02a5b752291882daa0a2befa23944e59087ce9fe65a91061476c3c399e4a0c')
version('4.1.0', sha256='b1ae874887e5ee037070f1dd46b145ad02ec9fd8a724c6b6ae194b534f01acdb', deprecated=True)
version('4.0.0', sha256='a9e64834d56a9221c242e71aa110c2cef0087aa8f86f50428dd618e5e623cc3c', deprecated=True)
version('3.10.0', sha256='675b8d3cc4aecc4428a93553abf664bbe6a2cb153f1f480e6cadeeb4d24ef4b1', deprecated=True)
version('3.9.0', sha256='3e56bf8b2b53d9102e8709b6259deea52257dc6210df16996b71a7d677952b1b', deprecated=True)
version('3.8.0', sha256='55243331ac4b0d90e88882eb29fd06fad354e278f8a34ac7f0680b2c895ca2ac', deprecated=True)
version('3.7.0', sha256='d0f442a2b224a734b0080c906f0fc3066a698e5cde9ff97ffeb485b36d2caba1', deprecated=True)
version('3.5.0', sha256='203ccb18d2ac508aae40bf364923f67375a08798b20057e574a0c5be8039f133', deprecated=True)
def url_for_version(self, version):
url = "https://github.com/ROCm-Developer-Tools/rocr_debug_agent/archive/"
if version <= Version('3.7.0'):
url += "roc-{0}.tar.gz".format(version)
else:
url += "rocm-{0}.tar.gz".format(version)
return url
variant('build_type', default='Release', values=("Release", "Debug", "RelWithDebInfo"), description='CMake build type')
depends_on('cmake@3:', type='build')
depends_on('elfutils@:0.168', type='link')
for ver in ['3.5.0', '3.7.0', '3.8.0', '3.9.0', '3.10.0', '4.0.0', '4.1.0',
'4.2.0', '4.3.0', '4.3.1', '4.5.0', '4.5.2']:
depends_on('hsa-rocr-dev@' + ver, when='@' + ver)
depends_on('hsakmt-roct@' + ver, when='@' + ver)
for ver in ['3.7.0', '3.8.0', '3.9.0', '3.10.0', '4.0.0', '4.1.0', '4.2.0',
'4.3.0', '4.3.1', '4.5.0', '4.5.2']:
depends_on('rocm-dbgapi@' + ver, when='@' + ver)
depends_on('hip@' + ver, when='@' + ver)
# https://github.com/ROCm-Developer-Tools/rocr_debug_agent/pull/4
patch('0001-Drop-overly-strict-Werror-flag.patch', when='@3.7.0:')
patch('0002-add-hip-architecture.patch', when='@3.9.0:')
@property
def root_cmakelists_dir(self):
if '@3.5.0' in self.spec:
return 'src'
else:
return self.stage.source_path
def cmake_args(self):
spec = self.spec
args = []
if '@3.5.0' in spec:
args.append(
'-DCMAKE_PREFIX_PATH={0}/include/hsa;{1}/include,'.
format(spec['hsa-rocr-dev'].prefix, spec['hsakmt-roct'].prefix)
)
if '@3.7.0:' in spec:
args.append(
'-DCMAKE_MODULE_PATH={0}'.
format(spec['hip'].prefix.cmake)
)
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/feh/package.py
|
<filename>var/spack/repos/builtin/packages/feh/package.py
# Copyright 2013-2022 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 Feh(MakefilePackage):
"""
feh is an X11 image viewer aimed mostly at console users. Unlike most
other viewers, it does not have a fancy GUI, but simply displays images. It
is controlled via commandline arguments and configurable key/mouse
actions.
"""
homepage = "https://feh.finalrewind.org/"
url = "https://feh.finalrewind.org/feh-3.3.tar.bz2"
maintainers = ['TheQueasle']
version('3.3', sha256='f3959958258111d5f7c9fbe2e165c52b9d5987f07fd1f37540a4abf9f9638811')
version('3.1.1', sha256='61d0242e3644cf7c5db74e644f0e8a8d9be49b7bd01034265cc1ebb2b3f9c8eb')
depends_on('imlib2')
depends_on('curl')
depends_on('libxinerama')
depends_on('libexif')
depends_on('libxt')
def build(self, spec, prefix):
make('PREFIX={0}'.format(prefix), 'exif=1', 'help=1')
def install(self, spec, prefix):
make('install', 'PREFIX={0}'.format(prefix))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-hoardr/package.py
|
# Copyright 2013-2022 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 RHoardr(RPackage):
"""Manage Cached Files.
Suite of tools for managing cached files, targeting use in other R
packages. Uses 'rappdirs' for cross-platform paths. Provides utilities to
manage cache directories, including targeting files by path or by key;
cached directories can be compressed and uncompressed easily to save disk
space."""
cran = "hoardr"
version('0.5.2', sha256='819113f0e25da105f120a676b5173872a4144f2f6f354cad14b35f898e76dc54')
depends_on('r-r6@2.2.0:', type=('build', 'run'))
depends_on('r-rappdirs@0.3.1:', type=('build', 'run'))
depends_on('r-digest', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/sprng/package.py
|
# Copyright 2013-2022 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)
class Sprng(AutotoolsPackage):
"""SPRNG: A Scalable Library For Pseudorandom Number Generation
Sprng is a distributed process-aware random number generator that
avoids correlations in random number sequences across processes.
"""
maintainers = ['kayarre']
homepage = "http://www.sprng.org"
url = "http://www.sprng.org/Version5.0/sprng5.tar.bz2"
version('5.0', sha256='9172a495472cc24893e7489ce9b5654300dc60cba4430e436ce50d28eb749a66')
variant('mpi', default=True, description='Enable MPI support')
variant('fortran', default=False, description='Enable Fortran support')
depends_on('mpi', when='+mpi')
def url_for_version(self, version):
url = "http://www.sprng.org/Version{0}/sprng{1}.tar.bz2"
return url.format(version, version.up_to(1))
def configure_args(self):
configure_args = []
configure_args += self.with_or_without('mpi')
configure_args += self.with_or_without('fortran')
if '+mpi' in self.spec:
mpi_link_flags = self.spec['mpi:cxx'].libs.link_flags
configure_args.append('LIBS={0}'.format(mpi_link_flags))
configure_args.append('CC={0}'.format(self.spec['mpi'].mpicc))
configure_args.append('CXX={0}'.format(self.spec['mpi'].mpicxx))
if '+fortran' in self.spec:
configure_args.append('FC={0}'.format(self.spec['mpi'].mpifc))
return configure_args
# TODO: update after solution for virtual depedencies
@run_before('configure')
def mpicxx_check(self):
# print(self.spec['mpi:fortran'].libs.names)
if '+mpi' in self.spec:
if 'mpi_cxx' not in self.spec['mpi:cxx'].libs.names:
msg = 'SPRNG requires a mpi Cxx bindings to build'
raise RuntimeError(msg)
if '+fortran' in self.spec:
if 'fmpi' not in self.spec['fortran'].libs.names:
msg = ('SPRNG requires fortran mpi '
'libraries with mpi enabled')
raise RuntimeError(msg)
# raise RuntimeError("test")
# FIXME: update after features in #15702 are enabled
@run_after('build')
@on_package_attributes(run_tests=True)
def check_build(self):
def listisclose(a, b, rel_tol=1e-09, abs_tol=1.0e-20):
for ai, bi in zip(a, b):
if (not abs(ai - bi) <=
max(rel_tol * max(abs(ai), abs(bi)), abs_tol)):
return False
return True
# Build and run a small program to test the installed sprng library
spec = self.spec
print("Checking sprng installation...")
checkdir = "spack-check"
with working_dir(checkdir, create=True):
source = r"""
#include <cstdio>
#define SIMPLE_SPRNG /* simple interface */
#include "sprng_cpp.h" /* SPRNG header file */
#define SEED 985456376
int main() {
int seed = SEED;
int i, j;
double rn;
for(j=0; j < 5; ++j) {
init_sprng(seed, SPRNG_DEFAULT, j);
for (i=0; i<3; ++i) {
rn = sprng();
printf("%f ", rn);
}
}
printf("\n");
return 0;
}
"""
expected = [0.504272, 0.558437, 0.000848,
0.707488, 0.664048, 0.005616,
0.060190, 0.415195, 0.933915,
0.085215, 0.456461, 0.244497,
0.626037, 0.917948, 0.135160
]
with open("check.c", 'w') as f:
f.write(source)
if '+mpi' in spec:
cc = Executable(spec['mpi'].mpicxx)
else:
cc = Executable(self.compiler.cxx)
cc(*(['-c', "check.c"] + spec['sprng'].headers.cpp_flags.split()))
cc(*(['-o', "check",
"check.o"] + spec['sprng'].libs.ld_flags.split()))
try:
check = Executable('./check')
output = check(output=str)
except ProcessError:
output = ""
out2float = [float(num) for num in output.split(' ')]
success = listisclose(expected, out2float)
if not success:
print("Produced output does not match expected output.")
print("Expected output:")
print('-' * 80)
print(expected)
print('-' * 80)
print("Produced output:")
print('-' * 80)
print(output)
print('-' * 80)
raise RuntimeError("sprng install check failed")
else:
print("test passed")
shutil.rmtree(checkdir)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-tfmpvalue/package.py
|
<filename>var/spack/repos/builtin/packages/r-tfmpvalue/package.py
# Copyright 2013-2022 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 RTfmpvalue(RPackage):
"""Efficient and Accurate P-Value Computation for Position Weight Matrices.
In putative Transcription Factor Binding Sites (TFBSs) identification from
sequence/alignments, we are interested in the significance of certain match
score. TFMPvalue provides the accurate calculation of P-value with score
threshold for Position Weight Matrices, or the score with given P-value.
This package is an interface to code originally made available by <NAME> and <NAME>, 2007, Algorithms Mol Biol:2, 15."""
cran = "TFMPvalue"
version('0.0.8', sha256='6d052529f7b59d0384edc097f724f70468013777b6adf4c63e61a359029d3841')
version('0.0.6', sha256='cee3aa2d4e22856865d820f695e29a5f23486e5e08cd42cb95a0728f5f9522a1')
depends_on('r@3.0.1:', type=('build', 'run'))
depends_on('r-rcpp@0.11.1:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-corrplot/package.py
|
# Copyright 2013-2022 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 RCorrplot(RPackage):
"""Visualization of a Correlation Matrix.
Provides a visual exploratory tool on correlation matrix that supports
automatic variable reordering to help detect hidden patterns among
variables."""
cran = "corrplot"
version('0.92', sha256='e8c09f963f9c4837036c439ebfe00fa3a6e462ccbb786d2cf90850ddcd9428bd')
version('0.84', sha256='0dce5e628ead9045580a191f60c58fd7c75b4bbfaaa3307678fc9ed550c303cc')
version('0.77', sha256='54b66ff995eaf2eee3f3002509c6f27bb5bd970b0abde41893ed9387e93828d3')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-spatialist/package.py
|
# Copyright 2013-2022 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 PySpatialist(PythonPackage):
"""This package offers functionalities for user-friendly geo data
processing using GDAL and OGR."""
homepage = "https://github.com/johntruckenbrodt/spatialist"
pypi = "spatialist/spatialist-0.4.tar.gz"
maintainers = ['adamjstewart']
version('0.4', sha256='153b118022c06ad2d1d51fb6cd9ecbfc8020bc1995b643ec7fa689a8c5dde7e9')
version('0.2.8', sha256='97de7f9c0fbf28497ef28970bdf8093a152e691a783e7edad22998cb235154c6')
depends_on('python@2.7.9:', type=('build', 'run'))
depends_on('py-setuptools', type='build')
depends_on('py-setuptools-scm', type='build')
depends_on('py-progressbar2', type=('build', 'run'))
depends_on('py-jupyter', type=('build', 'run'))
depends_on('py-ipython', type=('build', 'run'))
depends_on('py-ipywidgets', type=('build', 'run'))
depends_on('py-matplotlib', type=('build', 'run'))
depends_on('py-prompt-toolkit@2.0.10:2.0', type=('build', 'run'))
depends_on('py-pathos@0.2:', type=('build', 'run'))
depends_on('py-numpy', type=('build', 'run'))
depends_on('py-scoop', type=('build', 'run'))
depends_on('py-tblib', type=('build', 'run'))
depends_on('py-pyyaml', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-abaenrichment/package.py
|
<filename>var/spack/repos/builtin/packages/r-abaenrichment/package.py
# Copyright 2013-2022 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 RAbaenrichment(RPackage):
"""Gene expression enrichment in human brain regions.
The package ABAEnrichment is designed to test for enrichment of user
defined candidate genes in the set of expressed genes in different human
brain regions. The core function 'aba_enrich' integrates the expression
of the candidate gene set (averaged across donors) and the structural
information of the brain using an ontology, both provided by the Allen
Brain Atlas project. 'aba_enrich' interfaces the ontology enrichment
software FUNC to perform the statistical analyses. Additional functions
provided in this package like 'get_expression' and 'plot_expression'
facilitate exploring the expression data, and besides the standard
candidate vs. background gene set enrichment, also three additional
tests are implemented, e.g. for cases when genes are ranked instead of
divided into candidate and background."""
bioc = "ABAEnrichment"
version('1.24.0', commit='<KEY>')
version('1.20.0', commit='608433a0b07e6dd99915dc536a038d960f1be1d5')
version('1.14.1', commit='e1ebfb5de816b924af16675a5ba9ed1a6b527b23')
version('1.12.0', commit='1320e932deafd71d67c7a6f758d15b00d6d7f7d7')
version('1.10.0', commit='<KEY>')
version('1.8.0', commit='<KEY>')
version('1.6.0', commit='<KEY>')
depends_on('r+X', type=('build', 'run'))
depends_on('r@3.2:', type=('build', 'run'))
depends_on('r@3.4:', type=('build', 'run'), when='@1.8.0:')
depends_on('r-rcpp@0.11.5:', type=('build', 'run'))
depends_on('r-gplots@2.14.2:', type=('build', 'run'))
depends_on('r-gtools@3.5.0:', type=('build', 'run'))
depends_on('r-abadata@0.99.2:', type=('build', 'run'))
depends_on('r-data-table@1.10.4:', type=('build', 'run'), when='@1.8.0:')
depends_on('r-gofuncr@1.1.2:', type=('build', 'run'), when='@1.12.0:')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-spectra/package.py
|
<filename>var/spack/repos/builtin/packages/py-spectra/package.py
# Copyright 2013-2022 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 PySpectra(PythonPackage):
"""Color scales and color conversion made easy for Python."""
pypi = "spectra/spectra-0.0.8.tar.gz"
version('0.0.11', sha256='8eb362a5187cb63cee13cd01186799c0c791a3ad3bec57b279132e12521762b8')
version('0.0.8', sha256='851b88c9c0bba84e0be1fce5b9c02a7b4ef139a2b3e590b0d082d679e19f0759')
depends_on('py-setuptools', type='build')
depends_on('py-colormath', type=('build', 'run'))
depends_on('py-colormath@3.0.0:', type=('build', 'run'), when='@0.0.11:')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-sphinx-multiversion/package.py
|
# Copyright 2013-2022 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 PySphinxMultiversion(PythonPackage):
"""A Sphinx extension for building self-hosted versioned documentation."""
homepage = "https://github.com/Holzhaus/sphinx-multiversion"
pypi = "sphinx-multiversion/sphinx-multiversion-0.2.4.tar.gz"
version('0.2.4', sha256='5cd1ca9ecb5eed63cb8d6ce5e9c438ca13af4fa98e7eb6f376be541dd4990bcb')
version('0.2.3', sha256='e46565ac2f703f3b55652f33c159c8059865f5d13dae7f0e8403e5afc2996f5f')
version('0.2.2', sha256='c0a4f2cbb13eb62b5cd79e2f6901e5d90ea191d3f37e96e1f15b976827de0ac0')
version('0.2.1', sha256='0775847454965005a3a8433c1bf38379f723c026de9c4a7ddd447b0349df90c1')
depends_on('py-setuptools', type='build')
depends_on('py-sphinx', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin.mock/packages/mirror-sourceforge-broken/package.py
|
# Copyright 2013-2022 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 MirrorSourceforgeBroken(AutotoolsPackage, SourceforgePackage):
"""Simple sourceforge.net package"""
homepage = "http://www.tcl.tk"
url = "http://prdownloads.sourceforge.net/tcl/tcl8.6.5-src.tar.gz"
version('8.6.8', sha256='c43cb0c1518ce42b00e7c8f6eaddd5195c53a98f94adc717234a65cbcfd3f96a')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-visdom/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 PyVisdom(PythonPackage):
"""Visdom aims to facilitate visualization of (remote) data
with an emphasis on supporting scientific
experimentation."""
homepage = "https://github.com/facebookresearch/visdom"
pypi = "visdom/visdom-0.1.8.9.tar.gz"
version('0.1.8.9', sha256='c73ad23723c24a48156899f78dd76bd4538eba3edf9120b6c65a9528fa677126')
depends_on('py-setuptools', type='build')
depends_on('py-numpy@1.8:', type=('build', 'run'))
depends_on('py-scipy', type=('build', 'run'))
depends_on('py-requests', type=('build', 'run'))
depends_on('py-tornado', type=('build', 'run'))
depends_on('py-pyzmq', type=('build', 'run'))
depends_on('py-six', type=('build', 'run'))
depends_on('py-jsonpatch', type=('build', 'run'))
depends_on('py-websocket-client', type=('build', 'run'))
depends_on('py-torch@0.3.1:', type=('build', 'run'))
depends_on('pil', type=('build', 'run'))
depends_on('py-torchfile', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/ffmpeg/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 Ffmpeg(AutotoolsPackage):
"""FFmpeg is a complete, cross-platform solution to record,
convert and stream audio and video."""
homepage = "https://ffmpeg.org"
url = "https://ffmpeg.org/releases/ffmpeg-4.1.1.tar.bz2"
maintainers = ['xjrc']
version('4.4.1', sha256='8fc9f20ac5ed95115a9e285647add0eedd5cc1a98a039ada14c132452f98ac42')
version('4.3.2', sha256='ab3a6d6a70358ba0a5f67f37f91f6656b7302b02e98e5b8c846c16763c99913a')
version('4.2.2', sha256='b620d187c26f76ca19e74210a0336c3b8380b97730df5cdf45f3e69e89000e5c')
version('4.1.1', sha256='0cb40e3b8acaccd0ecb38aa863f66f0c6e02406246556c2992f67bf650fab058')
version('4.1', sha256='b684fb43244a5c4caae652af9022ed5d85ce15210835bce054a33fb26033a1a5')
version('3.2.4', sha256='c0fa3593a2e9e96ace3c1757900094437ad96d1d6ca19f057c378b5f394496a4')
version('2.8.15', sha256='35647f6c1f6d4a1719bc20b76bf4c26e4ccd665f46b5676c0e91c5a04622ee21')
version('1.0.10', sha256='1dbde434c3b5c573d3b2ffc1babe3814f781c10c4bc66193a4132a44c9715176')
# Licensing
variant('gpl', default=True,
description='allow use of GPL code, the resulting libs '
'and binaries will be under GPL')
variant('version3', default=True,
description='upgrade (L)GPL to version 3')
variant('nonfree', default=False,
description='allow use of nonfree code, the resulting libs '
'and binaries will be unredistributable')
# NOTE: The libopencv option creates a circular dependency.
# NOTE: There are more possible variants that would require additional
# spack packages.
# meta variants: These will toggle several settings
variant('X', default=False, description='X11 support')
variant('drawtext', default=False, description='drawtext filter')
# options
variant('bzlib', default=True, description='bzip2 support')
variant('libaom', default=False, description='AV1 video encoding/decoding')
variant('libmp3lame', default=False, description='MP3 encoding')
variant('libopenjpeg', default=False, description='JPEG 2000 de/encoding')
variant('libopus', default=False, description='Opus de/encoding')
variant('libsnappy', default=False,
description='Snappy compression, needed for hap encoding')
variant('libspeex', default=False, description='Speex de/encoding')
variant('libssh', default=False, description='SFTP protocol')
variant('libvorbis', default=False, description='Vorbis en/decoding')
variant('libvpx', default=False, description='VP9 en/decoding')
variant('libwebp', default=False, description='WebP encoding via libwebp')
# TODO: There is an issue with the spack headers property in the libxml2
# package recipe. Comment out the libxml2 variant until that is resolved.
# variant('libxml2', default=False,
# description='XML parsing, needed for dash demuxing support')
variant('libzmq', default=False, description='message passing via libzmq')
variant('lzma', default=False, description='lzma support')
variant('avresample', default=False, description='AV reasmpling component')
variant('openssl', default=False, description='needed for https support')
variant('sdl2', default=False, description='sdl2 support')
variant('shared', default=True, description='build shared libraries')
variant('libx264', default=False, description='H.264 encoding')
depends_on('alsa-lib', when='platform=linux')
depends_on('libiconv')
depends_on('yasm@1.2.0:')
depends_on('zlib')
depends_on('aom', when='+libaom')
depends_on('bzip2', when='+bzlib')
depends_on('fontconfig', when='+drawtext')
depends_on('freetype', when='+drawtext')
depends_on('fribidi', when='+drawtext')
depends_on('lame', when='+libmp3lame')
depends_on('libssh', when='+libssh')
depends_on('libvorbis', when='+libvorbis')
depends_on('libvpx', when='+libvpx')
depends_on('libwebp', when='+libwebp')
# TODO: enable libxml2 when libxml2 header issue is resolved
# depends_on('libxml2', when='+libxml2')
depends_on('libxv', when='+X')
depends_on('libzmq', when='+libzmq')
depends_on('openjpeg', when='+libopenjpeg')
depends_on('openssl', when='+openssl')
depends_on('opus', when='+libopus')
depends_on('sdl2', when='+sdl2')
depends_on('snappy', when='+libsnappy')
depends_on('speex', when='+libspeex')
depends_on('xz', when='+lzma')
depends_on('x264', when='+libx264')
# TODO: enable when libxml2 header issue is resolved
# conflicts('+libxml2', when='@:3')
# See: https://www.ffmpeg.org/index.html#news (search AV1)
conflicts('+libaom', when='@:3')
# All of the following constraints were sourced from the official 'ffmpeg'
# change log, which can be found here:
# https://raw.githubusercontent.com/FFmpeg/FFmpeg/release/4.0/Changelog
conflicts('+sdl2', when='@:3.1')
conflicts('+libsnappy', when='@:2.7')
conflicts('+X', when='@:2.4')
conflicts('+lzma', when='@2.3:')
conflicts('+libwebp', when='@2.1:')
conflicts('+libssh', when='@2.1:')
conflicts('+libzmq', when='@:1')
conflicts('%nvhpc')
@property
def libs(self):
return find_libraries('*', self.prefix, recursive=True)
@property
def headers(self):
headers = find_all_headers(self.prefix.include)
headers.directories = [self.prefix.include]
return headers
def enable_or_disable_meta(self, variant, options):
switch = 'enable' if '+{0}'.format(variant) in self.spec else 'disable'
return ['--{0}-{1}'.format(switch, option) for option in options]
def configure_args(self):
spec = self.spec
config_args = [
'--enable-pic',
'--cc={0}'.format(spack_cc),
'--cxx={0}'.format(spack_cxx)
]
# '+X' meta variant #
xlib_opts = []
if spec.satisfies('@2.5:'):
xlib_opts.extend([
'libxcb',
'libxcb-shape',
'libxcb-shm',
'libxcb-xfixes',
'xlib',
])
config_args += self.enable_or_disable_meta('X', xlib_opts)
# '+drawtext' meta variant #
drawtext_opts = [
'{0}fontconfig'.format('lib' if spec.satisfies('@3:') else ''),
'libfreetype',
]
if spec.satisfies('@2.3:'):
drawtext_opts.append('libfribidi')
config_args += self.enable_or_disable_meta('drawtext', drawtext_opts)
# other variants #
variant_opts = [
'bzlib',
'gpl',
'libmp3lame',
'libopenjpeg',
'libopus',
'libspeex',
'libvorbis',
'libvpx',
'libx264',
'avresample',
'nonfree',
'openssl',
'shared',
'version3',
]
if spec.satisfies('@2.0:'):
variant_opts.append('libzmq')
if spec.satisfies('@2.1:'):
variant_opts.append('libssh')
if spec.satisfies('@2.2:'):
variant_opts.append('libwebp')
if spec.satisfies('@2.4:'):
variant_opts.append('lzma')
if spec.satisfies('@2.8:'):
variant_opts.append('libsnappy')
if spec.satisfies('@3.2:'):
variant_opts.append('sdl2')
if spec.satisfies('@4:'):
variant_opts.append('libaom')
# TODO: enable when libxml2 header issue is resolved
# variant_opts.append('libxml2')
for variant_opt in variant_opts:
config_args += self.enable_or_disable(variant_opt)
return config_args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-imager/package.py
|
# Copyright 2013-2022 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 RImager(RPackage):
"""Image Processing Library Based on 'CImg'.
Fast image processing for images in up to 4 dimensions (two spatial
dimensions, one time/depth dimension, one colour dimension). Provides most
traditional image processing tools (filtering, morphology, transformations,
etc.) as well as various functions for easily analysing image data using R.
The package wraps 'CImg', <https://cimg.eu/>, a simple, modern C++ library
for image processing."""
cran = "imager"
version('0.42.11', sha256='47f8b7ff8d05a5191e30ad1869f12a62bdbe3142b22b12a6032dec9b5f8532a8')
version('0.42.10', sha256='01939eb03ad2e1369a4240a128c3b246a4c56f572f1ea4967f1acdc555adaeee')
version('0.42.3', sha256='6fc308153df8251cef48f1e13978abd5d29ec85046fbe0b27c428801d05ebbf3')
version('0.41.2', sha256='9be8bc8b3190d469fcb2883045a404d3b496a0380f887ee3caea11f0a07cd8a5')
depends_on('r+X')
depends_on('r@2.10.0:', type=('build', 'run'))
depends_on('r-magrittr', type=('build', 'run'))
depends_on('r-rcpp@0.11.5:', type=('build', 'run'))
depends_on('r-stringr', type=('build', 'run'))
depends_on('r-png', type=('build', 'run'))
depends_on('r-jpeg', type=('build', 'run'))
depends_on('r-readbitmap', type=('build', 'run'))
depends_on('r-purrr', type=('build', 'run'))
depends_on('r-downloader', type=('build', 'run'))
depends_on('r-igraph', type=('build', 'run'))
depends_on('fftw')
depends_on('libtiff')
depends_on('r-cairo', type=('build', 'run'), when='@:0.41.2')
depends_on('r-plyr', type=('build', 'run'), when='@:0.41.2')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/libnfs/package.py
|
# Copyright 2013-2022 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 Libnfs(CMakePackage):
"""LIBNFS is a client library for accessing NFS shares over a network."""
homepage = "https://sites.google.com/site/libnfstarballs/"
url = "https://github.com/sahlberg/libnfs/archive/libnfs-4.0.0.tar.gz"
version('4.0.0', sha256='6ee77e9fe220e2d3e3b1f53cfea04fb319828cc7dbb97dd9df09e46e901d797d')
version('3.0.0', sha256='445d92c5fc55e4a5b115e358e60486cf8f87ee50e0103d46a02e7fb4618566a5')
version('2.0.0', sha256='7ea6cd8fa6c461d01091e584d424d28e137d23ff4b65b95d01a3fd0ef95d120e')
version('1.11.0', sha256='fc2e45df14d8714ccd07dc2bbe919e45a2e36318bae7f045cbbb883a7854640f')
version('1.10.0', sha256='7f6c62a05c7e0f0749f2b13f178a4ed7aaf17bd09e65a10bb147bfe9807da272')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-tensorboard-data-server/package.py
|
<gh_stars>10-100
# Copyright 2013-2021 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)
import glob
from spack import *
class PyTensorboardDataServer(PythonPackage):
"""Fast data loading for TensorBoard"""
homepage = "https://github.com/tensorflow/tensorboard/tree/master/tensorboard/data/server"
git = "https://github.com/tensorflow/tensorboard"
version('0.6.1', commit='<PASSWORD>')
depends_on('python@3.6:', type=('build', 'run'))
depends_on('py-setuptools', type='build')
depends_on('rust', type='build')
def setup_build_environment(self, env):
env.set('CARGO_HOME', self.stage.source_path)
def install(self, spec, prefix):
with working_dir(join_path('tensorboard', 'data', 'server')):
cargo = which('cargo')
cargo('build', '--release')
with working_dir(join_path('tensorboard', 'data', 'server',
'pip_package')):
python('build.py',
'--out-dir={0}'.format(self.stage.source_path),
'--server-binary={0}'.format(join_path(self.stage.source_path,
'tensorboard',
'data',
'server',
'target',
'release',
'rustboard')))
wheel = glob.glob('*.whl')[0]
args = std_pip_args + ['--prefix=' + prefix, wheel]
pip(*args)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-xenv/package.py
|
<filename>var/spack/repos/builtin/packages/py-xenv/package.py<gh_stars>10-100
# Copyright 2013-2022 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 PyXenv(PythonPackage):
"""Helpers to work with the environment in a platform independent way."""
homepage = "https://gitlab.cern.ch/gaudi/xenv"
pypi = "xenv/xenv-1.0.0.tar.gz"
git = "https://gitlab.cern.ch/gaudi/xenv.git"
version('develop', branch='master')
version('1.0.0', sha256='cea9547295f0bd07c87e68353bb9eb1c2f2d1c09a840e3196c19cbc807ee4558')
depends_on('py-setuptools', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/kim-api/package.py
|
<filename>var/spack/repos/builtin/packages/kim-api/package.py
# Copyright 2013-2022 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 KimApi(CMakePackage):
"""OpenKIM is an online framework for making molecular simulations
reliable, reproducible, and portable. Computer implementations of
inter-atomic models are archived in OpenKIM, verified for coding
integrity, and tested by computing their predictions for a variety
of material properties. Models conforming to the KIM application
programming interface (API) work seamlessly with major simulation
codes that have adopted the KIM API standard.
This package provides the kim-api library and supporting
utilities. It also provides a small set of example models.
To obtain all models archived at https://openkim.org that are
compatible with the kim-api package, install and activate the
openkim-models package too.
"""
extendable = True
homepage = "https://openkim.org/"
url = "https://s3.openkim.org/kim-api/kim-api-2.2.1.txz"
git = "https://github.com/openkim/kim-api.git"
maintainers = ['ellio167']
version('develop', branch='devel')
version('2.2.1', sha256="1d5a12928f7e885ebe74759222091e48a7e46f77e98d9147e26638c955efbc8e")
version('2.1.3', sha256="88a5416006c65a2940d82fad49de0885aead05bfa8b59f87d287db5516b9c467")
version('2.1.2', sha256="16c7dd362cf95288b6288e1a76caf8baef652eb2cf8af500a5eb4767ba2fe80c")
version('2.1.1', sha256="25c4e83c6caa83a1c4ad480b430f1926fb44813b64f548fdaedc45e310b5f6b9")
version('2.1.0', sha256="d6b154b31b288ec0a5643db176950ed71f1ca83a146af210a1d5d01cce8ce958")
version('2.0.2', sha256="26e7cf91066692f316b8ba1548ccb7152bf56aad75902bce2338cff53e74e63d")
# The Fujitsu compiler requires the '--linkfortran'
# option to combine C++ and Fortran programs.
patch('fujitsu_add_link_flags.patch', when='%fj')
def patch(self):
# Remove flags not recognized by the NVIDIA compiler
if self.spec.satisfies('%nvhpc'):
filter_file('-std=gnu', '',
'examples/simulators/simulator-model-example/CMakeLists.txt')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/gchp/package.py
|
<filename>var/spack/repos/builtin/packages/gchp/package.py<gh_stars>1-10
# Copyright 2013-2022 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)
import shutil
from spack import *
class Gchp(CMakePackage):
"""GEOS-Chem High Performance model of atmospheric chemistry"""
homepage = "https://gchp.readthedocs.io/"
url = "https://github.com/geoschem/GCHP/archive/13.2.1.tar.gz"
git = "https://github.com/geoschem/GCHP.git"
maintainers = ['lizziel', 'la<PASSWORD>rada']
version('13.2.1', commit='<PASSWORD>cac684971fa9<PASSWORD>a<PASSWORD>ab8', submodules=True)
version('13.1.2', commit='<PASSWORD>', submodules=True)
version('13.1.1', commit='<KEY>', submodules=True)
version('13.1.0', commit='<PASSWORD>', submodules=True)
version('13.0.2', commit='<KEY>', submodules=True)
version('13.0.1', commit='<KEY>', submodules=True)
version('13.0.0', commit='<PASSWORD>30c5d066ff8306cbb8b83e267ca7c265', submodules=True)
version('dev', branch='dev', submodules=True)
patch('for_aarch64.patch', when='target=aarch64:')
depends_on('esmf@8.0.1', when='@13.0.0:')
depends_on('mpi@3')
depends_on('netcdf-fortran')
depends_on('cmake@3.13:')
depends_on('libfabric', when='+ofi')
depends_on('m4')
variant('omp', default=False, description="OpenMP parallelization")
variant('real8', default=True, description="REAL*8 precision")
variant('apm', default=False, description="APM Microphysics (Experimental)")
variant('rrtmg', default=False, description="RRTMG radiative transfer model")
variant('luo', default=False, description="Luo et al 2019 wet deposition scheme")
variant('tomas', default=False, description="TOMAS Microphysics (Experimental)")
variant('ofi', default=False, description="Build with Libfabric support")
def cmake_args(self):
args = [self.define("RUNDIR", self.prefix),
self.define_from_variant('OMP', 'omp'),
self.define_from_variant('USE_REAL8', 'real8'),
self.define_from_variant('APM', 'apm'),
self.define_from_variant('RRTMG', 'rrtmg'),
self.define_from_variant('LUO_WETDEP', 'luo'),
self.define_from_variant('TOMAS', 'tomas')]
return args
def install(self, spec, prefix):
super(Gchp, self).install(spec, prefix)
# Preserve source code in prefix for two reasons:
# 1. Run directory creation occurs independently of code compilation,
# possibly multiple times depending on user needs,
# and requires the preservation of some of the source code structure.
# 2. Run configuration is relatively complex and can result in error
# messages that point to specific modules / lines of the source code.
# Including source code thus facilitates runtime debugging.
shutil.move(self.stage.source_path,
join_path(prefix, 'source_code'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/apfel/package.py
|
<filename>var/spack/repos/builtin/packages/apfel/package.py
# Copyright 2013-2022 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 Apfel(AutotoolsPackage):
"""APFEL is a library able to perform DGLAP evolution up to NNLO in QCD and
to NLO in QED, both with pole and MSbar masses. The coupled DGLAP
QCD+QED evolution equations are solved in x-space by means of higher
order interpolations and Runge-Kutta techniques."""
homepage = "https://github.com/scarrazza/apfel"
url = "https://github.com/scarrazza/apfel/archive/3.0.4.tar.gz"
tags = ['hep']
version('3.0.4', sha256='c7bfae7fe2dc0185981850f2fe6ae4842749339d064c25bf525b4ef412bbb224')
depends_on('swig', when='+python')
depends_on('python', when='+python', type=('build', 'run'))
depends_on('lhapdf', when='+lhapdf', type=('build', 'run'))
variant('python', description='Build python wrapper', default=False)
variant('lhapdf', description='Link to LHAPDF', default=False)
def configure_args(self):
args = []
if self.spec.satisfies('~python'):
args.append('--disable-pywrap')
else:
args.append('--enable-pywrap')
args += self.enable_or_disable('lhapdf')
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-styler/package.py
|
# Copyright 2013-2022 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 RStyler(RPackage):
"""Non-Invasive Pretty Printing of R Code.
Pretty-prints R code without changing the user's formatting intent."""
cran = "styler"
version('1.6.2', sha256='a62fcc76aac851069f33874f9eaabdd580973b619cfc625d6ec910476015f75c')
version('1.3.2', sha256='3fcf574382c607c2147479bad4f9fa8b823f54fb1462d19ec4a330e135a44ff1')
depends_on('r-backports@1.1.0:', type=('build', 'run'))
depends_on('r-cli@1.1.0:', type=('build', 'run'))
depends_on('r-glue', type=('build', 'run'), when='@1.6.2:')
depends_on('r-magrittr@1.0.1:', type=('build', 'run'))
depends_on('r-magrittr@2.0.0:', type=('build', 'run'), when='@1.6.2:')
depends_on('r-purrr@0.2.3:', type=('build', 'run'))
depends_on('r-r-cache@0.14.0:', type=('build', 'run'))
depends_on('r-r-cache@0.15.0:', type=('build', 'run'), when='@1.6.2:')
depends_on('r-rematch2@2.0.1:', type=('build', 'run'))
depends_on('r-rlang@0.1.1:', type=('build', 'run'))
depends_on('r-rprojroot@1.1:', type=('build', 'run'))
depends_on('r-tibble@1.4.2:', type=('build', 'run'))
depends_on('r-withr@1.0.0:', type=('build', 'run'))
depends_on('r-xfun@0.1:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-timedate/package.py
|
<filename>var/spack/repos/builtin/packages/r-timedate/package.py
# Copyright 2013-2022 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 RTimedate(RPackage):
"""Rmetrics - Chronological and Calendar Objects.
The 'timeDate' class fulfils the conventions of the ISO 8601 standard as
well as of the ANSI C and POSIX standards. Beyond these standards it
provides the "Financial Center" concept which allows to handle data records
collected in different time zones and mix them up to have always the proper
time stamps with respect to your personal financial center, or
alternatively to the GMT reference time. It can thus also handle time
stamps from historical data records from the same time zone, even if the
financial centers changed day light saving times at different calendar
dates."""
cran = "timeDate"
version('3043.102', sha256='377cba03cddab8c6992e31d0683c1db3a73afa9834eee3e95b3b0723f02d7473')
version('3042.101', sha256='6c8d4c7689b31c6a43555d9c7258516556ba03b132e5643691e3e317b89a8c6d')
version('3012.100', sha256='6262ef7ca9f5eeb9db8229d6bb7a51d46d467a4fa73e2ccc5b4b78e18780c432')
depends_on('r@2.15.1:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin.mock/packages/module-path-separator/package.py
|
<filename>var/spack/repos/builtin.mock/packages/module-path-separator/package.py
# Copyright 2013-2022 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 ModulePathSeparator(Package):
homepage = "http://www.llnl.gov"
url = "http://www.llnl.gov/module-path-separator-1.0.tar.gz"
version(1.0, '0123456789abcdef0123456789abcdef')
def setup_environment(self, senv, renv):
renv.append_path("COLON", "foo")
renv.prepend_path("COLON", "foo")
renv.remove_path("COLON", "foo")
renv.append_path("SEMICOLON", "bar", separator=";")
renv.prepend_path("SEMICOLON", "bar", separator=";")
renv.remove_path("SEMICOLON", "bar", separator=";")
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/pdf2svg/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 Pdf2svg(AutotoolsPackage):
"""A simple PDF to SVG converter using the Poppler and Cairo libraries."""
homepage = "http://www.cityinthesky.co.uk/opensource/pdf2svg"
url = "https://github.com/dawbarton/pdf2svg/archive/v0.2.3.tar.gz"
version('0.2.3', sha256='4fb186070b3e7d33a51821e3307dce57300a062570d028feccd4e628d50dea8a')
version('0.2.2', sha256='e5f1d9b78821e44cd85379fb07f38a42f00bb2bde3743b95301ff8c0a5ae229a')
depends_on('pkgconfig@0.9.0:', type='build')
depends_on('cairo@1.2.6:')
depends_on('poppler@0.5.4:+glib')
# Note: the latest version of poppler requires glib 2.41+,
# but pdf2svg uses g_type_init, which is deprecated in glib 2.36+.
# At some point, we will need to force pdf2svg to use older
# versions of poppler and glib.
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/openscenegraph/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 Openscenegraph(CMakePackage):
"""OpenSceneGraph is an open source, high performance 3D graphics toolkit
that's used in a variety of visual simulation applications."""
homepage = "http://www.openscenegraph.org"
git = "https://github.com/openscenegraph/OpenSceneGraph.git"
url = "https://github.com/openscenegraph/OpenSceneGraph/archive/OpenSceneGraph-3.6.4.tar.gz"
version('3.6.5', sha256='aea196550f02974d6d09291c5d83b51ca6a03b3767e234a8c0e21322927d1e12')
version('3.6.4', sha256='81394d1b484c631028b85d21c5535280c21bbd911cb058e8746c87e93e7b9d33')
version('3.4.1', sha256='930eb46f05781a76883ec16c5f49cfb29a059421db131005d75bec4d78401fd5')
version('3.4.0', sha256='0d5efe12b923130d14a6fce5866675d7625fcfb1c004c9f9b10034b9feb61ac2')
version('3.2.3', sha256='a1ecc6524197024834e1277916922b32f30246cb583e27ed19bf3bf889534362')
version('3.1.5', sha256='dddecf2b33302076712100af59b880e7647bc595a9a7cc99186e98d6e0eaeb5c')
variant('shared', default=True, description='Builds a shared version of the library')
variant('ffmpeg', default=False, description='Builds ffmpeg plugin for audio encoding/decoding')
depends_on('cmake@2.8.7:', type='build')
depends_on('gl')
depends_on('qt+opengl', when='@:3.5.4') # Qt windowing system was moved into separate osgQt project
depends_on('qt@4:', when='@3.2:3.5.4')
depends_on('qt@:4', when='@:3.1')
depends_on('libxinerama')
depends_on('libxrandr')
depends_on('libpng')
depends_on('jasper')
depends_on('libtiff')
depends_on('glib')
depends_on('zlib')
depends_on('ffmpeg+avresample', when='+ffmpeg')
# https://github.com/openscenegraph/OpenSceneGraph/issues/167
depends_on('ffmpeg@:2', when='@:3.4.0+ffmpeg')
patch('glibc-jasper.patch', when='@3.4%gcc')
def cmake_args(self):
spec = self.spec
shared_status = 'ON' if '+shared' in spec else 'OFF'
opengl_profile = 'GL{0}'.format(spec['gl'].version.up_to(1))
args = [
# Variant Options #
'-DDYNAMIC_OPENSCENEGRAPH={0}'.format(shared_status),
'-DDYNAMIC_OPENTHREADS={0}'.format(shared_status),
'-DOPENGL_PROFILE={0}'.format(opengl_profile),
# General Options #
'-DBUILD_OSG_APPLICATIONS=OFF',
'-DOSG_NOTIFY_DISABLED=ON',
'-DLIB_POSTFIX=',
'-DCMAKE_RELWITHDEBINFO_POSTFIX=',
'-DCMAKE_MINSIZEREL_POSTFIX='
]
if spec.satisfies('~ffmpeg'):
for ffmpeg_lib in ['libavcodec', 'libavformat', 'libavutil']:
args.extend([
'-DFFMPEG_{0}_INCLUDE_DIRS='.format(ffmpeg_lib.upper()),
'-DFFMPEG_{0}_LIBRARIES='.format(ffmpeg_lib.upper()),
])
# NOTE: This is necessary in order to allow OpenSceneGraph to compile
# despite containing a number of implicit bool to int conversions.
if spec.satisfies('%gcc'):
args.extend([
'-DCMAKE_C_FLAGS=-fpermissive',
'-DCMAKE_CXX_FLAGS=-fpermissive',
])
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-pyproj/package.py
|
<filename>var/spack/repos/builtin/packages/py-pyproj/package.py
# Copyright 2013-2022 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 PyPyproj(PythonPackage):
"""Python interface to PROJ (cartographic projections and
coordinate transformations library)."""
homepage = "https://github.com/pyproj4/pyproj"
pypi = "pyproj/pyproj-2.2.0.tar.gz"
git = "https://github.com/pyproj4/pyproj.git"
maintainers = ['citibeth', 'adamjstewart']
version('3.1.0', sha256='67b94f4e694ae33fc90dfb7da0e6b5ed5f671dd0acc2f6cf46e9c39d56e16e1a')
version('3.0.1', sha256='bfbac35490dd17f706700673506eeb8170f8a2a63fb5878171d4e6eef242d141')
version('3.0.0', sha256='539e320d06e5441edadad2e2ab276e1877445eca384fc1c056b5501453d433c2')
version('2.6.1', sha256='52556f245f1112f121091937b47738d1fbcbd0f13be6fb32689de31ab0975d24')
version('2.6.0', sha256='977542d2f8cf2981cf3ad72cedfebcd6ac56977c7aa830d9b49fa7888b56e83d')
version('2.2.0', sha256='0a4f793cc93539c2292638c498e24422a2ec4b25cb47545addea07724b2a56e5')
version('2.1.3', sha256='99c52788b01a7bb9a88024bf4d40965c0a66a93d654600b5deacf644775f424d')
version('1.9.6', sha256='e0c02b1554b20c710d16d673817b2a89ff94738b0b537aead8ecb2edc4c4487b', deprecated=True)
version('1.9.5.1', sha256='53fa54c8fa8a1dfcd6af4bf09ce1aae5d4d949da63b90570ac5ec849efaf3ea8', deprecated=True)
# In setup.cfg and setup.py
depends_on('python@3.7:', when='@3.1:', type=('build', 'link', 'run'))
depends_on('python@3.6:', when='@3.0:', type=('build', 'link', 'run'))
depends_on('python@3.5:', when='@2.3:', type=('build', 'link', 'run'))
depends_on('python@2.7:2.8,3.5:', when='@2.2:', type=('build', 'link', 'run'))
depends_on('python@2.6:2.8,3.3:', type=('build', 'link', 'run'))
# In setup.py
# https://pyproj4.github.io/pyproj/stable/installation.html#installing-from-source
depends_on('proj')
depends_on('proj@7.2:', when='@3.0.1:')
depends_on('proj@7.2.0:7.2', when='@3.0.0')
depends_on('proj@6.2:7.0', when='@2.4:2.6')
depends_on('proj@6.1:7.0', when='@2.2:2.3')
depends_on('proj@6.0:6', when='@2.0:2.1')
depends_on('proj@:5.2', when='@:1.9')
# In setup.py
depends_on('py-setuptools', type='build')
depends_on('py-certifi', when='@3.0:', type=('build', 'run'))
depends_on('py-aenum', when='@2.2.0:2.2 ^python@:3.5', type=('build', 'run'))
# In pyproject.toml
depends_on('py-cython@0.28.4:', when='@2.0:')
def setup_build_environment(self, env):
# https://pyproj4.github.io/pyproj/stable/installation.html#pyproj-build-environment-variables
env.set('PROJ_VERSION', self.spec['proj'].version)
env.set('PROJ_DIR', self.spec['proj'].prefix)
env.set('PROJ_LIBDIR', self.spec['proj'].libs.directories[0])
env.set('PROJ_INCDIR', self.spec['proj'].headers.directories[0])
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/parsimonator/package.py
|
# Copyright 2013-2022 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)
class Parsimonator(MakefilePackage):
"""Parsimonator is a no-frills light-weight implementation for building
starting trees under parsimony for RAxML.
"""
homepage = "http://www.exelixis-lab.org/"
git = "https://github.com/stamatak/Parsimonator-1.0.2.git"
version('1.0.2', commit='<PASSWORD>')
patch('nox86.patch')
@property
def makefile_file(self):
if self.spec.target.family != 'x86_64':
return 'Makefile.nosse'
if 'avx' in self.spec.target:
return 'Makefile.AVX.gcc'
elif 'sse3' in self.spec.target:
return 'Makefile.SSE3.gcc'
return 'Makefile.gcc'
def edit(self, spec, prefix):
makefile = FileFilter(self.makefile_file)
makefile.filter('CC = gcc', 'CC = %s' % spack_cc)
def build(self, spec, prefix):
make('-f', self.makefile_file)
def install(self, spec, prefix):
mkdirp(prefix.bin)
if 'avx' in self.spec.target:
install('parsimonator-AVX', prefix.bin)
elif 'sse3' in self.spec.target:
install('parsimonator-SSE3', prefix.bin)
else:
install('parsimonator', prefix.bin)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/autodiff/package.py
|
# Copyright 2013-2022 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 Autodiff(CMakePackage):
"""autodiff is automatic differentiation made easier for C++."""
homepage = "https://autodiff.github.io"
url = "https://github.com/autodiff/autodiff/archive/refs/tags/v0.6.4.tar.gz"
list_url = "https://github.com/autodiff/autodiff/releases"
git = "https://github.com/autodiff/autodiff.git"
maintainers = ['wdconinc', 'HadrienG2']
version('0.6.4', sha256='cfe0bb7c0de10979caff9d9bfdad7e6267faea2b8d875027397486b47a7edd75')
version('0.5.13', sha256='a73dc571bcaad6b44f74865fed51af375f5a877db44321b5568d94a4358b77a1')
variant('python', default='False', description='Enable the compilation of the python bindings.')
variant('examples', default='False', description='Enable the compilation of the example files.')
depends_on('cmake@3.0:', type='build')
depends_on('eigen')
depends_on('py-pybind11', type=('build', 'run'))
def cmake_args(self):
args = [
self.define('AUTODIFF_BUILD_TESTS', self.run_tests),
self.define_from_variant('AUTODIFF_BUILD_PYTHON', 'python'),
self.define_from_variant('AUTODIFF_BUILD_EXAMPLES', 'examples',)
]
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-ellipse/package.py
|
# Copyright 2013-2022 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 REllipse(RPackage):
"""Functions for Drawing Ellipses and Ellipse-Like Confidence Regions.
Contains various routines for drawing ellipses and ellipse-like confidence
regions, implementing the plots described in Murdoch and Chow (1996), A
graphical display of large correlation matrices, The American Statistician
50, 178-180. There are also routines implementing the profile plots
described in Bates and Watts (1988), Nonlinear Regression Analysis and its
Applications."""
cran = "ellipse"
version('0.4.2', sha256='1719ce9a00b9ac4d56dbf961803085b892d3359726fda3567bb989ddfed9a5f2')
version('0.4.1', sha256='1a9a9c52195b26c2b4d51ad159ab98aff7aa8ca25fdc6b2198818d1a0adb023d')
version('0.3-8', sha256='508d474c142f0770c25763d6c8f8f8c9dcf8205afd42ffa22e6be1e0360e7f45')
depends_on('r@2.0.0:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-dgl/package.py
|
# Copyright 2013-2022 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)
class PyDgl(CMakePackage):
"""Deep Graph Library (DGL).
DGL is an easy-to-use, high performance and scalable Python package for
deep learning on graphs. DGL is framework agnostic, meaning if a deep graph
model is a component of an end-to-end application, the rest of the logics
can be implemented in any major frameworks, such as PyTorch, Apache MXNet
or TensorFlow."""
homepage = "https://www.dgl.ai/"
git = "https://github.com/dmlc/dgl.git"
maintainers = ['adamjstewart']
version('master', branch='master', submodules=True)
version('0.4.3', tag='0.4.3', submodules=True)
version('0.4.2', tag='0.4.2', submodules=True)
variant('cuda', default=True, description='Build with CUDA')
variant('openmp', default=True, description='Build with OpenMP')
variant('backend', default='pytorch', description='Default backend',
values=['pytorch', 'mxnet', 'tensorflow'], multi=False)
depends_on('cmake@3.5:', type='build')
depends_on('cuda', when='+cuda')
depends_on('llvm-openmp', when='%apple-clang +openmp')
# Python dependencies
# See python/setup.py
extends('python')
depends_on('python@3.5:', type=('build', 'run'))
depends_on('py-pip', type='build')
depends_on('py-wheel', type='build')
depends_on('py-setuptools', type='build')
depends_on('py-cython', type='build')
depends_on('py-numpy@1.14.0:', type=('build', 'run'))
depends_on('py-scipy@1.1.0:', type=('build', 'run'))
depends_on('py-networkx@2.1:', type=('build', 'run'))
depends_on('py-requests@2.19.0:', when='@0.4.3:', type=('build', 'run'))
# Backends
# See https://github.com/dmlc/dgl#installation
depends_on('py-torch@1.2.0:', when='@0.4.3: backend=pytorch', type='run')
depends_on('py-torch@0.4.1:', when='backend=pytorch', type='run')
depends_on('mxnet@1.5.1:', when='@0.4.3: backend=pytorch', type='run')
depends_on('mxnet@1.5.0:', when='backend=mxnet', type='run')
depends_on('py-tensorflow@2.1:', when='@0.4.3: backend=tensorflow', type='run')
depends_on('py-tensorflow@2.0:', when='backend=tensorflow', type='run')
depends_on('py-tfdlpack', when='backend=tensorflow', type='run')
build_directory = 'build'
# https://docs.dgl.ai/install/index.html#install-from-source
def cmake_args(self):
args = []
if '+cuda' in self.spec:
args.append('-DUSE_CUDA=ON')
else:
args.append('-DUSE_CUDA=OFF')
if '+openmp' in self.spec:
args.append('-DUSE_OPENMP=ON')
if self.spec.satisfies('%apple-clang'):
args.extend([
'-DOpenMP_CXX_FLAGS=' +
self.spec['llvm-openmp'].headers.include_flags,
'-DOpenMP_CXX_LIB_NAMES=' +
self.spec['llvm-openmp'].libs.names[0],
'-DOpenMP_C_FLAGS=' +
self.spec['llvm-openmp'].headers.include_flags,
'-DOpenMP_C_LIB_NAMES=' +
self.spec['llvm-openmp'].libs.names[0],
'-DOpenMP_omp_LIBRARY=' +
self.spec['llvm-openmp'].libs[0],
])
else:
args.append('-DUSE_OPENMP=OFF')
if self.run_tests:
args.append('-DBUILD_CPP_TEST=ON')
else:
args.append('-DBUILD_CPP_TEST=OFF')
return args
def install(self, spec, prefix):
with working_dir('python'):
args = std_pip_args + ['--prefix=' + prefix, '.']
pip(*args)
# Work around installation bug: https://github.com/dmlc/dgl/issues/1379
install_tree(prefix.dgl, prefix.lib)
def setup_run_environment(self, env):
# https://docs.dgl.ai/install/backend.html
backend = self.spec.variants['backend'].value
env.set('DGLBACKEND', backend)
@property
def import_modules(self):
modules = [
'dgl', 'dgl.nn', 'dgl.runtime', 'dgl.backend', 'dgl.function',
'dgl.contrib', 'dgl._ffi', 'dgl.data', 'dgl.runtime.ir',
'dgl.backend.numpy', 'dgl.contrib.sampling', 'dgl._ffi._cy2',
'dgl._ffi._cy3', 'dgl._ffi._ctypes',
]
if 'backend=pytorch' in self.spec:
modules.extend([
'dgl.nn.pytorch', 'dgl.nn.pytorch.conv', 'dgl.backend.pytorch'
])
elif 'backend=mxnet' in self.spec:
modules.extend([
'dgl.nn.mxnet', 'dgl.nn.mxnet.conv', 'dgl.backend.mxnet'
])
elif 'backend=tensorflow' in self.spec:
modules.extend([
'dgl.nn.tensorflow', 'dgl.nn.tensorflow.conv',
'dgl.backend.tensorflow'
])
return modules
@run_after('install')
@on_package_attributes(run_tests=True)
def import_module_test(self):
with working_dir('spack-test', create=True):
for module in self.import_modules:
python('-c', 'import {0}'.format(module))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/mg/package.py
|
<reponame>player1537-forks/spack
# Copyright 2013-2022 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 Mg(Package):
"""Mg is intended to be a small, fast, and portable editor for people
who can't (or don't want to) run emacs for one reason or another,
or are not familiar with the vi editor. It is compatible with
emacs because there shouldn't be any reason to learn more editor
types than emacs or vi."""
homepage = "https://github.com/ibara/mg"
url = "https://github.com/ibara/mg/archive/mg-6.6.tar.gz"
version('6.6', sha256='e8440353da1a52ec7d40fb88d4f145da49c320b5ba31daf895b0b0db5ccd0632')
depends_on('ncurses')
phases = ['configure', 'build', 'install']
def configure(self, spec, prefix):
configure = Executable('./configure')
args = [
'--mandir={0}'.format(self.prefix.man),
'--prefix={0}'.format(self.prefix),
]
configure(*args)
def build(self, spec, prefix):
make()
def install(self, spec, prefix):
make('install')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/utf8cpp/package.py
|
# Copyright 2013-2022 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 Utf8cpp(Package):
"""A simple, portable and lightweight generic library for handling UTF-8
encoded strings."""
homepage = "http://utfcpp.sourceforge.net/"
version('2.3.4', sha256='3373cebb25d88c662a2b960c4d585daf9ae7b396031ecd786e7bb31b15d010ef')
def url_for_version(self, version):
url = "https://sourceforge.net/projects/utfcpp/files/utf8cpp_2x/Release%20{0}/utf8_v{1}.zip"
return url.format(version, version.underscored)
def install(self, spec, prefix):
install_tree('doc', prefix.share.doc)
install_tree('source', prefix.include)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-dosnow/package.py
|
# Copyright 2013-2022 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 RDosnow(RPackage):
"""Foreach Parallel Adaptor for the 'snow' Package.
Provides a parallel backend for the %dopar% function using the snow package
of Tierney, Rossini, Li, and Sevcikova."""
cran = "doSNOW"
version('1.0.19', sha256='4cd2d080628482f4c6ecab593313d7e42516f5ff13fbf9f90e461fcad0580738')
version('1.0.18', sha256='70e7bd82186e477e3d1610676d4c6a75258ac08f104ecf0dcc971550ca174766')
depends_on('r@2.5.0:', type=('build', 'run'))
depends_on('r-foreach@1.2.0:', type=('build', 'run'))
depends_on('r-iterators@1.0.0:', type=('build', 'run'))
depends_on('r-snow@0.3.0:', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-digest/package.py
|
# Copyright 2013-2022 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 RDigest(RPackage):
"""Create Compact Hash Digests of R Objects.
Implementation of a function 'digest()' for the creation of hash digests of
arbitrary R objects (using the md5, sha-1, sha-256, crc32, xxhash and
murmurhash algorithms) permitting easy comparison of R language objects, as
well as a function 'hmac()' to create hash-based message authentication
code. The md5 algorithm by <NAME> is specified in RFC 1321, the sha-1
and sha-256 algorithms are specified in FIPS-180-1 and FIPS-180-2, and the
crc32 algorithm is described in
ftp://ftp.rocksoft.com/cliens/rocksoft/papers/crc_v3.txt. For md5, sha-1,
sha-256 and aes, this package uses small standalone implementations that
were provided by Christophe Devine. For crc32, code from the zlib library
is used. For sha-512, an implementation by <NAME> is used. For
xxhash, the implementation by <NAME> is used. For murmurhash, an
implementation by Shane Day is used. Please note that this package is not
meant to be deployed for cryptographic purposes for which more
comprehensive (and widely tested) libraries such as OpenSSL should be
used."""
cran = "digest"
version('0.6.29', sha256='792c1f14a4c8047745152f5e45ce7351978af8d770c29d2ea39c7acd5d619cd9')
version('0.6.28', sha256='4a328c75e95f8522fc07390d1dd00c19fb643f558e761a8aed04f99c1dc7db00')
version('0.6.27', sha256='f485f75122907da24c41d4a62c91a232f0c371befd2f77e973342a1bef00253f')
version('0.6.25', sha256='15ccadb7b8bccaa221b6700bb549011719d0f4b38dbd3a1f29face3e019e2de5')
version('0.6.20', sha256='05674b0b5d888461ff770176c67b10a11be062b0fee5dbd9298f25a9a49830c7')
version('0.6.19', sha256='28d159bd589ecbd01b8da0826eaed417f5c1bf5a11b79e76bf67ce8d935cccf4')
version('0.6.12', sha256='a479463f120037ad8e88bb1387170842e635a1f07ce7e3575316efd6e14d9eab')
version('0.6.11', sha256='edab2ca2a38bd7ee19482c9d2531cd169d5123cde4aa2a3dd65c0bcf3d1d5209')
version('0.6.9', sha256='95fdc36011869fcfe21b40c3b822b931bc01f8a531e2c9260582ba79560dbe47')
depends_on('r@2.4.1:', type=('build', 'run'))
depends_on('r@3.1.0:', type=('build', 'run'), when='@0.6.16:')
depends_on('r@3.3.0:', type=('build', 'run'), when='@0.6.27:')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-prettydoc/package.py
|
<filename>var/spack/repos/builtin/packages/r-prettydoc/package.py
# Copyright 2013-2022 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 RPrettydoc(RPackage):
"""Creating Pretty Documents from R Markdown.
Creating tiny yet beautiful documents and vignettes from R Markdown. The
package provides the 'html_pretty' output format as an alternative to the
'html_document' and 'html_vignette' engines that convert R Markdown into
HTML pages. Various themes and syntax highlight styles are supported."""
cran = "prettydoc"
version('0.4.1', sha256='1094a69b026238d149435472b4f41c75151c7370a1be6c6332147c88ad4c4829')
depends_on('r-rmarkdown@1.17:', type=('build', 'run'))
depends_on('pandoc@1.12.3:', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/miniaero/package.py
|
<reponame>player1537-forks/spack<gh_stars>10-100
# Copyright 2013-2022 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 Miniaero(MakefilePackage):
"""Proxy Application. MiniAero is a mini-application for the evaulation
of programming models and hardware for next generation platforms.
"""
homepage = "https://mantevo.org"
git = "https://github.com/Mantevo/miniAero.git"
tags = ['proxy-app']
version('2016-11-11', commit='<PASSWORD>')
depends_on('kokkos-legacy')
@property
def build_targets(self):
targets = [
'--directory=kokkos',
'CXX=c++',
'KOKKOS_PATH={0}'.format(
self.spec['kokkos-legacy'].prefix)
]
return targets
def install(self, spec, prefix):
# Manual Installation
mkdirp(prefix.bin)
mkdirp(prefix.doc)
install('kokkos/miniAero.host', prefix.bin)
install('kokkos/README', prefix.doc)
install('kokkos/tests/3D_Sod_Serial/miniaero.inp', prefix.bin)
install_tree('kokkos/tests', prefix.doc.tests)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/perl-www-robotrules/package.py
|
# Copyright 2013-2022 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 PerlWwwRobotrules(PerlPackage):
"""Database of robots.txt-derived permissions"""
homepage = "http://deps.cpantesters.org/?module=WWW%3A%3ARobotRules;perl=latest"
url = "http://search.cpan.org/CPAN/authors/id/G/GA/GAAS/WWW-RobotRules-6.02.tar.gz"
version('6.02', sha256='46b502e7a288d559429891eeb5d979461dd3ecc6a5c491ead85d165b6e03a51e')
depends_on('perl-uri', type=('build', 'run'))
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/protobuf-c/package.py
|
# Copyright 2013-2022 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 ProtobufC(AutotoolsPackage):
"""
Protocol Buffers implementation in C
"""
homepage = "https://github.com/protobuf-c/protobuf-c"
url = "https://github.com/protobuf-c/protobuf-c/releases/download/v1.3.2/protobuf-c-1.3.2.tar.gz"
version('1.3.2', sha256='53f251f14c597bdb087aecf0b63630f434d73f5a10fc1ac545073597535b9e74')
depends_on('protobuf')
depends_on('pkgconfig', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/aom/package.py
|
# Copyright 2013-2022 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)
#
# Author: <NAME> <<EMAIL>>,
# Institution: Trinity Centre for High Performance Computing, https://www.tchpc.tcd.ie/ # noqa: E501
# Date: May 09, 2019
# Author: <NAME> <<EMAIL>>
# Institution: Trinity Centre for High Performance Computing, https://www.tchpc.tcd.ie/ # noqa: E501
# Date: May 09, 2019
#
from spack import *
class Aom(CMakePackage):
"""Alliance for Open Media AOM AV1 Codec Library"""
homepage = "https://aomedia.googlesource.com/aom"
git = "https://aomedia.googlesource.com/aom"
version('v1.0.0-errata1', commit='<PASSWORD>')
depends_on('yasm')
def cmake_args(self):
args = []
args.append('-DBUILD_SHARED_LIBS=ON')
return args
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/genomeworks/package.py
|
# Copyright 2013-2022 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 Genomeworks(CMakePackage, CudaPackage):
"""SDK for GPU accelerated genome assembly and analysis."""
homepage = "https://clara-parabricks.github.io/GenomeWorks/"
url = "https://github.com/clara-parabricks/GenomeWorks/archive/v0.5.3.tar.gz"
git = "https://github.com/clara-parabricks/GenomeWorks.git"
version('0.5.3', tag='v0.5.3', submodules=True)
version('0.5.2', tag='v0.5.2', submodules=True)
version('0.5.1', tag='v0.5.1', submodules=True)
version('0.5.0', tag='v0.5.0', submodules=True)
version('0.4.4', tag='v0.4.4', submodules=True)
version('0.4.3', tag='v0.4.3', submodules=True)
version('0.4.0', tag='v0.4.0', submodules=True)
version('0.3.0', tag='v0.3.0', submodules=True)
version('0.2.0', tag='v0.2.0', submodules=True)
depends_on('cmake@3.10.2:', type=('build'))
depends_on('cuda@11:', type=('build', 'run'))
depends_on('python@3.6.7:', type=('build', 'run'))
# Disable CUB compilation, as it is already included in CUDA 11.
# See https://github.com/clara-parabricks/GenomeWorks/issues/570
# This patch breaks GenomeWorks with Cuda <11, cuda@11: is
# therefore used as dependency.
patch('3rdparty.patch')
def cmake_args(self):
args = []
spec = self.spec
if '+cuda' in spec:
args.append('-DWITH_CUDA=ON')
args.append('-Dgw_cuda_gen_all_arch=ON')
args.append('-DTHRUST_IGNORE_CUB_VERSION_CHECK=ON')
cuda_arch = spec.variants['cuda_arch'].value
if cuda_arch != 'none':
args.append('-DCUDA_FLAGS=-arch=sm_{0}'.format(cuda_arch[0]))
else:
args.append('-DWITH_CUDA=OFF')
return args
|
player1537-forks/spack
|
lib/spack/spack/test/cmd/tags.py
|
# Copyright 2013-2022 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)
import spack.main
import spack.repo
import spack.spec
tags = spack.main.SpackCommand('tags')
def test_tags_bad_options():
out = tags('-a', 'tag1', fail_on_error=False)
assert "option OR provide" in out
def test_tags_no_installed(install_mockery, mock_fetch):
out = tags('-i')
assert 'No installed' in out
def test_tags_invalid_tag(mock_packages):
out = tags('nosuchtag')
assert 'None' in out
def test_tags_all_mock_tags(mock_packages):
out = tags()
for tag in ['tag1', 'tag2', 'tag3']:
assert tag in out
def test_tags_all_mock_tag_packages(mock_packages):
out = tags('-a')
for pkg in ['mpich\n', 'mpich2\n']:
assert pkg in out
def test_tags_no_tags(monkeypatch):
class tag_path():
tag_index = dict()
monkeypatch.setattr(spack.repo, 'path', tag_path)
out = tags()
assert "No tagged" in out
def test_tags_installed(install_mockery, mock_fetch):
spec = spack.spec.Spec('mpich').concretized()
pkg = spack.repo.get(spec)
pkg.do_install()
out = tags('-i')
for tag in ['tag1', 'tag2']:
assert tag in out
out = tags('-i', 'tag1')
assert 'mpich' in out
out = tags('-i', 'tag3')
assert 'No installed' in out
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-avro-python3/package.py
|
# Copyright 2013-2022 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 PyAvroPython3(PythonPackage):
"""Apache Avro is a data serialization system.
Note: lang/py3 version (this package) will be deprecated and lang/py
functions will be made available for both python2 and python3."""
homepage = "https://github.com/apache/avro/tree/master/lang/py3"
pypi = "avro-python3/avro-python3-1.10.0.tar.gz"
version('1.10.0', sha256='a455c215540b1fceb1823e2a918e94959b54cb363307c97869aa46b5b55bde05')
version('1.9.1', sha256='daab2cea71b942a1eb57d700d4a729e9d6cd93284d4dd4d65a378b9f958aa0d2')
depends_on('python@3.5:', when='@1.10:', type=('build', 'run'))
depends_on('python@3.4:', type=('build', 'run'))
depends_on('py-setuptools', type='build')
depends_on('py-isort', when='@1.10:', type='build')
depends_on('py-pycodestyle', when='@1.10:', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/py-asynctest/package.py
|
# Copyright 2013-2022 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 PyAsynctest(PythonPackage):
"""The package asynctest is built on top of the standard unittest module
and cuts down boilerplate code when testing libraries for asyncio."""
homepage = "https://asynctest.readthedocs.io"
pypi = "asynctest/asynctest-0.13.0.tar.gz"
version('0.13.0', sha256='c27862842d15d83e6a34eb0b2866c323880eb3a75e4485b079ea11748fd77fac')
depends_on('python@3.5:', type=('build', 'run'))
depends_on('py-setuptools@30.3:', type='build')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/json-c/package.py
|
# Copyright 2013-2022 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 JsonC(CMakePackage):
"""A JSON implementation in C."""
homepage = "https://github.com/json-c/json-c/wiki"
url = "https://s3.amazonaws.com/json-c_releases/releases/json-c-0.15.tar.gz"
version('0.15', sha256='b8d80a1ddb718b3ba7492916237bbf86609e9709fb007e7f7d4322f02341a4c6')
version('0.14', sha256='b377de08c9b23ca3b37d9a9828107dff1de5ce208ff4ebb35005a794f30c6870')
version('0.13.1', sha256='b87e608d4d3f7bfdd36ef78d56d53c74e66ab278d318b71e6002a369d36f4873')
version('0.12.1', sha256='2a136451a7932d80b7d197b10441e26e39428d67b1443ec43bbba824705e1123')
version('0.12', sha256='000c01b2b3f82dcb4261751eb71f1b084404fb7d6a282f06074d3c17078b9f3f')
version('0.11', sha256='28dfc65145dc0d4df1dfe7701ac173c4e5f9347176c8983edbfac9149494448c')
depends_on('autoconf', when='@:0.13.1', type='build')
parallel = False
@when('@0.12:0.12.1 %gcc@7:')
def patch(self):
filter_file('-Wextra',
'-Wextra -Wno-error=implicit-fallthrough '
'-Wno-error=unused-but-set-variable',
'Makefile.in')
@when('@:0.13.1')
def cmake(self, spec, prefix):
configure_args = ['--prefix=' + prefix]
configure(*configure_args)
@when('@:0.13.1')
def build(self, spec, prefix):
make()
@when('@:0.13.1')
def install(self, spec, prefix):
make('install')
@when('%cce@11.0.3:')
def patch(self):
filter_file('-Werror',
'',
'CMakeLists.txt')
@run_after('install')
def darwin_fix(self):
# The shared library is not installed correctly on Darwin; fix this
if 'platform=darwin' in self.spec:
fix_darwin_install_name(self.prefix.lib)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/oras/package.py
|
# Copyright 2013-2022 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)
import llnl.util.tty as tty
from llnl.util.filesystem import find
from spack import *
class Oras(Package):
"""ORAS means OCI Registry As Storage"""
homepage = "https://oras.land"
git = "https://github.com/oras-project/oras"
url = "https://github.com/oras-project/oras/archive/refs/tags/v0.12.0.tar.gz"
maintainers = ['vsoch']
version('main', branch="main")
version("0.12.0", sha256="5e19d61683a57b414efd75bd1b0290c941b8faace5fcc9d488f5e4aa674bf03e")
depends_on("go", type='build')
def setup_build_environment(self, env):
# Point GOPATH at the top of the staging dir for the build step.
env.prepend_path('GOPATH', self.stage.path)
def install(self, spec, prefix):
if self.spec.satisfies('platform=linux target=aarch64:'):
make("build-linux-arm64")
elif self.spec.satisfies('platform=linux'):
make("build-linux")
elif self.spec.satisfies('platform=darwin target=aarch64:'):
make("build-mac-arm64")
elif self.spec.satisfies('platform=darwin'):
make("build-mac")
elif self.spec.satisfies('platform=windows'):
make("build-windows")
mkdirp(prefix.bin)
oras = find("bin", "oras")
if not oras:
tty.die("Oras executable missing in bin.")
tty.debug("Found oras executable %s to move into install bin" % oras[0])
install(oras[0], prefix.bin)
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/r-zeallot/package.py
|
# Copyright 2013-2022 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 RZeallot(RPackage):
"""Multiple, Unpacking, and Destructuring Assignment.
Provides a %<-% operator to perform multiple, unpacking, and destructuring
assignment in R. The operator unpacks the right-hand side of an assignment
into multiple values and assigns these values to variables on the left-hand
side of the assignment."""
cran = "zeallot"
version('0.1.0', sha256='439f1213c97c8ddef9a1e1499bdf81c2940859f78b76bc86ba476cebd88ba1e9')
|
player1537-forks/spack
|
var/spack/repos/builtin/packages/patchutils/package.py
|
<gh_stars>10-100
# Copyright 2013-2022 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 Patchutils(AutotoolsPackage):
"""This is patchutils, a collection of tools that operate on patch
files."""
homepage = "http://cyberelk.net/tim/software/patchutils/"
url = "http://cyberelk.net/tim/data/patchutils/stable/patchutils-0.4.2.tar.xz"
version('0.4.2', sha256='8875b0965fe33de62b890f6cd793be7fafe41a4e552edbf641f1fed5ebbf45ed')
version('0.4.0', sha256='da6df1fa662b635c2969e7d017e6f32f5b39f1b802673a0af635e4936d4bc2f4')
version('0.3.4', sha256='cf55d4db83ead41188f5b6be16f60f6b76a87d5db1c42f5459d596e81dabe876')
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.