Package: unhide
Version: 20071102-1.1
Severity: wishlist
Tags: patch

Hi,

I did some changes:
- Make the binaries static linked. So the package is independent of the
  glibc and can be used as (more or less) trusted binary. Also you can
  put the binaries on a cd.
- Add the old unhide for 2.4 kernels and add a alternative (see the
  patch)

-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (800, 'stable'), (700, 'testing'), (600, 'unstable'), (500, 
'oldstable'), (60, 'experimental')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/dash
Kernel: Linux 2.4.35.3
Locale: LANG=de_DE, LC_CTYPE=de_DE (charmap=ISO-8859-1) (ignored: LC_ALL set to 
de_DE)

-- no debconf information

-- 
Klaus Ethgen                            http://www.ethgen.de/
pub  2048R/D1A4EDE5 2000-02-26 Klaus Ethgen <[EMAIL PROTECTED]>
Fingerprint: D7 67 71 C4 99 A6 D4 FE  EA 40 30 57 3C 88 26 2B
diff -u unhide-20071102/debian/rules unhide-20071102/debian/rules
--- unhide-20071102/debian/rules
+++ unhide-20071102/debian/rules
@@ -19,11 +19,12 @@
 
 build: build-stamp
 
-build-stamp: configure-stamp 
+build-stamp: configure-stamp
 	dh_testdir
 
-	gcc $(CURDIR)/unhide-linux26.c -o $(CURDIR)/unhide
-	gcc $(CURDIR)/unhide-tcp.c -o $(CURDIR)/unhide-tcp
+	gcc --static $(CURDIR)/unhide.c -o $(CURDIR)/unhide-linux24
+	gcc --static $(CURDIR)/unhide-linux26.c -o $(CURDIR)/unhide-linux26
+	gcc --static $(CURDIR)/unhide-tcp.c -o $(CURDIR)/unhide-tcp
 	#docbook-to-man debian/unhide.sgml > unhide.1
 
 	touch $@
@@ -33,17 +34,17 @@
 	dh_testroot
 	rm -f build-stamp configure-stamp
 
-	rm -f $(CURDIR)/unhide $(CURDIR)/unhide-tcp
+	rm -f $(CURDIR)/unhide-linux24 $(CURDIR)/unhide-linux26 $(CURDIR)/unhide-tcp
 
-	dh_clean 
+	dh_clean
 
 install: build
 	dh_testdir
 	dh_testroot
-	dh_clean -k 
+	dh_clean -k
 	dh_installdirs
 
-	cp $(CURDIR)/unhide $(CURDIR)/unhide-tcp $(CURDIR)/debian/unhide/usr/sbin
+	cp $(CURDIR)/unhide-linux24 $(CURDIR)/unhide-linux26 $(CURDIR)/unhide-tcp $(CURDIR)/debian/unhide/usr/sbin
 
 
 # Build architecture-independent files here.
@@ -54,7 +55,7 @@
 binary-arch: build install
 	dh_testdir
 	dh_testroot
-	dh_installchangelogs 
+	dh_installchangelogs
 	dh_installdocs
 	dh_installman debian/unhide.8 debian/unhide-tcp.8
 	dh_link
diff -u unhide-20071102/debian/changelog unhide-20071102/debian/changelog
--- unhide-20071102/debian/changelog
+++ unhide-20071102/debian/changelog
@@ -1,3 +1,11 @@
+unhide (20071102-1.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Making binary static linked.
+  * Adding version for kernel 2.4 with automatic select.
+
+ -- Klaus Ethgen <[EMAIL PROTECTED]>  Fri, 04 Jan 2008 11:46:56 +0100
+
 unhide (20071102-1) unstable; urgency=low
 
   * Initial release (Closes: #451206)
only in patch2:
unchanged:
--- unhide-20071102.orig/debian/prerm
+++ unhide-20071102/debian/prerm
@@ -0,0 +1,42 @@
+#!/bin/sh
+# prerm script for unhide
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+#        * <prerm> `remove'
+#        * <old-prerm> `upgrade' <new-version>
+#        * <new-prerm> `failed-upgrade' <old-version>
+#        * <conflictor's-prerm> `remove' `in-favour' <package> <new-version>
+#        * <deconfigured's-prerm> `deconfigure' `in-favour'
+#          <package-being-installed> <version> `removing'
+#          <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+    upgrade|failed-upgrade)
+    ;;
+
+    remove|deconfigure)
+      update-alternatives --quiet --remove unhide /usr/sbin/unhide-linux24
+      update-alternatives --quiet --remove unhide /usr/sbin/unhide-linux26
+    ;;
+
+    *)
+        echo "prerm 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
+
+
only in patch2:
unchanged:
--- unhide-20071102.orig/debian/postinst
+++ unhide-20071102/debian/postinst
@@ -0,0 +1,51 @@
+#!/bin/sh
+# postinst script for unhide
+#
+# 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|abort-remove|abort-deconfigure)
+      kernelver1=`uname -r | cut -d. -f1`
+      kernelver2=`uname -r | cut -d. -f2`
+      update-alternatives --quiet --install /usr/sbin/unhide unhide /usr/sbin/unhide-linux24 10
+      update-alternatives --quiet --install /usr/sbin/unhide unhide /usr/sbin/unhide-linux26 20
+      if [ $kernelver1 -lt 2 -o $kernelver1 -eq 2 -a $kernelver2 -lt 6 ]
+      then
+	 update-alternatives --quiet --set unhide /usr/sbin/unhide-linux24
+      else
+	 update-alternatives --quiet --set unhide /usr/sbin/unhide-linux26
+      fi
+    ;;
+
+    abort-upgrade)
+    ;;
+
+    *)
+        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
+
+

Attachment: signature.asc
Description: Digital signature

Reply via email to