wok view slitaz-loram/receipt @ rev 309
Slitaz-loram*: update patch according to /etc/init.d/rcS
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Mar 01 12:55:33 2008 +0000 (2008-03-01) |
parents | 39ab194bbbef |
children | c570ed86d31a |
line source
1 # SliTaz package receipt.
3 PACKAGE="slitaz-loram"
4 VERSION="1.1"
5 CATEGORY="misc"
6 SHORT_DESC="Rules to build low ram rootfs.gz."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 DEPENDS="squashfs"
10 # Rules to gen a SliTaz package suitable for Tazpkg.
11 genpkg_rules()
12 {
13 mkdir -p $fs/etc/tazlito
14 cp stuff/loram.rootfs $fs/etc/tazlito
15 }
17 get_patch()
18 {
19 cat <<EOF
20 --- /etc/init.d/rcS
21 +++ /etc/init.d/rcS
22 @@ -58,2 +58,9 @@
24 +# Mount compressed /usr
25 +if [ -f /.usr.sqfs ]; then
26 + echo -n "Mounting compressed /usr read-only... "
27 + /bin/mount -o loop,ro -t squashfs /.usr.sqfs /usr
28 + status
29 +fi
30 +
31 # Creat /dev/cdrom if needed (symlink does not exist on LiveCD). Chmod
32 EOF
33 }
35 # Pre and post install commands for Tazpkg.
36 pre_install()
37 {
38 local $loram
39 loram=$(cd /var/lib/tazpkg/installed ; ls -d slitaz-loram* 2> /dev/null)
40 [ -n "$loram" ] && yes y | tazpkg remove $loram
41 }
43 post_install()
44 {
45 get_patch | patch -p0
46 }
48 # Pre remove commands for Tazpkg.
49 pre_remove()
50 {
51 [ -L /usr/bin/patch ] || get_patch | patch -R -p0
52 }