[pve-devel] [PATCH libqb 1/2] update to 1.0.3-1

Fabian Grünbichler f.gruenbichler at proxmox.com
Wed Nov 7 14:26:38 CET 2018


and adapt build Makefile for a straightforward backport from Debian
Buster.

Signed-off-by: Fabian Grünbichler <f.gruenbichler at proxmox.com>
---
 patches/0002-adapt-changelog.patch      | 23 +++++++++++
 Makefile                                | 54 ++++++++++++++++---------
 patches/0001-drop-DH-compat-to-10.patch | 31 ++++++++++++++
 patches/series                          |  2 +
 4 files changed, 92 insertions(+), 18 deletions(-)
 create mode 100644 patches/0002-adapt-changelog.patch
 create mode 100644 patches/0001-drop-DH-compat-to-10.patch
 create mode 100644 patches/series

diff --git a/patches/0002-adapt-changelog.patch b/patches/0002-adapt-changelog.patch
new file mode 100644
index 0000000..028065e
--- /dev/null
+++ b/patches/0002-adapt-changelog.patch
@@ -0,0 +1,23 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler at proxmox.com>
+Date: Wed, 7 Nov 2018 12:23:19 +0100
+Subject: [PATCH] adapt changelog
+
+---
+ debian/changelog | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/debian/changelog b/debian/changelog
+index 9923813..f62608e 100644
+--- a/debian/changelog
++++ b/debian/changelog
+@@ -1,3 +1,9 @@
++libqb (1.0.3-1~bpo9) unstable; urgency=medium
++
++  * backport from Debian Buster for PVE 5.x
++
++ -- Proxmox Support Team <support at proxmox.com>  Wed, 7 Nov 2018 12:23:07 +0100
++
+ libqb (1.0.3-1) unstable; urgency=medium
+ 
+   [ Christoph Berg ]
diff --git a/Makefile b/Makefile
index ccec439..66b4098 100644
--- a/Makefile
+++ b/Makefile
@@ -1,32 +1,50 @@
 RELEASE=5.0
 
-QBVERSION=1.0.1
-QBRELEASE=2
-QBDIR=libqb-${QBVERSION}
-QBSRC=libqb-${QBVERSION}.orig.tar.gz
+VERSION=1.0.3
+DEBRELEASE=1
+PVERELEASE=1~bpo9
+
+BUILDDIR=libqb-${VERSION}
+SRCARCHIVE=libqb_${VERSION}.orig.tar.xz
+DEBARCHIVE=libqb_${VERSION}-${DEBRELEASE}.debian.tar.xz
 
 ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
 
-DEBS=									\
-	libqb0_${QBVERSION}-${QBRELEASE}_${ARCH}.deb			\
-	libqb0-dbg_${QBVERSION}-${QBRELEASE}_${ARCH}.deb		\
-	libqb-dev_${QBVERSION}-${QBRELEASE}_${ARCH}.deb
+MAIN_DEB=libqb0_${VERSION}-${PVERELEASE}_${ARCH}.deb
+OTHER_DEBS=								\
+	libqb-doc_${VERSION}-${PVERELEASE}_all.deb			\
+	libqb0-dbgsym_${VERSION}-${PVERELEASE}_${ARCH}.deb		\
+	libqb-dev_${VERSION}-${PVERELEASE}_${ARCH}.deb			\
+	libqb-dev-dbgsym_${VERSION}-${PVERELEASE}_${ARCH}.deb		\
+
+DEBS=${MAIN_DEB} ${OTHER_DEBS}
+DSC=libqb-${VERSION}-${PVERELEASE}.dsc
 
 all: ${DEBS}
 	echo ${DEBS}
 
-${DEBS}: ${QBSRC}
-	rm -rf ${QBDIR}
-	tar xf ${QBSRC} 
-	cp -a debian ${QBDIR}/debian
-	cd ${QBDIR}; dpkg-buildpackage -b -us -uc
+${BUILDDIR}: upstream/${SRCARCHIVE} upstream/${DEBARCHIVE} patches/*
+	rm -rf ${BUILDDIR}
+	ln -sf upstream/${SRCARCHIVE} ${SRCARCHIVE}
+	tar -xf upstream/${SRCARCHIVE}
+	tar -C ${BUILDDIR} -xf upstream/${DEBARCHIVE}
+	cd ${BUILDDIR}; ln -s ../patches patches
+	cd ${BUILDDIR}; quilt push -a
+	cd ${BUILDDIR}; rm -rf .pc ./patches
+
+deb: ${DEBS}
+${OTHER_DEBS}: ${MAIN_DEB}
+${MAIN_DEB}: ${BUILDDIR}
+	cd ${BUILDDIR}; dpkg-buildpackage -b -us -uc
 
+dsc: ${DSC}
+${DSC}: ${BUILDDIR}
+	cd ${BUILDDIR}; dpkg-buildpackage -S -us -uc -d -nc
 
 download:
-	rm -rf libqb-${QBVERSION} libqb-${QBVERSION}.orig.tar.gz
-	git clone git://github.com/ClusterLabs/libqb.git libqb-${QBVERSION}
-	cd libqb-${QBVERSION}; git checkout v${QBVERSION}
-	tar czf libqb-${QBVERSION}.orig.tar.gz libqb-${QBVERSION}/
+	rm -rf upstream/${SRCARCHIVE} upstream/${DEBARCHIVE} ${BUILDDIR}
+	cd upstream; dget https://deb.debian.org/debian/pool/main/libq/libqb/libqb_${VERSION}-${DEBRELEASE}.dsc
+	cd upstream; rm -rf *.asc *.dsc ${BUILDDIR}
 
 .PHONY: upload
 upload: ${DEBS}
@@ -34,7 +52,7 @@ upload: ${DEBS}
 
 .PHONY: clean
 clean:
-	rm -rf *~ debian/*~ *_${ARCH}.deb *.changes *.dsc ${QBDIR} libqb_${QBVERSION}.orig.tar.gz
+	rm -rf *~ debian/*~ *_${ARCH}.deb *.changes *.dsc ${BUILDDIR} *.orig.tar.xz *.debian.tar.xz *.buildinfo
 
 .PHONY: dinstall
 dinstall: ${DEBS}
diff --git a/patches/0001-drop-DH-compat-to-10.patch b/patches/0001-drop-DH-compat-to-10.patch
new file mode 100644
index 0000000..88d3bb4
--- /dev/null
+++ b/patches/0001-drop-DH-compat-to-10.patch
@@ -0,0 +1,31 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler at proxmox.com>
+Date: Wed, 7 Nov 2018 12:22:39 +0100
+Subject: [PATCH] drop DH compat to 10
+
+for easier backporting
+---
+ debian/compat  | 2 +-
+ debian/control | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/debian/compat b/debian/compat
+index b4de394..f599e28 100644
+--- a/debian/compat
++++ b/debian/compat
+@@ -1 +1 @@
+-11
++10
+diff --git a/debian/control b/debian/control
+index 50c1826..06566f0 100644
+--- a/debian/control
++++ b/debian/control
+@@ -6,7 +6,7 @@ Uploaders:
+            Adrian Vondendriesch <adrian.vondendriesch at credativ.de>
+ Build-Depends:
+                check,
+-               debhelper (>= 11~),
++               debhelper (>= 10~),
+                doxygen,
+                libglib2.0-dev,
+                pkg-config
diff --git a/patches/series b/patches/series
new file mode 100644
index 0000000..bf526c4
--- /dev/null
+++ b/patches/series
@@ -0,0 +1,2 @@
+0001-drop-DH-compat-to-10.patch
+0002-adapt-changelog.patch
-- 
2.19.1





More information about the pve-devel mailing list