From b3288f94e625603d6b5b23740b721287e75eead7 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 27 Dec 2011 23:14:54 +0000 Subject: Tue Dec 27 23:14:54 UTC 2011 --- community/aria2/PKGBUILD | 6 ++-- community/calc/PKGBUILD | 11 ++++--- community/choqok/PKGBUILD | 4 +-- community/couchdb/PKGBUILD | 10 +++--- community/couchdb/rc-script.patch | 54 +++++++++++++++++++-------------- community/gluon/PKGBUILD | 3 +- community/stunnel/PKGBUILD | 18 ++++++++--- community/stunnel/stunnel.install | 32 +++++++++---------- community/stunnel/stunnel.rc.d | 30 +++++++++++------- community/stunnel/stunnel.tmpfiles.conf | 1 + 10 files changed, 96 insertions(+), 73 deletions(-) create mode 100644 community/stunnel/stunnel.tmpfiles.conf (limited to 'community') diff --git a/community/aria2/PKGBUILD b/community/aria2/PKGBUILD index 0fb4e866b..f0f41709f 100644 --- a/community/aria2/PKGBUILD +++ b/community/aria2/PKGBUILD @@ -4,15 +4,15 @@ # Contributor: Daniel J Griffiths pkgname=aria2 -pkgver=1.13.0 -pkgrel=2 +pkgver=1.14.0 +pkgrel=1 pkgdesc='Download utility that supports HTTP(S), FTP, BitTorrent, and Metalink' arch=('i686' 'x86_64') url='http://aria2.sourceforge.net/' license=('GPL') depends=('gnutls' 'libxml2' 'sqlite3' 'c-ares' 'ca-certificates') source=("http://downloads.sourceforge.net/aria2/aria2-${pkgver}.tar.bz2") -md5sums=('b86a5bd4a94e465a58656f71b48c90b9') +md5sums=('577b3b5f19c28de4451cd1a32de76eeb') build() { cd aria2-${pkgver} diff --git a/community/calc/PKGBUILD b/community/calc/PKGBUILD index 911d7facb..129fa3fc9 100644 --- a/community/calc/PKGBUILD +++ b/community/calc/PKGBUILD @@ -1,17 +1,18 @@ -# $Id: PKGBUILD 37217 2011-01-12 14:33:47Z spupykin $ +# $Id: PKGBUILD 61256 2011-12-26 12:59:57Z spupykin $ # Maintainer: Sergej Pupykin # Contributor: Sergej Pupykin pkgname=calc -pkgver=2.12.4.3 +pkgver=2.12.4.4 pkgrel=1 pkgdesc="console calculator" arch=(i686 x86_64) url="http://www.isthe.com/chongo/tech/comp/calc/" license=('GPL') depends=(glibc) -source=(http://switch.dl.sf.net/sourceforge/calc/calc-$pkgver.tar.bz2) -md5sums=('d95dccde71cc8d920af0f8375e85e9c8') +#source=(http://switch.dl.sf.net/sourceforge/calc/calc-$pkgver.tar.bz2) +source=(http://www.isthe.com/chongo/src/calc/calc-$pkgver.tar.bz2) +md5sums=('1ad16a9304df7137cd8626a1f50b6aae') build() { cd $srcdir/calc-$pkgver @@ -53,5 +54,5 @@ EOF make -j1 make T=$pkgdir install - mv $pkgdir/usr/bin/cscript $startdir/pkg/usr/share/calc/ + mv $pkgdir/usr/bin/cscript $pkgdir/usr/share/calc/ } diff --git a/community/choqok/PKGBUILD b/community/choqok/PKGBUILD index 558018682..9109daf32 100644 --- a/community/choqok/PKGBUILD +++ b/community/choqok/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 58036 2011-11-05 17:31:00Z plewis $ +# $Id: PKGBUILD 61252 2011-12-26 11:59:59Z andrea $ # Maintainer: Peter Richard Lewis # Contributor: Andrea Scarpino # Contributor: Emanuele Rossi @@ -6,7 +6,7 @@ pkgname=choqok pkgver=1.2 -pkgrel=2 +pkgrel=3 pkgdesc="A Twitter/identi.ca/laconica client for KDE" url="http://choqok.gnufolks.org/" license=('GPL') diff --git a/community/couchdb/PKGBUILD b/community/couchdb/PKGBUILD index a9d309c7b..8c405a625 100644 --- a/community/couchdb/PKGBUILD +++ b/community/couchdb/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 58574 2011-11-15 15:35:36Z spupykin $ +# $Id: PKGBUILD 61260 2011-12-26 21:33:37Z spupykin $ # Maintainer: Sergej Pupykin # Contributor: Vitaliy Berdinskikh ur6lad[at]i.ua # Previous Contributor: Michael Fellinger pkgname=couchdb pkgver=1.2.0 -pkgrel=1git20111115 +pkgrel=2git20111115 pkgdesc="A document-oriented database that can be queried and indexed in a MapReduce fashion using JSON" arch=('i686' 'x86_64') url="http://couchdb.apache.org" @@ -21,7 +21,7 @@ backup=('etc/couchdb/local.ini' source=("http://arch.p5n.pp.ru/~sergej/dl/apache-couchdb-$pkgver.git20111115.tar.gz" "rc-script.patch") md5sums=('b4236a36a473e3a1c81e7548de194c47' - '559b5e1483c3fb3e4327a9c58181a46c') + '8a3b1a1ff98a6411827ad991db7a355b') build() { cd "$srcdir/apache-$pkgname-$pkgver" @@ -30,14 +30,14 @@ build() { sed -i 's|-ljs|-lmozjs185|' configure [ -f Makefile ] || ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var make - patch etc/init/couchdb <$srcdir/rc-script.patch + patch -R etc/init/couchdb <$srcdir/rc-script.patch } package() { cd "$srcdir/apache-$pkgname-$pkgver" make DESTDIR="$pkgdir" install - install -Dm755 etc/default/couchdb $pkgdir/etc/conf.d/couchdb + install -Dm644 etc/default/couchdb $pkgdir/etc/conf.d/couchdb sed -i 's|\(CONFIGURATION_FILE=/etc/\)default\(/couchdb\)|\1conf.d\2|' $pkgdir/etc/rc.d/couchdb sed -i 's|\(COUCHDB_OPTIONS=\)|\1"-p /var/run/couchdb/couchdb.pid"|' $pkgdir/etc/conf.d/couchdb diff --git a/community/couchdb/rc-script.patch b/community/couchdb/rc-script.patch index ef7be39df..1dd723ffc 100644 --- a/community/couchdb/rc-script.patch +++ b/community/couchdb/rc-script.patch @@ -1,40 +1,40 @@ ---- couchdb.orig 2011-11-15 19:06:16.000000000 +0400 -+++ couchdb 2011-11-15 19:08:24.000000000 +0400 -@@ -1,4 +1,6 @@ --#!/bin/sh -e -+#!/bin/bash -+. /etc/rc.conf -+. /etc/rc.d/functions +--- couchdb 2011-12-27 01:21:59.000000000 +0400 ++++ couchdb.my 2011-12-27 01:21:18.000000000 +0400 +@@ -1,6 +1,4 @@ +-#!/bin/bash +-. /etc/rc.conf +-. /etc/rc.d/functions ++#!/bin/sh -e # Licensed under the Apache License, Version 2.0 (the "License"); you may not # use this file except in compliance with the License. You may obtain a copy of -@@ -29,7 +31,7 @@ +@@ -31,7 +29,7 @@ NAME=couchdb SCRIPT_NAME=`basename $0` COUCHDB=/usr/bin/couchdb --CONFIGURATION_FILE=/etc/default/couchdb -+CONFIGURATION_FILE=/etc/conf.d/couchdb +-CONFIGURATION_FILE=/etc/conf.d/couchdb ++CONFIGURATION_FILE=/etc/default/couchdb RUN_DIR=/var/run/couchdb LSB_LIBRARY=/lib/lsb/init-functions -@@ -42,16 +44,14 @@ +@@ -44,14 +42,16 @@ fi log_daemon_msg () { -- # Dummy function to be replaced by LSB library. -- -- echo $@ -+ stat_busy $@ +- stat_busy $@ ++ # Dummy function to be replaced by LSB library. ++ ++ echo $@ } log_end_msg () { -- # Dummy function to be replaced by LSB library. -- ++ # Dummy function to be replaced by LSB library. ++ if test "$1" != "0"; then -- echo "Error with $DESCRIPTION: $NAME" -+ stat_fail -+ else -+ stat_done +- stat_fail +- else +- stat_done ++ echo "Error with $DESCRIPTION: $NAME" fi return $1 } @@ -42,8 +42,16 @@ command="$command $COUCHDB_OPTIONS" fi if test -n "$COUCHDB_USER"; then -- if su $COUCHDB_USER -c "$command"; then -+ if su $COUCHDB_USER -s /bin/bash -c "$command"; then +- if su $COUCHDB_USER -s /bin/bash -c "$command"; then ++ if su $COUCHDB_USER -c "$command"; then return $SCRIPT_OK else return $SCRIPT_ERROR +@@ -84,7 +84,6 @@ + # Start Apache CouchDB as a background process. + + mkdir -p "$RUN_DIR" +- chown -R $COUCHDB_USER "$RUN_DIR" + command="$COUCHDB -b" + if test -n "$COUCHDB_STDOUT_FILE"; then + command="$command -o $COUCHDB_STDOUT_FILE" diff --git a/community/gluon/PKGBUILD b/community/gluon/PKGBUILD index 88aaacd92..b16442551 100644 --- a/community/gluon/PKGBUILD +++ b/community/gluon/PKGBUILD @@ -1,10 +1,11 @@ +# $Id: PKGBUILD 61254 2011-12-26 12:01:45Z andrea $ # Maintainer: Sven-Hendrik Haase # Contributor: Ivan Sichmann Freitas pkgname=gluon pkgver=0.71.0 _pkgver=0.71 -pkgrel=2 +pkgrel=3 pkgdesc="A free and open source platform for creating and distributing games" arch=('i686' 'x86_64') url="http://gluon.gamingfreedom.org/" diff --git a/community/stunnel/PKGBUILD b/community/stunnel/PKGBUILD index 17296a913..a501645fb 100644 --- a/community/stunnel/PKGBUILD +++ b/community/stunnel/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 60289 2011-12-08 23:55:42Z lfleischer $ +# $Id: PKGBUILD 61258 2011-12-26 17:36:12Z dreisner $ # Maintainer: Kaiting Chen # Contributor: Daniel J Griffiths # Contributor: Kevin Piche pkgname=stunnel pkgver=4.50 -pkgrel=1 +pkgrel=3 pkgdesc="A program that allows you to encrypt arbitrary TCP connections inside SSL" arch=('i686' 'x86_64') url="http://www.stunnel.org" @@ -15,11 +15,14 @@ install=$pkgname.install options=('!libtool') source=("ftp://ftp.stunnel.org/stunnel/$pkgname-$pkgver.tar.gz"{,.asc} 'Makefile.patch' - 'stunnel.rc.d') + 'stunnel.rc.d' + 'stunnel.tmpfiles.conf') + md5sums=('d68b4565294496a8bdf23c728a679f53' 'ea9e85daef0cc96ce21649901b3514f7' 'f15398497e10e080c2406d2fc541660c' - 'cb647c71ff4cb1e035b6e515d5f13ebf') + 'cb647c71ff4cb1e035b6e515d5f13ebf' + '2e065a39998e57727ee79887bbd1751e') build() { cd "$srcdir/$pkgname-$pkgver" @@ -46,9 +49,14 @@ package() { install -Dm644 tools/stunnel.cnf "$pkgdir/etc/stunnel/stunnel.cnf" install -Dm755 "$srcdir/stunnel.rc.d" "$pkgdir/etc/rc.d/stunnel" + install -Dm644 "$srcdir/stunnel.tmpfiles.conf" "$pkgdir/usr/lib/tmpfiles.d/stunnel.conf" + + # move systemd service into place + install -dm755 "$pkgdir/lib/systemd/system" + mv "tools/stunnel.service" "$pkgdir/lib/systemd/system/" sed -e "s:/usr/var/lib/stunnel/:/var/run/stunnel:g" \ -e "s:/usr/etc/stunnel/:/etc/stunnel/:g" \ - -e "s:nobody:stunnel:g" -e "s:nogroup:stunnel:g" \ + -e "s:no\(body\|group\):stunnel:g" \ -i "$pkgdir/etc/stunnel/stunnel.conf-sample" } diff --git a/community/stunnel/stunnel.install b/community/stunnel/stunnel.install index f7bbbffcb..d9998e4da 100644 --- a/community/stunnel/stunnel.install +++ b/community/stunnel/stunnel.install @@ -1,35 +1,31 @@ post_install() { # add stunnel group - if [ ! `grep stunnel /etc/group` ]; then - groupadd -g 16 stunnel &>/dev/null + if ! getent group stunnel >/dev/null 2>&1; then + groupadd -g 16 stunnel fi # add stunnel user - id stunnel &>/dev/null || \ + if ! getent passwd stunnel >/dev/null 2>&1; then useradd -u 16 -g stunnel -d /var/run/stunnel -s /bin/false stunnel - + fi + # create chroot dir if necessary. if [ ! -d /var/run/stunnel ]; then - install -d -m 770 -o stunnel -g stunnel /var/run/stunnel + install -dm770 -o stunnel -g stunnel /var/run/stunnel fi - - cat << EOF - -NOTE ----- -Copy /etc/stunnel/stunnel.conf-sample to /etc/stunnel/stunnel.conf -& edit it to match your setup before invoking the daemon (/etc/rc.d/stunnel). - -EOF } post_upgrade() { - post_install $1 + post_install "$@" } pre_remove() { # remove users & groups - userdel stunnel &> /dev/null - groupdel stunnel &> /dev/null - rm -rf /var/run/stunnel + if getent passwd stunnel >/dev/null 2>&1; then + userdel stunnel + fi + + if getent group stunnel >/dev/null 2>&1; then + groupdel stunnel + fi } diff --git a/community/stunnel/stunnel.rc.d b/community/stunnel/stunnel.rc.d index 15816abe8..ee67e20ce 100644 --- a/community/stunnel/stunnel.rc.d +++ b/community/stunnel/stunnel.rc.d @@ -3,26 +3,35 @@ . /etc/rc.conf . /etc/rc.d/functions -PID=`pidof -o %PPID /usr/bin/stunnel` +pidfile=/var/run/stunnel.pid +if [[ -r $pidfile ]]; then + read -r PID < "$pidfile" + if [[ $PID && ! -d /proc/$PID ]]; then + # stale pidfile + unset PID + rm -f "$pidfile" + fi +fi + case "$1" in start) stat_busy "Starting stunnel" - [ -z "$PID" ] && /usr/bin/stunnel - if [ $? -gt 0 ]; then - stat_fail - else + if [[ -z $PID ]] && /usr/bin/stunnel; then add_daemon stunnel stat_done + else + stat_fail + exit 1 fi ;; stop) stat_busy "Stopping stunnel" - [ ! -z "$PID" ] && kill $PID &> /dev/null - if [ $? -gt 0 ]; then - stat_fail - else + if [[ $PID ]] && kill $PID &>/dev/null; then rm_daemon stunnel stat_done + else + stat_fail + exit 1 fi ;; restart) @@ -31,6 +40,5 @@ case "$1" in $0 start ;; *) - echo "usage: $0 {start|stop|restart}" + echo "usage: $0 {start|stop|restart}" esac -exit 0 diff --git a/community/stunnel/stunnel.tmpfiles.conf b/community/stunnel/stunnel.tmpfiles.conf new file mode 100644 index 000000000..f118e68a0 --- /dev/null +++ b/community/stunnel/stunnel.tmpfiles.conf @@ -0,0 +1 @@ +d /var/run/stunnel 0770 stunnel stunnel - -- cgit v1.2.3-54-g00ecf