Skip to content

Commit

Permalink
Merge pull request #70 from scimerman/main
Browse files Browse the repository at this point in the history
added SHAPEIT4: 4.2.0 & 4.2.2
  • Loading branch information
marieke-bijlsma authored Mar 4, 2024
2 parents 35dc41a + 4dd95ec commit c17b230
Show file tree
Hide file tree
Showing 3 changed files with 133 additions and 0 deletions.
46 changes: 46 additions & 0 deletions s/SHAPEIT4/SHAPEIT4-4.2.0-foss-2022a.eb
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
easyblock = "MakeCp"

name = 'SHAPEIT4'
version = '4.2.0'

homepage = 'https://odelaneau.github.io/shapeit4/'
description = """
SHAPEIT4 is a fast and accurate method for estimation of haplotypes
(aka phasing) for SNP array and high coverage sequencing data.
"""

toolchain = {'name': 'foss', 'version': '2022a'}
toolchainopts = {'opt': True, 'cstd': 'c++11'}

source_urls = [GITHUB_SOURCE]
sources = ['v%(version)s.tar.gz']
patches = ['SHAPEIT4_%(version)s_use_EB_settings.patch']
checksums = [
'329aa920be49b085c96b420d4f42ade7ba92eae8a202ecb2f71ca32a61955588', # v4.2.0.tar.gz
'c4a5a5d280463a7e39435239284702e0d13feb2eb10f902434874176c884516e', # SHAPEIT4_4.2.0_use_EB_settings.patch
]

github_account = 'odelaneau'
dependencies = [
('zlib', '1.2.12'),
('bzip2', '1.0.8'),
('XZ', '5.2.5'),
('Boost', '1.79.0'),
('HTSlib', '1.14'),
]

buildopts = 'HTSLIB_INC="$EBROOTHTSLIB/include" HTSLIB_LIB=-lhts '
buildopts += 'BOOST_INC="$EBROOTBOOST/include" BOOST_LIB_IO=-lboost_iostreams BOOST_LIB_PO=-lboost_program_options '
buildopts += 'CXX="$CXX" CXXFLAG="$CXXFLAGS" LDFLAG="$CXXFLAGS" '

files_to_copy = [(['bin/shapeit4.2'], 'bin'), 'maps']

sanity_check_paths = {
'files': ["bin/shapeit4.2"],
'dirs': ['maps']
}

sanity_check_commands = ['shapeit4.2 --help']

moduleclass = 'bio'

46 changes: 46 additions & 0 deletions s/SHAPEIT4/SHAPEIT4-4.2.2-foss-2022a.eb
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
easyblock = "MakeCp"

name = 'SHAPEIT4'
version = '4.2.2'

homepage = 'https://odelaneau.github.io/shapeit4/'
description = """
SHAPEIT4 is a fast and accurate method for estimation of haplotypes
(aka phasing) for SNP array and high coverage sequencing data.
"""

toolchain = {'name': 'foss', 'version': '2022a'}
toolchainopts = {'opt': True, 'cstd': 'c++11'}

source_urls = [GITHUB_SOURCE]
sources = ['v%(version)s.tar.gz']
patches = ['SHAPEIT4_%(version)s_use_EB_settings.patch']
checksums = [
'9f109e307b5cc22ab68e7bf77de2429a9bbb2212d66303386e6a3dd81a5bc556', # v4.2.2.tar.gz
'92ed45545bfcde7b1fbe079e6321ccae00865c8f0f66a924e872967d762df885', # SHAPEIT4_4.2.2_use_EB_settings.patch
]

github_account = 'odelaneau'
dependencies = [
('zlib', '1.2.12'),
('bzip2', '1.0.8'),
('XZ', '5.2.5'),
('Boost', '1.79.0'),
('HTSlib', '1.14'),
]

buildopts = 'HTSLIB_INC="$EBROOTHTSLIB/include" HTSLIB_LIB=-lhts '
buildopts += 'BOOST_INC="$EBROOTBOOST/include" BOOST_LIB_IO=-lboost_iostreams BOOST_LIB_PO=-lboost_program_options '
buildopts += 'CXX="$CXX" CXXFLAG="$CXXFLAGS" LDFLAG="$CXXFLAGS" '

files_to_copy = [(['bin/shapeit4.2'], 'bin'), 'maps']

sanity_check_paths = {
'files': ["bin/shapeit4.2"],
'dirs': ['maps']
}

sanity_check_commands = ['shapeit4.2 --help']

moduleclass = 'bio'

41 changes: 41 additions & 0 deletions s/SHAPEIT4/SHAPEIT4_use_EB_settings.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
Don't use the hardcoded values in the makefile

Åke Sandgren, 20200615
diff --git a/makefile b/makefile
index c0bd9d2..808b7cd 100644
--- a/makefile
+++ b/makefile
@@ -1,14 +1,14 @@
#COMPILER MODE C++11
-CXX=g++ -std=c++11
+#CXX=g++ -std=c++11

#HTSLIB LIBRARY [SPECIFY YOUR OWN PATHS]
-HTSLIB_INC=$(HOME)/Tools/htslib-1.9
-HTSLIB_LIB=$(HOME)/Tools/htslib-1.9/libhts.a
+#HTSLIB_INC=$(HOME)/Tools/htslib-1.9
+#HTSLIB_LIB=$(HOME)/Tools/htslib-1.9/libhts.a

#BOOST IOSTREAM & PROGRAM_OPTION LIBRARIES [SPECIFY YOUR OWN PATHS]
-BOOST_INC=/usr/include
-BOOST_LIB_IO=/usr/lib/x86_64-linux-gnu/libboost_iostreams.a
-BOOST_LIB_PO=/usr/lib/x86_64-linux-gnu/libboost_program_options.a
+#BOOST_INC=/usr/include
+#BOOST_LIB_IO=/usr/lib/x86_64-linux-gnu/libboost_iostreams.a
+#BOOST_LIB_PO=/usr/lib/x86_64-linux-gnu/libboost_program_options.a

#HTSLIB LIBRARY [SPECIFY YOUR OWN PATHS]
#HTSLIB_INC=/software/UHTS/Analysis/samtools/1.4/include
@@ -23,10 +23,10 @@ BOOST_LIB_PO=/usr/lib/x86_64-linux-gnu/libboost_program_options.a
#Best performance is achieved with this. Use it if running on the same plateform you're compiling, it's definitely worth it!
#CXXFLAG=-O3 -march=native
#Good performance and portable on most intel CPUs
-CXXFLAG=-O3 -mavx2 -mfma
+#CXXFLAG=-O3 -mavx2 -mfma
#Portable version without avx2 (much slower)
#CXXFLAG=-O3
-LDFLAG=-O3
+#LDFLAG=-O3

#DYNAMIC LIBRARIES
DYN_LIBS=-lz -lbz2 -lm -lpthread -llzma

0 comments on commit c17b230

Please sign in to comment.