diff options
Diffstat (limited to 'debian')
| -rw-r--r--[-rwxr-xr-x] | debian/bitlbee-common.config (renamed from debian/config) | 0 | ||||
| -rw-r--r-- | debian/bitlbee-common.docs | 6 | ||||
| -rw-r--r-- | debian/bitlbee-common.examples | 1 | ||||
| -rw-r--r--[-rwxr-xr-x] | debian/bitlbee-common.init (renamed from debian/bitlbee.init) | 0 | ||||
| -rw-r--r--[-rwxr-xr-x] | debian/bitlbee-common.postinst (renamed from debian/postinst) | 23 | ||||
| -rw-r--r--[-rwxr-xr-x] | debian/bitlbee-common.postrm (renamed from debian/postrm) | 0 | ||||
| -rw-r--r--[-rwxr-xr-x] | debian/bitlbee-common.prerm (renamed from debian/prerm) | 6 | ||||
| -rw-r--r-- | debian/bitlbee-common.templates (renamed from debian/templates) | 0 | ||||
| -rw-r--r-- | debian/bitlbee.prerm | 5 | ||||
| -rw-r--r-- | debian/changelog | 15 | ||||
| -rw-r--r-- | debian/compat | 1 | ||||
| -rw-r--r-- | debian/conffiles | 3 | ||||
| -rw-r--r-- | debian/control | 52 | ||||
| -rw-r--r-- | debian/patches/bitlbee.conf.diff | 4 | ||||
| -rw-r--r-- | debian/po/POTFILES.in | 2 | ||||
| -rwxr-xr-x | debian/rules | 184 | 
16 files changed, 178 insertions, 124 deletions
| diff --git a/debian/config b/debian/bitlbee-common.config index 9bb78237..9bb78237 100755..100644 --- a/debian/config +++ b/debian/bitlbee-common.config diff --git a/debian/bitlbee-common.docs b/debian/bitlbee-common.docs new file mode 100644 index 00000000..72ff657c --- /dev/null +++ b/debian/bitlbee-common.docs @@ -0,0 +1,6 @@ +doc/user-guide/user-guide.txt +doc/user-guide/user-guide.html +doc/AUTHORS +doc/CREDITS +doc/FAQ +doc/README diff --git a/debian/bitlbee-common.examples b/debian/bitlbee-common.examples new file mode 100644 index 00000000..81562b9e --- /dev/null +++ b/debian/bitlbee-common.examples @@ -0,0 +1 @@ +utils/* diff --git a/debian/bitlbee.init b/debian/bitlbee-common.init index be1dcd66..be1dcd66 100755..100644 --- a/debian/bitlbee.init +++ b/debian/bitlbee-common.init diff --git a/debian/postinst b/debian/bitlbee-common.postinst index db541f6c..c965e09c 100755..100644 --- a/debian/postinst +++ b/debian/bitlbee-common.postinst @@ -63,11 +63,20 @@ if [ -e /usr/share/bitlbee/help.upgrading ]; then  	fi  fi -if [ -n "$2" -a "$BITLBEE_UPGRADE_DONT_RESTART" != "1" ]; then -	if which invoke-rc.d >/dev/null 2>&1; then -		invoke-rc.d bitlbee restart +# The official way to check if we're upgrading is to check if $2 is +# non-empty. However, previous versions of BitlBee didn't have a +# bitlbee-common package so in that case the var will also be empty. +# Instead, check if the port is in use (if netstat is available). This +# works since the debconf code will pick a free port on new installs. +if [ "$BITLBEE_UPGRADE_DONT_RESTART" != "1" ]; then +	unset IS_UPGRADE +	if type netstat > /dev/null 2> /dev/null; then +		netstat -an | grep -q :$PORT\\b.*LISTEN && IS_UPGRADE=1  	else -		/etc/init.d/bitlbee restart +		[ -n "$2" ] && IS_UPGRADE=1 +	fi +	if [ -n "$IS_UPGRADE" ]; then +		invoke-rc.d bitlbee restart  	fi  fi @@ -94,9 +103,5 @@ else  fi  if [ -z "$2" ]; then -	if which invoke-rc.d >/dev/null 2>&1; then -		invoke-rc.d bitlbee start -	else -		/etc/init.d/bitlbee start -	fi +	invoke-rc.d bitlbee start  fi diff --git a/debian/postrm b/debian/bitlbee-common.postrm index 5c3b4b2e..5c3b4b2e 100755..100644 --- a/debian/postrm +++ b/debian/bitlbee-common.postrm diff --git a/debian/prerm b/debian/bitlbee-common.prerm index 687c2cc1..50a49bee 100755..100644 --- a/debian/prerm +++ b/debian/bitlbee-common.prerm @@ -9,9 +9,5 @@ if [ "$1" = "upgrade" ]; then  		mv /usr/share/bitlbee/help.txt /usr/share/bitlbee/help.upgrading  	fi  else -	if which invoke-rc.d >/dev/null 2>&1; then -		invoke-rc.d bitlbee stop || exit 0 -	else -		/etc/init.d/bitlbee stop || exit 0 -	fi +	invoke-rc.d bitlbee stop || exit 0  fi diff --git a/debian/templates b/debian/bitlbee-common.templates index 0cd04426..0cd04426 100644 --- a/debian/templates +++ b/debian/bitlbee-common.templates diff --git a/debian/bitlbee.prerm b/debian/bitlbee.prerm new file mode 100644 index 00000000..c61db24b --- /dev/null +++ b/debian/bitlbee.prerm @@ -0,0 +1,5 @@ +#!/bin/sh -e + +if [ "$1" != "upgrade" ]; then +	invoke-rc.d bitlbee stop || exit 0 +fi diff --git a/debian/changelog b/debian/changelog index ca592229..8e3cabcb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,18 @@ +bitlbee (1.3-0) unstable; urgency=low + +  * Setting some bogus version number, fix that later. +  * Now using debhelper to improve maintainability. +  * Added a bitlbee-libpurple package, and split off docs and stuff into +    bitlbee-common. + + -- Wilmer van der Gaast <wilmer@gaast.net>  Wed, 18 Aug 2010 00:53:11 +0100 + +bitlbee (1.2.8-1) unstable; urgency=low + +  * New upstream version. + + -- Wilmer van der Gaast <wilmer@gaast.net>  Sat, 10 Jul 2010 13:54:55 +0100 +  bitlbee (1.2.7-1) unstable; urgency=high    * New upstream version. diff --git a/debian/compat b/debian/compat new file mode 100644 index 00000000..1e8b3149 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +6 diff --git a/debian/conffiles b/debian/conffiles deleted file mode 100644 index dcb4078e..00000000 --- a/debian/conffiles +++ /dev/null @@ -1,3 +0,0 @@ -/etc/bitlbee/motd.txt -/etc/bitlbee/bitlbee.conf -/etc/init.d/bitlbee diff --git a/debian/control b/debian/control index 25a90506..56859a58 100644 --- a/debian/control +++ b/debian/control @@ -3,26 +3,58 @@ Section: net  Priority: optional  Maintainer: Wilmer van der Gaast <wilmer@gaast.net>  Uploaders: Jelmer Vernooij <jelmer@samba.org> -Standards-Version: 3.8.0 -Build-Depends: libglib2.0-dev (>= 2.4), libevent-dev, libgnutls-dev | libnss-dev (>= 1.6), debconf-2.0, po-debconf +Standards-Version: 3.8.4 +Build-Depends: libglib2.0-dev (>= 2.4), libevent-dev, libgnutls-dev | libnss-dev (>= 1.6), po-debconf, libpurple-dev, debhelper (>= 6)  Homepage: http://www.bitlbee.org/  Vcs-Bzr: http://code.bitlbee.org/bitlbee/  DM-Upload-Allowed: yes  Package: bitlbee  Architecture: any -Depends: ${shlibs:Depends}, adduser, net-tools, ${debconf-depends}, debianutils (>= 1.16) -Description: An IRC to other chat networks gateway +Depends: ${shlibs:Depends}, adduser, debianutils (>= 1.16), bitlbee-common (= ${bee:Version}) +Conflicts: bitlbee-libpurple +Replaces: bitlbee-libpurple +Description: An IRC to other chat networks gateway (default version)   This program can be used as an IRC server which forwards everything you - say to people on other chat networks: Jabber, ICQ, AIM, MSN, Yahoo! and - Twitter. + say to people on other chat networks: Jabber (which includes Google Talk + and Facebook Chat), ICQ, AIM, MSN, Yahoo! and Twitter/Identica/Status.net. + +Package: bitlbee-libpurple +Architecture: any +Depends: ${shlibs:Depends}, adduser, debianutils (>= 1.16), bitlbee-common (= ${bee:Version}) +Conflicts: bitlbee +Replaces: bitlbee +Description: An IRC to other chat networks gateway (using libpurple) + This program can be used as an IRC server which forwards everything you + say to people on other chat networks: Jabber (which includes Google Talk + and Facebook Chat), ICQ, AIM, MSN, Yahoo! and Twitter/Identica/Status.net. + . + This package contains a version of BitlBee that uses the libpurple instant + messaging library instead of built-in code, which adds support for more IM + protocols (all protocols supported by Pidgin/Finch) and features (like file + transfers), at the price of being less lightweight. + . + This variant may not be very suitable for BitlBee instances used by many + (tens or hundreds) of clients. + +Package: bitlbee-common +Architecture: all +Depends: ${misc:Depends}, net-tools +Replaces: bitlbee +Description: An IRC to other chat networks gateway (common files/docs) + This program can be used as an IRC server which forwards everything you + say to people on other chat networks: Jabber (which includes Google Talk + and Facebook Chat), ICQ, AIM, MSN, Yahoo! and Twitter/Identica/Status.net. + . + This package contains common files (mostly documentation) for bitlbee and + bitlbee-libpurple.  Package: bitlbee-dev  Architecture: all -Depends: bitlbee (>= ${source:Version}), bitlbee (<< ${source:Version}.1~) -Description: An IRC to other chat networks gateway +Depends: ${misc:Depends}, bitlbee (>= ${bee:Version}), bitlbee (<< ${bee:Version}.1~) +Description: An IRC to other chat networks gateway (dev files)   This program can be used as an IRC server which forwards everything you - say to people on other chat networks: Jabber, ICQ, AIM, MSN, Yahoo! and - Twitter. + say to people on other chat networks: Jabber (which includes Google Talk + and Facebook Chat), ICQ, AIM, MSN, Yahoo! and Twitter/Identica/Status.net.   .   This package holds development stuff for compiling plug-ins. diff --git a/debian/patches/bitlbee.conf.diff b/debian/patches/bitlbee.conf.diff index c98fa546..339ccd4a 100644 --- a/debian/patches/bitlbee.conf.diff +++ b/debian/patches/bitlbee.conf.diff @@ -1,5 +1,5 @@ ---- debian/bitlbee/etc/bitlbee/bitlbee.conf	2009-06-01 00:20:24.000000000 +0100 -+++ debian/bitlbee/etc/bitlbee/bitlbee.conf	2009-06-07 21:16:19.000000000 +0100 +--- bitlbee.conf	2009-06-01 00:20:24.000000000 +0100 ++++ bitlbee.conf	2009-06-07 21:16:19.000000000 +0100  @@ -23,13 +23,18 @@   ## If BitlBee is started by root as a daemon, it can drop root privileges,   ## and change to the specified user. diff --git a/debian/po/POTFILES.in b/debian/po/POTFILES.in index cef83a34..8d2b570f 100644 --- a/debian/po/POTFILES.in +++ b/debian/po/POTFILES.in @@ -1 +1 @@ -[type: gettext/rfc822deb] templates +[type: gettext/rfc822deb] bitlbee-common.templates diff --git a/debian/rules b/debian/rules index ae6463fc..c5397085 100755 --- a/debian/rules +++ b/debian/rules @@ -1,113 +1,109 @@  #!/usr/bin/make -f - +# +# Finally switching to debhelper. +# +# Not using debhelper was an exercise suggested to me by my AM (Gergely +# Nagy). It was educating at the time but I finally decided that the +# exercise is over now. +# + +# Include the bitlbee-libpurple variant by default +BITLBEE_LIBPURPLE ?= 1 +BITLBEE_CONFIGURE_FLAGS ?=  DEBUG ?= 0 -ifdef BITLBEE_VERSION -BITLBEE_FORCE_VERSION=1 -else +ifndef BITLBEE_VERSION  # Want to use the full package version number instead of just the release. -BITLBEE_VERSION ?= "$(shell dpkg-parsechangelog | grep ^Version: | awk '{print $$2}')" -export BITLBEE_VERSION +BITLBEE_CONFIGURE_VERSION ?= BITLBEE_VERSION=\"$(shell dpkg-parsechangelog | grep ^Version: | awk '{print $$2}')\"  endif -build-arch: build-arch-stamp -build-arch-stamp: -	[ -d debian ] -	./configure --debug=$(DEBUG) --prefix=/usr --etcdir=/etc/bitlbee --events=libevent -	$(MAKE) -#	$(MAKE) -C doc/ all -	touch build-arch-stamp +ifneq ($(BITLBEE_LIBPURPLE),1) +DH_OPTIONS += -Nbitlbee-libpurple +endif -clean: -	[ "`whoami`" = "root" -a -d debian ] -	rm -rf build-arch-stamp debian/bitlbee debian/*.substvars debian/files debian/bitlbee-dev -	$(MAKE) distclean -#	-$(MAKE) -C doc/ clean -				 - -install-arch: build-arch -	[ "`whoami`" = "root" -a -d debian ] -	mkdir -p debian/bitlbee/DEBIAN/ -	$(MAKE) install install-etc DESTDIR=`pwd`/debian/bitlbee - -	mkdir -p debian/bitlbee/usr/share/doc/bitlbee/ -	cp doc/user-guide/user-guide.txt debian/bitlbee/usr/share/doc/bitlbee/ -	cp doc/user-guide/user-guide.html debian/bitlbee/usr/share/doc/bitlbee/ - -install-indep: install-arch -	[ "`whoami`" = "root" -a -d debian ] -	mkdir -p debian/bitlbee-dev/DEBIAN/ -	$(MAKE) install-dev DESTDIR=`pwd`/debian/bitlbee-dev - -	mkdir -p debian/bitlbee-dev/usr/share/doc/bitlbee-dev/ - -binary-arch: build-arch install-arch -	[ "`whoami`" = "root" -a -d debian ] - -	chmod 755 debian/post* debian/pre* debian/config debian/bitlbee.init - -	mkdir -p debian/bitlbee/usr/share/doc/bitlbee/examples/ debian/bitlbee/etc/init.d/ -	-cp doc/RELEASE-SPEECH* debian/bitlbee/usr/share/doc/bitlbee/ && gzip -9 debian/bitlbee/usr/share/doc/bitlbee/RELEASE-SPEECH* -	cp doc/CREDITS doc/AUTHORS doc/README doc/FAQ debian/README.Debian debian/bitlbee/usr/share/doc/bitlbee/ -	cp debian/changelog debian/bitlbee/usr/share/doc/bitlbee/changelog.Debian -	cp debian/copyright debian/bitlbee/usr/share/doc/bitlbee/copyright -	cp doc/CHANGES debian/bitlbee/usr/share/doc/bitlbee/changelog -	cp utils/* debian/bitlbee/usr/share/doc/bitlbee/examples/ -	cp debian/bitlbee.init debian/bitlbee/etc/init.d/bitlbee -	patch -p0 < debian/patches/bitlbee.conf.diff -	cd debian/bitlbee/usr/share/; \ -		gzip -9 doc/bitlbee/changelog.Debian doc/bitlbee/changelog doc/bitlbee/user-guide.txt \ -		        doc/bitlbee/examples/* man/man8/bitlbee.8 man/man5/bitlbee.conf.5 -	 -	chown -R root:root debian/bitlbee/ -	find debian/bitlbee/usr/share/ -type d -exec chmod 755 {} \; -	find debian/bitlbee/usr/share/ -type f -exec chmod 644 {} \; -	 -	cp debian/prerm debian/bitlbee/DEBIAN/ -	cp debian/postinst debian/bitlbee/DEBIAN/ -	cp debian/postrm debian/bitlbee/DEBIAN/ -	cp debian/config debian/bitlbee/DEBIAN/ - -	po2debconf debian/templates > debian/bitlbee/DEBIAN/templates -	cp debian/conffiles debian/bitlbee/DEBIAN/ -	 -	if [ "$(DEBUG)" = "0" ]; then strip -R .comment -R .note debian/bitlbee/usr/sbin/bitlbee; fi - -	cd debian/bitlbee; \ -		find usr -type f -exec md5sum {} \; > DEBIAN/md5sums -	dpkg-shlibdeps -Tdebian/bitlbee.substvars -dDepends debian/bitlbee/usr/sbin/bitlbee -ifdef BITLBEE_FORCE_VERSION -	dpkg-gencontrol -ldebian/changelog -isp -pbitlbee -Tdebian/bitlbee.substvars -Pdebian/bitlbee -v1:$(BITLBEE_VERSION)-0 -V'debconf-depends=debconf (>= 1.2.0) | debconf-2.0' -else -	dpkg-gencontrol -ldebian/changelog -isp -pbitlbee -Tdebian/bitlbee.substvars -Pdebian/bitlbee -V'debconf-depends=debconf (>= 1.2.0) | debconf-2.0' +build: build-stamp +build-stamp: +	dh_testdir + +	mkdir -p debian/build-native +	ROOT=$$PWD; cd debian/build-native; $(BITLBEE_CONFIGURE_VERSION) $$ROOT/configure --debug=$(DEBUG) --prefix=/usr --etcdir=/etc/bitlbee --events=libevent $(BITLBEE_CONFIGURE_FLAGS) +	$(MAKE) -C debian/build-native + +ifeq ($(BITLBEE_LIBPURPLE),1) +	mkdir -p debian/build-libpurple +	ROOT=$$PWD; cd debian/build-libpurple; $(BITLBEE_CONFIGURE_VERSION) $$ROOT/configure --debug=$(DEBUG) --prefix=/usr --etcdir=/etc/bitlbee --purple=1 $(BITLBEE_CONFIGURE_FLAGS) +	$(MAKE) -C debian/build-libpurple  endif -	dpkg --build debian/bitlbee .. +	$(MAKE) -C doc -binary-indep: install-indep -	[ "`whoami`" = "root" -a -d debian ] +	touch build-stamp -	chown -R root.root debian/bitlbee-dev/ -	find debian/bitlbee-dev/usr/share/ -type d -exec chmod 755 {} \; -	find debian/bitlbee-dev/usr/share/ -type f -exec chmod 644 {} \; +clean: +	dh_testdir +	dh_testroot +	rm -f build-stamp + +	rm -rf build-arch-stamp debian/build-* debian/bitlbee-libpurple.prerm +	$(MAKE) distclean + +	dh_clean -	cp debian/changelog debian/bitlbee-dev/usr/share/doc/bitlbee-dev/changelog.Debian -	gzip -9 debian/bitlbee-dev/usr/share/doc/bitlbee-dev/changelog.Debian -	cp debian/copyright debian/bitlbee-dev/usr/share/doc/bitlbee-dev/copyright +install: build +	dh_testdir +	dh_testroot +	dh_clean -k +	dh_installdirs -	cd debian/bitlbee-dev; \ -		find usr -type f -exec md5sum {} \; > DEBIAN/md5sums +	$(MAKE) -C debian/build-native install DESTDIR=`pwd`/debian/bitlbee +	$(MAKE) -C debian/build-native install-etc DESTDIR=`pwd`/debian/bitlbee-common +	$(MAKE) -C debian/build-native install-dev DESTDIR=`pwd`/debian/bitlbee-dev +	patch debian/bitlbee-common/etc/bitlbee/bitlbee.conf debian/patches/bitlbee.conf.diff -ifdef BITLBEE_FORCE_VERSION -	dpkg-gencontrol -ldebian/changelog -isp -pbitlbee-dev -Pdebian/bitlbee-dev -v1:$(BITLBEE_VERSION)-0 +ifeq ($(BITLBEE_LIBPURPLE),1) +	$(MAKE) -C debian/build-libpurple install DESTDIR=`pwd`/debian/bitlbee-libpurple +	ln -sf debian/bitlbee.prerm debian/bitlbee-libpurple.prerm +endif + +	mkdir -p debian/bitlbee-common/usr +	mv debian/bitlbee/usr/share debian/bitlbee-common/usr +	rm -rf debian/bitlbee-libpurple/usr/share + +binary-common: +	dh_testdir +	dh_testroot + +	dh_installchangelogs doc/CHANGES +	dh_installexamples +	dh_installdocs #--link-doc=bitlbee-common +	# TODO: Restore --link-doc up here and remove the hack below once +	# Hardy and Lenny are deprecated. +	for p in bitlbee bitlbee-libpurple bitlbee-dev; do rm -r debian/$$p/usr/share/doc/$$p && ln -s bitlbee-common debian/$$p/usr/share/doc/$$p; done +	dh_installdebconf +	dh_installinit --init-script=bitlbee +	dh_installman +	dh_strip +	dh_link +	dh_compress +	dh_fixperms +	dh_installdeb +	dh_shlibdeps +ifdef BITLBEE_VERSION +	dh_gencontrol -- -v1:$(BITLBEE_VERSION)-0  -Vbee:Version=1:$(BITLBEE_VERSION)-0  else -	dpkg-gencontrol -ldebian/changelog -isp -pbitlbee-dev -Pdebian/bitlbee-dev +	dh_gencontrol -- -Vbee:Version=$(shell dpkg-parsechangelog | grep ^Version: | awk '{print $$2}' | sed -e 's/+b[0-9]\+$$//')  endif +	dh_md5sums +	dh_builddeb + +binary-indep: build install +	DH_OPTIONS=-i $(MAKE) -f debian/rules binary-common -	dpkg --build debian/bitlbee-dev .. +binary-arch: build install +	DH_OPTIONS=-a $(MAKE) -f debian/rules binary-common -binary: binary-arch binary-indep -build: build-arch -install: install-arch install-indep +binary-%: build install +	DH_OPTIONS=-p$* $(MAKE) -f debian/rules binary-common -.PHONY: build-arch build clean binary-arch binary install-arch install binary-indep install-indep +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary-common binary install | 
