diff options
author | Nicolás Reynolds <apoyosis@correo.inta.gob.ar> | 2011-12-18 12:10:42 -0300 |
---|---|---|
committer | Nicolás Reynolds <apoyosis@correo.inta.gob.ar> | 2011-12-18 12:10:42 -0300 |
commit | 2882e85db0e82645f4c7851bf52a06d9e190f4db (patch) | |
tree | ebe79bb1333f92946e7474b4d797f31ff6b04a8c | |
parent | 452fb86a5d288522a30d2be6b078171e863c34b2 (diff) |
social/seeks-0.4.0-1
Plus Tokyo* dependencies
-rw-r--r-- | social/seeks/PKGBUILD | 67 | ||||
-rw-r--r-- | social/seeks/install | 18 | ||||
-rw-r--r-- | social/seeks/logfile.patch | 29 | ||||
-rwxr-xr-x | social/seeks/seeks | 68 | ||||
-rw-r--r-- | social/seeks/seeks.conf.d | 6 | ||||
-rw-r--r-- | social/seeks/seeks.logrotate | 6 | ||||
-rw-r--r-- | social/tokyocabinet/PKGBUILD | 33 | ||||
-rwxr-xr-x | social/tokyotyrant/PKGBUILD | 33 | ||||
-rwxr-xr-x | social/tokyotyrant/tokyotyrant.conf | 21 | ||||
-rwxr-xr-x | social/tokyotyrant/tokyotyrant.rc | 41 |
10 files changed, 322 insertions, 0 deletions
diff --git a/social/seeks/PKGBUILD b/social/seeks/PKGBUILD new file mode 100644 index 000000000..2997e1be6 --- /dev/null +++ b/social/seeks/PKGBUILD @@ -0,0 +1,67 @@ +# Co-maintainer: Gitus < git at shroomrider dot com > +# Co-maintainer: Enjolras < 0enjolras0 at laposte dot net > + +pkgname=seeks +pkgver=0.4.0 +pkgrel=1 +pkgdesc="An open decentralized platform for collaborative search content" +arch=('i686' 'x86_64') +url="http://www.seeks-project.info" +license=('AGPL3') +backup=('etc/logrotate.d/seeks' + 'etc/conf.d/seeks' + 'etc/seeks/config') +depends=('curl' 'libevent' 'protobuf' 'tokyotyrant' 'opencv' 'icu') +makedepends=('docbook2x' 'pkg-config' ) +source=("http://downloads.sourceforge.net/project/seeks/hippy/seeks-0.4.0.tar.gz" + 'seeks' + 'seeks.conf.d' + 'seeks.logrotate' + 'logfile.patch') +install='install' + +build() { + cd "$srcdir/$pkgname-$pkgver" + + autoreconf -ivs + sed -i s/docbook2x-man/docbook2man/ ./configure + ./configure LDFLAGS="-Wl,--no-as-needed" \ + --prefix=/usr --sysconfdir=/etc \ + --enable-opencv --enable-httpserv-plugin --enable-image-websearch-plugin=yes \ + --enable-xslserializer-plugin --enable-personalization --enable-keepalive --enable-extended-host-patterns + + sed -i s/cxflann.h/cv.h/ src/plugins/img_websearch/ocvsurf.cpp + sed -i s/,--as-needed,/,/ config.status + + make + +} + +package() { + cd "$srcdir/$pkgname-$pkgver/src/" + + #Changing logdir and logfile options + #disable plugins cf and query-capture in config + patch -p0 < "$srcdir/logfile.patch" + + cd "$srcdir/$pkgname-$pkgver" + + make DESTDIR="$pkgdir" install + + install -D -m644 Licenses "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + install -m644 AGPL-3.txt "${pkgdir}/usr/share/licenses/${pkgname}/" + install -m644 BSD-yui.txt "${pkgdir}/usr/share/licenses/${pkgname}/" + install -D -m755 ../seeks "${pkgdir}"/etc/rc.d/seeks + install -D -m644 ../seeks.conf.d "${pkgdir}"/etc/conf.d/seeks + install -D -m600 ../seeks.logrotate "${pkgdir}"/etc/logrotate.d/seeks +} +md5sums=('dd80c832f80c34c392be5872239a8d9f' + '33e6da05cca492019e6aff39684aed26' + '52e7e06a28974547041012a1cf3207f3' + 'd1aba6739972239c6cd09178807e196f' + 'e352306f5396a1af4dfc81a18bfc5a71') +md5sums=('a2d0b6e7b91036883c0b327ead5e93c0' + '33e6da05cca492019e6aff39684aed26' + '52e7e06a28974547041012a1cf3207f3' + 'd1aba6739972239c6cd09178807e196f' + 'e352306f5396a1af4dfc81a18bfc5a71') diff --git a/social/seeks/install b/social/seeks/install new file mode 100644 index 000000000..35f383a3c --- /dev/null +++ b/social/seeks/install @@ -0,0 +1,18 @@ +post_install() { + getent group seeks >/dev/null || groupadd -r seeks + getent passwd seeks >/dev/null || useradd -r -c "Seeks daemon" -g seeks -M -d /var/run/seeks -s /bin/false seeks + passwd -l seeks &>/dev/null + touch var/log/seeks.log + chown seeks:log var/log/seeks.log + mkdir -p var/lib/seeks + touch var/lib/seeks/seeks.db + chown -R seeks:seeks var/lib/seeks +} + +pre_remove() { + getent passwd seeks &>/dev/null && userdel seeks >/dev/null + getent group seeks &>/dev/null && groupdel seeks >/dev/null + return 0 +} + + diff --git a/social/seeks/logfile.patch b/social/seeks/logfile.patch new file mode 100644 index 000000000..9f4ab9b02 --- /dev/null +++ b/social/seeks/logfile.patch @@ -0,0 +1,29 @@ +--- config 2011-10-21 10:42:20.000000000 +0200 ++++ config.patch 2011-11-17 18:48:48.914516206 +0100 +@@ -193,7 +193,7 @@ + # + # No trailing "/", please. + # +-logdir . ++logdir /var/log/ + # + # + # 2.4. logfile +@@ -239,7 +239,7 @@ + # Any log files must be writable by whatever user Seeks is + # being run as. + # +-logfile logfile ++logfile seeks.log + # + # + # 2.5. plugindir +@@ -377,7 +377,7 @@ + # Unset. This means the db is located in $HOME/.seeks/seeks_user.db + # as default location. + # +-# user-db-file /path/to/file.db ++user-db-file /var/lib/seeks/seeks.db + # + # 2.10. user-db-address + # ===================== diff --git a/social/seeks/seeks b/social/seeks/seeks new file mode 100755 index 000000000..01f34a432 --- /dev/null +++ b/social/seeks/seeks @@ -0,0 +1,68 @@ +#!/bin/bash + +daemon_name="seeks" + +. /etc/rc.conf +. /etc/rc.d/functions +. /etc/conf.d/$daemon_name + +get_pid() { + pidof -o %PPID $daemon_name +} + +case "$1" in + start) + stat_busy "Starting $daemon_name daemon" + + PID=$(get_pid) + if [ -z "$PID" ]; then + [ -f /var/run/$daemon_name.pid ] && rm -f /var/run/$daemon_name.pid + # RUN + $daemon_name $SEEKS_ARGS 2> /dev/null + # + if [ $? -gt 0 ]; then + stat_fail + exit 1 + else + echo $(get_pid) > /var/run/$daemon_name.pid + add_daemon $daemon_name + stat_done + fi + else + stat_fail + exit 1 + fi + ;; + + stop) + stat_busy "Stopping $daemon_name daemon" + PID=$(get_pid) + # KILL + [ ! -z "$PID" ] && kill $PID &> /dev/null + # + if [ $? -gt 0 ]; then + stat_fail + exit 1 + else + rm -f /var/run/$daemon_name.pid &> /dev/null + rm_daemon $daemon_name + stat_done + fi + ;; + + restart) + $0 stop + sleep 3 + $0 start + ;; + + status) + stat_busy "Checking $daemon_name status"; + ck_status $daemon_name + ;; + + *) + echo "usage: $0 {start|stop|restart|status}" +esac + +exit 0 diff --git a/social/seeks/seeks.conf.d b/social/seeks/seeks.conf.d new file mode 100644 index 000000000..21ed0526a --- /dev/null +++ b/social/seeks/seeks.conf.d @@ -0,0 +1,6 @@ +# +# Array for your vde config files +SEEKS_CONFIG="" + +# Parameters to be passed to seeks +SEEKS_ARGS="--daemon --user seeks $SEEKS_CONFIG" diff --git a/social/seeks/seeks.logrotate b/social/seeks/seeks.logrotate new file mode 100644 index 000000000..24b6f539f --- /dev/null +++ b/social/seeks/seeks.logrotate @@ -0,0 +1,6 @@ +/var/log/seeks.log { + missingok + notifempty + size 30k + create +} diff --git a/social/tokyocabinet/PKGBUILD b/social/tokyocabinet/PKGBUILD new file mode 100644 index 000000000..6e9b7969d --- /dev/null +++ b/social/tokyocabinet/PKGBUILD @@ -0,0 +1,33 @@ +# Maintainer: Mark Foxwell <fastfret79@archlinux.org.uk> +# Contributor: Nicolas Martyanoff <khaelin@gmail.com> + +pkgname=tokyocabinet +pkgver=1.4.47 +pkgrel=1 +pkgdesc="a modern implementation of DBM" +arch=('i686' 'x86_64') +url="http://fallabs.com/tokyocabinet/" +license=('LGPL') +makedepends=('gcc>=3.1' 'make' 'pkgconfig') +depends=('zlib' 'bzip2') +source=("http://fallabs.com/tokyocabinet/${pkgname}-${pkgver}.tar.gz") +md5sums=('3d94fe2aebf5d9ff0478ed895bc46fc9') + +build() { + cd "$srcdir/$pkgname-$pkgver" + ./configure --prefix=/usr --enable-off64 --enable-fastest + make +} + +# uncomment check routine if needed (can take ~5mins to run check) +check() { + cd "$srcdir/$pkgname-$pkgver" + make -k check +} + +package() { + cd "$srcdir/$pkgname-$pkgver" + make DESTDIR="$pkgdir/" install +} + +# vim:set ts=2 sw=2 et: diff --git a/social/tokyotyrant/PKGBUILD b/social/tokyotyrant/PKGBUILD new file mode 100755 index 000000000..74da4570c --- /dev/null +++ b/social/tokyotyrant/PKGBUILD @@ -0,0 +1,33 @@ +# # Maintainer: Angel Velasquez <angvp@archlinux.org> +# Contributor: Paul Sadauskas <psadauskas@gmail.com> + +pkgname=tokyotyrant +pkgver=1.1.41 +pkgrel=2 +pkgdesc="Network interface to TokyoCabinet" +arch=('i686' 'x86_64') +url="http://www.fallabs.com" +license=('LGPL') +makedepends=('gcc>=3.1' 'make' 'pkgconfig') +depends=('zlib' 'bzip2' 'tokyocabinet>=1.4.27') +source=("http://fallabs.com/$pkgname/$pkgname-$pkgver.tar.gz" + "tokyotyrant.rc" + "tokyotyrant.conf") + +md5sums=('a47e58897bd1cbbac173d5a66cc32ae3' + '3ed9229c9cfb8e1b3055b814d5038799' + '2558846ece69d1f265ee1ba5728c39cd') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + ./configure --prefix=/usr + make +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}" + make DESTDIR="$pkgdir" install + install -m 644 -D ${srcdir}/tokyotyrant.conf $pkgdir/etc/conf.d/ttserver + install -m 755 -D ${srcdir}/tokyotyrant.rc $pkgdir/etc/rc.d/ttserver +} + diff --git a/social/tokyotyrant/tokyotyrant.conf b/social/tokyotyrant/tokyotyrant.conf new file mode 100755 index 000000000..77c299a81 --- /dev/null +++ b/social/tokyotyrant/tokyotyrant.conf @@ -0,0 +1,21 @@ +# /etc/conf.d/ttserver: config file for /etc/init.d/ttserver + +# TCP port TokyoTyrant server should listen on +TYRANT_PORT="1978" + +# Location of the TokyoTyrant server database +# Also put addional options here, eg, #bnum +# See 'ttserver' man page +TYRANT_DB="/var/lib/tokyotyrant/tokyotyrant.tch" + +# Location of the TokyoTyrant server log file +TYRANT_LOG_FILE="/var/log/ttserver.log" + +# Location of the TokyoTyrant server PID file +TYRANT_PID_FILE="/var/run/ttserver.pid" + +# Pass extra options to TokyoTyrant server +# Example: TYRANT_EXTRA_OPTS="-ld" - enables logging of debug messages +# See the 'ttserver' man page for more +TYRANT_EXTRA_OPTS="" + diff --git a/social/tokyotyrant/tokyotyrant.rc b/social/tokyotyrant/tokyotyrant.rc new file mode 100755 index 000000000..eaecb0af0 --- /dev/null +++ b/social/tokyotyrant/tokyotyrant.rc @@ -0,0 +1,41 @@ +#!/bin/bash + +# source config +[ -f /etc/conf.d/ttserver ] && . /etc/conf.d/ttserver + +. /etc/rc.conf +. /etc/rc.d/functions + +case "$1" in + start) + stat_busy "Starting TokyoTyrant Server" + /usr/bin/ttserver ${TYRANT_EXTRA_OPTS} -dmn -pid ${TYRANT_PID_FILE} -log ${TYRANT_LOG_FILE} -port ${TYRANT_PORT} ${TYRANT_DB} + if [ $? -gt 0 ]; then + stat_fail + else + add_daemon ttserver + stat_done + fi + ;; + stop) + stat_busy "Stopping TokyoTyrant Server" + if [ -f $TYRANT_PID_FILE ]; then + pid=`cat "$TYRANT_PID_FILE"` + kill -TERM "$pid" + if [ $? -gt 0 ]; then + stat_fail + else + rm_daemon ttserver + stat_done + fi + fi + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac +exit 0 |