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

David Runge dvzrv at archlinux.org
Mon Mar 12 03:15:07 UTC 2018


    Date: Monday, March 12, 2018 @ 03:15:06
  Author: dvzrv
Revision: 306255

upgpkg: ssmtp 2.64-11

Adding .install script to fix FS#57787 for remaining files.

Added:
  ssmtp/trunk/ssmtp.install
Modified:
  ssmtp/trunk/PKGBUILD

---------------+
 PKGBUILD      |    3 ++-
 ssmtp.install |   13 +++++++++++++
 2 files changed, 15 insertions(+), 1 deletion(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2018-03-12 02:33:21 UTC (rev 306254)
+++ PKGBUILD	2018-03-12 03:15:06 UTC (rev 306255)
@@ -3,7 +3,7 @@
 
 pkgname=ssmtp
 pkgver=2.64
-pkgrel=10
+pkgrel=11
 pkgdesc="Extremely simple MTA to get mail off the system to a mailhub"
 arch=('x86_64')
 license=('GPL')
@@ -13,6 +13,7 @@
 provides=('smtp-forwarder')
 backup=('etc/ssmtp/ssmtp.conf' 'etc/ssmtp/revaliases')
 options=('!makeflags' '!emptydirs')
+install=${pkgname}.install
 source=("http://ftp.debian.org/debian/pool/main/s/ssmtp/${pkgname}_${pkgver}.orig.tar.bz2"
         'opessl_crypto.patch'
         'build-idempotency.patch')

Added: ssmtp.install
===================================================================
--- ssmtp.install	                        (rev 0)
+++ ssmtp.install	2018-03-12 03:15:06 UTC (rev 306255)
@@ -0,0 +1,13 @@
+post_upgrade() {
+  # if upgrading from 2.64-9 or 2.64-11, make sure to set permissions and setgid
+  if [ $(vercmp $2 "2.64-9") -eq 0 ] || [ $(vercmp $2 "2.64-10") -eq 0 ]; then
+    # set ownership and permissions for configuration and exectuables
+    # FS#57787
+    echo "Running post_upgrade function to fix FS#57787"
+    chgrp -cR mail /etc/ssmtp \
+      /usr/bin/{ssmtp,sendmail,newaliases,mailq}
+    chmod -cR 640 /etc/ssmtp
+    # setgid executables
+    chmod -c 2755 /usr/bin/{ssmtp,sendmail,newaliases,mailq}
+  fi
+}



More information about the arch-commits mailing list