From beb17b3de3b8058c6610f0c8c1025ed2fabed87c Mon Sep 17 00:00:00 2001 From: abveritas Date: Wed, 5 Dec 2012 02:38:11 +0000 Subject: [PATCH] one more util update, mlocate --- mlocate/PKGBUILD | 27 +++++++++++---------------- mlocate/mlocate.install | 18 ------------------ mlocate/updatedb.cron | 6 ++++++ 3 files changed, 17 insertions(+), 34 deletions(-) delete mode 100644 mlocate/mlocate.install create mode 100755 mlocate/updatedb.cron diff --git a/mlocate/PKGBUILD b/mlocate/PKGBUILD index 0111f8d90..81e4d58b1 100644 --- a/mlocate/PKGBUILD +++ b/mlocate/PKGBUILD @@ -1,29 +1,24 @@ # -# Chakra Packages for Chakra, part of chakra-project.org +# Core Packages for Chakra, part of chakra-project.org # -# maintainer (i686): Phil Miller -# maintainer (x86_64): Manuel Tortosa +# maintainer: abveritas@chakra-project.org pkgname=mlocate -pkgver=0.24 -pkgrel=2 +pkgver=0.26 +pkgrel=1 pkgdesc="Faster merging drop-in for slocate" -arch=('i686' 'x86_64') +arch=('x86_64') url="http://carolina.mff.cuni.cz/~trmac/blog/mlocate" license=('GPL') -conflicts=('slocate') -provides=('slocate') -replaces=('slocate') depends=('glibc' 'coreutils' 'sh') backup=('etc/updatedb.conf' 'etc/cron.daily/updatedb') -install=mlocate.install -source=(https://fedorahosted.org/releases/m/l/mlocate/mlocate-$pkgver.tar.xz - updatedb.conf - updatedb.cron.daily) -md5sums=('a9c221e5bc489a2ed710c943990137bd' +source=("https://fedorahosted.org/releases/m/l/mlocate/mlocate-$pkgver.tar.xz" + 'updatedb.conf' + 'updatedb.cron') +md5sums=('539e6f86bf387358aa2b14d5f880e49a' '66898efb290eff4efd44a0b94fe3927d' - 'cde5da81bebad2de556ef2e43d895e13') + '4298849f2cdfc43f5403fda15581e265') build() { cd $srcdir/$pkgname-$pkgver @@ -44,7 +39,7 @@ package() { # Set up a default updatedb.conf and a daily cronjob install -Dm644 ${srcdir}/updatedb.conf $pkgdir/etc/updatedb.conf - install -Dm744 ${srcdir}/updatedb.cron.daily $pkgdir/etc/cron.daily/updatedb + install -Dm744 ${srcdir}/updatedb.cron $pkgdir/etc/cron.daily/updatedb # Install Mlocate make DESTDIR=$pkgdir install diff --git a/mlocate/mlocate.install b/mlocate/mlocate.install deleted file mode 100644 index c7b7f9cf7..000000000 --- a/mlocate/mlocate.install +++ /dev/null @@ -1,18 +0,0 @@ -post_install() { - post_upgrade "$1" "$1" - echo "mlocate command is technically locate, but slocate is symlinked and still works." - echo "You should run updatedb as root." -} - -post_upgrade() { - # This can be removed after {m,x}locate have both been updated - getent group slocate &>/dev/null && usr/sbin/groupdel slocate &>/dev/null - getent group mlocate &>/dev/null && usr/sbin/groupdel mlocate &>/dev/null - - getent group locate &>/dev/null || usr/sbin/groupadd -g 21 locate &>/dev/null - chown -R root:locate var/lib/mlocate -} - -pre_remove() { - getent group locate &>/dev/null && usr/sbin/groupdel locate &>/dev/null -} diff --git a/mlocate/updatedb.cron b/mlocate/updatedb.cron new file mode 100755 index 000000000..431cb533e --- /dev/null +++ b/mlocate/updatedb.cron @@ -0,0 +1,6 @@ +#!/bin/sh + +NICE='nice -n 19' +IONICE='ionice -c 2 -n 7' + +exec ${IONICE} ${NICE} updatedb -f proc