[med-svn] [brig] 03/03: Rework source package compeletly since download does not include BIRG source
Andreas Tille
tille at debian.org
Sun Nov 29 10:33:14 UTC 2015
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository brig.
commit 045d1f151d51b2b598415b9301402abe5a56fa5f
Author: Andreas Tille <tille at debian.org>
Date: Sun Nov 29 11:28:15 2015 +0100
Rework source package compeletly since download does not include BIRG source
---
debian/control | 7 ++-
debian/get-orig-source | 64 +++++++++++++++++++++++++++
debian/jlibs | 1 +
debian/links | 1 +
debian/manifest | 5 +++
debian/patches/series | 1 +
debian/patches/use_debian_packaged_jars.patch | 22 +++++++++
debian/rules | 7 ++-
debian/watch | 3 +-
9 files changed, 107 insertions(+), 4 deletions(-)
diff --git a/debian/control b/debian/control
index 0c317ce..96422a5 100644
--- a/debian/control
+++ b/debian/control
@@ -5,7 +5,12 @@ Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.
Uploaders: Andreas Tille <tille at debian.org>
Build-Depends: debhelper (>= 9),
javahelper,
- cgview
+ ant,
+ libjdom1-java,
+ libswing-layout-java,
+ cgview,
+ blast2 | ncbi-blast+-legacy,
+ ncbi-blast+
Standards-Version: 3.9.6
Vcs-Browser: https://anonscm.debian.org/cgit/debian-med/brig.git
Vcs-Git: git://anonscm.debian.org/debian-med/brig.git
diff --git a/debian/get-orig-source b/debian/get-orig-source
new file mode 100755
index 0000000..4695c97
--- /dev/null
+++ b/debian/get-orig-source
@@ -0,0 +1,64 @@
+#!/bin/sh
+# if you need to repack for whatever reason you can
+# use this script via uscan or directly
+#
+# FIXME: currently the code is not conform to Debian Policy
+# http://www.debian.org/doc/debian-policy/ch-source.html
+# "get-orig-source (optional)"
+# This target may be invoked in any directory, ...
+# --> currently it is assumed the script is called in the
+# source directory featuring the debian/ dir
+
+COMPRESS=xz
+
+NAME=`dpkg-parsechangelog | awk '/^Source/ { print $2 }'`
+
+set -x
+echo args = $@
+if ! echo $@ | grep -q upstream-version ; then
+ VERSION=`dpkg-parsechangelog | awk '/^Version:/ { print $2 }' | sed 's/\([0-9\.]\+\)-[0-9]\+$/\1/'`
+ uscan --force-download
+else
+ VERSION=`echo $@ | sed "s?^.*--upstream-version \([0-9.]\+\) .*BRIG.*-dist.*?\1?"`
+ if echo "$VERSION" | grep -q "upstream-version" ; then
+ echo "Unable to parse version number"
+ exit
+ fi
+fi
+
+set -e
+
+## NO tags no branches
+SVNURI="svn://svn.code.sf.net/p/brig/code/"
+
+TARDIR=${NAME}-${VERSION}
+
+mkdir -p ../tarballs
+cd ../tarballs
+# svn export conserves time stamps of the files, checkout does not
+rm -rf ${NAME}-code
+LC_ALL=C svn --quiet export ${SVNURI} ${NAME}-code
+unzip -q ../BRIG-${VERSION}-dist.zip
+mv BRIG-${VERSION}-dist ${TARDIR}
+cd ${TARDIR}
+find . -name "*.jar" -delete
+find . -name ".DS_Store" -delete
+find . -name "*.pdf" -delete
+rm -rf errorlog.xml
+rm -rf cgview
+# copy Java source from SVN
+mv ../${NAME}-code/BRIG/src .
+# Cherry pick from SVN content - no idea what principle upstream followed when creating download archive
+mv ../${NAME}-code/BRIG/HELP HELP
+mv ../${NAME}-code/BRIG/README.txt README_devel.txt
+mv ../${NAME}-code/BRIG/[a-d]*.xml .
+mv ../${NAME}-code/BRIG/manifest* .
+mv ../${NAME}-code/BRIG/*.fasta .
+mv ../${NAME}-code/BRIG/proteins.txt .
+mv ../${NAME}-code/BRIG/nbproject .
+chmod 644 proteins.txt src/brig/*
+rm -rf ../${NAME}-code
+cd ..
+
+GZIP="--best --no-name" tar --owner=root --group=root --mode=a+rX -caf "$NAME"_"$VERSION".orig.tar.${COMPRESS} "${TARDIR}"
+rm -rf ${TARDIR}
diff --git a/debian/jlibs b/debian/jlibs
new file mode 100644
index 0000000..0ef7c6d
--- /dev/null
+++ b/debian/jlibs
@@ -0,0 +1 @@
+dist/*.jar
diff --git a/debian/links b/debian/links
new file mode 100644
index 0000000..92cf5c3
--- /dev/null
+++ b/debian/links
@@ -0,0 +1 @@
+usr/share/java/BRIG.jar usr/bin/brig
diff --git a/debian/manifest b/debian/manifest
new file mode 100644
index 0000000..6b44ea4
--- /dev/null
+++ b/debian/manifest
@@ -0,0 +1,5 @@
+/usr/share/java/BRIG.jar:
+ Class-Path: /usr/share/java/cgview.jar /usr/share/java/jdom1.jar /usr/share/java/swing-layout.jar
+
+
+
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..a19efd6
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+use_debian_packaged_jars.patch
diff --git a/debian/patches/use_debian_packaged_jars.patch b/debian/patches/use_debian_packaged_jars.patch
new file mode 100644
index 0000000..73cc494
--- /dev/null
+++ b/debian/patches/use_debian_packaged_jars.patch
@@ -0,0 +1,22 @@
+Author: Andreas Tille <tille at debian.org>
+Last-Update: Fri, 27 Nov 2015 08:36:19 +0100
+Description: Use Debian packaged JARs
+
+--- a/nbproject/project.properties
++++ b/nbproject/project.properties
+@@ -26,12 +26,13 @@ dist.javadoc.dir=${dist.dir}/javadoc
+ endorsed.classpath=
+ excludes=
+ file.reference.commons-cli-1.2.jar=/home/nabil/Downloads/commons-cli-1.2/commons-cli-1.2.jar
+-file.reference.jdom.jar=src\\brig\\jdom.jar
++file.reference.jdom.jar=/usr/share/java/jdom1.jar
++file.reference.swing-layout.jar=/usr/share/java/swing-layout.jar
+ includes=**
+ jar.compress=false
+ javac.classpath=\
+ ${file.reference.jdom.jar}:\
+- ${libs.swing-layout.classpath}:\
++ ${file.reference.swing-layout.jar}:\
+ ${file.reference.commons-cli-1.2.jar}
+ # Space-separated list of extra javac options
+ javac.compilerargs=
diff --git a/debian/rules b/debian/rules
index 7a8ee54..c3be751 100755
--- a/debian/rules
+++ b/debian/rules
@@ -15,8 +15,11 @@
# include /usr/share/dpkg/default.mk
# and use what is set there.
+JAVA_HOME=/usr/lib/jvm/default-java
+
%:
- dh $@
+ dh $@ --with javahelper
get-orig-source:
- uscan --verbose --force-download --repack --compression xz
+ . debian/get-orig-source
+ # uscan --verbose --force-download --repack --compression xz
diff --git a/debian/watch b/debian/watch
index 44a47ae..cba41a5 100644
--- a/debian/watch
+++ b/debian/watch
@@ -1,4 +1,5 @@
version=3
opts="repacksuffix=+dfsg,dversionmangle=s/\+dfsg//g" \
- http://sf.net/brig/BRIG-(\d[\d\.]+)-dist\.(?:tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz))|zip)
+ http://sf.net/brig/BRIG-(\d[\d\.]+)-dist\.(?:tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz))|zip) \
+ debian debian/get-orig-source
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/brig.git
More information about the debian-med-commit
mailing list