Skip to content

{bio}[GCC/9.3.0] SRA-Toolkit v2.10.8 #11161

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
102 changes: 102 additions & 0 deletions easybuild/easyconfigs/s/SRA-Toolkit/SRA-Toolkit-2.10.8-GCC-9.3.0.eb
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
easyblock = 'Bundle'

name = 'SRA-Toolkit'
version = '2.10.8'

homepage = 'https://github.com/ncbi/sra-tools'
description = """The SRA Toolkit, and the source-code SRA System Development
Kit (SDK), will allow you to programmatically access data housed within SRA
and convert it from the SRA format"""
github_account = 'ncbi'

toolchain = {'name': 'GCC', 'version': '9.3.0'}

builddependencies = [
('Perl', '5.30.2'),
('Python', '3.8.2'),
]

dependencies = [
('NGS', '2.10.5'),
('file', '5.38'), # provides libmagic
('HDF5.Serial', '1.10.6'),
('libxml2', '2.9.10'),
]

# Linking HDF5 dynamically instead of statically
local_base_preconfig = "sed -i 's/-lhdf5 -Wl,-Bdynamic/-Wl,-Bdynamic -lhdf5 -Wl,-Bdynamic/' setup/konfigure.perl && "

# Change default build directory and add paths to dependencies in EB
local_base_config = '--build-prefix=%(builddir)s --with-ngs-sdk-prefix=$EBROOTNGS '
local_base_config += '--with-hdf5-prefix=$EBROOTHDF5SERIAL --with-xml2-prefix=$EBROOTLIBXML2'
local_vdb_config = local_base_config + ' --with-ngs-java-prefix=$EBROOTNGS/jar/ngs-java.jar'
# SRA-Tools need the source and build directory of NCBI-VDB
local_sra_config = local_base_config + ' --with-ncbi-vdb-sources=%(builddir)s/ncbi-vdb-%(version)s'
local_sra_config += ' --with-ncbi-vdb-build=%(builddir)s/ncbi-vdb '

# Replace hardcoded optimization flags with flags from EB
local_base_prebuild = "find build/ -name \"Makefile*\" -exec sed -i 's/-O3/$(EBFLAGS)/g' {} + && "
local_base_prebuild += 'EBFLAGS="$CFLAGS" '
local_base_preinstall = 'EBFLAGS="$CFLAGS" '

# Standalone compilation of utf8proc to ensure that its shared objects are available
local_sra_prebuild = "make -C tools/driver-tool/utf8proc && "
# Linking libxml2 dynamically
local_sra_prebuild += "find build/ -name \"ld*.sh\" -exec sed -i 's/-lxml2/-Wl,-Bdynamic -lxml2/g' {} + && "
local_sra_prebuild += local_base_prebuild

default_easyblock = 'ConfigureMake'
default_component_specs = {
'source_urls': [GITHUB_LOWER_SOURCE],
'sources': [{'download_filename': '%(version)s.tar.gz', 'filename': SOURCE_TAR_GZ}],
'start_dir': '%(namelower)s-%(version)s',
'preconfigopts': local_base_preconfig,
'preinstallopts': local_base_preinstall,
}

components = [
# NCBI-VDB has to be installed as component instead of dependency because SRA-Tools needs its sources
('NCBI-VDB', version, {
'patches': ['NCBI-VDB-%(version)s_fix-LD_LIBRARY_PATH.patch'],
'checksums': [
'7a593aa22584db9443bb56ac01409707bca01b8f9601fe530dac81b73f1a44df', # NCBI-VDB-2.10.8.tar.gz
# NCBI-VDB-2.10.8_fix-LD_LIBRARY_PATH.patch
'e8f22dbd0c2e564e296bafdf76ba0e0e2da0d13e22be5aaf322135e5f26eb133',
],
'configopts': local_vdb_config,
'prebuildopts': local_base_prebuild,
}),
('SRA-Tools', version, {
'patches': ['SRA-Toolkit-%(version)s_fix-LD_LIBRARY_PATH.patch'],
'checksums': [
'4adb969a9a998f6a50020f99aa66f6ae27916f7dc83ddf6722fc0fea4a3a4d17', # SRA-Tools-2.10.8.tar.gz
# SRA-Toolkit-2.10.8_fix-LD_LIBRARY_PATH.patch
'cac8e8db25c25ce2e06c3354b27c31dcad613beda3d76e70074f446dff84e63f',
],
'configopts': local_sra_config,
'prebuildopts': local_sra_prebuild,
}),
]

local_bin = ['abi-dump', 'abi-load', 'align-info', 'bam-load', 'cache-mgr', 'cg-load', 'copycat', 'fasterq-dump',
'fastq-dump', 'fastq-load', 'helicos-load', 'illumina-dump', 'illumina-load', 'kar', 'kdbmeta', 'kget',
'latf-load', 'magic', 'pacbio-load', 'prefetch', 'rcexplain', 'sam-dump', 'sff-dump', 'sff-load',
'srapath', 'sra-pileup', 'sra-sort', 'sra-stat', 'sratools', 'srf-load', 'test-sra', 'vdb-config',
'vdb-copy', 'vdb-decrypt', 'vdb-dump', 'vdb-encrypt', 'vdb-lock', 'vdb-passwd', 'vdb-unlock',
'vdb-validate']

sanity_check_paths = {
'files': ['bin/%s' % x for x in local_bin] +
['include/ncbi-vdb/NGS.hpp', ('lib/libncbi-ngs-c++.a', 'lib64/libncbi-ngs-c++.a')] +
[('lib/libncbi-%s.%s' % (l, e), 'lib64/libncbi-%s.%s' % (l, e))
for l in ['vdb', 'wvdb'] for e in ['a', SHLIB_EXT]],
'dirs': []
}

sanity_check_commands = [
"abi-dump --help",
"kar --help",
"sra-sort --help",
]

moduleclass = 'bio'