aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2014-01-10 14:38:18 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2014-01-10 14:38:36 +0100
commitee62f8dd57632de462faf434a4f12ec359290980 (patch)
treeda705b33f45b64b6b356e6bc60242f3d4b37765e
parent46006eb7eae54ab1f3cc5b76c0b025b5d80731ab (diff)
downloadoverlay-ee62f8dd57632de462faf434a4f12ec359290980.tar.gz
overlay-ee62f8dd57632de462faf434a4f12ec359290980.tar.xz
overlay-ee62f8dd57632de462faf434a4f12ec359290980.zip
net-im/spectrum: remove ebuild
use this instead: http://spectrum.im/documentation/installation/gentoo.html
-rw-r--r--metadata/cache/net-im/spectrum-1.4.822
-rw-r--r--metadata/cache/net-im/spectrum-1.4.8-r122
-rw-r--r--net-im/spectrum/Manifest7
-rw-r--r--net-im/spectrum/files/spectrum.cfg151
-rw-r--r--net-im/spectrum/files/spectrum.confd7
-rw-r--r--net-im/spectrum/files/spectrum.initd22
-rw-r--r--net-im/spectrum/files/spectrum.symlink.cfg151
-rw-r--r--net-im/spectrum/spectrum-1.4.8-r1.ebuild131
-rw-r--r--net-im/spectrum/spectrum-1.4.8.ebuild137
9 files changed, 0 insertions, 650 deletions
diff --git a/metadata/cache/net-im/spectrum-1.4.8 b/metadata/cache/net-im/spectrum-1.4.8
deleted file mode 100644
index 9898a4a..0000000
--- a/metadata/cache/net-im/spectrum-1.4.8
+++ /dev/null
@@ -1,22 +0,0 @@
-dev-libs/libev >=dev-libs/poco-1.3.3[mysql?,sqlite?] dev-python/xmpppy media-gfx/imagemagick[cxx] >=net-im/pidgin-2.6.0 >=net-libs/gloox-1.0 dev-util/cmake sys-devel/gettext >=dev-util/cmake-2.8.4 userland_GNU? ( >=sys-apps/findutils-4.4.0 )
-dev-libs/libev >=dev-libs/poco-1.3.3[mysql?,sqlite?] dev-python/xmpppy media-gfx/imagemagick[cxx] >=net-im/pidgin-2.6.0 >=net-libs/gloox-1.0
-0
-http://spectrum.im/attachments/download/43/spectrum-1.4.8.tar.gz
-
-http://spectrum.im
-GPL-2
-XMPP transport/gateway
-~amd64 ~x86
-base cmake-utils eutils flag-o-matic multilib toolchain-funcs user
-mysql sqlite symlinks tools staticport
-
-
-
-2
-
-compile configure install postinst prepare setup test unpack
-
-
-
-
-
diff --git a/metadata/cache/net-im/spectrum-1.4.8-r1 b/metadata/cache/net-im/spectrum-1.4.8-r1
deleted file mode 100644
index 8e6d1c9..0000000
--- a/metadata/cache/net-im/spectrum-1.4.8-r1
+++ /dev/null
@@ -1,22 +0,0 @@
->=dev-libs/poco-1.3.3[mysql?,sqlite?] media-gfx/imagemagick[cxx] >=net-im/pidgin-2.6.0 >=net-libs/gloox-1.0 dev-python/xmpppy dev-libs/libev <dev-lang/python-3 sys-devel/gettext dev-util/cmake >=dev-util/cmake-2.8.4 userland_GNU? ( >=sys-apps/findutils-4.4.0 )
->=dev-libs/poco-1.3.3[mysql?,sqlite?] media-gfx/imagemagick[cxx] >=net-im/pidgin-2.6.0 >=net-libs/gloox-1.0 dev-python/xmpppy dev-libs/libev <dev-lang/python-3
-0
-http://spectrum.im/attachments/download/43/spectrum-1.4.8.tar.gz
-
-http://spectrum.im
-GPL-2
-Spectrum is an XMPP transport/gateway
-~amd64 ~x86
-base cmake-utils eutils flag-o-matic multilib toolchain-funcs user
-mysql sqlite symlinks tools staticport
-
-
-
-4
-
-compile configure install prepare setup test unpack
-
-
-
-
-
diff --git a/net-im/spectrum/Manifest b/net-im/spectrum/Manifest
deleted file mode 100644
index ece7db4..0000000
--- a/net-im/spectrum/Manifest
+++ /dev/null
@@ -1,7 +0,0 @@
-AUX spectrum.cfg 4770 RMD160 1dfba51b4c4ee6f991b3082a8cf4f4b0234cf8b0 SHA1 c321c107ac4c5d5dfe239bc6e03e46b405b2a72a SHA256 c29eb5bed5776bdce171eb303e0e6815b60dc3c61f2a311492204337145cbe85
-AUX spectrum.confd 157 RMD160 dec3aebc84f379e42faf6760dc0524b960541f4c SHA1 7894af53b8aebf457a4d5de81ffee35843563d01 SHA256 5f1c7a7c614ffb15ba64caadd560088cf3a8032f3973489a31f65c89ce286c85
-AUX spectrum.initd 548 RMD160 ea5bbfdec4c71f1e6bbf3ef04b0b0b961803bbee SHA1 2cf0114bb19c22a92bd78e7396419472c4da6d17 SHA256 8e6d6c07ecf14c458abe9ab42d959b333a95a6dc199e0839b8df63bd8b404d01
-AUX spectrum.symlink.cfg 4855 RMD160 8e4cf7ab0237dfff0f713a32e37d2630af777273 SHA1 22a17ecc225fe6a9237947c35126b32c0f3a9447 SHA256 3dfb88f041ae3a835241ea4c128ce6958a95f944534349aebdb56d9d74efe1f3
-DIST spectrum-1.4.8.tar.gz 239725 RMD160 859c1d0f6f1c4d535bbada13c1c11f2b4550805a SHA1 9323f8f89eb1f84e36e1d64845741cbebbf0d249 SHA256 40045139cdeb7fbc085fe80bb8124b518bb57520fbb644bc50b132de8cebc3cc
-EBUILD spectrum-1.4.8-r1.ebuild 3511 RMD160 3c8e80fd6e6af01ea74ddca0911212edb2ed4546 SHA1 6bac125036ffe1305bfa2b0733f7a2e24a92b037 SHA256 0a64dd42a8518c625fa0d12ee5d853ccf03069189d0b6d08bd4de4858fcdfba7
-EBUILD spectrum-1.4.8.ebuild 3663 RMD160 8e51a36b4846ea601c263691a47c2ef606233a4b SHA1 d9a64f610188282268f1b237675b4a06bcaa9566 SHA256 b8895c5e673d7ceb9adfb7676fa2c8313abacf5e51c215b56c5c2cdc7939d2f0
diff --git a/net-im/spectrum/files/spectrum.cfg b/net-im/spectrum/files/spectrum.cfg
deleted file mode 100644
index c512ef4..0000000
--- a/net-im/spectrum/files/spectrum.cfg
+++ /dev/null
@@ -1,151 +0,0 @@
-[service]
-# enable this spectrum instance
-enable=1
-
-# one of: aim, facebook, gg, icq, irc, msn, myspace, qq, simple, xmpp, yahoo
-protocol=S2P
-
-# component ip
-server=127.0.0.1
-
-# if use_proxy is 1, the http_proxy env var will be used as the proxy server
-# for example export http_proxy="http://user:passwd@your.proxy.server:port/"
-use_proxy=0
-
-# component JID
-jid=S2P.example.com
-
-# component secret
-password=secret
-
-# component port
-port=5347
-
-config_interface = /var/run/spectrum/S2P.sock
-
-# IP:port where filetransfer proxy binds to. This has to be public IP.
-#filetransfer_bind_address=192.0.2.1:12345
-
-# IP:port which will be sent in filetransfer request as stream host.
-#filetransfer_public_address=192.0.2.1:12345
-
-# admin JIDs - Jabber IDs of transport administrators who have access to admin adhoc commands
-# separated by semicolons
-#admins=admin@example.com;foo@bar.cz
-
-# directory where downloaded files will be saved
-filetransfer_cache=/var/lib/spectrum/S2P/filetransfer_cache
-
-# URL used to acces filestransfer_cache directory from the web.
-filetransfer_web=http://example.com/files/
-
-# name of transport (this will appear in service discovery)
-name=My S2P Transport
-
-# default language
-language=en
-
-# transport features separated by semicolons
-# combination of: avatars, chatstate, filetransfer
-# if commented, all features will be used
-# This variable is DEPRECATED and will be removed in future versions. Use [features] instead.
-#transport_features = avatars;chatstate;filetransfer
-
-# if vip_mode is 1, users are divided to 2 groups according to 'vip' database field
-vip_mode=0
-
-# if vip_mode is 1, you can set transport to be availabe only for VIP users by setting only_for_vip to 1.
-only_for_vip=0
-
-# if vip_mode is 1 and only_for_vip is 1, users can connect from these servers even they are not VIP.
-# This feature is useful, if you want to enable transport only for users from your server, but also want
-# to give access to VIP users from other servers (for example from GTalk)
-# seperated by semicolons
-#allowed_servers=localhost
-
-# transport features separated by semicolons which will be used for VIP users.
-# combination of: avatars, chatstate, filetransfer
-# if commented, all features will be used
-# This variable is DEPRECATED and will be removed in future versions. Use [vip-features] instead.
-#vip_features = avatars;chatstate;filetransfer
-
-# pid file
-pid_file=/var/run/spectrum/S2P.pid
-
-# require_tls to connect legacy network
-#require_tls=false
-
-# Eventloop used by Spectrum. Allows to change default use of poll to epoll,
-# which should be faster and handles more connections better.
-# WARNING: some 3rd party libpurple protocol plugins are not prepared to be
-# used with different eventloop, but protocols included in libpurple by default
-# works OK.
-#eventloop=glib
-
-[registration]
-# Set to 0 to disable transport registration to everyone except
-# people from host from allowed_servers list.
-#enable_public_registration=1
-
-# You can override username registered by transport user. This is useful
-# for example if you want to let users to register only their Facebook name
-# and internally connect them to facebook_name@chat.facebook.com.
-# $username variable is replaced by username which has been registered
-# by particular user.
-#username_mask = $username@chat.facebook.com
-
-# This option allows you to white-list newly created accounts according
-# to regexp. for example allowed_usernames=*.\.gmail\.com$ will allow only
-# GTalk users to register. If you use username_mask, then username_mask is
-# applied before this option.
-#allowed_usernames=regexp
-
-# Label used to described username field in registration form
-#username_label = Facebook username
-
-# This variable overrides default instructions text in registration form.
-#instructions = Type your Facebook name here:
-
-# Transport features, all features are enabled by default.
-[features]
-#filetransfer=1
-#avatars=1
-#chatstates=1
-#statistics=1
-
-# Transport features for VIP users, all features are enabled by default.
-[vip-features]
-#filetransfer=1
-#avatars=1
-#chatstates=1
-
-[logging]
-# log file, needs to be unique for each spectrum instance
-log_file=/var/log/spectrum/S2P.log
-
-# log areas
-# combination of: xml, purple
-log_areas=xml;purple
-
-[database]
-# mysql or sqlite
-type=sqlite
-
-# hostname (not needed for sqlite)
-#host=localhost
-
-# username (not needed for sqlite)
-#user=user
-
-# password (not needed for sqlite)
-#password=password
-# sqlite: set path to database file here
-# mysql: set to name of database
-database=/var/lib/spectrum/S2P/database/S2P.sqlite
-# table prefix for multiple transport instances sharing the same database
-#prefix=S2P_
-
-[purple]
-# avatar, vcard, roster storage
-# needs to be unique for each spectrum instance
-userdir=/var/lib/spectrum/S2P/userdir
diff --git a/net-im/spectrum/files/spectrum.confd b/net-im/spectrum/files/spectrum.confd
deleted file mode 100644
index fec3b06..0000000
--- a/net-im/spectrum/files/spectrum.confd
+++ /dev/null
@@ -1,7 +0,0 @@
-# /etc/conf.d/spectrum.S2P: config file for spectrum S2P transport
-
-# Configfile
-CONFFILE="/etc/spectrum/S2P.cfg"
-
-# PID
-PIDFILE="/var/run/spectrum/S2P.pid"
diff --git a/net-im/spectrum/files/spectrum.initd b/net-im/spectrum/files/spectrum.initd
deleted file mode 100644
index f5ce89b..0000000
--- a/net-im/spectrum/files/spectrum.initd
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-depend() {
- need net
- use jabber-server
-}
-
-start() {
- ebegin "Starting S2P Spectrum Transport"
- start-stop-daemon --start --pidfile ${PIDFILE} \
- --chuid jabber:jabber --exec /usr/bin/spectrum -- ${CONFFILE}
- eend $?
-}
-
-stop() {
- ebegin "Stopping S2P Spectrum Transport"
- start-stop-daemon --stop --quiet --pidfile ${PIDFILE}
- eend $?
-}
diff --git a/net-im/spectrum/files/spectrum.symlink.cfg b/net-im/spectrum/files/spectrum.symlink.cfg
deleted file mode 100644
index 514fcbd..0000000
--- a/net-im/spectrum/files/spectrum.symlink.cfg
+++ /dev/null
@@ -1,151 +0,0 @@
-[service]
-# enable this spectrum instance
-enable=1
-
-# one of: aim, facebook, gg, icq, irc, msn, myspace, qq, simple, xmpp, yahoo
-protocol=$filename:protocol
-
-# component ip
-server=127.0.0.1
-
-# if use_proxy is 1, the http_proxy env var will be used as the proxy server
-# for example export http_proxy="http://user:passwd@your.proxy.server:port/"
-use_proxy=0
-
-# component JID
-jid=$protocol.example.com
-
-# component secret
-password=secret
-
-# component port
-port=$filename:port
-
-config_interface = /var/run/spectrum/$protocol.sock
-
-# IP:port where filetransfer proxy binds to. This has to be public IP.
-#filetransfer_bind_address=192.0.2.1:$port
-
-# IP:port which will be sent in filetransfer request as stream host.
-#filetransfer_public_address=192.0.2.1:$port
-
-# admin JIDs - Jabber IDs of transport administrators who have access to admin adhoc commands
-# separated by semicolons
-#admins=admin@example.com;foo@bar.cz
-
-# directory where downloaded files will be saved
-filetransfer_cache=/var/lib/spectrum/$protocol/filetransfer_cache
-
-# URL used to acces filestransfer_cache directory from the web.
-filetransfer_web=http://example.com/files/
-
-# name of transport (this will appear in service discovery)
-name=My $protocol Transport
-
-# default language
-language=en
-
-# transport features separated by semicolons
-# combination of: avatars, chatstate, filetransfer
-# if commented, all features will be used
-# This variable is DEPRECATED and will be removed in future versions. Use [features] instead.
-#transport_features = avatars;chatstate;filetransfer
-
-# if vip_mode is 1, users are divided to 2 groups according to 'vip' database field
-vip_mode=0
-
-# if vip_mode is 1, you can set transport to be availabe only for VIP users by setting only_for_vip to 1.
-only_for_vip=0
-
-# if vip_mode is 1 and only_for_vip is 1, users can connect from these servers even they are not VIP.
-# This feature is useful, if you want to enable transport only for users from your server, but also want
-# to give access to VIP users from other servers (for example from GTalk)
-# seperated by semicolons
-#allowed_servers=localhost
-
-# transport features separated by semicolons which will be used for VIP users.
-# combination of: avatars, chatstate, filetransfer
-# if commented, all features will be used
-# This variable is DEPRECATED and will be removed in future versions. Use [vip-features] instead.
-#vip_features = avatars;chatstate;filetransfer
-
-# pid file
-pid_file=/var/run/spectrum/$protocol.pid
-
-# require_tls to connect legacy network
-#require_tls=false
-
-# Eventloop used by Spectrum. Allows to change default use of poll to epoll,
-# which should be faster and handles more connections better.
-# WARNING: some 3rd party libpurple protocol plugins are not prepared to be
-# used with different eventloop, but protocols included in libpurple by default
-# works OK.
-#eventloop=glib
-
-[registration]
-# Set to 0 to disable transport registration to everyone except
-# people from host from allowed_servers list.
-#enable_public_registration=1
-
-# You can override username registered by transport user. This is useful
-# for example if you want to let users to register only their Facebook name
-# and internally connect them to facebook_name@chat.facebook.com.
-# $username variable is replaced by username which has been registered
-# by particular user.
-#username_mask = $username@chat.facebook.com
-
-# This option allows you to white-list newly created accounts according
-# to regexp. for example allowed_usernames=*.\.gmail\.com$ will allow only
-# GTalk users to register. If you use username_mask, then username_mask is
-# applied before this option.
-#allowed_usernames=regexp
-
-# Label used to described username field in registration form
-#username_label = Facebook username
-
-# This variable overrides default instructions text in registration form.
-#instructions = Type your Facebook name here:
-
-# Transport features, all features are enabled by default.
-[features]
-#filetransfer=1
-#avatars=1
-#chatstates=1
-#statistics=1
-
-# Transport features for VIP users, all features are enabled by default.
-[vip-features]
-#filetransfer=1
-#avatars=1
-#chatstates=1
-
-[logging]
-# log file, needs to be unique for each spectrum instance
-log_file=/var/log/spectrum/$protocol.log
-
-# log areas
-# combination of: xml, purple
-log_areas=xml;purple
-
-[database]
-# mysql or sqlite
-type=sqlite
-
-# hostname (not needed for sqlite)
-#host=localhost
-
-# username (not needed for sqlite)
-#user=user
-
-# password (not needed for sqlite)
-#password=password
-# sqlite: set path to database file here
-# mysql: set to name of database
-database=/var/lib/spectrum/$protocol/database/$protocol.sqlite
-# table prefix for multiple transport instances sharing the same database
-#prefix=$protocol_
-
-[purple]
-# avatar, vcard, roster storage
-# needs to be unique for each spectrum instance
-userdir=/var/lib/spectrum/$protocol/userdir
diff --git a/net-im/spectrum/spectrum-1.4.8-r1.ebuild b/net-im/spectrum/spectrum-1.4.8-r1.ebuild
deleted file mode 100644
index 2e32141..0000000
--- a/net-im/spectrum/spectrum-1.4.8-r1.ebuild
+++ /dev/null
@@ -1,131 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI="4"
-
-inherit cmake-utils
-
-DESCRIPTION="Spectrum is an XMPP transport/gateway"
-HOMEPAGE="http://spectrum.im"
-
-SRC_URI="http://spectrum.im/attachments/download/43/spectrum-${PV}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-
-IUSE="mysql sqlite symlinks tools staticport"
-
-RDEPEND=">=dev-libs/poco-1.3.3[mysql?,sqlite?]
- media-gfx/imagemagick[cxx]
- >=net-im/pidgin-2.6.0
- >=net-libs/gloox-1.0
- dev-python/xmpppy
- dev-libs/libev
- <dev-lang/python-3"
-DEPEND="${RDEPEND}
- sys-devel/gettext
- dev-util/cmake"
-
-PROTOCOL_LIST="aim facebook gg icq irc msn msn_pecan myspace qq simple sipe twitter xmpp yahoo"
-mycmakeargs=( -DPYTHON_EXECUTABLE=/usr/bin/python2 )
-
-pkg_setup() {
- if ! ( use sqlite || use mysql ); then
- ewarn "No database use flag set!"
- ewarn "You need to enable the mysql or sqlite use flag!"
- die
- fi
-}
-
-src_install () {
- cmake-utils_src_install
-
- # Install transports with seperate config files (default).
- # If USE="symlinks" is set, install one config file with symlinks to all transports.
-
- port=5347
-
- # prepare config for mysql or just copy
- cp "${FILESDIR}/spectrum.cfg" spectrum.cfg
-
- if use mysql ; then
- sed -e 's,^\(type\)=sqlite$,\1=mysql,' \
- -e 's,^#\(host=localhost\)$,\1,' \
- -e 's,^#\(user=user\)$,\1,' \
- -e 's,^#\(password=password\)$,\1,' \
- -e 's,^\(database=.*\),#\1,' \
- -e 's,^#\(prefix=.*\),\1,' \
- -i spectrum.cfg || die
- fi
-
- # install shared-config when using symlinks
- if use symlinks; then
- insinto /etc/spectrum
- newins spectrum.cfg spectrum-shared-conf || die
- fi
-
- # install protocol-specific configs or symlinks
- dodir /etc/spectrum
- for protocol in ${PROTOCOL_LIST}; do
- if use symlinks; then
- dosym spectrum-shared-conf "/etc/spectrum/${protocol}:${port}.cfg" || die
- sed -e 's,PROTOCOL,'${protocol}:${port}',g' \
- "${FILESDIR}"/spectrum.confd > spectrum.confd
- else
- sed -e 's,\$filename:protocol,'${protocol}',g' \
- -e 's,\$filename:port,'${port}',g' \
- spectrum.cfg > "${ED}/etc/spectrum/${protocol}.cfg" || die
- sed -e 's,PROTOCOL,'${protocol}',g' \
- "${FILESDIR}"/spectrum.confd > spectrum.confd
- fi
-
- # install prepared confd
- newconfd spectrum.confd spectrum.${protocol} || die
-
- if ! use staticport; then
- port=$[${port}+1]
- fi
- done
-
- # Install init files
- newinitd "${FILESDIR}"/spectrum.initd spectrum || die
- for protocol in ${PROTOCOL_LIST}; do
- dosym spectrum /etc/init.d/spectrum."${protocol}"
- done
-
- # Directories
- dodir "/var/lib/spectrum" || die
- dodir "/var/log/spectrum" || die
- dodir "/var/run/spectrum" || die
-
- # Directories for each transport
- for protocol in ${PROTOCOL_LIST}; do
- dodir "/var/lib/spectrum/$protocol/database" || die
- dodir "/var/lib/spectrum/$protocol/userdir" || die
- dodir "/var/lib/spectrum/$protocol/filetransfer_cache" || die
- done
-
- # Install mysql schema
- if use mysql; then
- insinto "/usr/share/spectrum/schemas"
- doins schemas/* || die
- fi
-
- # Install misc tools
- if use tools; then
- insinto "/usr/share/spectrum/tools"
- doins tools/* || die
- fi
-
- # Set correct rights
- fowners jabber:jabber -R "/etc/spectrum" || die
- fowners jabber:jabber -R "/var/lib/spectrum" || die
- fowners jabber:jabber -R "/var/log/spectrum" || die
- fowners jabber:jabber -R "/var/run/spectrum" || die
- fperms 750 "/etc/spectrum" || die
- fperms 750 "/var/lib/spectrum" || die
- fperms 750 "/var/log/spectrum" || die
- fperms 750 "/var/run/spectrum" || die
-}
diff --git a/net-im/spectrum/spectrum-1.4.8.ebuild b/net-im/spectrum/spectrum-1.4.8.ebuild
deleted file mode 100644
index 804d888..0000000
--- a/net-im/spectrum/spectrum-1.4.8.ebuild
+++ /dev/null
@@ -1,137 +0,0 @@
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-EAPI=2
-
-inherit cmake-utils
-
-DESCRIPTION="XMPP transport/gateway"
-HOMEPAGE="http://spectrum.im"
-
-SRC_URI="http://spectrum.im/attachments/download/43/spectrum-${PV}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-
-IUSE="mysql sqlite symlinks tools staticport"
-
-RDEPEND="dev-libs/libev
- >=dev-libs/poco-1.3.3[mysql?,sqlite?]
- dev-python/xmpppy
- media-gfx/imagemagick[cxx]
- >=net-im/pidgin-2.6.0
- >=net-libs/gloox-1.0"
-DEPEND="${RDEPEND}
- dev-util/cmake
- sys-devel/gettext"
-
-PROTOCOL_LIST="aim facebook gg icq irc msn msn_pecan myspace qq simple sipe twitter xmpp yahoo"
-
-pkg_setup() {
- if ! ( use sqlite || use mysql ); then
- ewarn "No database use flag set!"
- ewarn "You need to enable the mysql or sqlite use flag!"
- die
- fi
-}
-
-src_install () {
- cmake-utils_src_install
-
- # Install transports with seperate config files (default).
- # If USE="symlinks" is set, install one config file with symlinks to all transports.
-
- # Declare (start) port
- port=5347
-
- # prepare config for mysql or just copy
- cp "${FILESDIR}/spectrum.cfg" "${WORKDIR}/spectrum.cfg"
-
- if use mysql ; then
- sed -e 's,^\(type\)=sqlite$,\1=mysql,' \
- -e 's,^#\(host=localhost\)$,\1,' \
- -e 's,^#\(user=user\)$,\1,' \
- -e 's,^#\(password=password\)$,\1,' \
- -e 's,^\(database=.*\),#\1,' \
- -e 's,^#\(prefix=.*\),\1,' \
- -i "${WORKDIR}/spectrum.cfg" || die
- fi
-
- # install shared-config when using symlinks
- if use symlinks; then
- insinto /etc/spectrum
- newins "${WORKDIR}"/spectrum.cfg spectrum-shared-conf || die
- fi
-
- # install protocol-specific configs or symlinks
- insinto /etc/spectrum
- for protocol in ${PROTOCOL_LIST}; do
- if use symlinks; then
- dosym spectrum-shared-conf "/etc/spectrum/${protocol}:${port}.cfg" || die
- sed -e 's,PROTOCOL,'${protocol}:${port}',g' \
- "${FILESDIR}"/spectrum.confd > "${WORKDIR}"/spectrum.confd
- else
- sed -e 's,\$filename:protocol,'${protocol}',g' \
- -e 's,\$filename:port,'${port}',g' \
- "${WORKDIR}"/spectrum.cfg > "${WORKDIR}/${protocol}.cfg" || die
- sed -e 's,PROTOCOL,'${protocol}',g' \
- "${FILESDIR}"/spectrum.confd > "${WORKDIR}"/spectrum.confd
- doins "${WORKDIR}/${protocol}.cfg" || die
- fi
-
- # install prepared confd
- newconfd "${WORKDIR}"/spectrum.confd spectrum.${protocol} || die
-
- if ! use staticport; then
- port=$[${port}+1]
- fi
- done
-
- # Install init files
- newinitd "${FILESDIR}"/spectrum.initd spectrum || die
- for protocol in ${PROTOCOL_LIST}; do
- dosym spectrum /etc/init.d/spectrum."${protocol}"
- done
-
- # Directories
- dodir "/var/lib/spectrum" || die
- dodir "/var/log/spectrum" || die
- dodir "/var/run/spectrum" || die
-
- # Directories for each transport
- for protocol in ${PROTOCOL_LIST}; do
- dodir "/var/lib/spectrum/$protocol/database" || die
- dodir "/var/lib/spectrum/$protocol/userdir" || die
- dodir "/var/lib/spectrum/$protocol/filetransfer_cache" || die
- done
-
- # Install mysql schema
- if use mysql; then
- insinto "/usr/share/spectrum/schemas"
- doins schemas/* || die
- fi
-
- # Install misc tools
- if use tools; then
- insinto "/usr/share/spectrum/tools"
- doins tools/* || die
- fi
-}
-
-pkg_postinst() {
- # Create jabber-user
- enewgroup jabber
- enewuser jabber -1 -1 -1 jabber
-
- # Set correct rights
- chown jabber:jabber -R "/etc/spectrum" || die
- chown jabber:jabber -R "/var/lib/spectrum" || die
- chown jabber:jabber -R "/var/log/spectrum" || die
- chown jabber:jabber -R "/var/run/spectrum" || die
- chmod 750 "/etc/spectrum" || die
- chmod 750 "/var/lib/spectrum" || die
- chmod 750 "/var/log/spectrum" || die
- chmod 750 "/var/run/spectrum" || die
-}