updated : debian package scripts
authorgreg
Mon, 02 Mar 2009 09:27:55 +0100
changeset 171 59f5197b088a
parent 170 e10fbd3707df
child 172 bfa2e7806d7d
updated : debian package scripts
debian/changelog
debian/postinst
debian/postrm
debian/rules
--- a/debian/changelog	Tue Jan 20 15:06:13 2009 +0100
+++ b/debian/changelog	Mon Mar 02 09:27:55 2009 +0100
@@ -1,4 +1,4 @@
-matiec (1.0-1) unstable; urgency=low
+matiec (2009.0-%DATEVERSION%) unstable; urgency=low
 
   * Initial release (Closes: #nnnn)  <nnnn is the bug number of your ITP>
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/debian/postinst	Mon Mar 02 09:27:55 2009 +0100
@@ -0,0 +1,43 @@
+#!/bin/sh
+# postinst script for canfestival
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+#        * <postinst> `configure' <most-recently-configured-version>
+#        * <old-postinst> `abort-upgrade' <new version>
+#        * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+#          <new-version>
+#        * <postinst> `abort-remove'
+#        * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+#          <failed-install-package> <version> `removing'
+#          <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+    configure)
+	ln -sf /usr/share/matiec/iec2c /usr/bin/iec2c
+	chmod 755 /usr/share/matiec/iec2c
+	;;
+	
+    abort-upgrade|abort-remove|abort-deconfigure)
+    ;;
+
+    *)
+        echo "postinst called with unknown argument \`$1'" >&2
+        exit 1
+    ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/debian/postrm	Mon Mar 02 09:27:55 2009 +0100
@@ -0,0 +1,31 @@
+#!/bin/sh
+# postrm script for canfestival-objdictedit
+#
+# see: dh_installdeb(1)
+
+set -e
+
+MATIEC=/usr/bin/iec2c
+
+case "$1" in
+    purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+	
+	if [ -f "$MATIEC" ]; then
+		rm $MATIEC
+	fi
+	;;
+
+    *)
+        echo "postrm called with unknown argument \`$1'" >&2
+        exit 1
+    ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
+
--- a/debian/rules	Tue Jan 20 15:06:13 2009 +0100
+++ b/debian/rules	Mon Mar 02 09:27:55 2009 +0100
@@ -17,42 +17,18 @@
 	CFLAGS += -O2
 endif
 
-configure: configure-stamp
-configure-stamp:
-	dh_testdir
-	# Add here commands to configure the package.
-
-	touch configure-stamp
-
-##############
-# And now the simple things for dpatch. Here we only apply/unapply the patches.
-# You can do more things with dpatch, like having patches only applied on
-# a special architecture - see the non-dh version of the sample for this!
-patch: patch-stamp
-patch-stamp:
-	dpatch apply-all
-	dpatch cat-all >patch-stamp
-	touch patch-stamp
-
-unpatch:
-	dpatch deapply-all
-	rm -rf patch-stamp debian/patched
-
 build: build-stamp
 
-build-stamp: configure-stamp patch
+build-stamp:
 	dh_testdir
-
 	# Add here commands to compile the package.
 	$(MAKE)
-	#docbook-to-man debian/matiec.sgml > matiec.1
-
 	touch $@
 
-clean: unpatch
+clean:
 	dh_testdir
 	dh_testroot
-	rm -f build-stamp configure-stamp
+	rm -f build-stamp
 
 	# Add here commands to clean up after the build process.
 	-$(MAKE) clean
@@ -66,8 +42,14 @@
 	dh_installdirs
 
 	# Add here commands to install the package into debian/matiec.
-	$(MAKE) INSTALL_PREDIR=$(CURDIR)/debian/matiec/usr INSTALL_BINDIR=/bin IECLIBDIR=/lib install	
+	#$(MAKE) INSTALL_PREDIR=$(CURDIR)/debian/matiec/usr INSTALL_BINDIR=/bin IECLIBDIR=/lib install	
 	
+	# Add here commands to install the package into debian/beremiz.
+	mkdir -p $(CURDIR)/debian/matiec/usr/share/matiec
+	
+	cp -a lib $(CURDIR)/debian/matiec/usr/share/matiec
+	cp iec2c $(CURDIR)/debian/matiec/usr/share/matiec
+		
 
 # Build architecture-independent files here.
 binary-indep: build install
@@ -105,4 +87,4 @@
 	dh_builddeb
 
 binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install configure patch unpatch
+.PHONY: build clean binary-indep binary-arch binary install