summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sci-biology/bowtie/bowtie-1.1.2-r1.ebuild75
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-_ContextLss-1.1-1.4.patch17
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-fix-setBegin-call.patch42
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-seqan-popcount.patch24
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-ChunkPool.patch382
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-fill-to-resize.patch85
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-spelling.patch48
-rw-r--r--sci-biology/bowtie/files/bowtie-1.1.2-unbundle-seqan.patch27
8 files changed, 700 insertions, 0 deletions
diff --git a/sci-biology/bowtie/bowtie-1.1.2-r1.ebuild b/sci-biology/bowtie/bowtie-1.1.2-r1.ebuild
new file mode 100644
index 000000000000..e0b435899caa
--- /dev/null
+++ b/sci-biology/bowtie/bowtie-1.1.2-r1.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit flag-o-matic toolchain-funcs
+
+DESCRIPTION="Popular short read aligner for Next-generation sequencing data"
+HOMEPAGE="http://bowtie-bio.sourceforge.net/"
+SRC_URI="mirror://sourceforge/bowtie-bio/${P}-src.zip"
+
+LICENSE="Artistic"
+SLOT="1"
+KEYWORDS="~amd64 ~x86 ~x64-macos"
+
+IUSE="examples +tbb"
+
+RDEPEND="tbb? ( dev-cpp/tbb )"
+DEPEND="${RDEPEND}
+ sci-biology/seqan:1.4
+ app-arch/unzip"
+
+DOCS=( AUTHORS NEWS TUTORIAL doc/README )
+HTML_DOCS=( doc/{manual.html,style.css} )
+
+PATCHES=(
+ "${FILESDIR}/${P}-_ContextLss-1.1-1.4.patch"
+ "${FILESDIR}/${P}-fix-setBegin-call.patch"
+ "${FILESDIR}/${P}-seqan-popcount.patch"
+ "${FILESDIR}/${P}-seqan-rename-ChunkPool.patch"
+ "${FILESDIR}/${P}-seqan-rename-fill-to-resize.patch"
+ "${FILESDIR}/${P}-spelling.patch"
+ "${FILESDIR}/${P}-tbb-tinythread-missing.patch"
+ "${FILESDIR}/${P}-unbundle-seqan.patch"
+)
+
+src_prepare() {
+ default
+
+ # remove bundled libraries, use system seqan 1.4
+ rm -rf SeqAn-1.1/ third_party/ || die
+
+ # innocuous non-security flags, prevent log pollution
+ append-cxxflags \
+ -Wno-unused-local-typedefs \
+ -Wno-unused-but-set-variable \
+ -Wno-unused-variable
+}
+
+src_compile() {
+ emake \
+ CC="$(tc-getCC)" \
+ CPP="$(tc-getCXX)" \
+ CFLAGS="" \
+ CXXFLAGS="" \
+ EXTRA_FLAGS="${LDFLAGS}" \
+ RELEASE_FLAGS="${CXXFLAGS}" \
+ WITH_TBB="$(usex tbb 1 0)"
+}
+
+src_install() {
+ dobin ${PN} ${PN}-*
+
+ exeinto /usr/libexec/${PN}
+ doexe scripts/*
+
+ newman MANUAL ${PN}.1
+ einstalldocs
+
+ if use examples; then
+ insinto /usr/share/${PN}
+ doins -r genomes indexes
+ fi
+}
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-_ContextLss-1.1-1.4.patch b/sci-biology/bowtie/files/bowtie-1.1.2-_ContextLss-1.1-1.4.patch
new file mode 100644
index 000000000000..78b9c01a0462
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-_ContextLss-1.1-1.4.patch
@@ -0,0 +1,17 @@
+Description: Change class name of _Context_LSS
+ New version 1.4 of SeQan uses a different name of the class.
+Forwarded: no
+Author: Gert Wollny <gw.fossdev@gmail.com>
+Last-Update: 2014-100-06
+
+--- a/diff_sample.h
++++ b/diff_sample.h
+@@ -856,7 +856,7 @@ void DifferenceCoverSample<TStr>::build(
+ {
+ Timer timer(cout, " Invoking Larsson-Sadakane on ranks time: ", this->verbose());
+ VMSG_NL(" Invoking Larsson-Sadakane on ranks");
+- _Context_LSS<TIndexOff> c;
++ ContextLss_<TIndexOff> c;
+ c.suffixsort(
+ (TIndexOff*)begin(_isaPrime, Standard()),
+ (TIndexOff*)begin(sPrime, Standard()),
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-fix-setBegin-call.patch b/sci-biology/bowtie/files/bowtie-1.1.2-fix-setBegin-call.patch
new file mode 100644
index 000000000000..af7f7f61cd5e
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-fix-setBegin-call.patch
@@ -0,0 +1,42 @@
+Description: Proper type-casting in using seqan::_setBegin().
+ Required by newer versions of GCC.
+Forwarded: no
+Author: Ognyan Kulev <ogi@debian.org>
+Last-Update: 2013-04-18
+
+--- a/pat.h
++++ b/pat.h
+@@ -82,20 +82,20 @@ struct ReadBuf {
+ ~ReadBuf() {
+ clearAll(); reset();
+ // Prevent seqan from trying to free buffers
+- _setBegin(patFw, NULL);
+- _setBegin(patRc, NULL);
+- _setBegin(qual, NULL);
+- _setBegin(patFwRev, NULL);
+- _setBegin(patRcRev, NULL);
+- _setBegin(qualRev, NULL);
+- _setBegin(name, NULL);
++ _setBegin(patFw, (Dna5*)NULL);
++ _setBegin(patRc, (Dna5*)NULL);
++ _setBegin(qual, (char*)NULL);
++ _setBegin(patFwRev, (Dna5*)NULL);
++ _setBegin(patRcRev, (Dna5*)NULL);
++ _setBegin(qualRev, (char*)NULL);
++ _setBegin(name, (char*)NULL);
+ for(int j = 0; j < 3; j++) {
+- _setBegin(altPatFw[j], NULL);
+- _setBegin(altPatFwRev[j], NULL);
+- _setBegin(altPatRc[j], NULL);
+- _setBegin(altPatRcRev[j], NULL);
+- _setBegin(altQual[j], NULL);
+- _setBegin(altQualRev[j], NULL);
++ _setBegin(altPatFw[j], (Dna5*)NULL);
++ _setBegin(altPatFwRev[j], (Dna5*)NULL);
++ _setBegin(altPatRc[j], (Dna5*)NULL);
++ _setBegin(altPatRcRev[j], (Dna5*)NULL);
++ _setBegin(altQual[j], (char*)NULL);
++ _setBegin(altQualRev[j], (char*)NULL);
+ }
+ }
+
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-seqan-popcount.patch b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-popcount.patch
new file mode 100644
index 000000000000..52cb4f496521
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-popcount.patch
@@ -0,0 +1,24 @@
+Description: Use SeqAn 1.4's seqan::popCount() function instead of own function
+Author: Ognyan Kulev <ogi@debian.org>
+Last-Update: 2014-03-08
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/diff_sample.h
++++ b/diff_sample.h
+@@ -476,6 +476,8 @@ static String<T> getDeltaMap(T v, const
+ return amap;
+ }
+
++// Debian: Use seqan::popCount
++#if 0
+ /**
+ * Return population count (count of all bits set to 1) of i.
+ */
+@@ -488,6 +490,7 @@ static unsigned int popCount(T i) {
+ }
+ return cnt;
+ }
++#endif
+
+ /**
+ * Calculate log-base-2 of i
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-ChunkPool.patch b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-ChunkPool.patch
new file mode 100644
index 000000000000..171f9bab8fae
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-ChunkPool.patch
@@ -0,0 +1,382 @@
+Description: Renamed ChunkPool class to bowtieChunkPool.
+ SeqAn has a class with the same name and fatal name collision happens.
+Forwarded: no
+Author: Ognyan Kulev <ogi@debian.org>
+Last-Update: 2013-04-18
+
+--- a/aligner.h
++++ b/aligner.h
+@@ -337,7 +337,7 @@ public:
+ bool verbose,
+ bool quiet,
+ int maxBts,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ int *btCnt = NULL,
+ AlignerMetrics *metrics = NULL) :
+ Aligner(true, rangeMode),
+@@ -544,7 +544,7 @@ protected:
+ bool quiet_; // don't print informational/warning info
+
+ const int maxBts_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ int *btCnt_;
+ AlignerMetrics *metrics_;
+ };
+@@ -585,7 +585,7 @@ public:
+ bool verbose,
+ bool quiet,
+ int maxBts,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ int *btCnt) :
+ Aligner(true, rangeMode),
+ refs_(refs),
+@@ -1358,7 +1358,7 @@ protected:
+ bool quiet_;
+
+ int maxBts_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ int *btCnt_;
+
+ // Range-finding state for first mate
+@@ -1482,7 +1482,7 @@ public:
+ bool verbose,
+ bool quiet,
+ int maxBts,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ int *btCnt) :
+ Aligner(true, rangeMode),
+ refs_(refs),
+@@ -2035,7 +2035,7 @@ protected:
+ TDriver* driver_;
+
+ // Pool for distributing chunks of best-first path descriptor memory
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+
+ bool verbose_;
+ bool quiet_;
+--- a/aligner_0mm.h
++++ b/aligner_0mm.h
+@@ -32,7 +32,7 @@ public:
+ RangeCache* cacheFw,
+ RangeCache* cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool maqPenalty,
+@@ -124,7 +124,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ bool maqPenalty_;
+@@ -164,7 +164,7 @@ public:
+ RangeCache* cacheFw,
+ RangeCache* cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool reportSe,
+@@ -366,7 +366,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool reportSe_;
+--- a/aligner_1mm.h
++++ b/aligner_1mm.h
+@@ -32,7 +32,7 @@ public:
+ RangeCache *cacheFw,
+ RangeCache *cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool maqPenalty,
+@@ -161,7 +161,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool maqPenalty_;
+@@ -201,7 +201,7 @@ public:
+ RangeCache *cacheFw,
+ RangeCache *cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool reportSe,
+@@ -478,7 +478,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool reportSe_;
+--- a/aligner_23mm.h
++++ b/aligner_23mm.h
+@@ -33,7 +33,7 @@ public:
+ RangeCache *cacheFw,
+ RangeCache *cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool maqPenalty,
+@@ -231,7 +231,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool maqPenalty_;
+@@ -273,7 +273,7 @@ public:
+ RangeCache *cacheFw,
+ RangeCache *cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool reportSe,
+@@ -675,7 +675,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool reportSe_;
+--- a/aligner_seed_mm.h
++++ b/aligner_seed_mm.h
+@@ -37,7 +37,7 @@ public:
+ RangeCache* cacheFw,
+ RangeCache* cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool maqPenalty,
+@@ -554,7 +554,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ bool strandFix_;
+@@ -598,7 +598,7 @@ public:
+ RangeCache* cacheFw,
+ RangeCache* cacheBw,
+ uint32_t cacheLimit,
+- ChunkPool *pool,
++ bowtieChunkPool *pool,
+ BitPairReference* refs,
+ vector<String<Dna5> >& os,
+ bool reportSe,
+@@ -1375,7 +1375,7 @@ private:
+ RangeCache *cacheFw_;
+ RangeCache *cacheBw_;
+ const uint32_t cacheLimit_;
+- ChunkPool *pool_;
++ bowtieChunkPool *pool_;
+ BitPairReference* refs_;
+ vector<String<Dna5> >& os_;
+ const bool reportSe_;
+--- a/ebwt_search.cpp
++++ b/ebwt_search.cpp
+@@ -111,7 +111,7 @@ static bool strandFix; // attempt to fi
+ static bool randomizeQuals; // randomize quality values
+ static bool stats; // print performance stats
+ static int chunkPoolMegabytes; // max MB to dedicate to best-first search frames per thread
+-static int chunkSz; // size of single chunk disbursed by ChunkPool
++static int chunkSz; // size of single chunk disbursed by bowtieChunkPool
+ static bool chunkVerbose; // have chunk allocator output status messages?
+ static bool recal;
+ static int recalMaxCycle;
+@@ -223,7 +223,7 @@ static void resetOptions() {
+ randomizeQuals = false; // randomize quality values
+ stats = false; // print performance stats
+ chunkPoolMegabytes = 64; // max MB to dedicate to best-first search frames per thread
+- chunkSz = 256; // size of single chunk disbursed by ChunkPool (in KB)
++ chunkSz = 256; // size of single chunk disbursed by bowtieChunkPool (in KB)
+ chunkVerbose = false; // have chunk allocator output status messages?
+ recal = false;
+ recalMaxCycle = 64;
+@@ -1201,7 +1201,7 @@ static void exactSearchWorkerStateful(vo
+ PatternSourcePerThreadFactory* patsrcFact = createPatsrcFactory(_patsrc, tid);
+ HitSinkPerThreadFactory* sinkFact = createSinkFactory(_sink);
+
+- ChunkPool *pool = new ChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
++ bowtieChunkPool *pool = new bowtieChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
+ UnpairedExactAlignerV1Factory alSEfact(
+ ebwt,
+ NULL,
+@@ -1385,7 +1385,7 @@ static void mismatchSearchWorkerFullStat
+ // Global initialization
+ PatternSourcePerThreadFactory* patsrcFact = createPatsrcFactory(_patsrc, tid);
+ HitSinkPerThreadFactory* sinkFact = createSinkFactory(_sink);
+- ChunkPool *pool = new ChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
++ bowtieChunkPool *pool = new bowtieChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
+
+ Unpaired1mmAlignerV1Factory alSEfact(
+ ebwtFw,
+@@ -1687,7 +1687,7 @@ static void twoOrThreeMismatchSearchWork
+ PatternSourcePerThreadFactory* patsrcFact = createPatsrcFactory(_patsrc, tid);
+ HitSinkPerThreadFactory* sinkFact = createSinkFactory(_sink);
+
+- ChunkPool *pool = new ChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
++ bowtieChunkPool *pool = new bowtieChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
+ Unpaired23mmAlignerV1Factory alSEfact(
+ ebwtFw,
+ &ebwtBw,
+@@ -2156,7 +2156,7 @@ static void seededQualSearchWorkerFullSt
+ // Global initialization
+ PatternSourcePerThreadFactory* patsrcFact = createPatsrcFactory(_patsrc, tid);
+ HitSinkPerThreadFactory* sinkFact = createSinkFactory(_sink);
+- ChunkPool *pool = new ChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
++ bowtieChunkPool *pool = new bowtieChunkPool(chunkSz * 1024, chunkPoolMegabytes * 1024 * 1024, chunkVerbose);
+
+ AlignerMetrics *metrics = NULL;
+ if(stats) {
+--- a/ebwt_search_backtrack.h
++++ b/ebwt_search_backtrack.h
+@@ -2724,7 +2724,7 @@ public:
+ bool verbose,
+ bool quiet,
+ bool mate1,
+- ChunkPool* pool,
++ bowtieChunkPool* pool,
+ int *btCnt) :
+ SingleRangeSourceDriver<EbwtRangeSource>(
+ params, rs, fw, sink, sinkPt, os, verbose,
+@@ -2927,7 +2927,7 @@ public:
+ bool verbose,
+ bool quiet,
+ bool mate1,
+- ChunkPool* pool,
++ bowtieChunkPool* pool,
+ int *btCnt = NULL) :
+ params_(params),
+ rs_(rs),
+@@ -2986,7 +2986,7 @@ protected:
+ bool verbose_;
+ bool quiet_;
+ bool mate1_;
+- ChunkPool* pool_;
++ bowtieChunkPool* pool_;
+ int *btCnt_;
+ };
+
+--- a/pool.h
++++ b/pool.h
+@@ -19,13 +19,13 @@
+ * is set at construction time. Heap memory is only allocated at
+ * construction and deallocated at destruction.
+ */
+-class ChunkPool {
++class bowtieChunkPool {
+ public:
+ /**
+ * Initialize a new pool with an initial size of about 'bytes'
+ * bytes. Exit with an error message if we can't allocate it.
+ */
+- ChunkPool(uint32_t chunkSz, uint32_t totSz, bool verbose_) :
++ bowtieChunkPool(uint32_t chunkSz, uint32_t totSz, bool verbose_) :
+ verbose(verbose_), patid(0), pool_(NULL), cur_(0),
+ chunkSz_(chunkSz), totSz_(totSz), lim_(totSz/chunkSz),
+ bits_(lim_), exhaustCrash_(false),
+@@ -38,7 +38,7 @@ public:
+ }
+ } catch(std::bad_alloc& e) {
+ ThreadSafe _ts(&gLock);
+- std::cerr << "Error: Could not allocate ChunkPool of "
++ std::cerr << "Error: Could not allocate bowtieChunkPool of "
+ << totSz << " bytes" << std::endl;
+ exhausted();
+ throw 1; // Exit if we haven't already
+@@ -48,7 +48,7 @@ public:
+ /**
+ * Delete all the pools.
+ */
+- ~ChunkPool() {
++ ~bowtieChunkPool() {
+ if(pool_ != NULL) delete[] pool_;
+ }
+
+@@ -189,7 +189,7 @@ public:
+ * Initialize a new pool with an initial size of about 'bytes'
+ * bytes. Exit with an error message if we can't allocate it.
+ */
+- AllocOnlyPool(ChunkPool* pool, const char *name) :
++ AllocOnlyPool(bowtieChunkPool* pool, const char *name) :
+ pool_(pool), name_(name), curPool_(0), cur_(0)
+ {
+ assert(pool != NULL);
+@@ -388,7 +388,7 @@ protected:
+ lastCurInPool_.pop_back();
+ }
+
+- ChunkPool* pool_;
++ bowtieChunkPool* pool_;
+ const char *name_;
+ std::vector<T*> pools_; /// the memory pools
+ uint32_t curPool_; /// pool we're current allocating from
+--- a/range_source.h
++++ b/range_source.h
+@@ -1388,7 +1388,7 @@ class PathManager {
+
+ public:
+
+- PathManager(ChunkPool* cpool_, int *btCnt, bool verbose, bool quiet) :
++ PathManager(bowtieChunkPool* cpool_, int *btCnt, bool verbose, bool quiet) :
+ branchQ_(verbose, quiet),
+ cpool(cpool_),
+ bpool(cpool, "branch"),
+@@ -1637,7 +1637,7 @@ protected:
+
+ public:
+
+- ChunkPool *cpool; // pool for generic chunks of memory
++ bowtieChunkPool *cpool; // pool for generic chunks of memory
+ AllocOnlyPool<Branch> bpool; // pool for allocating Branches
+ AllocOnlyPool<RangeState> rpool; // pool for allocating RangeStates
+ AllocOnlyPool<Edit> epool; // pool for allocating Edits
+@@ -1811,7 +1811,7 @@ public:
+ bool quiet,
+ bool mate1,
+ uint32_t minCostAdjustment,
+- ChunkPool* pool,
++ bowtieChunkPool* pool,
+ int *btCnt) :
+ RangeSourceDriver<TRangeSource>(true, minCostAdjustment),
+ len_(0), mate1_(mate1),
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-fill-to-resize.patch b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-fill-to-resize.patch
new file mode 100644
index 000000000000..38664aeee989
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-seqan-rename-fill-to-resize.patch
@@ -0,0 +1,85 @@
+Description: Renamed seqan::fill function calls to use seqan::resize.
+ SeqAn 1.3 renamed seqan::fill() to seqan::resize().
+ SeqAn ticket: http://trac.seqan.de/ticket/77
+Forwarded: no
+Author: Ognyan Kulev <ogi@debian.org>
+Last-Update: 2014-08-13
+
+--- a/blockwise_sa.h
++++ b/blockwise_sa.h
+@@ -456,8 +456,8 @@ void KarkkainenBlockwiseSA<TStr>::buildS
+ try {
+ // Allocate and initialize containers for holding bucket
+ // sizes and representatives.
+- fill(bucketSzs, numBuckets, 0, Exact());
+- fill(bucketReps, numBuckets, OFF_MASK, Exact());
++ resize(bucketSzs, numBuckets, 0, Exact());
++ resize(bucketReps, numBuckets, OFF_MASK, Exact());
+ } catch(bad_alloc &e) {
+ if(this->_passMemExc) {
+ throw e; // rethrow immediately
+@@ -816,7 +816,7 @@ void KarkkainenBlockwiseSA<TStr>::nextBl
+ // Not the last bucket
+ assert_lt(_cur, length(_sampleSuffs));
+ hi = _sampleSuffs[_cur];
+- fill(zHi, _dcV, 0, Exact());
++ resize(zHi, _dcV, 0, Exact());
+ assert_eq(zHi[0], 0);
+ calcZ(t, hi, zHi, this->verbose(), this->sanityCheck());
+ }
+@@ -825,7 +825,7 @@ void KarkkainenBlockwiseSA<TStr>::nextBl
+ assert_gt(_cur, 0);
+ assert_leq(_cur, length(_sampleSuffs));
+ lo = _sampleSuffs[_cur-1];
+- fill(zLo, _dcV, 0, Exact());
++ resize(zLo, _dcV, 0, Exact());
+ assert_gt(_dcV, 3);
+ assert_eq(zLo[0], 0);
+ calcZ(t, lo, zLo, this->verbose(), this->sanityCheck());
+--- a/diff_sample.h
++++ b/diff_sample.h
+@@ -452,7 +452,7 @@ static String<T> getDeltaMap(T v, const
+ // Declare anchor-map-related items
+ String<T> amap;
+ size_t amapEnts = 1;
+- fill(amap, v, 0xffffffff, Exact());
++ resize(amap, v, 0xffffffff, Exact());
+ amap[0] = 0;
+ // Print out difference cover (and optionally calculate
+ // anchor map)
+@@ -532,7 +532,7 @@ public:
+ assert_gt(_d, 0);
+ assert_eq(1, popCount(_v)); // must be power of 2
+ // Build map from d's to idx's
+- fill(_dInv, _v, 0xffffffff, Exact());
++ resize(_dInv, _v, 0xffffffff, Exact());
+ uint32_t lim = (uint32_t)length(_ds);
+ for(uint32_t i = 0; i < lim; i++) {
+ _dInv[_ds[i]] = i;
+@@ -656,7 +656,7 @@ void DifferenceCoverSample<TStr>::doBuil
+ VMSG_NL(" Doing sanity check");
+ TIndexOffU added = 0;
+ String<TIndexOffU> sorted;
+- fill(sorted, length(_isaPrime), OFF_MASK, Exact());
++ resize(sorted, length(_isaPrime), OFF_MASK, Exact());
+ for(size_t di = 0; di < this->d(); di++) {
+ uint32_t d = _ds[di];
+ size_t i = 0;
+@@ -717,7 +717,7 @@ void DifferenceCoverSample<TStr>::buildS
+ assert_eq(length(_doffs), d+1);
+ // Size sPrime appropriately
+ reserve(sPrime, sPrimeSz+1, Exact()); // reserve extra slot for LS
+- fill(sPrime, sPrimeSz, OFF_MASK, Exact());
++ resize(sPrime, sPrimeSz, OFF_MASK, Exact());
+ // Slot suffixes from text into sPrime according to the mu
+ // mapping; where the mapping would leave a blank, insert a 0
+ TIndexOffU added = 0;
+@@ -823,7 +823,7 @@ void DifferenceCoverSample<TStr>::build(
+ // arrays back into sPrime.
+ VMSG_NL(" Allocating rank array");
+ reserve(_isaPrime, length(sPrime)+1, Exact());
+- fill(_isaPrime, length(sPrime), OFF_MASK, Exact());
++ resize(_isaPrime, length(sPrime), OFF_MASK, Exact());
+ assert_gt(length(_isaPrime), 0);
+ {
+ Timer timer(cout, " Ranking v-sort output time: ", this->verbose());
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-spelling.patch b/sci-biology/bowtie/files/bowtie-1.1.2-spelling.patch
new file mode 100644
index 000000000000..ff484dfa3ebb
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-spelling.patch
@@ -0,0 +1,48 @@
+Author: Andreas Tille <tille@debian.org>
+Last-Update: Thu, 01 Oct 2015 09:47:23 +0200
+Description: Fix spelling
+
+--- a/MANUAL
++++ b/MANUAL
+@@ -544,7 +544,7 @@ The `bowtie`, `bowtie-build` and `bowtie
+ actually wrapper scripts that call binary programs as appropriate. The
+ wrappers shield users from having to distinguish between "small" and
+ "large" index formats, discussed briefly in the following section. The
+-appropiate index type is selected based on the input size.
++appropriate index type is selected based on the input size.
+
+ It is recommended that you always run the bowtie wrappers and not run
+ the binaries directly.
+--- a/MANUAL.markdown
++++ b/MANUAL.markdown
+@@ -559,7 +559,7 @@ The `bowtie`, `bowtie-build` and `bowtie
+ actually wrapper scripts that call binary programs as appropriate. The
+ wrappers shield users from having to distinguish between "small" and
+ "large" index formats, discussed briefly in the following section. The
+-appropiate index type is selected based on the input size.
++appropriate index type is selected based on the input size.
+
+ It is recommended that you always run the bowtie wrappers and not run
+ the binaries directly.
+--- a/doc/manual.html
++++ b/doc/manual.html
+@@ -201,7 +201,7 @@ T2302111203131231130300111123220
+ <p>Like other platforms, SOLiD supports generation of paired-end reads. When colorspace alignment is enabled, the default paired-end orientation setting is <a href="#bowtie-options-fr"><code>--ff</code></a>. This is because most SOLiD datasets have that orientation.</p>
+ <p>Note that SOLiD-generated read files can have &quot;orphaned&quot; mates; i.e. mates without a correpsondingly-named mate in the other file. To avoid problems due to orphaned mates, SOLiD paired-end output should first be converted to <code>.csfastq</code> files with unpaired mates omitted. This can be accomplished using, for example, [Galaxy]'s conversion tool (click &quot;NGS: QC and manipulation&quot;, then &quot;SOLiD-to-FASTQ&quot; in the left-hand sidebar).</p>
+ <h2 id="wrapper-scripts">Wrapper scripts</h2>
+-<p>The <code>bowtie</code>, <code>bowtie-build</code> and <code>bowtie-inspect</code> executables are actually wrapper scripts that call binary programs as appropriate. The wrappers shield users from having to distinguish between &quot;small&quot; and &quot;large&quot; index formats, discussed briefly in the following section. The appropiate index type is selected based on the input size.</p>
++<p>The <code>bowtie</code>, <code>bowtie-build</code> and <code>bowtie-inspect</code> executables are actually wrapper scripts that call binary programs as appropriate. The wrappers shield users from having to distinguish between &quot;small&quot; and &quot;large&quot; index formats, discussed briefly in the following section. The appropriate index type is selected based on the input size.</p>
+ <p>It is recommended that you always run the bowtie wrappers and not run the binaries directly.</p>
+ <h2 id="small-and-large-indexes">Small and large indexes</h2>
+ <p><code>bowtie-build</code> can index reference genomes of any size. For genomes less than about 4 billion nucleotides in length, <code>bowtie-build</code> builds a &quot;small&quot; index using 32-bit numbers in various parts of the index. When the genome is longer, <code>bowtie-build</code> builds a &quot;large&quot; index using 64-bit numbers. Small indexes are stored in files with the <code>.ebwt</code> extension, and large indexes are stored in files with the <code>.ebwtl</code> extension. The user need not worry about whether a particular index is small or large; the wrapper scripts will automatically build and use the appropriate index.</p>
+--- a/ref_read.cpp
++++ b/ref_read.cpp
+@@ -263,7 +263,7 @@ fastaRefReadSizes(vector<FileBuf*>& in,
+ << "reference into smaller chunks and index each independently." << endl;
+ #else
+ cerr << "Error: Reference sequence has more than 2^32-1 characters! Please try to" << endl
+- << "build a large index instead using the appropiate options." << endl;
++ << "build a large index instead using the appropriate options." << endl;
+ #endif
+ throw 1;
+ }
diff --git a/sci-biology/bowtie/files/bowtie-1.1.2-unbundle-seqan.patch b/sci-biology/bowtie/files/bowtie-1.1.2-unbundle-seqan.patch
new file mode 100644
index 000000000000..54391ae415a3
--- /dev/null
+++ b/sci-biology/bowtie/files/bowtie-1.1.2-unbundle-seqan.patch
@@ -0,0 +1,27 @@
+Description: Use Debian packaged SeqAn library instead of copy in upstream source
+Author: Andreas Tille <tille@debian.org>
+Date: 2011-01-30
+Last-Update: 2013-04-18
+Reviewed-by: Ognyan Kulev <ogi@debian.org>
+
+--- a/Makefile
++++ b/Makefile
+@@ -5,9 +5,7 @@
+ prefix = /usr/local
+ bindir = $(prefix)/bin
+
+-SEQAN_DIR = SeqAn-1.1
+-SEQAN_INC = -I $(SEQAN_DIR)
+-INC = $(SEQAN_INC) -I third_party
++INC = `pkg-config --cflags seqan-1.4`
+ CPP = g++
+ CXX = $(CPP)
+ CC = gcc
+@@ -168,7 +166,6 @@
+ $(wildcard genomes/NC_008253.fna) \
+ $(wildcard reads/e_coli_1000.*) \
+ $(wildcard reads/e_coli_1000_*) \
+- SeqAn-1.1 \
+ bowtie \
+ bowtie-build \
+ bowtie-inspect \