changeset 524:3c3cef8a32e6 maemo

- Make it do the postinst files etc for dropbear-server - Improve the NO_START message
author Matt Johnston <matt@ucc.asn.au>
date Tue, 18 Nov 2008 23:15:24 +0000
parents 4ff1bf0345c9
children 15b1e9adf02f
files debian/control debian/dropbear.init debian/rules
diffstat 3 files changed, 17 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/debian/control	Tue Nov 18 13:55:57 2008 +0000
+++ b/debian/control	Tue Nov 18 23:15:24 2008 +0000
@@ -25,6 +25,7 @@
 Package: dropbear-server
 Architecture: any
 Depends: ${shlibs:Depends}, dropbear-common
+Conflicts: dropbear
 Recommends: dropbear-scp
 Description: lightweight SSH2 server
  dropbear is a SSH 2 server and client designed to be small enough to
@@ -38,6 +39,7 @@
 
 Package: dropbear-client
 Architecture: any
+Conflicts: dropbear
 Depends: ${shlibs:Depends}
 Recommends: dropbear-common, dropbear-scp
 Description: lightweight SSH2 client
@@ -52,6 +54,7 @@
 
 Package: dropbear-common
 Architecture: any
+Conflicts: dropbear
 Depends: ${shlibs:Depends}
 Description: lightweight SSH2, key management utilities
  dropbear is a SSH 2 server and client designed to be small enough to
@@ -65,6 +68,7 @@
 
 Package: dropbear-scp
 Architecture: any
+Conflicts: dropbear
 Depends: ${shlibs:Depends}
 Description: lightweight SSH2 scp
  dropbear is a SSH 2 server and client designed to be small enough to
--- a/debian/dropbear.init	Tue Nov 18 13:55:57 2008 +0000
+++ b/debian/dropbear.init	Tue Nov 18 23:15:24 2008 +0000
@@ -38,7 +38,7 @@
 
 case "$1" in
   start)
-	test "$NO_START" = "0" || cancel 'NO_START is not set to zero.'
+	test "$NO_START" = "0" || cancel '/etc/default/dropbear NO_START is set, Dropbear will not run.'
 	echo -n "Starting $DESC: "
 	start-stop-daemon --start --quiet --pidfile /var/run/"$NAME".pid \
 	  --exec "$DAEMON" -- -d "$DROPBEAR_DSSKEY" -r "$DROPBEAR_RSAKEY" \
@@ -51,7 +51,7 @@
 	echo "$NAME."
 	;;
   restart|force-reload)
-	test "$NO_START" = "0" || cancel 'NO_START is not set to zero.'
+	test "$NO_START" = "0" || cancel '/etc/default/dropbear NO_START is set, Dropbear will not run.'
 	echo -n "Restarting $DESC: "
 	start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/"$NAME".pid
 	sleep 1
--- a/debian/rules	Tue Nov 18 13:55:57 2008 +0000
+++ b/debian/rules	Tue Nov 18 23:15:24 2008 +0000
@@ -88,8 +88,6 @@
 	install -d -m0755 '$(DIR)'/DEBIAN
 	test '$(CC)' != 'gcc' || \
 	  dpkg-shlibdeps '$(DIR)'/usr/sbin/*
-	dpkg-gencontrol -isp -pdropbear-server -P'$(DIR)'
-	dpkg -b '$(DIR)' ..
 
 install-client: DIR=$(shell pwd)/debian/dropbear-client
 install-client: deb-checkdir deb-checkuid config.status 
@@ -106,8 +104,6 @@
 	install -d -m0755 '$(DIR)'/DEBIAN
 	test '$(CC)' != 'gcc' || \
 	  dpkg-shlibdeps  '$(DIR)'/usr/bin/*
-	dpkg-gencontrol -isp -pdropbear-client -P'$(DIR)'
-	dpkg -b '$(DIR)' ..
 
 install-common: DIR=$(shell pwd)/debian/dropbear-common
 install-common: deb-checkdir deb-checkuid config.status 
@@ -131,8 +127,6 @@
 	install -d -m0755 '$(DIR)'/DEBIAN
 	test '$(CC)' != 'gcc' || \
 	  dpkg-shlibdeps '$(DIR)'/usr/bin/*  '$(DIR)'/usr/lib/dropbear/*
-	dpkg-gencontrol -isp -pdropbear-common -P'$(DIR)'
-	dpkg -b '$(DIR)' ..
 
 install-scp: DIR=$(shell pwd)/debian/dropbear-scp
 install-scp: deb-checkdir deb-checkuid config.status 
@@ -146,8 +140,6 @@
 	install -d -m0755 '$(DIR)'/DEBIAN
 	test '$(CC)' != 'gcc' || \
 	  dpkg-shlibdeps '$(DIR)'/usr/bin/* 
-	dpkg-gencontrol -isp -pdropbear-scp -P'$(DIR)'
-	dpkg -b '$(DIR)' ..
 
 install-multi: DIR=$(shell pwd)/debian/dropbear
 install-multi: deb-checkdir deb-checkuid config.status 
@@ -188,13 +180,21 @@
 	test '$(CC)' != 'gcc' || \
 	  dpkg-shlibdeps '$(DIR)'/usr/sbin/* '$(DIR)'/usr/bin/* \
 	    '$(DIR)'/usr/lib/dropbear/*
-	dpkg-gencontrol -isp -pdropbear -P'$(DIR)'
-	dpkg -b '$(DIR)' ..
 
 install: install-client install-server install-common install-multi install-scp
 binary-indep:
 
-binary-arch: install dropbear.deb
+binary-arch: install dropbear.deb dropbear-server.deb dropbear-common.deb dropbear-scp.deb dropbear-client.deb
+	dpkg-gencontrol -isp -pdropbear -P'$(shell pwd)/debian'/dropbear
+	dpkg-gencontrol -isp -pdropbear-server -P'$(shell pwd)/debian'/dropbear-server
+	dpkg-gencontrol -isp -pdropbear-client -P'$(shell pwd)/debian'/dropbear-client
+	dpkg-gencontrol -isp -pdropbear-common -P'$(shell pwd)/debian'/dropbear-common
+	dpkg-gencontrol -isp -pdropbear-scp -P'$(shell pwd)/debian'/dropbear-scp
+	dpkg -b '$(shell pwd)/debian'/dropbear ..
+	dpkg -b '$(shell pwd)/debian'/dropbear-server ..
+	dpkg -b '$(shell pwd)/debian'/dropbear-common ..
+	dpkg -b '$(shell pwd)/debian'/dropbear-scp ..
+	dpkg -b '$(shell pwd)/debian'/dropbear-client ..
 
 binary: binary-arch binary-indep