Several updates for grml-small
authorMichael Prokop <devnull@localhost>
Mon, 29 Sep 2008 11:24:33 +0000 (13:24 +0200)
committerMichael Prokop <devnull@localhost>
Mon, 29 Sep 2008 11:24:33 +0000 (13:24 +0200)
debian/changelog
etc/grml/fai/config/package_config/GRML_SMALL
etc/grml/fai/config/scripts/GRMLBASE/90-update-alternatives
etc/grml/fai/config/scripts/GRMLBASE/98-clean-chroot
etc/grml/fai/grml/grml_cleanup_chroot
etc/grml/fai/grml/grml_cleanup_chroot.remove_docs

index 352c6a3..50b3c66 100644 (file)
@@ -14,11 +14,14 @@ grml-live (0.9.4) unstable; urgency=low
   * GRML_MEDIUM:
     - replace rt73-module-2.6.26-grml with rt73-modules-2.6.26-grml.
   * GRML_SMALL:
+    - several improvements to keep the ISO size as small as possible
     - use kernel 2.6.26-grml instead of 2.6.26-grml-small
+    - remove fuse-utils
+    - remove nvi (see #490361)
     - remove ppoeconf (just too big with its dependencies)
     - remove prism54-firmware (for saving disk space)
 
- -- Michael Prokop <mika@grml.org>  Mon, 29 Sep 2008 11:28:31 +0200
+ -- Michael Prokop <mika@grml.org>  Mon, 29 Sep 2008 13:23:44 +0200
 
 grml-live (0.9.3) unstable; urgency=low
 
index 416f180..cd90149 100644 (file)
@@ -50,7 +50,7 @@ file-rc
 findutils
 firmware-ipw3945
 fnord
-fuse-utils
+fuse-utils
 gawk
 gpm
 grep
@@ -71,7 +71,7 @@ grml-saveconfig
 grml-scanpartitions
 grml-scripts
 grml-shlib
-grml-small
+grml-small
 grml-tips
 grml-usleep
 grub
@@ -127,7 +127,7 @@ net-tools
 nfs-common
 ntfsprogs
 ntpdate
-nvi
+# nvi -> see #490361
 openssh-client
 openssh-server
 passwd
index a413a40..d67281f 100755 (executable)
@@ -4,22 +4,26 @@
 # Authors:       grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
 # Bug-Reports:   see http://grml.org/bugs/
 # License:       This file is licensed under the GPL v2 or any later version.
-# Latest change: Mon Aug 25 15:07:12 CEST 2008 [mika]
+# Latest change: Mon Sep 29 13:15:35 CEST 2008 [mika]
 ################################################################################
 
 set -u
 set -e
 
+## Editor:
+# Too many people don't expect to get that, so use it only for grml-small:
+if ifclass GRML_SMALL ; then
+   if [ -r $target/usr/bin/vim.tiny ] ; then
+      $ROOTCMD update-alternatives --set editor /usr/bin/vim.tiny
+      $ROOTCMD update-alternatives --set vi     /usr/bin/vim.tiny
+   fi
+fi
+
 if [ -r $target/usr/bin/vim.basic ] ; then
    $ROOTCMD update-alternatives --set editor /usr/bin/vim.basic
    $ROOTCMD update-alternatives --set vi     /usr/bin/vim.basic
 fi
 
-## Too many people don't expect to get that, so deactive by default:
-# if [ -r $target/usr/bin/vim.tiny ] ; then
-#    $ROOTCMD update-alternatives --set vi /usr/bin/vim.tiny
-# fi
-
 if [ -r $target/usr/bin/uxterm ] ; then
    $ROOTCMD update-alternatives --set x-terminal-emulator /usr/bin/uxterm
 elif [ -r $target/usr/bin/xterm ] ; then
index 902bd02..be8c47f 100755 (executable)
@@ -27,7 +27,7 @@ fi
 if ifclass GRML_SMALL ; then
    $ROOTCMD apt-get -y --purge remove aptitude
    for pkg in groff-base info locales man-db manpages nano; do
-     $ROOTCMD apt-get --purge $pkg || true
+     $ROOTCMD apt-get --purge remove --yes $pkg || true
    done
 fi
 
index d59c77b..57756d2 100755 (executable)
@@ -140,6 +140,7 @@ einfo "Removing /var/lib/apt/lists/*-stuff, dpkg-status-old and pkgcache.bin"
   rm -f /var/lib/apt/lists/*Packages
   rm -f /var/lib/apt/lists/*Release
   rm -f /var/lib/apt/lists/*Sources
+  rm -f /var/lib/apt/lists/*IndexDiff
   rm -f /var/lib/apt/lists/*.gpg
   rm -f /var/cache/apt-show-versions/*
   rm -f /var/cache/debconf/templates.dat-old
@@ -151,6 +152,30 @@ einfo "Removing /var/lib/apt/lists/*-stuff, dpkg-status-old and pkgcache.bin"
   rm -f /var/lib/dpkg/available-old
 eend $?
 
+if ifclass GRML_SMALL ; then
+   einfo "Removing /var/cache/debconf/templates.dat"
+   rm -f /var/cache/debconf/templates.dat
+   eend $?
+
+   einfo "Removing /usr/share/ssh/blacklist.*"
+   rm -f /usr/share/ssh/blacklist.DSA-1024 /usr/share/ssh/blacklist.RSA-2048
+   eend $?
+fi
+
+# get rid of large kernel modules:
+if ifclass GRML_SMALL ; then
+  if [ -r "/lib/modules/${KERNEL}/kernel/fs/ocfs2/ocfs2.ko" ] ; then
+    einfo "Removing /lib/modules/${KERNEL}/kernel/fs/ocfs2/ocfs2.ko"
+    rm -f "/lib/modules/${KERNEL}/kernel/fs/ocfs2/ocfs2.ko"
+    eend $?
+  fi
+  if [ -r "/lib/modules/${KERNEL}/kernel/drivers/isdn/hisax/hisax.ko" ] ; then
+    einfo "Removing /lib/modules/${KERNEL}/kernel/drivers/isdn/hisax/hisax.ko"
+    rm -f "/lib/modules/${KERNEL}/kernel/drivers/isdn/hisax/hisax.ko"
+    eend $?
+  fi
+fi
+
 if [ -x /usr/bin/grep-dctrl ] ; then
    einfo "Cleaning up /var/lib/dpkg/status"
    grep-dctrl -v -F Status "purge ok not-installed" /var/lib/dpkg/status > status.new && \
@@ -173,6 +198,10 @@ einfo "Removing ssh-keys"
   rm -f /etc/ssh/*key*
 eend $?
 
+einfo "Removing unused/backup files"
+  find / -name *~ -print0 | xargs -0 rm -f
+eend $?
+
 # remove only "temporary" or saved files in the given directories
 nuke(){
   for i in `find "$@" -name \*.gz -o -name \*.bz2 -o -name \*.0 2>/dev/null`; do
index a4531ea..f5ce327 100755 (executable)
@@ -24,6 +24,7 @@ rm -rf /usr/share/gtk-doc/
 rm -rf /usr/share/man/
 rm -rf /usr/man
 rm -rf /usr/share/info
+rm -rf /var/cache/man/*
 eend $?
 
 einfo "Creating /usr/share/info/..."