bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH rumpkernel] prune.sh: Remove ~1.1G of currently unused bits.


From: Janneke Nieuwenhuizen
Subject: [PATCH rumpkernel] prune.sh: Remove ~1.1G of currently unused bits.
Date: Mon, 19 Jun 2023 22:00:32 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)

Hi!

The rumpkernel archive is ridiculously large.  It manages to grow so big
mainly by adopting the evil practice of bundling other packages.  The
archive contains copies of many GNU utilities, a copy of llvm, and even
a copy of postfix.

The archive can most probably be pruned a lot further without
consequences, but this is a helpful start.  I'm built the Guix
rumpkernel using this pruned archive and it works fine.  The same list
of librump* libraries are built and there are no messages in the build
log that suggest things are missing.

Because the patches are so big I'm only sharing the prune.sh script that
will create some 'prune: ...' commits.

Greetings,
Janneke

>From 04ffacdbca4a72535aeca22ddf00a40ed6becacb Mon Sep 17 00:00:00 2001
From: Janneke Nieuwenhuizen <janneke@gnu.org>
Date: Mon, 19 Jun 2023 19:13:01 +0200
Subject: [PATCH rumpkernel] prune.sh: Remove ~1.1G of currently unused bits.

---
 prune.sh | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 61 insertions(+)
 create mode 100755 prune.sh

diff --git a/prune.sh b/prune.sh
new file mode 100755
index 000000000..8cba948fe
--- /dev/null
+++ b/prune.sh
@@ -0,0 +1,61 @@
+#! /bin/sh
+
+# This script prunes ~1.1G of currently unused files.
+
+set -ex
+
+cd buildrump.sh/src
+
+git rm -rf crypto
+git commit -F- <<EOF
+prune: buildrump.sh/src/crypto.
+
+Saves 169M.'
+EOF
+
+git rm -rf distrib
+git commit -F- <<EOF
+prune: buildrump.sh/src/distrib.
+
+Saves 30M.
+EOF
+
+git rm -rf external
+mkdir -p external/{bsd/{byacc,flex,mdocml},historical/nawk}
+git reset external/{bsd/{byacc,flex,mdocml},historical/nawk}
+git checkout external/{bsd/{byacc,flex,mdocml},historical/nawk}
+git commit -F- <<EOF
+prune: buildrump.sh/src/external, except bsd/{byacc,flex,mdocml}, 
historical/nawk.
+
+Saves 787M.
+EOF
+
+git rm -rf games
+git commit -F- <<EOF
+prune: buildrump.sh/src/games.
+
+Saves 10M.
+EOF
+
+git rm -rf share
+mkdir -p share/mk
+git reset share/mk
+git checkout share/mk
+git commit -F- <<EOF
+prune: buildrump.sh/src/share, except mk.
+
+Saves 36M.
+EOF
+
+git rm -rf sys/external
+mkdir -p sys/external/bsd
+git reset sys/external/bsd
+git checkout sys/external/bsd
+mkdir -p sys/external/isc
+git reset sys/external/isc
+git checkout sys/external/isc
+git commit -F- <<EOF
+prune: buildrump.sh/src/sys/external, except bsd,isc.
+
+Saves 29M.
+EOF
-- 
2.40.1

-- 
Janneke Nieuwenhuizen <janneke@gnu.org>  | GNU LilyPond https://LilyPond.org
Freelance IT https://www.JoyOfSource.com | AvatarĀ® https://AvatarAcademy.com

reply via email to

[Prev in Thread] Current Thread [Next in Thread]