On Sat, 2014-03-22 at 13:50 +0530, Ritesh Raj Sarraf wrote:
> Please consider integrating it as it would save a lot of resources
> both,
> for our users/developers, and our infrastructure.
> 
> Appended below is the log after applying this patch, and debdelta
> into
> action (ofcourse one is expected to install debdelta and its
> dependencies in the chroot first)


Hello Mattia,

Based on our conversation on IRC, please consider the attached patch.



Here's the result.

rrs@learner:/var/tmp/Debian-Build/Result$ sudo pbuilder --update --
debdelta
I: Current time: Sat Oct  3 18:17:41 IST 2015
I: pbuilder-time-stamp: 1443876461
I: Building the build Environment
I: extracting base tarball [/var/cache/pbuilder/sid-amd64-base.tgz]
I: copying local configuration
I: mounting /proc filesystem
I: mounting /run/shm filesystem
I: mounting /dev/pts filesystem
I: Mounting /var/cache/apt/archives/
I: policy-rc.d already exists
I: Refreshing the base.tgz 
I: upgrading packages
Hit http://ftp.debian.org sid InRelease
Get:1 http://ftp.debian.org sid/main amd64 Packages/DiffIndex [4540 B]
Get:2 http://ftp.debian.org sid/contrib amd64 Packages/DiffIndex [919
B]
Get:3 http://ftp.debian.org sid/non-free amd64 Packages/DiffIndex [1057
B]
Get:4 http://ftp.debian.org sid/contrib Translation-en/DiffIndex [367
B]
Get:5 http://ftp.debian.org sid/main Translation-en/DiffIndex [4401 B]
Get:6 http://ftp.debian.org sid/non-free Translation-en/DiffIndex [1057
B]
Fetched 12.3 kB in 2s (4859 B/s)
Reading package lists...
I: Using debdelta-upgrade for available deltas
Delta-upgrade
statistics:                                                            
                                                                       
                                   
 total resulting debs, size 0B time 2sec virtual speed 0B/sec
Reading package lists...
Building dependency tree...
Reading state information...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
Package 'ccache' is not installed, so not removed
apt-utils is already the newest version.
aptitude is already the newest version.
build-essential is already the newest version.
debdelta is already the newest version.
dpkg-dev is already the newest version.
eatmydata is already the newest version.
python-apt is already the newest version.
xdelta3 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
I: unmounting /var/cache/apt/archives/ filesystem
I: unmounting dev/pts filesystem
I: unmounting run/shm filesystem
I: unmounting proc filesystem
I: creating base tarball [/var/cache/pbuilder/sid-amd64-base.tgz]
I: cleaning the build env 
I: removing directory /tmp/27612 and its subdirectories
2015-10-03 / 18:19:31 ♒♒♒  ☺    


-- 
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."

From fc9544ab825c111c1ad137ae9f431dde90fb7e09 Mon Sep 17 00:00:00 2001
From: Ritesh Raj Sarraf <r...@debian.org>
Date: Sat, 3 Oct 2015 16:09:43 +0530
Subject: [PATCH 2/2] Add debdelta as a feature, which can be enabled in
 pbuilderrc

Fix typo in variable reference

Signed-off-by: Ritesh Raj Sarraf <r...@debian.org>
---
 pbuilder-checkparams    | 4 ++++
 pbuilder-updatebuildenv | 5 +++++
 2 files changed, 9 insertions(+)

diff --git a/pbuilder-checkparams b/pbuilder-checkparams
index 07534ba..15f26cc 100755
--- a/pbuilder-checkparams
+++ b/pbuilder-checkparams
@@ -217,6 +217,10 @@ while [ -n "$1" ]; do
 	    ALLOWUNTRUSTED=yes;
 	    shift;
 	    ;;
+	--debdelta)
+	    DEBDELTA=yes;
+	    shift;
+	    ;;
 	--keyring)
 	    APTKEYRINGS[${#APTKEYRINGS[@]}]="$2";
 	    shift; shift;
diff --git a/pbuilder-updatebuildenv b/pbuilder-updatebuildenv
index 13dd043..713ad6e 100755
--- a/pbuilder-updatebuildenv
+++ b/pbuilder-updatebuildenv
@@ -41,6 +41,11 @@ log "I: Refreshing the base.tgz "
 log "I: upgrading packages"
 $CHROOTEXEC /usr/bin/apt-get -q update
 
+if [ "$DEBDELTA" = "yes" ]; then
+	log "I: Using debdelta-upgrade for available deltas"
+	$CHROOTEXEC /usr/bin/debdelta-upgrade
+fi
+
 case "$(readlink -e "$PBUILDERSATISFYDEPENDSCMD")" in
   *-aptitude)
     EXTRAPACKAGES="$EXTRAPACKAGES aptitude"
-- 
2.6.0

From 02d5e0706f95f75a76b99037cfa003ebda42ccad Mon Sep 17 00:00:00 2001
From: Ritesh Raj Sarraf <r...@debian.org>
Date: Sat, 3 Oct 2015 18:33:17 +0530
Subject: [PATCH] Also update the manpage

Signed-off-by: Ritesh Raj Sarraf <r...@debian.org>
---
 pbuilderrc.5 | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/pbuilderrc.5 b/pbuilderrc.5
index 5a1f6aa..b0f19d1 100644
--- a/pbuilderrc.5
+++ b/pbuilderrc.5
@@ -188,6 +188,11 @@ may also be used to reset the list of options.
 
 The default value is to build source and binary package.
 .TP
+
+.BI "DEBDELTA=" "yes/no"
+Whether to use debdelta or not. debdelta needs to be pre-installed inside the chroot
+.TP
+
 .BI "DEBOOTSTRAPOPTS=" "( '\-\-variant=buildd' '\-\-keyring' '/usr/share/keyrings/debian\-archive\-keyring.gpg' )"
 When this option is set to
 .B "\-\-variant=buildd"
-- 
2.6.0

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to