[med-svn] r9384 - trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian
Andreas Tille
tille at alioth.debian.org
Sun Jan 22 22:03:58 UTC 2012
Author: tille
Date: 2012-01-22 22:03:58 +0000 (Sun, 22 Jan 2012)
New Revision: 9384
Added:
trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install
Removed:
trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install.template
Modified:
trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/changelog
trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/rules
Log:
Simplify installation method
Modified: trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/changelog
===================================================================
--- trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/changelog 2012-01-22 14:01:13 UTC (rev 9383)
+++ trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/changelog 2012-01-22 22:03:58 UTC (rev 9384)
@@ -8,6 +8,14 @@
- Use GZIP="--best --no-name" tar --owner=root --group=root --mode=a+rX
when building tarball to get better reproducible results
- Make sure the originally downloaded files will not be kept in two copies
+ * debian/install.template renamed to debian/install
+ * debian/rules:
+ - Fix clean target to remove debian/defaults.template which was created in
+ package building process
+ - use Make variables instead of "export SHELL_VARIABLE"
+ - make install process less complex by simply using a fixed
+ debian/install and move those files that needs manual moving straight
+ into place
-- Andreas Tille <tille at debian.org> Sat, 21 Jan 2012 11:17:10 +0100
Added: trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install
===================================================================
--- trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install (rev 0)
+++ trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install 2012-01-22 22:03:58 UTC (rev 9384)
@@ -0,0 +1,2 @@
+debian/defaults.template /usr/share/fis-gtm-initial
+
Deleted: trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install.template
===================================================================
--- trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install.template 2012-01-22 14:01:13 UTC (rev 9383)
+++ trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/install.template 2012-01-22 22:03:58 UTC (rev 9384)
@@ -1,2 +0,0 @@
-debian/defaults.template /usr/share/fis-gtm-initial
-
Modified: trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/rules
===================================================================
--- trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/rules 2012-01-22 14:01:13 UTC (rev 9383)
+++ trunk/packages/fis-gtm/fis-gtm-initial/trunk/debian/rules 2012-01-22 22:03:58 UTC (rev 9384)
@@ -5,9 +5,15 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
-export FISGTM_VERSION_INITIAL=`dpkg-parsechangelog | grep 'Version:'|sed 's?Version: ??g'| cut -d- -f1`
-export FISGTM_ROOT=/usr/lib/fis-gtm
+FISGTM_VERSION_INITIAL := $(shell dpkg-parsechangelog | grep 'Version:'|sed 's?Version: ??g'| cut -d- -f1)
+FISGTM_ROOT := /usr/lib/fis-gtm
+# obtain package name which can be used to address the temporary packaging dir
+pkg := $(shell dpkg-parsechangelog | sed -n 's/^Source: //p')
+
+# obtain build architecture to detect the right binary for installation
+BUILDARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
+
%:
dh $@
@@ -15,15 +21,22 @@
echo "do not configure anything in this step"
override_dh_auto_install:
- cat debian/install.template > debian/install
- echo "${FISGTM_ROOT}" >> debian/install
- mkdir -p debian/tmp/${FISGTM_ROOT}/distribution
+ # that's a pretty complex way to copy the gtm tarball to a certain dir - let's rather do this directly
+ # cat debian/install.template > debian/install
+ # echo "$(FISGTM_ROOT)" >> debian/install
+ mkdir -p debian/$(pkg)/$(FISGTM_ROOT)/distribution
+ # Considering that there are two distinct tarballs in the original tarball copying both into the
+ # target binary deb is just wrong - wee need to grep for the right architecture as well
+ cp -a `ls -1 | grep -v debian | grep $(BUILDARCH)` debian/$(pkg)/$(FISGTM_ROOT)/distribution
+
cat debian/defaults.template.template |\
- sed "s?RRRRR?${FISGTM_ROOT}?g" |\
- sed "s/VVVVV/${FISGTM_VERSION_INITIAL}/g" > debian/defaults.template
- cp -a `ls -1 |grep -v debian` debian/tmp/${FISGTM_ROOT}/distribution
- dh_install
+ sed "s?RRRRR?$(FISGTM_ROOT)?g" |\
+ sed "s/VVVVV/$(FISGTM_VERSION_INITIAL)/g" > debian/defaults.template
+override_dh_auto_clean:
+ dh_auto_clean
+ rm -f debian/defaults.template
+
get-orig-source:
. ./debian/get-orig-source
More information about the debian-med-commit
mailing list