Dear Stefan,
some years ago I did some work in this respect.
debpatch and debdelta-upgrade have an option
--format unzipped
that will recreate the deb w/o compressing the data part: this is much
faster.
The point is, I do not know if apt will accept those .debs . Maybe apt
may have an option to accept debs even when the size is not what is
expected.
I also experimented with other --format options. One option would write
all new files in the filesystem, the way that
dpkg --unpack
does, so after that, only configuration would be needed; this work is
there but uncomplete.
a.
Il 27/10/23 18:09, Stefan Monnier ha scritto:
Subject: debdelta: Avoid generating the actual `.deb`
Package: debdelta
Version: 0.67
Severity: wishlist
Dear Maintainer,
`debdelta-upgrade` is great at reducing the amount of data downloaded,
but on some of my (weaker) machines, generating the `.deb` files takes
a lot of time, and for no good reason: 99% of the time is spent not
applying the xdelta but (re)compressing the result with `xz`.
So, this wishlist item is to change APT such that we can skip the
generation of the `.deb` file and instead keep the old `.deb` together
with the patch(es) in `/var/cache/apt/archives`.
When APT needs to install the (not created) `.deb`, instead of
unpacking+uncompressing the (not created) `.deb`, it would
unpack+uncompress the old `.deb`, and apply the (set of) patch(es).
Since the old `.deb` + patch(es) is usually larger than
a patched+recompressed `.deb`, we could occasionally "repack" the files
in `/var/cache/apt/archives`, but that would be optional and could be
performed opportunistically in the background, a bit like Git's GC.
Stefan
-- System Information:
Debian Release: trixie/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'stable-security'), (100, 'stable')
Architecture: i386 (x86_64)
Foreign Architectures: amd64
Kernel: Linux 6.1.0-7-amd64 (SMP w/2 CPU threads; PREEMPT)
Kernel taint flags: TAINT_WARN, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=fr_CH.UTF-8, LC_CTYPE=fr_CH.UTF-8 (charmap=UTF-8), LANGUAGE not se$
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages debdelta depends on:
ii binutils 2.41-6
ii bzip2 1.0.8-5+b1
ii libbz2-1.0 1.0.8-5+b1
ii libc6 2.37-12
ii python3 3.11.4-5+b1
ii python3-requests 2.31.0+dfsg-1
ii zlib1g 1:1.2.13.dfsg-3
Versions of packages debdelta recommends:
ii bsdiff 4.3-23
ii gnupg2 2.2.40-1.1
ii gpg-agent [gnupg-agent] 2.2.40-1.1
ii lzma 9.22-2.2
ii python3-apt 2.6.0
ii python3-debian 0.1.49
ii xdelta 1.1.3-10.4
ii xdelta3 3.0.11-dfsg-1.2
ii xz-utils [lzma] 5.4.4-0.1
Versions of packages debdelta suggests:
pn debdelta-doc <none>
-- no debconf information