From 9d36fcd5638035abf19f303deebd9e861d384254 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 7 Aug 2012 00:01:58 +0000 Subject: Tue Aug 7 00:01:58 UTC 2012 --- community/c++-gtk-utils/PKGBUILD | 6 +-- community/linux-tools/PKGBUILD | 21 ++++---- community/linux-tools/cpupower.rc | 34 ++----------- community/linux-tools/cpupower.service | 2 +- community/linux-tools/cpupower.systemd | 32 ++++++++++++ community/mailman/PKGBUILD | 93 ++++++++++++++++++++-------------- community/mailman/mailman.install | 28 +++++----- community/mailman/mailman.profile.csh | 1 + community/mailman/mailman.profile.sh | 3 ++ community/mailman/mailman.rc | 29 +++++++++++ community/mailman/mailman.service | 13 +++++ community/pcsclite/PKGBUILD | 8 +-- 12 files changed, 170 insertions(+), 100 deletions(-) create mode 100644 community/linux-tools/cpupower.systemd create mode 100644 community/mailman/mailman.profile.csh create mode 100644 community/mailman/mailman.profile.sh create mode 100644 community/mailman/mailman.rc create mode 100644 community/mailman/mailman.service (limited to 'community') diff --git a/community/c++-gtk-utils/PKGBUILD b/community/c++-gtk-utils/PKGBUILD index c466f8b8f..5ddde2fff 100644 --- a/community/c++-gtk-utils/PKGBUILD +++ b/community/c++-gtk-utils/PKGBUILD @@ -1,8 +1,8 @@ -# $Id: PKGBUILD 73736 2012-07-15 04:46:33Z giovanni $ +# $Id: PKGBUILD 74790 2012-08-05 09:41:39Z giovanni $ # Maintainer: Giovanni Scafora pkgname=c++-gtk-utils -pkgver=2.0.10 +pkgver=2.0.11 pkgrel=1 pkgdesc="Classes and functions for programming in GTK+" arch=('i686' 'x86_64') @@ -11,7 +11,7 @@ license=('LGPL2.1') depends=('gtk3') options=('!libtool') source=("http://downloads.sourceforge.net/project/cxx-gtk-utils/cxx-gtk-utils/${pkgver}/${pkgname}-${pkgver}.tar.gz") -md5sums=('6a2ba8c42356fa82e60d75410ebe6c54') +md5sums=('30e0299d677fb857bb0291e467408279') build() { cd "${srcdir}/${pkgname}-${pkgver}" diff --git a/community/linux-tools/PKGBUILD b/community/linux-tools/PKGBUILD index 56dfeb802..a0541720d 100644 --- a/community/linux-tools/PKGBUILD +++ b/community/linux-tools/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 74127 2012-07-22 02:44:47Z seblu $ +# $Id: PKGBUILD 74810 2012-08-06 02:37:26Z seblu $ # Maintainer: Sébastien Luttringer pkgbase=linux-tools pkgname=('perf' 'cpupower' 'x86_energy_perf_policy') pkgver=3.5 -pkgrel=1 +pkgrel=2 license=('GPL2') arch=('i686' 'x86_64') url='http://www.kernel.org' @@ -16,11 +16,13 @@ source=("http://ftp.kernel.org/pub/linux/kernel/v3.x/linux-$pkgver.tar.xz" # "http://ftp.kernel.org/pub/linux/kernel/v3.x/patch-$pkgver.4.xz" 'cpupower.rc' 'cpupower.conf' + 'cpupower.systemd' 'cpupower.service') md5sums=('24153eaaa81dedc9481ada8cd9c3b83d' - '73dbc931e86b3b73d6e2338dcbee81a4' + '1d9214637968b91706b6e616a100d44b' '857ccdd0598511e3bf4b63522754dc48' - '20870541e88109d2f153be3c58a277f1') + 'c0d17b5295fe964623c772a2dd981771' + '2450e8ff41b30eb58d43b5fffbfde1f4') build() { # apply stable patching set @@ -83,17 +85,18 @@ package_cpupower() { install install-man popd # install rc.d script - install -D -m 755 cpupower.rc "$pkgdir/etc/rc.d/cpupower" - install -D -m 644 cpupower.conf "$pkgdir/etc/conf.d/cpupower" - install -D -m 644 cpupower.service "$pkgdir/usr/lib/systemd/system/cpupower.service" + install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname" + install -Dm 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname" + install -Dm 644 $pkgname.service "$pkgdir/usr/lib/systemd/system/$pkgname.service" + install -Dm 755 $pkgname.systemd "$pkgdir/usr/lib/systemd/scripts/$pkgname" } package_x86_energy_perf_policy() { pkgdesc='Read or write MSR_IA32_ENERGY_PERF_BIAS' cd linux-$pkgver/tools/power/x86/x86_energy_perf_policy - install -D -m 755 x86_energy_perf_policy "$pkgdir/usr/bin/x86_energy_perf_policy" - install -D -m 644 x86_energy_perf_policy.8 "$pkgdir/usr/share/man/man8/x86_energy_perf_policy.8" + install -Dm 755 x86_energy_perf_policy "$pkgdir/usr/bin/x86_energy_perf_policy" + install -Dm 644 x86_energy_perf_policy.8 "$pkgdir/usr/share/man/man8/x86_energy_perf_policy.8" } # vim:set ts=2 sw=2 ft=sh et: diff --git a/community/linux-tools/cpupower.rc b/community/linux-tools/cpupower.rc index 27a491e95..2c4441c4e 100644 --- a/community/linux-tools/cpupower.rc +++ b/community/linux-tools/cpupower.rc @@ -2,40 +2,16 @@ . /etc/rc.conf . /etc/rc.d/functions - -[[ -f /etc/conf.d/cpupower ]] && . /etc/conf.d/cpupower +. /etc/conf.d/${0##*/} case "$1" in start|restart) - stat_busy "Setting cpupower rules" - declare -i fail=0 - - # frequency-set options - declare -a params=() - params+=(${governor:+-g $governor}) - params+=(${min_freq:+-d $min_freq}) - params+=(${max_freq:+-u $max_freq}) - params+=(${freq:+-f $freq}) - if ((${#params[@]} > 0)); then - cpupower frequency-set "${params[@]}" >/dev/null || fail=1 - fi - - # set options - declare -a params=() - params+=(${mc_scheduler:+-m $mc_scheduler}) - params+=(${smp_scheduler:+-s $smp_scheduler}) - params+=(${perf_bias:+-b $perf_bias}) - if ((${#params[@]} > 0)); then - cpupower set "${params[@]}" >/dev/null || fail=1 - fi - - # print failure if any - (($fail > 0)) && stat_fail && exit 1 || stat_done + status 'Setting cpupower rules' /usr/lib/systemd/scripts/cpupower || exit 1 ;; *) - echo "usage: ${0##*/} {start|restart}" + echo "usage: ${0##*/} {start|restart}" >&2 + exit 1 + ;; esac -true - # vim:set ts=2 sw=2 ft=sh et: diff --git a/community/linux-tools/cpupower.service b/community/linux-tools/cpupower.service index f77cfdc97..aaeba2b08 100644 --- a/community/linux-tools/cpupower.service +++ b/community/linux-tools/cpupower.service @@ -3,7 +3,7 @@ Description=Apply cpupower configuration [Service] Type=oneshot -ExecStart=/etc/rc.d/cpupower start +ExecStart=/usr/lib/systemd/scripts/cpupower RemainAfterExit=yes [Install] diff --git a/community/linux-tools/cpupower.systemd b/community/linux-tools/cpupower.systemd new file mode 100644 index 000000000..f45b02bc8 --- /dev/null +++ b/community/linux-tools/cpupower.systemd @@ -0,0 +1,32 @@ +#!/bin/bash + +. /etc/conf.d/cpupower + +declare -i fail=0 + +# parse frequency options +declare -a params=() +params+=(${governor:+-g $governor}) +params+=(${min_freq:+-d $min_freq}) +params+=(${max_freq:+-u $max_freq}) +params+=(${freq:+-f $freq}) + +# apply frequency options +if ((${#params[@]} > 0)); then + cpupower frequency-set "${params[@]}" >/dev/null || fail=1 +fi + +# parse cpu options +declare -a params=() +params+=(${mc_scheduler:+-m $mc_scheduler}) +params+=(${smp_scheduler:+-s $smp_scheduler}) +params+=(${perf_bias:+-b $perf_bias}) + +# apply cpu options +if ((${#params[@]} > 0)); then + cpupower set "${params[@]}" >/dev/null || fail=1 +fi + +exit $fail + +# vim:set ts=2 sw=2 ft=sh et: diff --git a/community/mailman/PKGBUILD b/community/mailman/PKGBUILD index 975b3cb96..74db47b4b 100644 --- a/community/mailman/PKGBUILD +++ b/community/mailman/PKGBUILD @@ -1,14 +1,15 @@ -# $Id: PKGBUILD 67164 2012-03-05 00:39:58Z pschmitz $ -# Maintainer: Paul Mattal +# $Id: PKGBUILD 74799 2012-08-05 16:06:17Z seblu $ +# Maintainer: Sébastien Luttringer +# Contributor: Paul Mattal pkgname=mailman -pkgver=2.1.14 -pkgrel=4 -pkgdesc="Mailing list manager with built in web access" -arch=('i686' 'x86_64') +pkgver=2.1.15 +pkgrel=2 +pkgdesc='The GNU Mailing List Manager' +arch=(i686 x86_64) license=('GPL') -url="http://www.list.org/" -depends=('python2' 'smtp-server') +url='http://www.list.org/' +depends=('glibc' 'python2' 'smtp-server') # we need to have the mailman user to build mailman makedepends=('mailman') # 'Defaults.py' should not be changed by users; 'mm_cfg.py' should instead. @@ -16,35 +17,42 @@ backup=('usr/lib/mailman/Mailman/mm_cfg.py') install=$pkgname.install source=("http://ftp.gnu.org/gnu/$pkgname/$pkgname-$pkgver.tgz" 'mailman-2.1-build.patch' - 'rc.mailman') -md5sums=('9ea163871ceccbd33fee4c9e335fcf7b' + "$pkgname.profile.sh" + "$pkgname.profile.csh" + "$pkgname.rc" + "$pkgname.service") +md5sums=('7d207489e8e9de0727cb334d46029833' 'ed04d062379eb21e39ce1e70e6b1ade2' - '3d83d06d0ec3319bf3c7d9df5d18e89f') + 'a9c71ec940c56173415fbd49087d10b0' + '85a8c30ffc444e677b286f54df530482' + '3a4014c15e9923451f5f282860896057' + 'f3ea6ef02ab135274406ce52ea8bbb7b') build() { - cd $srcdir/$pkgname-$pkgver - - # fix calls to /usr/bin/python - find . -name '*.py' -exec sed -i 's@^#!.*python$@#!/usr/bin/python2@' {} + + cd $pkgname-$pkgver + # some files in mailman doesn't use configure parameter + find . -type f -exec \ + sed -i '1s,^#! \?/usr/bin/\(env \|\)python$,#!/usr/bin/python2,' {} \; # fix directory permissions to satisfy check_perms - patch -p1 -i ${srcdir}/mailman-2.1-build.patch + patch -p1 -i "$srcdir/mailman-2.1-build.patch" # set some sane defaults before the configure script has a chance to screw them up - sed -e 's/@MAILHOST@/localhost/g' \ - -e 's/@URLHOST@/localhost/g' \ - -i Mailman/Defaults.py.in - - ./configure --without-permcheck \ - --prefix=/usr/lib/mailman \ - --with-var-prefix=/var/lib/mailman \ - --with-mail-gid=mailman \ - --with-username=mailman --with-groupname=mailman \ - --with-cgi-gid=http --with-python=/usr/bin/python2 + ./configure \ + --without-permcheck \ + --prefix=/usr/lib/mailman \ + --with-var-prefix=/var/lib/mailman \ + --with-mail-gid=mailman \ + --with-username=mailman \ + --with-groupname=mailman \ + --with-cgi-gid=http \ + --with-python=/usr/bin/python2 \ + --with-mailhost=localhost \ + --with-urlhost=localhost make } package() { - cd $srcdir/$pkgname-$pkgver - make DESTDIR=$pkgdir install + cd $pkgname-$pkgver + make DESTDIR="$pkgdir" install # let's follow Fedora FHS way; Gentoo does it the other way round @@ -56,16 +64,23 @@ package() { # experienced mailman admins will expect to find it there. But having it # "appear" in the config directory is good practice and heading in the # right direction for FHS compliance. - install -d -m755 ${pkgdir}/etc/${pkgname} - ln -sv /usr/lib/mailman/Mailman/mm_cfg.py ${pkgdir}/etc/${pkgname}/mm_cfg.py - + install -d -m755 "$pkgdir/etc/$pkgname" + ln -sv /usr/lib/mailman/Mailman/mm_cfg.py "$pkgdir/etc/$pkgname/mm_cfg.py" # fix some permissions to satisfy check_perms - chown -R mailman:mailman $pkgdir/{usr/lib/mailman,var/lib/mailman,etc/mailman/*} - chown http:mailman ${pkgdir}/var/lib/mailman/archives/private - chmod 2770 ${pkgdir}/var/lib/mailman/archives/private - chmod 2755 ${pkgdir}/usr/lib/mailman/cgi-bin/* - chmod 2755 ${pkgdir}/usr/lib/mailman/mail/mailman - - # install the launch script - install -D -m755 $srcdir/rc.mailman $pkgdir/etc/rc.d/mailman + chown -R mailman:mailman "$pkgdir"/{usr/lib/mailman,var/lib/mailman,etc/mailman/*} + chown http:mailman "$pkgdir"/var/lib/mailman/archives/private + chmod 2770 "$pkgdir"/var/lib/mailman/archives/private + chmod 2755 "$pkgdir"/usr/lib/mailman/cgi-bin/* + chmod 2755 "$pkgdir"/usr/lib/mailman/mail/mailman + cd "$srcdir" + # install initscripts + install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname" + # install systemd service + install -Dm 644 $pkgname.service \ + "$pkgdir/usr/lib/systemd/system/$pkgname.service" + # install profiles + install -Dm 755 $pkgname.profile.sh "$pkgdir/etc/profile.d/$pkgname.sh" + install -Dm 755 $pkgname.profile.csh "$pkgdir/etc/profile.d/$pkgname.csh" } + +# vim:set ts=2 sw=2 et: diff --git a/community/mailman/mailman.install b/community/mailman/mailman.install index ec85260a5..62a364e1a 100644 --- a/community/mailman/mailman.install +++ b/community/mailman/mailman.install @@ -1,31 +1,29 @@ +#!/bin/sh + ## arg 1: the new package version post_install() { - # Make sure the group and user "mailman" exists on this system and has the correct values - if grep -q "^mailman:" /etc/group &> /dev/null ; then - groupmod -g 80 -n mailman mailman &> /dev/null - else - groupadd -g 80 mailman &> /dev/null + if ! getent group mailman >/dev/null; then + groupadd -g 80 mailman >/dev/null fi - - if grep -q "^mailman:" /etc/passwd 2> /dev/null ; then - usermod -s /sbin/nologin -c "GNU Mailing List Manager" -d /usr/lib/mailman -u 80 -g mailman mailman &> /dev/null - else - useradd -s /sbin/nologin -c "GNU Mailing List Manager" -d /usr/lib/mailman -u 80 -g mailman -M -r mailman &> /dev/null - fi + if ! getent passwd mailman >/dev/null; then + useradd -s /sbin/nologin -c "GNU Mailing List Manager" -d /usr/lib/mailman \ + -u 80 -g mailman -M -r mailman >/dev/null + fi # check file permissions -# cd /usr/lib/mailman && bin/check_perms -f > /dev/null 2>&1 # -f applies fixes we should solve in the PKGBUILD cd /usr/lib/mailman && bin/check_perms > /dev/null } ## arg 1: the new package version ## arg 2: the old package version post_upgrade() { - post_install $1 + post_install "$1" } ## arg 1: the old package version pre_remove() { - userdel mailman &>/dev/null - groupdel mailman &>/dev/null || /bin/true + userdel mailman >/dev/null || true + groupdel mailman >/dev/null || true } + +# vim:set ts=2 sw=2 ft=sh et: diff --git a/community/mailman/mailman.profile.csh b/community/mailman/mailman.profile.csh new file mode 100644 index 000000000..c0a39edee --- /dev/null +++ b/community/mailman/mailman.profile.csh @@ -0,0 +1 @@ +[ -d /usr/lib/mailman/bin ] && setenv PATH ${PATH}:/usr/lib/mailman/bin diff --git a/community/mailman/mailman.profile.sh b/community/mailman/mailman.profile.sh new file mode 100644 index 000000000..51b69ebfb --- /dev/null +++ b/community/mailman/mailman.profile.sh @@ -0,0 +1,3 @@ +[ -d /usr/lib/mailman/bin ] && PATH=$PATH:/usr/lib/mailman/bin + +export PATH diff --git a/community/mailman/mailman.rc b/community/mailman/mailman.rc new file mode 100644 index 000000000..79c1cd661 --- /dev/null +++ b/community/mailman/mailman.rc @@ -0,0 +1,29 @@ +#!/bin/bash + +. /etc/rc.conf +. /etc/rc.d/functions + +MAILMANCTL=/usr/lib/mailman/bin/mailmanctl + +case "$1" in + start) + status 'Starting GNU Mailing List Manager' $MAILMANCTL -q start && + add_daemon ${0##*/} || exit 1 + ;; + stop) + status 'Stoping GNU Mailing List Manager' $MAILMANCTL -q stop && + rm_daemon ${0##*/} || exit 1 + ;; + reload) + status 'Reloading GNU Mailing List Manager' $MAILMANCTL -q restart + ;; + restart) + $0 stop && $0 start + ;; + *) + echo "usage: ${0##*/} {start|stop|restart|reload}" >&2 + ;; +esac + +: +# vim:set ts=2 sw=2 ft=sh et: diff --git a/community/mailman/mailman.service b/community/mailman/mailman.service new file mode 100644 index 000000000..633412dbc --- /dev/null +++ b/community/mailman/mailman.service @@ -0,0 +1,13 @@ +[Unit] +Description=GNU Mailing List Manager +After=network.target + +[Service] +ExecStart=/usr/lib/mailman/bin/mailmanctl -s start +ExecReload=/usr/lib/mailman/bin/mailmanctl restart +ExecStop=/usr/lib/mailman/bin/mailmanctl stop +StandardError=syslog +Type=forking + +[Install] +WantedBy=multi-user.target diff --git a/community/pcsclite/PKGBUILD b/community/pcsclite/PKGBUILD index 5434d920a..a5049f41e 100644 --- a/community/pcsclite/PKGBUILD +++ b/community/pcsclite/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 73085 2012-06-30 14:21:47Z giovanni $ +# $Id: PKGBUILD 74792 2012-08-05 10:29:48Z giovanni $ # Maintainer: Giovanni Scafora # Contributor: Daniel Plaza pkgname=pcsclite -pkgver=1.8.4 +pkgver=1.8.5 pkgrel=1 pkgdesc="PC/SC Architecture smartcard middleware library" arch=('i686' 'x86_64') @@ -12,9 +12,9 @@ license=('BSD') depends=('python2' 'systemd-tools') makedepends=('pkg-config') options=('!libtool' '!docs') -source=("https://alioth.debian.org/frs/download.php/3734/pcsc-lite-${pkgver}.tar.bz2" +source=("https://alioth.debian.org/frs/download.php/3741/pcsc-lite-${pkgver}.tar.bz2" 'pcscd') -md5sums=('3ef6b569128b15969adba25d80ced8d0' +md5sums=('c9d176f2f868814e836ff894983c537c' 'c97b6bce695222efb0f003d8e8369010') build() { -- cgit v1.2.3-54-g00ecf