summaryrefslogtreecommitdiff
path: root/community/couchdb
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2011-08-24 23:14:38 +0000
committerroot <root@rshg054.dnsready.net>2011-08-24 23:14:38 +0000
commitf53c212680c1817ef2337855ef8814dea6b07e4e (patch)
treec93db9dbaade4f2c86a8d550c237edf7d574f6da /community/couchdb
parent9254c2bc6500471b22eead69781ddef84f87e2bf (diff)
Wed Aug 24 23:14:37 UTC 2011
Diffstat (limited to 'community/couchdb')
-rw-r--r--community/couchdb/PKGBUILD15
-rw-r--r--community/couchdb/rc-script.patch91
2 files changed, 32 insertions, 74 deletions
diff --git a/community/couchdb/PKGBUILD b/community/couchdb/PKGBUILD
index 6d4d6d171..db519cae8 100644
--- a/community/couchdb/PKGBUILD
+++ b/community/couchdb/PKGBUILD
@@ -1,11 +1,11 @@
-# $Id: PKGBUILD 51045 2011-07-04 15:16:10Z spupykin $
+# $Id: PKGBUILD 54686 2011-08-23 09:50:02Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Vitaliy Berdinskikh ur6lad[at]i.ua
# Previous Contributor: Michael Fellinger <m.fellinger@gmail.com>
pkgname=couchdb
pkgver=1.1.0
-pkgrel=1.svn20110704
+pkgrel=1.svn20110823
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"
@@ -18,16 +18,17 @@ backup=('etc/couchdb/local.ini'
'etc/conf.d/couchdb'
'etc/logrotate.d/couchdb')
#source=("http://www.apache.org/dist/$pkgname/$pkgver/apache-$pkgname-$pkgver.tar.gz"
-source=("http://arch.p5n.pp.ru/~sergej/dl/apache-couchdb-$pkgver.svn20110704.tar.gz"
+source=("http://arch.p5n.pp.ru/~sergej/dl/apache-couchdb-$pkgver.svn20110823.tar.gz"
"rc-script.patch")
-md5sums=('a961f9047aa34df56ef19d6f6dce083b'
- 'e9b5595338efbdc1a5db13284a296612')
+md5sums=('b5a6e2dab45f19ef39f04a46ac146a0a'
+ '12171b097d2f98f4874e002bc1eabfc5')
build() {
cd "$srcdir/apache-$pkgname-$pkgver"
+ [ -x configure ] || ./bootstrap
sed -i 's|-ljs|-lmozjs185|' configure
- ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
+ [ -f Makefile ] || ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
make
patch etc/init/couchdb <$srcdir/rc-script.patch
}
@@ -39,8 +40,6 @@ package() {
install -Dm755 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
- sed -i 's|$COUCHDB -s|$COUCHDB $COUCHDB_OPTIONS -s|' $pkgdir/etc/rc.d/couchdb
- sed -i 's|su $COUCHDB_USER -c|su $COUCHDB_USER -s /bin/bash -c|' $pkgdir/etc/rc.d/couchdb
rm -rf $pkgdir/etc/default/ $pkgdir/var/run
}
diff --git a/community/couchdb/rc-script.patch b/community/couchdb/rc-script.patch
index d38f4dc6c..d7fd105c4 100644
--- a/community/couchdb/rc-script.patch
+++ b/community/couchdb/rc-script.patch
@@ -1,15 +1,14 @@
---- couchdb.org 2011-04-01 19:56:32.000000000 +0000
-+++ couchdb 2011-04-01 19:59:17.000000000 +0000
-@@ -1,4 +1,7 @@
+--- couchdb.orig 2011-08-23 13:13:45.000000000 +0400
++++ couchdb 2011-08-23 13:34:20.000000000 +0400
+@@ -1,4 +1,6 @@
-#!/bin/sh -e
+#!/bin/bash
-+#general config
+. /etc/rc.conf
+. /etc/rc.d/functions
# 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 +32,7 @@
+@@ -29,7 +31,7 @@
NAME=couchdb
SCRIPT_NAME=`basename $0`
COUCHDB=/usr/bin/couchdb
@@ -18,73 +17,33 @@
RUN_DIR=/var/run/couchdb
LSB_LIBRARY=/lib/lsb/init-functions
-@@ -61,8 +63,9 @@
+@@ -42,16 +44,14 @@
fi
- start_couchdb () {
-- # Start Apache CouchDB as a background process.
-+ stat_busy "Starting the CouchDB daemon"
+ log_daemon_msg () {
+- # Dummy function to be replaced by LSB library.
+-
+- echo $@
++ stat_busy $@
+ }
-+ [ -d /var/run/couchdb ] || mkdir -p /var/run/couchdb
- command="$COUCHDB -b"
- if test -n "$COUCHDB_STDOUT_FILE"; then
- command="$command -o $COUCHDB_STDOUT_FILE"
-@@ -79,38 +82,38 @@
- mkdir -p "$RUN_DIR"
- if test -n "$COUCHDB_USER"; then
- chown $COUCHDB_USER "$RUN_DIR"
-- if su $COUCHDB_USER -c "$command" > /dev/null; then
-- return $SCRIPT_OK
-+ if su $COUCHDB_USER -s /bin/bash -c "$command" > /dev/null; then
-+ stat_done
- else
-- return $SCRIPT_ERROR
-+ stat_fail
- fi
- else
- if $command > /dev/null; then
-- return $SCRIPT_OK
-+ stat_done
- else
-- return $SCRIPT_ERROR
-+ stat_fail
- fi
+ log_end_msg () {
+- # Dummy function to be replaced by LSB library.
+-
+ if test "$1" != "0"; then
+- echo "Error with $DESCRIPTION: $NAME"
++ stat_fail
++ else
++ stat_done
fi
+ return $1
}
-
- stop_couchdb () {
-- # Stop the running Apache CouchDB process.
-+ stat_busy "Stopping the CouchDB daemon"
-
- command="$COUCHDB -d"
- if test -n "$COUCHDB_OPTIONS"; then
+@@ -66,7 +66,7 @@
command="$command $COUCHDB_OPTIONS"
fi
if test -n "$COUCHDB_USER"; then
-- if su $COUCHDB_USER -c "$command" > /dev/null; then
-- return $SCRIPT_OK
-+ if su $COUCHDB_USER -s /bin/bash -c "$command" > /dev/null; then
-+ stat_done
+- if su $COUCHDB_USER -c "$command"; then
++ if su $COUCHDB_USER -s /bin/bash -c "$command"; then
+ return $SCRIPT_OK
else
-- return $SCRIPT_ERROR
-+ stat_fail
- fi
- else
- if $command > /dev/null; then
-- return $SCRIPT_OK
-+ stat_done
- else
-- return $SCRIPT_ERROR
-+ stat_fail
- fi
- fi
- }
-@@ -118,7 +121,7 @@
- display_status () {
- # Display the status of the running Apache CouchDB process.
-
-- $COUCHDB -s
-+ $COUCHDB $COUCHDB_OPTIONS -s
- }
-
- parse_script_option_list () {
+ return $SCRIPT_ERROR