98-remove_unwanted_packages 1.32 KB
Newer Older
1 2
#!/bin/sh

3 4
set -e

5 6 7 8 9 10 11
echo "Removing unwanted packages"

### Deinstall dev packages.

# We use apt-get as aptitude doesn't know about globs.
# There are packages we could be tempted to remove but we can't:
#   - gcc-4.4-base (libstdc++6 depends on it)
12 13
#   - libgcc1 (vidalia depends on it)
#   - cpp, cpp-4.4 (big parts of GNOME depend on it)
14
apt-get --yes purge  \
15 16
   '^linux-kbuild-*' \
   '^linux-headers-*' \
17
   build-essential debhelper dkms dpatch dpkg-dev \
18
   cpp-4.3 \
19
   gcc gcc-4.3 gcc-4.3-base gcc-4.4 \
20
   g++ '^g\+\+-*' \
21
   intltool-debian \
22
   libc6-dev libgl1-mesa-dev libstdc++6-4.4-dev linux-libc-dev \
23 24 25
   make \
   module-assistant \
   po-debconf \
26
   virtualbox-guest-dkms
27 28

### Deinstall some other unwanted packages.
29
apt-get --yes purge  \
30
   aptitude live-build tasksel tasksel-data
31 32

### Deinstall dependencies of the just removed packages.
33
apt-get --yes --purge autoremove
34

35
### Deinstall gnome-core and some of its new dependencies.
36

37
# We do this last as we don't want apt-get autoremove to deinstall all
38
# gnome-core dependencies.
39 40

# - gnome-core itself
41
apt-get --yes purge gnome-core
42 43

# - evolution and its dependencies
44
apt-get --yes purge \
45 46 47 48
   evolution evolution-common libevolution \
   libgtkhtml-editor-common libgtkhtml-editor0 libgtkhtml3.14-19

# - others
49
apt-get --yes purge \
50
   gnome-screensaver \
51
   gnome-user-guide