[med-svn] [jellyfish] 02/07: enable perl binding
Michael Crusoe
misterc-guest at moszumanska.debian.org
Sat Mar 12 22:17:30 UTC 2016
This is an automated email from the git hooks/post-receive script.
misterc-guest pushed a commit to branch master
in repository jellyfish.
commit 5d226e8e42ef7a393a21f24311c6a3b55ab8cbb5
Author: Michael R. Crusoe <crusoe at ucdavis.edu>
Date: Sat Mar 12 06:00:32 2016 -0800
enable perl binding
---
debian/changelog | 14 +++++++-
debian/control | 9 ++++--
debian/libjellyfish-perl.install | 1 +
debian/patches/drop-rpath | 69 ++++++++++++++++++++++++++++++++++++++++
debian/patches/modern-g++ | 15 +++++++++
debian/patches/series | 1 +
debian/rules | 26 ++++++++-------
7 files changed, 120 insertions(+), 15 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 9527671..05447a0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -11,7 +11,19 @@ jellyfish (2.2.4-3) UNRELEASED; urgency=medium
* Add building with python3
* Add call to setup.py in dh_autobuild override
- -- Andreas Tille <tille at debian.org> Tue, 29 Dec 2015 21:47:07 +0100
+ [ Michael R. Crusoe ]
+ * Upgrade Standards-Version to 3.9.7
+ * Mark python3- package as arch specifc, not indep; include shared library
+ dependencies
+ * Likewise with the -perl package; also build & install them
+ * debian/patches/drop-rpath: don't compile in a relative path as per policy
+ * debian/patches/modern-g++: use recent g++, not the unavailable version 4.4
+ * debian/patches/pkg-config-with-name: fix error in upstream: pkg-config was
+ called without the package name
+ * debian/rules: enable parallel builds & improve clean target
+ * debian/control: add myself as an uploader
+
+ -- Michael R. Crusoe <crusoe at ucdavis.edu> Sat, 12 Mar 2016 07:49:18 -0800
jellyfish (2.2.4-2) unstable; urgency=medium
diff --git a/debian/control b/debian/control
index 1e7dc8a..34c63a6 100644
--- a/debian/control
+++ b/debian/control
@@ -1,7 +1,8 @@
Source: jellyfish
Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.org>
Uploaders: Shaun Jackman <sjackman at debian.org>,
- Andreas Tille <tille at debian.org>
+ Andreas Tille <tille at debian.org>,
+ Michael R. Crusoe <crusoe at ucdavis.edu>
Section: science
Priority: optional
Build-Depends: debhelper (>= 9),
@@ -15,7 +16,8 @@ Build-Depends: debhelper (>= 9),
valgrind,
swig,
python3-all-dev,
- dh-python
+ dh-python,
+ perl
Standards-Version: 3.9.7
Vcs-Browser: https://anonscm.debian.org/cgit/debian-med/jellyfish.git
Vcs-Git: https://anonscm.debian.org/git/debian-med/jellyfish.git
@@ -115,7 +117,8 @@ Package: libjellyfish-perl
Architecture: any-amd64
Section: perl
Depends: ${perl:Depends},
- ${misc:Depends}
+ ${misc:Depends},
+ ${shlibs:Depends}
Description: count k-mers in DNA sequences (Perl bindings of jellyfish)
JELLYFISH is a tool for fast, memory-efficient counting of k-mers in
DNA. A k-mer is a substring of length k, and counting the occurrences
diff --git a/debian/libjellyfish-perl.install b/debian/libjellyfish-perl.install
new file mode 100644
index 0000000..2379cef
--- /dev/null
+++ b/debian/libjellyfish-perl.install
@@ -0,0 +1 @@
+debian/tmp/usr/lib/*/perl5
diff --git a/debian/patches/drop-rpath b/debian/patches/drop-rpath
index d4d802d..53dbdd4 100644
--- a/debian/patches/drop-rpath
+++ b/debian/patches/drop-rpath
@@ -1,3 +1,5 @@
+Description: Don't compile using an rpath
+Author: Michael R. Crusoe <crusoe at ucdavis.edu>
--- jellyfish.orig/swig/python/setup.py
+++ jellyfish/swig/python/setup.py
@@ -25,7 +25,6 @@
@@ -17,3 +19,70 @@
language = "c++")
setup(name = 'jellyfish',
version = '0.0.1',
+--- jellyfish.orig/swig/Tuprules.tup
++++ jellyfish/swig/Tuprules.tup
+@@ -77,12 +77,6 @@
+ JELLYFISH_LIBS = `pkg-config --libs jellyfish-2.0`
+ endif
+
+-ifdef JELLYFISH_RPATH
+- JELLYFISH_RPATH = @(JELLYFISH_RPATH)
+-else
+- JELLYFISH_RPATH = `pkg-config --libs-only-L jellyfish-2.0 | sed -e 's/-L/-Wl,-rpath,/g'`
+-endif
+-
+ ifdef RUBY_CFLAGS
+ RUBY_CFLAGS = @(RUBY_CFLAGS)
+ else
+--- jellyfish.orig/swig/perl5/Makefile.PL
++++ jellyfish/swig/perl5/Makefile.PL
+@@ -9,7 +9,6 @@
+
+ my $jf_cflags = `pkg-config --cflags jellyfish-2.0`;
+ my $jf_libs = `pkg-config --libs jellyfish-2.0`;
+-my $jf_rpath = `pkg-config --libs-only-L jellyfish-2.0 | sed -e 's/-L/-Wl,-rpath,/g'`;
+
+ WriteMakefile(NAME => 'jellyfish',
+ CC => 'g++-4.4',
+--- jellyfish.orig/swig/perl5/Tupfile
++++ jellyfish/swig/perl5/Tupfile
+@@ -3,7 +3,7 @@
+ export PKG_CONFIG_PATH
+ SWIGFLAGS = -perl5
+ CXXFLAGS += $(JELLYFISH_CFLAGS) $(PERL_CFLAGS) -fPIC
+-LDFLAGS += -shared $(JELLYFISH_LIBS) $(JELLYFISH_RPATH) $(PERL_LIBS)
++LDFLAGS += -shared $(JELLYFISH_LIBS) $(PERL_LIBS)
+
+ : ../jellyfish.i |> !swigxx |> jellyfish_wrap.cxx | jellyfish.pm <jf>
+ : jellyfish_wrap.cxx |> !cxx |>
+--- jellyfish.orig/swig/python/Tupfile
++++ jellyfish/swig/python/Tupfile
+@@ -3,7 +3,7 @@
+ export PKG_CONFIG_PATH
+ SWIGFLAGS = -python
+ CXXFLAGS += $(JELLYFISH_CFLAGS) $(PYTHON_CFLAGS) -fPIC
+-LDFLAGS += -shared $(JELLYFISH_LIBS) $(JELLYFISH_RPATH) $(PYTHON_LIBS)
++LDFLAGS += -shared $(JELLYFISH_LIBS) $(PYTHON_LIBS)
+
+ : ../jellyfish.i |> !swigxx |> jellyfish_wrap.cxx | jellyfish.py <jf>
+ : jellyfish_wrap.cxx |> !cxx |>
+--- jellyfish.orig/swig/ruby/Tupfile
++++ jellyfish/swig/ruby/Tupfile
+@@ -3,7 +3,7 @@
+ export PKG_CONFIG_PATH
+ SWIGFLAGS = -ruby
+ CXXFLAGS += $(JELLYFISH_CFLAGS) $(RUBY_CFLAGS) -fPIC
+-LDFLAGS += -shared $(JELLYFISH_LIBS) $(JELLYFISH_RPATH) $(RUBY_LIBS)
++LDFLAGS += -shared $(JELLYFISH_LIBS) $(RUBY_LIBS)
+
+ : ../jellyfish.i |> !swigxx |> jellyfish_wrap.cxx
+ : jellyfish_wrap.cxx |> !cxx |>
+--- jellyfish.orig/swig/ruby/extconf.rb
++++ jellyfish/swig/ruby/extconf.rb
+@@ -7,6 +7,5 @@
+
+ $defs << `pkg-config --cflags jellyfish-2.0`.chomp << '-std=c++0x'
+ $libs << `pkg-config --libs jellyfish-2.0`.chomp
+-$libs << `pkg-config --libs-only-L jellyfish-2.0 | sed -e 's/-L/-Wl,-rpath,/g'`.chomp
+
+ create_makefile('jellyfish')
diff --git a/debian/patches/modern-g++ b/debian/patches/modern-g++
new file mode 100644
index 0000000..de43b52
--- /dev/null
+++ b/debian/patches/modern-g++
@@ -0,0 +1,15 @@
+Description: Use the version of g++ in Debian, not 4.4
+Author: Michael R. Crusoe <crusoe at ucdavis.edu>
+--- jellyfish.orig/swig/perl5/Makefile.PL
++++ jellyfish/swig/perl5/Makefile.PL
+@@ -11,8 +11,8 @@
+ my $jf_libs = `pkg-config --libs jellyfish-2.0`;
+
+ WriteMakefile(NAME => 'jellyfish',
+- CC => 'g++-4.4',
+- LD => 'g++-4.4',
++ CC => 'g++',
++ LD => 'g++',
+ CCFLAGS => "-std=c++0x $jf_cflags",
+ LIBS => "$jf_libs",
+ OBJECT => 'jellyfish_wrap.o',
diff --git a/debian/patches/series b/debian/patches/series
index 90bdc8d..144a51e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
pkg-config-with-name
enable_c++11_error_deprecated-declarations.patch
drop-rpath
+modern-g++
diff --git a/debian/rules b/debian/rules
index e512a28..080edec 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,6 +4,10 @@ DEBPKGNAME := $(shell dpkg-parsechangelog | awk '/^Source:/ {print $$2}')
build3vers := $(shell py3versions -sv)
export DH_OPTIONS
+export PKG_CONFIG_LIBDIR=${CURDIR}
+export PKG_CONFIG_ALLOW_SYSTEM_LIBS=true
+export PKG_CONFIG_SYSROOT_DIR=${CURDIR}/debian/tmp/
+export PERL_MM_OPT=INSTALLDIRS=vendor
%:
dh $@ --with autoreconf,python3 --parallel
@@ -13,13 +17,16 @@ override_dh_install:
dh_install -ppython3-jellyfish
set -e && for i in $(build3vers); do \
cd swig/python ; \
- PKG_CONFIG_LIBDIR=${CURDIR} PKG_CONFIG_ALLOW_SYSTEM_LIBS=true \
- PKG_CONFIG_SYSROOT_DIR=${CURDIR}/debian/tmp/ \
- python$$i ./setup.py install \
+ python$$i ./setup.py install \
--install-layout=deb --root ../../debian/python3-jellyfish; \
cd ../.. ; \
done
-
+
+ dh_auto_configure --sourcedirectory=swig/perl5
+ cd swig/perl5 ; \
+ $(MAKE) OPTIMIZE="-O2 -g -Wall" ; \
+ $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
+
dh_install
d-shlibmove --commit \
--multiarch \
@@ -28,17 +35,14 @@ override_dh_install:
--movedev "debian/tmp/usr/include/$(DEBPKGNAME)*/$(DEBPKGNAME)/*.h" usr/include/$(DEBPKGNAME) \
debian/tmp/usr/lib/*/lib$(DEBPKGNAME)-*.so
-override_dh_auto_configure:
-# for target in ${SOURCE_DIRECTORIES}; do dh_auto_configure \
-# --sourcedirectory=$${target}
- dh_auto_configure -- --enable-swig --enable-python-binding --enable-perl-binding
+#override_dh_auto_configure:
+# # the doc says you need --enable-python-binding but we call setup.py manually
+# dh_auto_configure -- --enable-swig --enable-python-binding --enable-perl-binding
override_dh_auto_clean:
set -e && for i in $(build3vers); do \
cd swig/python ; \
- PKG_CONFIG_LIBDIR=${CURDIR} PKG_CONFIG_ALLOW_SYSTEM_LIBS=true \
- PKG_CONFIG_SYSROOT_DIR=${CURDIR}/debian/tmp/ \
- python$$i ./setup.py clean --all ; \
+ python$$i ./setup.py clean --all 2> /dev/null; \
cd ../.. ; \
done
dh_auto_clean
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/jellyfish.git
More information about the debian-med-commit
mailing list