-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy path09-Multilib.sh
More file actions
executable file
·84 lines (63 loc) · 2.3 KB
/
Copy path09-Multilib.sh
File metadata and controls
executable file
·84 lines (63 loc) · 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
#!/bin/bash
#set -x
set -e
NP=`basename $0 | cut -d "." -f 1`
clean_download_install() {
rm -rf $NP $NP-removed
mkdir -p $NP $NP-work $NP-removed
for i in $EXCLUDE; do
ROPT=" --exclude $i $ROPT"
FOPT=" -name $i -or $FOPT"
done
FOPT=$FOPT" -size +30M"
rsync -ah --delete $ROPT --log-file=/var/log/rsync-alien.log --timeout=300 taper.alienbase.nl::mirrors/people/alien/multilib/current/ $NP-work/
find $NP-work/ $FOPT | xargs rm -r
installpkg -root $NP $NP-work/*.t?z
installpkg -root $NP $NP-work/slackware64-compat32/*-compat32/*.t?z
for i in $DELETE; do
rm -r ${NP}/${i}
done
}
run-caches() {
AUFS="aufs-temp"
echo "Rebuilding caches chrooted inside $AUFS"
mount | grep aufs-temp && umount aufs-temp
mkdir -p $AUFS
mount -t aufs -o xino=/mnt/live/memory/aufs.xino,br:$NP none $AUFS
mount -t aufs -o remount,append:07-Devel64=ro none $AUFS
mount -t aufs -o remount,append:05-KDE64=ro none $AUFS
mount -t aufs -o remount,append:04-Apps64=ro none $AUFS
#mount -t aufs -o remount,append:03-Libs64=ro none $AUFS
mount -t aufs -o remount,append:02-Xorg64=ro none $AUFS
mount -t aufs -o remount,append:01-Core64=ro none $AUFS
chroot $AUFS ldconfig
chroot $AUFS fc-cache
chroot $AUFS update-mime-database /usr/share/mime
chroot $AUFS update-desktop-database -q /usr/share/applications
chroot $AUFS gio-querymodules /usr/lib64/gio/modules
#chroot $AUFS update-gtk-immodules
chroot $AUFS update-gdk-pixbuf-loaders
chroot $AUFS glib-compile-schemas /usr/share/glib-2.0/schemas/
umount $AUFS
rm -rf $NP/.wh..wh.*
}
case $1 in
"min" )
EXCLUDE="qt-compat32-* icu4c-compat32-* seamonkey-solibs-compat32-* lesstif-compat32-* gst-plugins-* gstreamer-compat32-* cairo-compat32-* libgphoto2-compat32-* cairo-compat32-* mesa-compat32-* libsamplerate-compat32-* audiofile-compat32-* openssl-solibs-compat32-* gcc-go-* gcc-gnat-* gcc-gfortran-* gcc-objc-* debug ap-compat32 n-compat32 ap-compat32 d-compat32 xap-compat32"
DELETE="usr/lib/locale usr/lib64/locale usr/share/locale usr/doc"
clean_download_install
echo "...Minimum Multilib Setup"
;;
"med" )
clean_download_install
echo "...Average Multilib Setup"
;;
"max" )
clean_download_install
echo "...Fully Blown Multilib"
;;
esac
run-caches
SQUASH_OPT="-comp xz -noappend -b 256K -Xbcj x86 -no-xattrs"
mksquashfs $NP $NP.lzm $SQUASH_OPT
echo -e "\n $0 \033[7m DONE \033[0m \n"