wok-current rev 229

Add: slitaz-loram
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Feb 16 16:18:57 2008 +0100 (2008-02-16)
parents 92615b1ee474
children c838d59930a2
files slitaz-loram/receipt
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/slitaz-loram/receipt	Sat Feb 16 16:18:57 2008 +0100
     1.3 @@ -0,0 +1,45 @@
     1.4 +# SliTaz package receipt.
     1.5 +
     1.6 +PACKAGE="slitaz-loram"
     1.7 +VERSION="1.0"
     1.8 +CATEGORY="misc"
     1.9 +SHORT_DESC="Rules to build low ram rootfs.gz."
    1.10 +MAINTAINER="pascal.bellard@slitaz.org"
    1.11 +DEPENDS="squashfs"
    1.12 +
    1.13 +# Rules to gen a SliTaz package suitable for Tazpkg.
    1.14 +genpkg_rules()
    1.15 +{
    1.16 +    mkdir -p $fs/etc/tazlito
    1.17 +    cat > $fs/etc/tazlito/loram.rootfs << EOF
    1.18 +mksquashfs usr .usr.sqfs && rm -rf usr/* && COMPRESSION="none"
    1.19 +EOF
    1.20 +}
    1.21 +
    1.22 +get_patch()
    1.23 +{
    1.24 +    cat <<EOF
    1.25 +--- /etc/init.d/rcS
    1.26 ++++ /etc/init.d/rcS
    1.27 +@@ -79,2 +79,7 @@
    1.28 + 
    1.29 ++# Mount compressed /usr
    1.30 ++if [ -f /.usr.sqfs ]; then
    1.31 ++	/bin/mount -o loop,ro -t squashfs /.usr.sqfs /usr
    1.32 ++fi
    1.33 ++
    1.34 + # Handle kernel cmdline parameter config=<device>,<path> to source a 
    1.35 +EOF
    1.36 +}
    1.37 +
    1.38 +# Pre and post install commands for Tazpkg.
    1.39 +post_install()
    1.40 +{
    1.41 +    get_patch | patch -p0
    1.42 +}
    1.43 +
    1.44 +# Pre remove commands for Tazpkg.
    1.45 +pre_remove()
    1.46 +{
    1.47 +    get_patch | patch -R -p0
    1.48 +}