1 # Maintainer: Ng Oon-Ee <ngoonee.talk@gmail.com>
2 # Contributor: Thomas Baechler <thomas@archlinux.org>
3 # Contributor: Guillaume ALAUX <guillaume at alaux dot net>
5 pkgname=hibernate-script
8 pkgdesc="Set of scripts for managing tux on ice, hibernation and suspend to RAM"
10 url="http://www.tuxonice.net"
14 backup=('etc/hibernate/hibernate.conf' 'etc/hibernate/tuxonice.conf' \
15 'etc/hibernate/disk.conf' 'etc/hibernate/ram.conf' \
16 'etc/hibernate/common.conf' 'etc/hibernate/blacklisted-modules' \
17 'etc/hibernate/ususpend-both.conf' 'etc/hibernate/sysfs-ram.conf' \
18 'etc/hibernate/ususpend-ram.conf' 'etc/hibernate/sysfs-disk.conf' \
19 'etc/hibernate/ususpend-disk.conf')
20 source=(http://tuxonice.net/files/${pkgname}-${pkgver}.tar.gz
21 hibernate-script-${pkgver}-arch.patch
23 md5sums=('5c21770afbae503450e3c4a5502bf29d'
24 '2e6dba2c90e90952b8b1f167045c38e6'
25 '5d7e83902a00bf72b1de97a5450a558e')
28 cd ${srcdir}/${pkgname}-${pkgver}
29 # Fix scriptlets to work properly with Archlinux
30 patch -Np1 -i ${srcdir}/${pkgname}-${pkgver}-arch.patch
34 cd ${srcdir}/${pkgname}-${pkgver}
35 export BASE_DIR=${pkgdir}
37 export MAN_DIR=$BASE_DIR$PREFIX/share/man
38 install -dm755 ${pkgdir}/etc/{rc,logrotate}.d
39 ./install.sh || return 1
40 install -m 755 $srcdir/hibernate.rc $pkgdir/etc/rc.d/hibernate-cleanup
41 # Allow for behaviour as in man-page (calling by hibernate-* uses
42 # /etc/hibernate/*.conf file.
43 ln -s /usr/sbin/hibernate ${pkgdir}/usr/sbin/hibernate-ram
44 ln -s /usr/sbin/hibernate ${pkgdir}/usr/sbin/hibernate-disk