diff -Nru unworkable-0.53/debian/changelog unworkable-0.53/debian/changelog --- unworkable-0.53/debian/changelog 2012-04-30 13:22:55.000000000 +0000 +++ unworkable-0.53/debian/changelog 2012-05-29 21:04:11.000000000 +0000 @@ -1,3 +1,10 @@ +unworkable (0.53-3) unstable; urgency=low + + * Switch to libbsd, patch by Guillem Jover (Closes: #675077) + * Enable hardening + + -- Michael Stapelberg Tue, 29 May 2012 22:53:34 +0200 + unworkable (0.53-2) unstable; urgency=low * Update Homepage address (Closes: #670723) diff -Nru unworkable-0.53/debian/control unworkable-0.53/debian/control --- unworkable-0.53/debian/control 2012-04-30 13:17:41.000000000 +0000 +++ unworkable-0.53/debian/control 2012-05-29 21:03:37.000000000 +0000 @@ -2,7 +2,8 @@ Section: net Priority: optional Maintainer: Michael Stapelberg -Build-Depends: debhelper (>= 5), libevent-dev, libssl-dev, bison +Build-Depends: debhelper (>= 5), libbsd-dev, libevent-dev, libssl-dev, bison, + pkg-config, dpkg-dev (>= 1.16.1~) Standards-Version: 3.9.3.1 Homepage: http://code.google.com/p/unworkable/ diff -Nru unworkable-0.53/debian/patches/libbsd.patch unworkable-0.53/debian/patches/libbsd.patch --- unworkable-0.53/debian/patches/libbsd.patch 1970-01-01 00:00:00.000000000 +0000 +++ unworkable-0.53/debian/patches/libbsd.patch 2012-05-29 20:56:15.000000000 +0000 @@ -0,0 +1,26 @@ +Description: Use libbsd instead of shipped openbsd-compat + This deduplicates code we already have in libbsdat build- and run-time. +Author: Guillem Jover +Bug-Debian: http://bugs.debian.org/675077 +Forwarded: no +Last-Update: 2012-05-29 +Reviewed-By: Michael Stapelberg + +--- unworkable-0.53.orig/GNUmakefile ++++ unworkable-0.53/GNUmakefile +@@ -29,13 +29,9 @@ SRCS=announce.c bencode.c buf.c ctl_serv + LIBS=-levent -lcrypto -lpthread + UNAME=$(shell uname) + ifneq (, $(filter Linux GNU GNU/%, $(UNAME))) +-SRCS+=openbsd-compat/strlcpy.c +-SRCS+=openbsd-compat/strlcat.c + SRCS+=openbsd-compat/sha1.c +-SRCS+=openbsd-compat/strtonum.c +-CFLAGS+=-DNO_STRLCPY +-CFLAGS+=-DNO_STRLCAT +-CFLAGS+=-DNO_STRTONUM ++LIBS+=$(shell pkg-config --libs libbsd-overlay) ++CFLAGS+=$(shell pkg-config --cflags libbsd-overlay) + else + ifeq ($(UNAME),sunos) + SRCS+=openbsd-compat/err.c diff -Nru unworkable-0.53/debian/patches/series unworkable-0.53/debian/patches/series --- unworkable-0.53/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 +++ unworkable-0.53/debian/patches/series 2012-05-29 20:54:15.000000000 +0000 @@ -0,0 +1 @@ +libbsd.patch diff -Nru unworkable-0.53/debian/rules unworkable-0.53/debian/rules --- unworkable-0.53/debian/rules 2012-04-30 13:23:18.000000000 +0000 +++ unworkable-0.53/debian/rules 2012-05-29 21:02:31.000000000 +0000 @@ -9,6 +9,9 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +DPKG_EXPORT_BUILDFLAGS = 1 +include /usr/share/dpkg/buildflags.mk + config.status: configure dh_testdir touch $@