[med-svn] [Git][med-team/libvcflib][master] 8 commits: adjust inclusion of the packaged SmithWatermanGotoh.h
Michael R. Crusoe
gitlab at salsa.debian.org
Sat Oct 31 20:48:50 GMT 2020
Michael R. Crusoe pushed to branch master at Debian Med / libvcflib
Commits:
ce9aabfd by Michael R. Crusoe at 2020-10-31T18:06:25+01:00
adjust inclusion of the packaged SmithWatermanGotoh.h
- - - - -
2854c476 by Michael R. Crusoe at 2020-10-31T18:06:48+01:00
routine-update: Standards-Version: 4.5.0
- - - - -
8edcc2be by Michael R. Crusoe at 2020-10-31T18:06:48+01:00
routine-update: debhelper-compat 13
- - - - -
2005009c by Michael R. Crusoe at 2020-10-31T18:06:52+01:00
routine-update: Add salsa-ci file
- - - - -
57579471 by Michael R. Crusoe at 2020-10-31T18:06:52+01:00
routine-update: Rules-Requires-Root: no
- - - - -
d038923c by Michael R. Crusoe at 2020-10-31T18:06:56+01:00
Set upstream metadata fields: Bug-Database, Bug-Submit, Repository, Repository-Browse.
Changes-By: lintian-brush
Fixes: lintian: upstream-metadata-missing-bug-tracking
See-also: https://lintian.debian.org/tags/upstream-metadata-missing-bug-tracking.html
Fixes: lintian: upstream-metadata-missing-repository
See-also: https://lintian.debian.org/tags/upstream-metadata-missing-repository.html
- - - - -
c87dd12d by Michael R. Crusoe at 2020-10-31T18:41:17+01:00
Update patch headers.
- - - - -
cbb46c4e by Michael R. Crusoe at 2020-10-31T18:53:08+01:00
IntervalTree.h patch is no longer needed
- - - - -
20 changed files:
- debian/changelog
- debian/control
- − debian/include/IntervalTree.h
- debian/patches/crossbuild
- debian/patches/disorder_include
- debian/patches/dont_link_pthread
- debian/patches/fix_ssw_cpp_header_name.patch
- debian/patches/hardening-flags
- − debian/patches/intervaltree.patch
- debian/patches/no_fsom
- debian/patches/no_libVCFH
- debian/patches/override_version
- debian/patches/pkg-config.patch
- debian/patches/shared_lib.patch
- debian/patches/use_debian_packaged_fastahack.patch
- debian/patches/use_debian_packaged_libssw.patch
- debian/patches/use_debian_packaged_smithwaterman.patch
- debian/patches/use_debian_packaged_tabixpp.patch
- + debian/salsa-ci.yml
- debian/upstream/metadata
Changes:
=====================================
debian/changelog
=====================================
@@ -1,3 +1,20 @@
+libvcflib (1.0.1+dfsg-4) UNRELEASED; urgency=medium
+
+ * Team upload.
+ * debian/patches/use_debian_packaged_smithwaterman.patch: adjust
+ inclusion of the packaged
+ /usr/include/smithwaterman/SmithWatermanGotoh.h
+ * Standards-Version: 4.5.0 (routine-update)
+ * debhelper-compat 13 (routine-update)
+ * Add salsa-ci file (routine-update)
+ * Rules-Requires-Root: no (routine-update)
+ * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
+ Repository-Browse.
+ * Update patch headers.
+ * IntervalTree.h patch is no longer needed
+
+ -- Michael R. Crusoe <crusoe at debian.org> Sat, 31 Oct 2020 18:05:41 +0100
+
libvcflib (1.0.1+dfsg-3) unstable; urgency=medium
* Team upload.
=====================================
debian/control
=====================================
@@ -3,7 +3,7 @@ Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.
Uploaders: Andreas Tille <tille at debian.org>
Section: science
Priority: optional
-Build-Depends: debhelper-compat (= 12),
+Build-Depends: debhelper-compat (= 13),
dh-exec,
markdown <!nodoc>,
libtabixpp-dev,
@@ -14,10 +14,11 @@ Build-Depends: debhelper-compat (= 12),
libfastahack-dev (>= 0.0+git20160702.bbc645f+dfsg-5~),
pkg-config,
libipc-run3-perl <!nocheck>
-Standards-Version: 4.4.1
+Standards-Version: 4.5.0
Vcs-Browser: https://salsa.debian.org/med-team/libvcflib
Vcs-Git: https://salsa.debian.org/med-team/libvcflib.git
Homepage: https://github.com/vcflib/vcflib
+Rules-Requires-Root: no
Package: libvcflib1
Architecture: any
=====================================
debian/include/IntervalTree.h deleted
=====================================
@@ -1,343 +0,0 @@
-#ifndef __INTERVAL_TREE_H
-#define __INTERVAL_TREE_H
-
-#include <vector>
-#include <algorithm>
-#include <iostream>
-#include <memory>
-#include <cassert>
-
-#ifdef USE_INTERVAL_TREE_NAMESPACE
-namespace interval_tree {
-#endif
-template <class Scalar, typename Value>
-class Interval {
-public:
- Scalar start;
- Scalar stop;
- Value value;
- Interval(const Scalar& s, const Scalar& e, const Value& v)
- : start(std::min(s, e))
- , stop(std::max(s, e))
- , value(v)
- {}
-};
-
-template <class Scalar, typename Value>
-Value intervalStart(const Interval<Scalar,Value>& i) {
- return i.start;
-}
-
-template <class Scalar, typename Value>
-Value intervalStop(const Interval<Scalar, Value>& i) {
- return i.stop;
-}
-
-template <class Scalar, typename Value>
-std::ostream& operator<<(std::ostream& out, const Interval<Scalar, Value>& i) {
- out << "Interval(" << i.start << ", " << i.stop << "): " << i.value;
- return out;
-}
-
-template <class Scalar, class Value>
-class IntervalTree {
-public:
- typedef Interval<Scalar, Value> interval;
- typedef std::vector<interval> interval_vector;
-
-
- struct IntervalStartCmp {
- bool operator()(const interval& a, const interval& b) {
- return a.start < b.start;
- }
- };
-
- struct IntervalStopCmp {
- bool operator()(const interval& a, const interval& b) {
- return a.stop < b.stop;
- }
- };
-
- IntervalTree()
- : left(nullptr)
- , right(nullptr)
- , center(0)
- {}
-
- ~IntervalTree() = default;
-
- std::unique_ptr<IntervalTree> clone() const {
- return std::unique_ptr<IntervalTree>(new IntervalTree(*this));
- }
-
- IntervalTree(const IntervalTree& other)
- : intervals(other.intervals),
- left(other.left ? other.left->clone() : nullptr),
- right(other.right ? other.right->clone() : nullptr),
- center(other.center)
- {}
-
- IntervalTree& operator=(IntervalTree&&) = default;
- IntervalTree(IntervalTree&&) = default;
-
- IntervalTree& operator=(const IntervalTree& other) {
- center = other.center;
- intervals = other.intervals;
- left = other.left ? other.left->clone() : nullptr;
- right = other.right ? other.right->clone() : nullptr;
- return *this;
- }
-
- IntervalTree(
- interval_vector&& ivals,
- std::size_t depth = 16,
- std::size_t minbucket = 64,
- std::size_t maxbucket = 512,
- Scalar leftextent = 0,
- Scalar rightextent = 0)
- : left(nullptr)
- , right(nullptr)
- {
- --depth;
- const auto minmaxStop = std::minmax_element(ivals.begin(), ivals.end(),
- IntervalStopCmp());
- const auto minmaxStart = std::minmax_element(ivals.begin(), ivals.end(),
- IntervalStartCmp());
- if (!ivals.empty()) {
- center = (minmaxStart.first->start + minmaxStop.second->stop) / 2;
- }
- if (leftextent == 0 && rightextent == 0) {
- // sort intervals by start
- std::sort(ivals.begin(), ivals.end(), IntervalStartCmp());
- } else {
- assert(std::is_sorted(ivals.begin(), ivals.end(), IntervalStartCmp()));
- }
- if (depth == 0 || (ivals.size() < minbucket && ivals.size() < maxbucket)) {
- std::sort(ivals.begin(), ivals.end(), IntervalStartCmp());
- intervals = std::move(ivals);
- assert(is_valid().first);
- return;
- } else {
- Scalar leftp = 0;
- Scalar rightp = 0;
-
- if (leftextent || rightextent) {
- leftp = leftextent;
- rightp = rightextent;
- } else {
- leftp = ivals.front().start;
- rightp = std::max_element(ivals.begin(), ivals.end(),
- IntervalStopCmp())->stop;
- }
-
- interval_vector lefts;
- interval_vector rights;
-
- for (typename interval_vector::const_iterator i = ivals.begin();
- i != ivals.end(); ++i) {
- const interval& interval = *i;
- if (interval.stop < center) {
- lefts.push_back(interval);
- } else if (interval.start > center) {
- rights.push_back(interval);
- } else {
- assert(interval.start <= center);
- assert(center <= interval.stop);
- intervals.push_back(interval);
- }
- }
-
- if (!lefts.empty()) {
- left.reset(new IntervalTree(std::move(lefts),
- depth, minbucket, maxbucket,
- leftp, center));
- }
- if (!rights.empty()) {
- right.reset(new IntervalTree(std::move(rights),
- depth, minbucket, maxbucket,
- center, rightp));
- }
- }
- assert(is_valid().first);
- }
-
- // Call f on all intervals near the range [start, stop]:
- template <class UnaryFunction>
- void visit_near(const Scalar& start, const Scalar& stop, UnaryFunction f) const {
- if (!intervals.empty() && ! (stop < intervals.front().start)) {
- for (auto & i : intervals) {
- f(i);
- }
- }
- if (left && start <= center) {
- left->visit_near(start, stop, f);
- }
- if (right && stop >= center) {
- right->visit_near(start, stop, f);
- }
- }
-
- // Call f on all intervals crossing pos
- template <class UnaryFunction>
- void visit_overlapping(const Scalar& pos, UnaryFunction f) const {
- visit_overlapping(pos, pos, f);
- }
-
- // Call f on all intervals overlapping [start, stop]
- template <class UnaryFunction>
- void visit_overlapping(const Scalar& start, const Scalar& stop, UnaryFunction f) const {
- auto filterF = [&](const interval& interval) {
- if (interval.stop >= start && interval.start <= stop) {
- // Only apply f if overlapping
- f(interval);
- }
- };
- visit_near(start, stop, filterF);
- }
-
- // Call f on all intervals contained within [start, stop]
- template <class UnaryFunction>
- void visit_contained(const Scalar& start, const Scalar& stop, UnaryFunction f) const {
- auto filterF = [&](const interval& interval) {
- if (start <= interval.start && interval.stop <= stop) {
- f(interval);
- }
- };
- visit_near(start, stop, filterF);
- }
-
- interval_vector findOverlapping(const Scalar& start, const Scalar& stop) const {
- interval_vector result;
- visit_overlapping(start, stop,
- [&](const interval& interval) {
- result.emplace_back(interval);
- });
- return result;
- }
-
- interval_vector findContained(const Scalar& start, const Scalar& stop) const {
- interval_vector result;
- visit_contained(start, stop,
- [&](const interval& interval) {
- result.push_back(interval);
- });
- return result;
- }
- bool empty() const {
- if (left && !left->empty()) {
- return false;
- }
- if (!intervals.empty()) {
- return false;
- }
- if (right && !right->empty()) {
- return false;
- }
- return true;
- }
-
- template <class UnaryFunction>
- void visit_all(UnaryFunction f) const {
- if (left) {
- left->visit_all(f);
- }
- std::for_each(intervals.begin(), intervals.end(), f);
- if (right) {
- right->visit_all(f);
- }
- }
-
- std::pair<Scalar, Scalar> extentBruitForce() const {
- struct Extent {
- std::pair<Scalar, Scalar> x = {std::numeric_limits<Scalar>::max(),
- std::numeric_limits<Scalar>::min() };
- void operator()(const interval & interval) {
- x.first = std::min(x.first, interval.start);
- x.second = std::max(x.second, interval.stop);
- }
- };
- Extent extent;
-
- visit_all([&](const interval & interval) { extent(interval); });
- return extent.x;
- }
-
- // Check all constraints.
- // If first is false, second is invalid.
- std::pair<bool, std::pair<Scalar, Scalar>> is_valid() const {
- const auto minmaxStop = std::minmax_element(intervals.begin(), intervals.end(),
- IntervalStopCmp());
- const auto minmaxStart = std::minmax_element(intervals.begin(), intervals.end(),
- IntervalStartCmp());
-
- std::pair<bool, std::pair<Scalar, Scalar>> result = {true, { std::numeric_limits<Scalar>::max(),
- std::numeric_limits<Scalar>::min() }};
- if (!intervals.empty()) {
- result.second.first = std::min(result.second.first, minmaxStart.first->start);
- result.second.second = std::min(result.second.second, minmaxStop.second->stop);
- }
- if (left) {
- auto valid = left->is_valid();
- result.first &= valid.first;
- result.second.first = std::min(result.second.first, valid.second.first);
- result.second.second = std::min(result.second.second, valid.second.second);
- if (!result.first) { return result; }
- if (valid.second.second >= center) {
- result.first = false;
- return result;
- }
- }
- if (right) {
- auto valid = right->is_valid();
- result.first &= valid.first;
- result.second.first = std::min(result.second.first, valid.second.first);
- result.second.second = std::min(result.second.second, valid.second.second);
- if (!result.first) { return result; }
- if (valid.second.first <= center) {
- result.first = false;
- return result;
- }
- }
- if (!std::is_sorted(intervals.begin(), intervals.end(), IntervalStartCmp())) {
- result.first = false;
- }
- return result;
- }
-
- friend std::ostream& operator<<(std::ostream& os, const IntervalTree& itree) {
- return writeOut(os, itree);
- }
-
- friend std::ostream& writeOut(std::ostream& os, const IntervalTree& itree,
- std::size_t depth = 0) {
- auto pad = [&]() { for (std::size_t i = 0; i != depth; ++i) { os << ' '; } };
- pad(); os << "center: " << itree.center << '\n';
- for (const interval & inter : itree.intervals) {
- pad(); os << inter << '\n';
- }
- if (itree.left) {
- pad(); os << "left:\n";
- writeOut(os, *itree.left, depth + 1);
- } else {
- pad(); os << "left: nullptr\n";
- }
- if (itree.right) {
- pad(); os << "right:\n";
- writeOut(os, *itree.right, depth + 1);
- } else {
- pad(); os << "right: nullptr\n";
- }
- return os;
- }
-
-private:
- interval_vector intervals;
- std::unique_ptr<IntervalTree> left;
- std::unique_ptr<IntervalTree> right;
- Scalar center;
-};
-#ifdef USE_INTERVAL_TREE_NAMESPACE
-}
-#endif
-
-#endif
=====================================
debian/patches/crossbuild
=====================================
@@ -1,6 +1,6 @@
-Author: Michael R. Crusoe <michael.crusoe at gmail.com>
+Author: Michael R. Crusoe <crusoe at debian.org>
Description: Enable cross-building
-
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -1,4 +1,9 @@
=====================================
debian/patches/disorder_include
=====================================
@@ -1,11 +1,12 @@
-From: Michael R. Crusoe <michael.crusoe at gmail.com>
+From: Michael R. Crusoe <crusoe at debian.org>
Subject: Put the disorder.h include where it is used
+Forwarded: https://github.com/vcflib/vcflib/pull/299
--- libvcflib.orig/src/Variant.h
+++ libvcflib/src/Variant.h
@@ -19,7 +19,6 @@
#include "join.h"
#include "tabix.hpp"
- #include "SmithWatermanGotoh.h"
+ #include <smithwaterman/SmithWatermanGotoh.h>
-#include "disorder.h"
#include <ssw_cpp.h>
#include "convert.h"
=====================================
debian/patches/dont_link_pthread
=====================================
@@ -1,5 +1,6 @@
-Author: Michael R. Crusoe <michael.crusoe at gmail.com>
+Author: Michael R. Crusoe <crusoe at debian.org>
Description: pthread is needed by the libraries we link to, but not us
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -125,11 +125,11 @@
=====================================
debian/patches/fix_ssw_cpp_header_name.patch
=====================================
@@ -1,12 +1,12 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Thu, 13 Sep 2018 19:35:33 +0200
Description: The header file is named ssw_cpp.h
-
---- a/src/Variant.h
-+++ b/src/Variant.h
+Forwarded: not-needed
+--- libvcflib.orig/src/Variant.h
++++ libvcflib/src/Variant.h
@@ -20,7 +20,7 @@
#include "tabix.hpp"
- #include "SmithWatermanGotoh.h"
+ #include <smithwaterman/SmithWatermanGotoh.h>
#include "disorder.h"
-#include "ssw_cpp.hpp"
+#include <ssw_cpp.h>
=====================================
debian/patches/hardening-flags
=====================================
@@ -1,5 +1,6 @@
-From: Michael R. Crusoe <michael.crusoe at gmail.com>
+From: Michael R. Crusoe <crusoe at debian.org>
Subject: Pass CPPFLAGS
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -125,7 +125,7 @@
=====================================
debian/patches/intervaltree.patch deleted
=====================================
@@ -1,15 +0,0 @@
-Author: Andreas Tille <tille at debian.org>
-Last-Update: Thu, 23 Jun 2016 09:10:54 +0200
-Description: We provide a local copy of intervaltree in debian/include and
- inject it here in the build system
-
---- libvcflib.orig/Makefile
-+++ libvcflib/Makefile
-@@ -171,6 +171,7 @@
- multichoose: pre
- echo "Source does not contain dir multichoose"
- #cd multichoose && $(MAKE) && cp *.h* $(VCF_LIB_LOCAL)/$(INC_DIR)/
-+ mkdir -p $(VCF_LIB_LOCAL)/$(INC_DIR)/ && cp -a debian/include/* $(VCF_LIB_LOCAL)/$(INC_DIR)/
-
- intervaltree: pre
- echo "Source does not contain dir intervaltree"
=====================================
debian/patches/no_fsom
=====================================
@@ -1,5 +1,6 @@
-From: Michael R. Crusoe <michael.crusoe at gmail.com>
+From: Michael R. Crusoe <crusoe at debian.org>
Subject: fsom is not used
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -114,9 +114,6 @@
=====================================
debian/patches/no_libVCFH
=====================================
@@ -1,5 +1,6 @@
-From: Michael R. Crusoe <michael.crusoe at gmail.com>
+From: Michael R. Crusoe <crusoe at debian.org>
Subject: libVCFH is not used
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -200,7 +200,6 @@
=====================================
debian/patches/override_version
=====================================
@@ -1,5 +1,6 @@
-Author: Michael R. Crusoe
+Author: Michael R. Crusoe <crusoe at debian.org>
Description: allow us to specify the package version
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -136,7 +136,7 @@
=====================================
debian/patches/pkg-config.patch
=====================================
@@ -1,7 +1,7 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Fri, 10 Feb 2017 09:09:35 +0100
Description: Add pkg-config file to simplify building of freebayes
-
+Forwarded: not-needed
--- /dev/null
+++ libvcflib/libvcflib.pc
@@ -0,0 +1,12 @@
=====================================
debian/patches/shared_lib.patch
=====================================
@@ -1,7 +1,7 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Thu, 15 Sep 2016 22:26:26 +0200
Description: Create shared lib instead of static
-
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -152,7 +152,7 @@
=====================================
debian/patches/use_debian_packaged_fastahack.patch
=====================================
@@ -1,7 +1,7 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Thu, 23 Jun 2016 09:10:54 +0200
Description: Use Debian packaged libfastahack (and libdisorder)
-
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -119,7 +119,6 @@
=====================================
debian/patches/use_debian_packaged_libssw.patch
=====================================
@@ -3,7 +3,7 @@ Last-Update: Tue, 22 Nov 2016 10:56:09 +0100
Bug-Debian: https://bugs.debian.org/838513
Description: Use Debian packaged libssw (while its not clear
why two implementations of Smith-Waterman are needed at all)
-
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -129,9 +129,7 @@
=====================================
debian/patches/use_debian_packaged_smithwaterman.patch
=====================================
@@ -1,7 +1,7 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Thu, 23 Jun 2016 09:10:54 +0200
Description: Use Debian packaged libsmithwaterman
-
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
@@ -120,11 +120,6 @@
@@ -66,3 +66,14 @@ Description: Use Debian packaged libsmithwaterman
$(MAKE) clean -C fastahack
$(MAKE) clean -C multichoose
$(MAKE) clean -C libVCFH
+--- libvcflib.orig/src/Variant.h
++++ libvcflib/src/Variant.h
+@@ -18,7 +18,7 @@
+ #include "split.h"
+ #include "join.h"
+ #include "tabix.hpp"
+-#include "SmithWatermanGotoh.h"
++#include <smithwaterman/SmithWatermanGotoh.h>
+ #include "disorder.h"
+ #include "ssw_cpp.hpp"
+ #include "convert.h"
=====================================
debian/patches/use_debian_packaged_tabixpp.patch
=====================================
@@ -1,6 +1,7 @@
Author: Andreas Tille <tille at debian.org>
Last-Update: Thu, 23 Jun 2016 09:10:54 +0200
Description: Use Debian packaged libtabixpp
+Forwarded: not-needed
--- libvcflib.orig/Makefile
+++ libvcflib/Makefile
=====================================
debian/salsa-ci.yml
=====================================
@@ -0,0 +1,4 @@
+---
+include:
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/salsa-ci.yml
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/pipeline-jobs.yml
=====================================
debian/upstream/metadata
=====================================
@@ -1,3 +1,5 @@
+Bug-Database: https://github.com/vcflib/vcflib/issues
+Bug-Submit: https://github.com/vcflib/vcflib/issues/new
Registry:
- Name: bio.tools
Entry: vcflib
@@ -7,3 +9,5 @@ Registry:
Entry: SCR_001231
- Name: conda:bioconda
Entry: vcflib
+Repository: https://github.com/vcflib/vcflib.git
+Repository-Browse: https://github.com/vcflib/vcflib
View it on GitLab: https://salsa.debian.org/med-team/libvcflib/-/compare/b072c53c3c167285e0c15cec0d17164993554420...cbb46c4e6719e4c9706ce9432f6313dd5f610021
--
View it on GitLab: https://salsa.debian.org/med-team/libvcflib/-/compare/b072c53c3c167285e0c15cec0d17164993554420...cbb46c4e6719e4c9706ce9432f6313dd5f610021
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20201031/4a109390/attachment-0001.html>
More information about the debian-med-commit
mailing list