Date: Thursday, May 16, 2013 @ 12:00:47 Author: stativ Revision: 90952
prepare for the sbin -> bin move, remove the sysvinit script. Modified: laptop-mode-tools/trunk/PKGBUILD Deleted: laptop-mode-tools/trunk/laptop-mode -------------+ PKGBUILD | 11 +++++------ laptop-mode | 57 --------------------------------------------------------- 2 files changed, 5 insertions(+), 63 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2013-05-16 09:13:23 UTC (rev 90951) +++ PKGBUILD 2013-05-16 10:00:47 UTC (rev 90952) @@ -46,10 +46,8 @@ etc/laptop-mode/laptop-mode.conf etc/laptop-mode/lm-profiler.conf) install=laptop-mode.install -source=("http://www.samwel.tk/laptop_mode/tools/downloads/${pkgname}_${pkgver}.tar.gz" - 'laptop-mode') -md5sums=('58d7dbffe9a60746a67f4b2a27ab284f' - '4d3b4d95c6532451b3dba588c83fb86b') +source=("http://www.samwel.tk/laptop_mode/tools/downloads/${pkgname}_${pkgver}.tar.gz") +md5sums=('58d7dbffe9a60746a67f4b2a27ab284f') build() { cd "$srcdir/${pkgname}_$pkgver" @@ -58,6 +56,7 @@ package() { cd "$srcdir/${pkgname}_$pkgver" make DESTDIR="$pkgdir" INIT_D=none MAN_D=/usr/share/man LIB_D=/usr/lib install - - install -D -m755 "$srcdir/laptop-mode" "$pkgdir/etc/rc.d/laptop-mode" + # use bin instead of sbin + mv "$pkgdir/usr/sbin" "$pkgdir/usr/bin" + find "$pkgdir" -type f -exec sed -i 's|sbin/laptop_mode|bin/laptop_mode|g' '{}' ';' } Deleted: laptop-mode =================================================================== --- laptop-mode 2013-05-16 09:13:23 UTC (rev 90951) +++ laptop-mode 2013-05-16 10:00:47 UTC (rev 90952) @@ -1,57 +0,0 @@ -#!/bin/bash - -. /etc/rc.conf -. /etc/rc.d/functions - -case "$1" in - start) - stat_busy "Starting laptop-mode" - [ ! -d /var/run/laptop-mode-tools ] && install -d /var/run/laptop-mode-tools - touch /var/run/laptop-mode-tools/enabled - /usr/sbin/laptop_mode auto >/dev/null 2>&1 - if [ $? -gt 0 ]; then - stat_fail - else - add_daemon laptop-mode - stat_done - fi - ;; - stop) - stat_busy "Stopping laptop-mode" - rm -f /var/run/laptop-mode-tools/enabled - /usr/sbin/laptop_mode stop >/dev/null 2>&1 - if [ $? -gt 0 ]; then - stat_fail - else - rm_daemon laptop-mode - stat_done - fi - ;; - restart) - stat_busy "Restarting laptop-mode" - rm -f /var/run/laptop-mode-tools/enabled - /usr/sbin/laptop_mode stop >/dev/null 2>&1 - - if [ $? -gt 0 ]; then - stat_fail - rm_daemon laptop-mode - else - rm -f /var/run/laptop-mode-tools/* - touch /var/run/laptop-mode-tools/enabled - /usr/sbin/laptop_mode auto force >/dev/null 2>&1 - if [ $? -gt 0 ]; then - stat_fail - rm_daemon laptop-mode - else - stat_done - fi - fi - ;; - status) - /usr/sbin/laptop_mode status - ;; - *) - echo "Usage: $0 {stop|start|restart|status}" - ;; -esac -exit 0