[arch-commits] Commit in spamassassin/trunk (spamassassin.install)

Florian Pritz bluewind at archlinux.org
Thu Mar 1 23:38:18 UTC 2012


    Date: Thursday, March 1, 2012 @ 18:38:17
  Author: bluewind
Revision: 151746

remove hardcoded executable paths from install script

Modified:
  spamassassin/trunk/spamassassin.install

----------------------+
 spamassassin.install |   16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

Modified: spamassassin.install
===================================================================
--- spamassassin.install	2012-03-01 23:28:16 UTC (rev 151745)
+++ spamassassin.install	2012-03-01 23:38:17 UTC (rev 151746)
@@ -1,25 +1,11 @@
-# arg 1:  the new package version
 post_install() {
   echo "You must run 'sa-update' to install spam rules before use."
-  /bin/true
 }
 
-# arg 1:  the new package version
-# arg 2:  the old package version
 post_upgrade() {
   # Compile rules, if rules have previously been compiled, and it's possible
-  if [ -x /usr/bin/re2c -a -x /usr/bin/perlbin/vendor/sa-compile -a -d /var/lib/spamassassin/compiled ]; then
+  if type re2c &>/dev/null && type sa-compile &>/dev/null && [[ -d /var/lib/spamassassin/compiled ]]
     echo "Detected compiled rules, running sa-compile..."
     sa-compile > /dev/null 2>&1
 fi
 }
-
-# arg 1:  the old package version
-pre_remove() {
-  /bin/true
-}
-
-# arg 1:  the old package version
-post_remove() {
-  /bin/true
-}




More information about the arch-commits mailing list