From cdeecf2507d92c41625c9d7d3ee21b973c404f5b Mon Sep 17 00:00:00 2001 From: dunatotatos Date: Fri, 16 Oct 2020 10:17:32 +0200 Subject: GenomeWorks: added new package at v0.5.3 (#19263) --- .../builtin/packages/genomeworks/3rdparty.patch | 11 +++++ .../repos/builtin/packages/genomeworks/package.py | 48 ++++++++++++++++++++++ 2 files changed, 59 insertions(+) create mode 100644 var/spack/repos/builtin/packages/genomeworks/3rdparty.patch create mode 100644 var/spack/repos/builtin/packages/genomeworks/package.py (limited to 'var') diff --git a/var/spack/repos/builtin/packages/genomeworks/3rdparty.patch b/var/spack/repos/builtin/packages/genomeworks/3rdparty.patch new file mode 100644 index 0000000000..34930a25ee --- /dev/null +++ b/var/spack/repos/builtin/packages/genomeworks/3rdparty.patch @@ -0,0 +1,11 @@ +--- a/cmake/3rdparty.cmake 2020-10-08 19:23:46.717478760 +0200 ++++ b/cmake/3rdparty.cmake 2020-10-08 19:26:29.251160827 +0200 +@@ -46,7 +46,7 @@ + add_library(cub INTERFACE IMPORTED) + #target_include_directories(cub INTERFACE ${CUB_DIR}>) does not work with + #cmake before 3.11, use the following for now: +-set_property(TARGET cub APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${CUB_DIR}") +-#set_property(TARGET cub APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${CUB_DIR}") + + set(KSEQPP_DIR ${PROJECT_SOURCE_DIR}/3rdparty/kseqpp/src CACHE STRING + "Path to kseqpp repo") diff --git a/var/spack/repos/builtin/packages/genomeworks/package.py b/var/spack/repos/builtin/packages/genomeworks/package.py new file mode 100644 index 0000000000..fce2e91d81 --- /dev/null +++ b/var/spack/repos/builtin/packages/genomeworks/package.py @@ -0,0 +1,48 @@ +# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack import * + + +class 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 -- cgit v1.2.3-70-g09d2