summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael R. Crusoe <michael.crusoe@gmail.com>2020-03-01 11:30:18 +0100
committerMichael R. Crusoe <michael.crusoe@gmail.com>2020-04-04 09:43:42 +0200
commit8ce2630841927af5b96fa30896ae802e30abcb15 (patch)
tree6567e37c84a8b71b9c8231428a78c53ba7ed1961
parentc2b1d2c27a360a96eb55e91268f107f614b5a618 (diff)
Freshen patches
-rw-r--r--debian/changelog1
-rw-r--r--debian/patches/2to3.patch248
-rw-r--r--debian/patches/correct_64bit_test56
-rw-r--r--debian/patches/drop-not-needed-js-from-manual.patch4
-rw-r--r--debian/patches/hardening.patch20
-rw-r--r--debian/patches/no_sanity133
-rw-r--r--debian/patches/reproducible.patch20
-rw-r--r--debian/patches/series1
-rw-r--r--debian/patches/simde16
-rw-r--r--debian/patches/wrong-interpreter-path.patch95
10 files changed, 229 insertions, 365 deletions
diff --git a/debian/changelog b/debian/changelog
index 7589324..8018b0e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,7 @@ bowtie2 (2.4.1-1) UNRELEASED; urgency=medium
2-3+ hours to fail, so lets be nice and skip them.
Patches to fix 32-bit archs are very welcomed!
* Standards-Version: 4.5.0 (routine-update)
+ * Freshen patches
-- Michael R. Crusoe <michael.crusoe@gmail.com> Thu, 19 Dec 2019 11:52:41 -0800
diff --git a/debian/patches/2to3.patch b/debian/patches/2to3.patch
deleted file mode 100644
index 2daaf5f..0000000
--- a/debian/patches/2to3.patch
+++ /dev/null
@@ -1,248 +0,0 @@
-Description: Use 2to3 to port to Python3
-Bug-Debian: https://bugs.debian.org/936233
-Author: Andreas Tille <tille@debian.org>
-Last-Update: Wed, 04 Sep 2019 15:18:29 +0200
-
---- a/Makefile
-+++ b/Makefile
-@@ -481,11 +481,11 @@
-
- bowtie2-build.bat:
- echo "@echo off" > bowtie2-build.bat
-- echo "python %~dp0/bowtie2-build %*" >> bowtie2-build.bat
-+ echo "python3 %~dp0/bowtie2-build %*" >> bowtie2-build.bat
-
- bowtie2-inspect.bat:
- echo "@echo off" > bowtie2-inspect.bat
-- echo "python %~dp0/bowtie2-inspect %*" >> bowtie2-inspect.bat
-+ echo "python3 %~dp0/bowtie2-inspect %*" >> bowtie2-inspect.bat
-
- .PHONY: bowtie2-src-pkg
- bowtie2-src-pkg: $(SRC_PKG_LIST)
---- a/scripts/sa.py
-+++ b/scripts/sa.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
-
- """
- sa.py
-@@ -15,7 +15,7 @@
- def loadBowtieSa(fh):
- """ Load a .sa file from handle into an array of ints """
- nsa = struct.unpack('I', fh.read(4))[0]
-- return [ struct.unpack('I', fh.read(4))[0] for i in xrange(0, nsa) ]
-+ return [ struct.unpack('I', fh.read(4))[0] for i in range(0, nsa) ]
-
- def loadBowtieSaFilename(fn):
- """ Load a .sa file from filename into an array of ints """
-@@ -58,7 +58,7 @@
- # Suffix array is in sas; note that $ is considered greater than all
- # other characters
- if ref is not None:
-- for i in xrange(1, len(sas)):
-+ for i in range(1, len(sas)):
- sa1, sa2 = sas[i-1], sas[i]
- assert sa1 != sa2
- # Sanity check that suffixes are really in order
-@@ -76,4 +76,4 @@
- assert sas[-1] == len(ref)
-
- go()
--
-\ No newline at end of file
-+
---- a/scripts/test/README.md
-+++ b/scripts/test/README.md
-@@ -17,7 +17,7 @@
-
- From root:
-
-- python scripts/test/regressions.py --verbose
-+ python3 scripts/test/regressions.py --verbose
-
- Val Antonescu originally set these up.
-
-@@ -27,7 +27,7 @@
-
- From root:
-
-- python scripts/test/large_idx.py --verbose
-+ python3 scripts/test/large_idx.py --verbose
-
- #### Randomized tests
-
---- a/scripts/test/benchmark/benchmarks.py
-+++ b/scripts/test/benchmark/benchmarks.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
- """
- A few items to deal with sets of benchmarks.
- """
-@@ -57,7 +57,7 @@
- self.set_idx = 0
- return self
-
-- def next(self):
-+ def __next__(self):
- if self.set_idx == len(self.values):
- raise StopIteration
-
-@@ -250,7 +250,7 @@
- delta = [0, 1]
- logging.debug("%s: missed (pos:%d vs %d)" % (q_name, orig[1], rec.pos))
- try:
-- mapq_summary[rec.mapq] = map(sum, zip(delta, mapq_summary[rec.mapq]))
-+ mapq_summary[rec.mapq] = list(map(sum, list(zip(delta, mapq_summary[rec.mapq]))))
- except KeyError:
- mapq_summary[rec.mapq] = delta
-
---- a/scripts/test/benchmark/run.py
-+++ b/scripts/test/benchmark/run.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
- """
- Runs benchmark sets specified in JSON files.
-
---- a/scripts/test/benchmark/samreader.py
-+++ b/scripts/test/benchmark/samreader.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
- """
- A reader of SAM format.
-
-@@ -49,7 +49,7 @@
- self.curr_idx = 0
- return self
-
-- def next(self):
-+ def __next__(self):
- if self.curr_idx == len(self.header_lines):
- raise StopIteration
-
-@@ -114,7 +114,7 @@
- self._source_fh.seek(self.header.end_header_pointer)
- return self
-
-- def next(self):
-+ def __next__(self):
- line = self._source_fh.readline()
- if not line:
- raise StopIteration
---- a/scripts/test/bt2face.py
-+++ b/scripts/test/bt2face.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
-
- import os
- import logging
---- a/scripts/test/btdata.py
-+++ b/scripts/test/btdata.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
- """
- Note: This would look so much better replaced by XML or at least JSON. But
- is not worth to do it for now.
-@@ -6,7 +6,7 @@
-
- import os
- import gzip
--import urllib2
-+import urllib.request, urllib.error, urllib.parse
- import logging
-
-
-@@ -66,14 +66,14 @@
- def init_data(self):
- """ Try and init the data we need.
- """
-- for genome,gdata in self.genomes.iteritems():
-+ for genome,gdata in self.genomes.items():
- gn_path = os.path.join(self.data_dir_path,genome)
- gn_fasta = os.path.join(gn_path,gdata['ref_name'])
- if not os.path.exists(gn_fasta):
- self._get_genome(genome)
- self._build_genome(genome)
-
-- for genome,gdata in self.joint_genomes.iteritems():
-+ for genome,gdata in self.joint_genomes.items():
- gn_path = os.path.join(self.data_dir_path,genome)
- gn_fasta = os.path.join(gn_path,gdata['ref_name'])
- if not os.path.exists(gn_fasta):
-@@ -103,7 +103,7 @@
-
- try:
- f = open(fname,'wb')
-- u = urllib2.urlopen(uri)
-+ u = urllib.request.urlopen(uri)
- f.write(u.read())
- except:
- f.close()
---- a/scripts/test/dataface.py
-+++ b/scripts/test/dataface.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
-
- import os
- import logging
---- a/scripts/test/large_idx.py
-+++ b/scripts/test/large_idx.py
-@@ -1,8 +1,8 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
-
- import os
- import gzip
--import urllib2
-+import urllib.request, urllib.error, urllib.parse
- import inspect
- import unittest
- import logging
-@@ -69,7 +69,7 @@
-
- def get_suite():
- tests = ['test_human','test_mouse','test_large_index']
-- return unittest.TestSuite(map(TestLargeIndex,tests))
-+ return unittest.TestSuite(list(map(TestLargeIndex,tests)))
-
-
-
---- a/scripts/test/regressions.py
-+++ b/scripts/test/regressions.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python3
-
- import os
- import inspect
---- a/bowtie2-build
-+++ b/bowtie2-build
-@@ -1,4 +1,4 @@
--#!/usr/bin/python
-+#!/usr/bin/python3
-
- """
- Copyright 2014, Ben Langmead <langmea@cs.jhu.edu>
---- a/bowtie2-inspect
-+++ b/bowtie2-inspect
-@@ -1,4 +1,4 @@
--#!/usr/bin/python
-+#!/usr/bin/python3
-
- """
- Copyright 2014, Ben Langmead <langmea@cs.jhu.edu>
-@@ -21,7 +21,7 @@
-
-
- import os
--import imp
-+import importlib
- import sys
- import inspect
- import logging
diff --git a/debian/patches/correct_64bit_test b/debian/patches/correct_64bit_test
index 55a7313..08451ba 100644
--- a/debian/patches/correct_64bit_test
+++ b/debian/patches/correct_64bit_test
@@ -2,40 +2,48 @@ Author: Michael R. Crusoe <michael.crusoe@gmail.com>
Description: Handle -m64 and -msse2 flags better
--- bowtie2.orig/Makefile
+++ bowtie2/Makefile
-@@ -197,31 +197,13 @@
- SEARCH_FRAGMENTS := $(wildcard search_*_phase*.c)
- VERSION := $(shell cat VERSION)
+@@ -198,38 +198,12 @@
+ SANITIZER_FLAGS := -fsanitize=undefined
+ endif
-BITS := 32
+-SSE_FLAG := -msse2
-ifeq (x86_64,$(shell uname -m))
-- BITS := 64
--endif
--ifeq (amd64,$(shell uname -m))
-- BITS := 64
--endif
--ifeq (aarch64,$(shell uname -m))
-- BITS := 64
+- BITS := 64
+-else ifeq (amd64,$(shell uname -m))
+- BITS := 64
+-else ifeq (aarch64,$(shell uname -m))
+- BITS := 64
+- SSE_FLAG :=
+- CXXFLAGS := -fopenmp-simd
+- CPPFLAGS := -Ithird_party/simde
+-else ifeq (s390x,$(shell uname -m))
+- BITS := 64
+- SSE_FLAG :=
+- CXXFLAGS := -fopenmp-simd
+- CPPFLAGS := -Ithird_party/simde
+- SANITIZER_FLAGS :=
+-else ifeq (ppc64le,$(shell uname -m))
+- BITS := 64
+- SSE_FLAG :=
+- CXXFLAGS := -fopenmp-simd
+- CPPFLAGS += -Ithird_party/simde
+- SANITIZER_FLAGS :=
-endif
-# msys will always be 32 bit so look at the cpu arch instead.
-ifneq (,$(findstring AMD64,$(PROCESSOR_ARCHITEW6432)))
-- ifeq (1,$(MINGW))
-- BITS := 64
-- endif
+- ifeq (1,$(MINGW))
+- BITS := 64
+- endif
-endif
-ifeq (32,$(BITS))
- $(error bowtie2 compilation requires a 64-bit platform )
--endif
-+M64_FLAG :=
-
--SSE_FLAG := -msse2
--M64_FLAG := -m64
--ifeq (aarch64,$(shell uname -m))
+ifeq (amd64,$(dpkg-architecture -q DEB_TARGET_ARCH))
-+ SSE_FLAG := -msse2
-+ M64_FLAG := -m64
++ SSE_FLAG = -msse2
++ M64_FLAG = -m64
+else
- SSE_FLAG =
-- M64_FLAG =
++ SSE_FLAG =
++ M64_FLAG =
endif
- DEBUG_FLAGS := -O0 -g3 $(M64_FLAG) $(SSE_FLAG)
+ DEBUG_FLAGS := -O0 -g3 $(SSE_FLAG)
diff --git a/debian/patches/drop-not-needed-js-from-manual.patch b/debian/patches/drop-not-needed-js-from-manual.patch
index 76ecd47..25f7b9f 100644
--- a/debian/patches/drop-not-needed-js-from-manual.patch
+++ b/debian/patches/drop-not-needed-js-from-manual.patch
@@ -3,8 +3,8 @@ Author: Alex Mestiashvili <amestia@rsh2.donotuse.de>
Forwarded: not-needed
--- bowtie2.orig/doc/manual.html
+++ bowtie2/doc/manual.html
-@@ -12,9 +12,6 @@
- div.column{display: inline-block; vertical-align: top; width: 50%;}
+@@ -14,9 +14,6 @@
+ ul.task-list{list-style: none;}
</style>
<link rel="stylesheet" href="doc/style.css" />
- <!--[if lt IE 9]>
diff --git a/debian/patches/hardening.patch b/debian/patches/hardening.patch
index ff9ec2a..e10236e 100644
--- a/debian/patches/hardening.patch
+++ b/debian/patches/hardening.patch
@@ -3,18 +3,16 @@ Author: Alexandre Mestiashvili <alex@biotec.tu-dresden.de>
Sascha Steinbiss <satta@debian.org>
Origin: Debian Med Packaging Team <debian-med-packaging@lists.alioth.debian.org>
Last-Update: Tue, 2 Jan 2018 16:20:02 +0100
-Index: bowtie2/Makefile
-===================================================================
--- bowtie2.orig/Makefile
+++ bowtie2/Makefile
-@@ -332,7 +332,9 @@ DEFS := -fno-strict-aliasing \
- $(FILE_FLAGS) \
- $(PREF_DEF) \
- $(MM_DEF) \
-- $(SHMEM_DEF)
-+ $(SHMEM_DEF) \
-+ $(CPPFLAGS) \
-+ $(CFLAGS)
+@@ -328,7 +328,9 @@
+ $(FILE_FLAGS) \
+ $(PREF_DEF) \
+ $(MM_DEF) \
+- $(SHMEM_DEF)
++ $(SHMEM_DEF) \
++ $(CPPFLAGS) \
++ $(CFLAGS)
# set compiler flags for all sanitized builds
- $(BOWTIE2_BIN_LIST_SAN): CXXFLAGS += $(SANITIZER_FLAGS)
+ ifdef BOWTIE2_BIN_LIST_SAN
diff --git a/debian/patches/no_sanity b/debian/patches/no_sanity
index aed8eaf..ec58116 100644
--- a/debian/patches/no_sanity
+++ b/debian/patches/no_sanity
@@ -2,41 +2,39 @@ Author: Michael R. Crusoe <michael.crusoe@gmail.com>
Description: save resources by not making/testing the -fsantize variants
--- bowtie2.orig/Makefile
+++ bowtie2/Makefile
-@@ -213,20 +213,6 @@
- DEBUG_DEFS = -DCOMPILER_OPTIONS="\"$(filter-out -fdebug-prefix-map=%,$(DEBUG_FLAGS) $(CXXFLAGS))\""
- RELEASE_DEFS = -DCOMPILER_OPTIONS="\"$(filter-out -fdebug-prefix-map=%,$(RELEASE_FLAGS) $(CXXFLAGS))\""
+@@ -189,15 +189,6 @@
+ SEARCH_FRAGMENTS := $(wildcard search_*_phase*.c)
+ VERSION := $(shell cat VERSION)
--ifeq (0,$(shell $(CPP) -E -fsanitize=address,undefined btypes.h 2>&1 > /dev/null; echo $$?))
-- SANITIZER_FLAGS := -fsanitize=address,undefined
--endif
--ifndef SANITIZER_FLAGS
-- ifeq (0,$(shell $(CPP) -E -fsanitize=address btypes.h 2>&1 > /dev/null; echo $$?))
-- SANITIZER_FLAGS := -fsanitize=address
-- endif
--endif
--ifndef SANITIZER_FLAGS
-- ifeq (0,$(shell $(CPP) -E -fsanitize=undefined btypes.h 2>&1 > /dev/null; echo $$?))
-- SANITIZER_FLAGS := -fsanitize=undefined
-- endif
+-SANITIZER_FLAGS :=
+-ifeq (0,$(shell $(CXX) -E -fsanitize=address,undefined btypes.h > /dev/null 2>&1; echo $$?))
+- SANITIZER_FLAGS := -fsanitize=address,undefined
+-else ifeq (0,$(shell $(CXX) -E -fsanitize=address btypes.h > /dev/null 2>&1; echo $$?))
+- SANITIZER_FLAGS := -fsanitize=address
+-else ifeq (0,$(shell $(CXX) -E -fsanitize=undefined btypes.h > /dev/null 2>&1; echo $$?))
+- SANITIZER_FLAGS := -fsanitize=undefined
-endif
-
- BOWTIE2_BIN_LIST := bowtie2-build-s \
- bowtie2-build-l \
- bowtie2-align-s \
-@@ -239,12 +225,6 @@
- bowtie2-align-l-debug \
- bowtie2-inspect-s-debug \
- bowtie2-inspect-l-debug
+ ifeq (amd64,$(dpkg-architecture -q DEB_TARGET_ARCH))
+ SSE_FLAG = -msse2
+ M64_FLAG = -m64
+@@ -225,15 +216,6 @@
+ bowtie2-align-l-debug \
+ bowtie2-inspect-s-debug \
+ bowtie2-inspect-l-debug
-BOWTIE2_BIN_LIST_SAN := bowtie2-build-s-sanitized \
-- bowtie2-build-l-sanitized \
-- bowtie2-align-s-sanitized \
-- bowtie2-align-l-sanitized \
-- bowtie2-inspect-s-sanitized \
-- bowtie2-inspect-l-sanitized
+- bowtie2-build-l-sanitized \
+- bowtie2-align-s-sanitized \
+- bowtie2-align-l-sanitized \
+- bowtie2-inspect-s-sanitized \
+- bowtie2-inspect-l-sanitized
+-ifndef SANITIZER_FLAGS
+- BOWTIE2_BIN_LIST_SAN =
+-endif
GENERAL_LIST := $(wildcard scripts/*.sh) \
- $(wildcard scripts/*.pl) \
-@@ -301,10 +281,9 @@
+ $(wildcard scripts/*.pl) \
+@@ -289,10 +271,9 @@
.PHONY: all allall both both-debug
all: $(BOWTIE2_BIN_LIST) ;
@@ -47,14 +45,18 @@ Description: save resources by not making/testing the -fsantize variants
-both-sanitized: bowtie2-align-s-sanitized bowtie2-build-s-sanitized bowtie2-align-l-sanitized bowtie2-build-l-sanitized ;
DEFS := -fno-strict-aliasing \
- -DBOWTIE2_VERSION="\"`cat VERSION`\"" \
-@@ -318,14 +297,12 @@
- $(CPPFLAGS) \
- $(CFLAGS)
+ -DBOWTIE2_VERSION="\"`cat VERSION`\"" \
+@@ -306,18 +287,11 @@
+ $(CPPFLAGS) \
+ $(CFLAGS)
-# set compiler flags for all sanitized builds
--$(BOWTIE2_BIN_LIST_SAN): CXXFLAGS += $(SANITIZER_FLAGS)
-
+-ifdef BOWTIE2_BIN_LIST_SAN
+-$(BOWTIE2_BIN_LIST_SAN): CXXFLAGS+=$(SANITIZER_FLAGS)
+-else
+-$(BOWTIE2_BIN_LIST_SAN): $(error "Compiler does not support...")
+-endif
+-
#
# bowtie2-build targets
#
@@ -64,7 +66,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) $(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 $(NOASSERT_FLAGS) -Wall \
$(CPPFLAGS) \
-@@ -333,7 +310,7 @@
+@@ -325,7 +299,7 @@
$(SHARED_CPPS) $(BUILD_CPPS_MAIN) \
$(LDFLAGS) $(LDLIBS)
@@ -73,7 +75,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) $(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 -DBOWTIE_64BIT_INDEX $(NOASSERT_FLAGS) -Wall \
$(CPPFLAGS) \
-@@ -361,7 +338,7 @@
+@@ -353,7 +327,7 @@
# bowtie2-align targets
#
@@ -82,7 +84,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) $(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 $(NOASSERT_FLAGS) -Wall \
$(CPPFLAGS) \
-@@ -369,7 +346,7 @@
+@@ -361,7 +335,7 @@
$(SHARED_CPPS) $(SEARCH_CPPS_MAIN) \
$(LDFLAGS) $(LDLIBS)
@@ -91,7 +93,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) $(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 -DBOWTIE_64BIT_INDEX $(NOASSERT_FLAGS) -Wall \
$(CPPFLAGS) \
-@@ -399,7 +376,7 @@
+@@ -391,7 +365,7 @@
# bowtie2-inspect targets
#
@@ -100,7 +102,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) \
$(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 -DBOWTIE_INSPECT_MAIN -Wall \
-@@ -408,7 +385,7 @@
+@@ -400,7 +374,7 @@
$(SHARED_CPPS) \
$(LDFLAGS) $(LDLIBS)
@@ -109,7 +111,7 @@ Description: save resources by not making/testing the -fsantize variants
$(CXX) $(RELEASE_FLAGS) \
$(RELEASE_DEFS) $(CXXFLAGS) \
$(DEFS) -DBOWTIE2 -DBOWTIE_INSPECT_MAIN -DBOWTIE_64BIT_INDEX -Wall \
-@@ -609,7 +586,7 @@
+@@ -601,7 +575,7 @@
.PHONY: clean
clean:
@@ -120,26 +122,23 @@ Description: save resources by not making/testing the -fsantize variants
rm -f core.* .tmp.head
--- bowtie2.orig/bowtie2
+++ bowtie2/bowtie2
-@@ -140,7 +140,6 @@
- }
+@@ -122,7 +122,6 @@
+ sub isWrapped($) { return defined($wrapped{$_[0]}); }
my $debug = 0;
-my $sanitized = 0;
my %read_fns = ();
my %read_compress = ();
my $cap_out = undef; # Filename for passthrough
-@@ -199,10 +198,6 @@
- $debug = 1;
- $bt2_args[$i] = undef;
- }
-- if(not $debug and $arg eq "--sanitized") {
-- $sanitized = 1;
-- $bt2_args[$i] = undef;
-- }
- if($arg eq "--no-unal") {
- $no_unal = 1;
- $bt2_args[$i] = undef;
-@@ -503,9 +498,6 @@
+@@ -183,7 +182,6 @@
+ "keep" => \$keep,
+ "verbose" => \$verbose,
+ "debug" => \$debug,
+- "sanitized" => \$sanitized,
+ "large-index" => \$large_idx,
+ "no-unal" => \$no_unal,
+ "un=s" => \&handle_un_or_al,
+@@ -450,9 +448,6 @@
if ($debug) {
$suffix = "-debug";
}
@@ -172,7 +171,7 @@ Description: save resources by not making/testing the -fsantize variants
elif len(argv) >= 2:
--- bowtie2.orig/bowtie2-inspect
+++ bowtie2/bowtie2-inspect
-@@ -34,7 +34,6 @@
+@@ -33,7 +33,6 @@
group = parser.add_mutually_exclusive_group()
group.add_argument('--debug', action='store_true')
@@ -180,7 +179,7 @@ Description: save resources by not making/testing the -fsantize variants
parser.add_argument('--verbose', action='store_true')
parser.add_argument('--large-index', action='store_true')
-@@ -61,10 +60,6 @@
+@@ -60,10 +59,6 @@
inspect_bin_spec += '-debug'
inspect_bin_l += '-debug'
@@ -235,3 +234,23 @@ Description: save resources by not making/testing the -fsantize variants
perl scripts/test/simple_tests.pl \
--bowtie2=./bowtie2 \
--bowtie2-build=./bowtie2-build \
+--- bowtie2.orig/bt2_build.cpp
++++ bowtie2/bt2_build.cpp
+@@ -144,7 +144,6 @@
+ out << " --large-index force generated index to be 'large', even if ref" << endl
+ << " has fewer than 4 billion nucleotides" << endl
+ << " --debug use the debug binary; slower, assertions enabled" << endl
+- << " --sanitized use sanitized binary; slower, uses ASan and/or UBSan" << endl
+ << " --verbose log the issued command" << endl;
+ }
+ out << " -a/--noauto disable automatic -p/--bmax/--dcv memory-fitting" << endl
+--- bowtie2.orig/bt2_inspect.cpp
++++ bowtie2/bt2_inspect.cpp
+@@ -78,7 +78,6 @@
+ out << " --large-index force inspection of the 'large' index, even if a" << endl
+ << " 'small' one is present." << endl
+ << " --debug use the debug binary; slower, assertions enabled" << endl
+- << " --sanitized use sanitized binary; slower, uses ASan and/or UBSan" << endl
+ << " --verbose log the issued command" << endl;
+ }
+ out << " -a/--across <int> Number of characters across in FASTA output (default: 60)" << endl
diff --git a/debian/patches/reproducible.patch b/debian/patches/reproducible.patch
index 7406142..d9d88f0 100644
--- a/debian/patches/reproducible.patch
+++ b/debian/patches/reproducible.patch
@@ -5,17 +5,17 @@ Description: make build reproducible
Author: Sascha Steinbiss <sascha@steinbiss.name>
--- bowtie2.orig/Makefile
+++ bowtie2/Makefile
-@@ -36,7 +36,7 @@
- CPPFLAGS += -Ithird_party/simde
- endif
+@@ -31,7 +31,7 @@
+ CPP ?= $(GCC_PREFIX)/g++$(GCC_SUFFIX)
+ CXX ?= $(CPP)
-HEADERS := $(wildcard *.h)
+HEADERS := $(sort $(wildcard *.h))
BOWTIE_MM := 1
BOWTIE_SHARED_MEM :=
-@@ -228,8 +228,8 @@
- RELEASE_FLAGS := -O3 $(M64_FLAG) $(SSE_FLAG) -funroll-loops -g3
+@@ -236,8 +236,8 @@
+ RELEASE_FLAGS := -O3 $(SSE_FLAG) -funroll-loops -g3
NOASSERT_FLAGS := -DNDEBUG
FILE_FLAGS := -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE
-DEBUG_DEFS = -DCOMPILER_OPTIONS="\"$(DEBUG_FLAGS) $(CXXFLAGS)\""
@@ -23,11 +23,11 @@ Author: Sascha Steinbiss <sascha@steinbiss.name>
+DEBUG_DEFS = -DCOMPILER_OPTIONS="\"$(filter-out -fdebug-prefix-map=%,$(DEBUG_FLAGS) $(CXXFLAGS))\""
+RELEASE_DEFS = -DCOMPILER_OPTIONS="\"$(filter-out -fdebug-prefix-map=%,$(RELEASE_FLAGS) $(CXXFLAGS))\""
- ifeq (0,$(shell $(CPP) -E -fsanitize=address,undefined btypes.h 2>&1 > /dev/null; echo $$?))
- SANITIZER_FLAGS := -fsanitize=address,undefined
+ BOWTIE2_BIN_LIST := bowtie2-build-s \
+ bowtie2-build-l \
--- bowtie2.orig/bt2_build.cpp
+++ bowtie2/bt2_build.cpp
-@@ -551,15 +551,15 @@
+@@ -561,15 +561,15 @@
} else {
cout << "Neither 32- nor 64-bit: sizeof(void*) = " << sizeof(void*) << endl;
}
@@ -81,7 +81,7 @@ Author: Sascha Steinbiss <sascha@steinbiss.name>
--- bowtie2.orig/bt2_search.cpp
+++ bowtie2/bt2_search.cpp
-@@ -5128,15 +5128,15 @@
+@@ -5145,15 +5145,15 @@
} else {
cout << "Neither 32- nor 64-bit: sizeof(void*) = " << sizeof(void*) << endl;
}
@@ -108,7 +108,7 @@ Author: Sascha Steinbiss <sascha@steinbiss.name>
{
--- bowtie2.orig/CMakeLists.txt
+++ bowtie2/CMakeLists.txt
-@@ -276,7 +276,8 @@
+@@ -275,7 +275,8 @@
include_directories(${PROJECT_SOURCE_DIR})
get_directory_property(COMPILER_DEFS COMPILE_DEFINITIONS)
diff --git a/debian/patches/series b/debian/patches/series
index 9298199..e11a345 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -4,7 +4,6 @@ hardening.patch
reproducible.patch
skip_test_requiring_non-free_libmath-random-perl.patch
do-not-rebuild-during-test.patch
-2to3.patch
silence_tbb_deprecation_warning.patch
simde
correct_64bit_test
diff --git a/debian/patches/simde b/debian/patches/simde
index 4041221..a02488c 100644
--- a/debian/patches/simde
+++ b/debian/patches/simde
@@ -7,15 +7,13 @@ Description: Enable SIMDE everywhere
#ifndef SSE_WRAP_H_
#define SSE_WRAP_H_
--#ifdef __aarch64__
+-#if defined(__aarch64__) || defined(__s390x__) || defined(__powerpc__)
-#include "simde/x86/sse2.h"
-#else
-#include <emmintrin.h>
-#endif
-+#define SIMDE_ENABLE_NATIVE_ALIASES
-+#include "debian/include/simde/x86/sse2.h"
-
--#ifdef __aarch64__
+-
+-#if defined(__aarch64__) || defined(__s390x__) || defined(__powerpc__)
-typedef simde__m128i __m128i;
-#define _mm_adds_epi16(x, y) simde_mm_adds_epi16(x, y)
-#define _mm_adds_epu8(x, y) simde_mm_adds_epu8(x, y)
@@ -44,6 +42,8 @@ Description: Enable SIMDE everywhere
-#define _mm_subs_epi16(x, y) simde_mm_subs_epi16(x, y)
-#define _mm_subs_epu8(x, y) simde_mm_subs_epu8(x, y)
-#define _mm_xor_si128(x, y) simde_mm_xor_si128(x, y)
- #endif
--
--#endif /* SSE_WRAP_H_ */
+-#endif
++#define SIMDE_ENABLE_NATIVE_ALIASES
++#include "debian/include/simde/x86/sse2.h"
+
+ #endif /* SSE_WRAP_H_ */
diff --git a/debian/patches/wrong-interpreter-path.patch b/debian/patches/wrong-interpreter-path.patch
index a7d3d66..d2abaeb 100644
--- a/debian/patches/wrong-interpreter-path.patch
+++ b/debian/patches/wrong-interpreter-path.patch
@@ -12,16 +12,103 @@ Forwarded: not-needed
--- bowtie2.orig/bowtie2-build
+++ bowtie2/bowtie2-build
@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python
+-#!/usr/bin/env python3
++#!/usr/bin/python3
"""
Copyright 2014, Ben Langmead <langmea@cs.jhu.edu>
--- bowtie2.orig/bowtie2-inspect
+++ bowtie2/bowtie2-inspect
@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!/usr/bin/python
+-#!/usr/bin/env python3
++#!/usr/bin/python3
"""
Copyright 2014, Ben Langmead <langmea@cs.jhu.edu>
+--- bowtie2.orig/example/reads/simulate.pl
++++ bowtie2/example/reads/simulate.pl
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env perl
++#!/usr/bin/perl
+
+ ##
+ # Copyright 2011, Ben Langmead <langmea@cs.jhu.edu>
+--- bowtie2.orig/scripts/sa.py
++++ bowtie2/scripts/sa.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+
+ """
+ sa.py
+--- bowtie2.orig/scripts/test/benchmark/benchmarks.py
++++ bowtie2/scripts/test/benchmark/benchmarks.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+ """
+ A few items to deal with sets of benchmarks.
+ """
+--- bowtie2.orig/scripts/test/benchmark/run.py
++++ bowtie2/scripts/test/benchmark/run.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+ """
+ Runs benchmark sets specified in JSON files.
+
+--- bowtie2.orig/scripts/test/benchmark/samreader.py
++++ bowtie2/scripts/test/benchmark/samreader.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+ """
+ A reader of SAM format.
+
+--- bowtie2.orig/scripts/test/bt2face.py
++++ bowtie2/scripts/test/bt2face.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+
+ import os
+ import logging
+--- bowtie2.orig/scripts/test/btdata.py
++++ bowtie2/scripts/test/btdata.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+ """
+ Note: This would look so much better replaced by XML or at least JSON. But
+ is not worth to do it for now.
+--- bowtie2.orig/scripts/test/dataface.py
++++ bowtie2/scripts/test/dataface.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+
+ import os
+ import logging
+@@ -78,4 +78,4 @@
+
+
+
+-
+\ No newline at end of file
++
+--- bowtie2.orig/scripts/test/large_idx.py
++++ bowtie2/scripts/test/large_idx.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+
+ import os
+ import gzip
+--- bowtie2.orig/scripts/test/regressions.py
++++ bowtie2/scripts/test/regressions.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python3
++#!/usr/bin/python3
+
+ import os
+ import inspect