1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
# 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.package import *
class Simsipm(CMakePackage):
"""SimSiPM is a simple and easy to use C++ library providing a set of
object-oriented tools with all the functionality needed to describe
and simulate Silicon PhotonMultipliers (SiPM) sensors."""
url = "https://github.com/EdoPro98/SimSiPM/archive/refs/tags/v1.2.4.tar.gz"
homepage = "https://github.com/EdoPro98/SimSiPM/"
git = "https://github.com/EdoPro98/SimSiPM.git"
tags = ['hep']
maintainers = ['vvolkl']
version('1.2.4', sha256='1c633bebb19c490b5e6dfa5ada4a6bc7ec36348237c2626d57843a25af923211')
variant('python', default=False, description="Build pybind11-based python bindings")
variant('openmp', default=False, description="Use OpenMP")
extends('python', when='+python')
depends_on('python@3.6:', when="+python", type=('build', 'run'))
depends_on('py-pybind11', when="+python", type=('build', 'link'))
def cmake_args(self):
args = [
self.define_from_variant("SIPM_BUILD_PYTHON", "python"),
self.define_from_variant("SIPM_ENABLE_OPENMP", "openmp"),
self.define("SIPM_ENABLE_TEST", self.run_tests),
]
return args
|