[cpl-plugin-template] 15/58: Automatically detect whether the calibration files are included, and build downloader only if not

Ole Streicher olebole at moszumanska.debian.org
Tue Mar 31 09:23:37 UTC 2015


This is an automated email from the git hooks/post-receive script.

olebole pushed a commit to branch debian-template
in repository cpl-plugin-template.

commit b0b538db44aef572383a974f0e96f244978dfe05
Author: Ole Streicher <debian at liska.ath.cx>
Date:   Sun Sep 15 17:50:07 2013 +0200

    Automatically detect whether the calibration files are included, and build downloader only if not
---
 debian/cpl-plugin-calib.install.in | 1 +
 debian/repackage.sh                | 2 ++
 debian/rules                       | 8 +++++++-
 3 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/debian/cpl-plugin-calib.install.in b/debian/cpl-plugin-calib.install.in
new file mode 100644
index 0000000..9f0855f
--- /dev/null
+++ b/debian/cpl-plugin-calib.install.in
@@ -0,0 +1 @@
+calib/cal usr/share/cpl-plugins/__PIPELINE__
diff --git a/debian/repackage.sh b/debian/repackage.sh
index 4ea4d52..8b9fe5d 100755
--- a/debian/repackage.sh
+++ b/debian/repackage.sh
@@ -16,6 +16,8 @@ PIPELINE=$(echo ${DEBIAN_PACKAGE} | cut -d- -f3-)
 VERSION=$2
 
 # Include full calibration set?
+# If not, the "calib" package will act as a "downloader" package for the 
+# calibration files.
 INCLUDE_CALIB="no"
 #INCLUDE_CALIB="yes"
 
diff --git a/debian/rules b/debian/rules
index b7a6eca..764f5a6 100755
--- a/debian/rules
+++ b/debian/rules
@@ -11,7 +11,12 @@ PIPELINE ?= $(shell echo '$(DEBPKGNAME)' | sed -e 's/cpl-plugin-//')
 	dh  $@ --with autoreconf
 
 debian_files:
-	for f in .install -calib.postinst -calib.prerm ; do \
+	if [ -d calib/cal ] ; then \
+	    dfiles=".install -calib.install" ; \
+	else \
+	    dfiles=".install -calib.postinst -calib.prerm" ; \
+	fi ; \
+	for f in $$dfiles ; do \
 	    sed "s/__VERSION__/$(VERSION)/g;s/__PIPELINE__/${PIPELINE}/g" \
 	        < debian/cpl-plugin$$f.in \
                 > debian/${DEBPKGNAME}$$f ; \
@@ -23,6 +28,7 @@ override_dh_install: debian_files
 override_dh_clean:
 	dh_clean
 	rm -f debian/${DEBPKGNAME}.install \
+	      debian/${DEBPKGNAME}-calib.install \
 	      debian/${DEBPKGNAME}-calib.postinst \
               debian/${DEBPKGNAME}-calib.prerm
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-astro/packages/cpl-plugin-template.git



More information about the debian-science-commits mailing list