diff options
Diffstat (limited to 'net-im/prosody')
-rw-r--r-- | net-im/prosody/ChangeLog | 13 | ||||
-rw-r--r-- | net-im/prosody/files/prosody-0.9.2-cfg.lua.patch | 52 | ||||
-rw-r--r-- | net-im/prosody/files/prosody.initd | 21 | ||||
-rw-r--r-- | net-im/prosody/files/prosody.initd.old | 47 | ||||
-rw-r--r-- | net-im/prosody/metadata.xml | 4 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.8.1.ebuild | 6 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.8.2-r1.ebuild | 6 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.8.2.ebuild | 6 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.9.1-r1.ebuild | 6 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.9.1.ebuild | 6 | ||||
-rw-r--r-- | net-im/prosody/prosody-0.9.2.ebuild | 81 |
11 files changed, 220 insertions, 28 deletions
diff --git a/net-im/prosody/ChangeLog b/net-im/prosody/ChangeLog index 5e51cd090720..ec3f855e9cd3 100644 --- a/net-im/prosody/ChangeLog +++ b/net-im/prosody/ChangeLog @@ -1,6 +1,15 @@ # ChangeLog for net-im/prosody -# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/ChangeLog,v 1.32 2013/11/01 20:33:25 hasufell Exp $ +# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/ChangeLog,v 1.33 2014/01/27 02:21:51 zx2c4 Exp $ + +*prosody-0.9.2 (27 Jan 2014) + + 27 Jan 2014; Jason A. Donenfeld <zx2c4@gentoo.org> + +files/prosody-0.9.2-cfg.lua.patch, +files/prosody.initd.old, + +prosody-0.9.2.ebuild, files/prosody.initd, metadata.xml, + prosody-0.8.1.ebuild, prosody-0.8.2-r1.ebuild, prosody-0.8.2.ebuild, + prosody-0.9.1-r1.ebuild, prosody-0.9.1.ebuild: + Version bump and rework init system. 01 Nov 2013; Julian Ospald <hasufell@gentoo.org> prosody-0.9.1.ebuild, prosody-0.9.1-r1.ebuild: diff --git a/net-im/prosody/files/prosody-0.9.2-cfg.lua.patch b/net-im/prosody/files/prosody-0.9.2-cfg.lua.patch new file mode 100644 index 000000000000..15c09a24fd80 --- /dev/null +++ b/net-im/prosody/files/prosody-0.9.2-cfg.lua.patch @@ -0,0 +1,52 @@ +diff -ru prosody-0.9.2/prosody.cfg.lua.dist prosody-0.9.2-gentoo/prosody.cfg.lua.dist +--- prosody-0.9.2/prosody.cfg.lua.dist 2013-12-08 19:05:39.000000000 +0100 ++++ prosody-0.9.2-gentoo/prosody.cfg.lua.dist 2014-01-27 03:00:44.929196948 +0100 +@@ -1,5 +1,3 @@ +--- Prosody Example Configuration File +--- + -- Information on configuring Prosody can be found on our + -- website at http://prosody.im/doc/configure + -- +@@ -7,9 +5,6 @@ + -- when you have finished by running: luac -p prosody.cfg.lua + -- If there are any errors, it will let you know what and where + -- they are, otherwise it will keep quiet. +--- +--- The only thing left to do is rename this file to remove the .dist ending, and fill in the +--- blanks. Good luck, and happy Jabbering! + + + ---------- Server-wide settings ---------- +@@ -63,7 +58,7 @@ + --"http_files"; -- Serve static files from a directory over HTTP + + -- Other specific functionality +- --"posix"; -- POSIX functionality, sends server to background, enables syslog, etc. ++ "posix"; -- POSIX functionality, sends server to background, enables syslog, etc. (Keep enabled for Gentoo.) + --"groups"; -- Shared roster support + --"announce"; -- Send announcement to all online users + --"welcome"; -- Welcome users who register accounts +@@ -72,6 +67,12 @@ + --"legacyauth"; -- Legacy authentication. Only used by some old clients and bots. + }; + ++-- Settings for Gentoo init script and net-im/jabber-base permissions system: ++daemonize = true; ++prosody_user = "jabber"; ++prosody_group = "jabber"; ++pidfile = "/var/run/jabber/prosody.pid"; ++ + -- These modules are auto-loaded, but should you want + -- to disable them then uncomment them here: + modules_disabled = { +@@ -139,8 +140,8 @@ + -- Logging configuration + -- For advanced logging see http://prosody.im/doc/logging + log = { +- info = "prosody.log"; -- Change 'info' to 'debug' for verbose logging +- error = "prosody.err"; ++ info = "/var/log/jabber/prosody.log"; -- Change 'info' to 'debug' for verbose logging ++ error = "/var/log/jabber/prosody.err"; + -- "*syslog"; -- Uncomment this for logging to syslog + -- "*console"; -- Log to the console, useful for debugging with daemonize=false + } diff --git a/net-im/prosody/files/prosody.initd b/net-im/prosody/files/prosody.initd index 16bd231947c7..c1bc0e94dba1 100644 --- a/net-im/prosody/files/prosody.initd +++ b/net-im/prosody/files/prosody.initd @@ -1,15 +1,12 @@ #!/sbin/runscript -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/files/prosody.initd,v 1.2 2012/11/27 09:20:26 klausman Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/files/prosody.initd,v 1.3 2014/01/27 02:21:51 zx2c4 Exp $ description="Prosody is a server for Jabber/XMPP written in Lua." description_reload="Reload configuration and reopen log files." extra_started_commands="reload" - -PIDFILE="/var/run/jabber/prosody.pid" -USER="jabber" -COMMAND="/usr/bin/prosody" +pidfile="/var/run/jabber/prosody.pid" depend() { use dns @@ -22,26 +19,28 @@ checkconfig() { eerror "You need a /etc/jabber/prosody.cfg.lua file to run prosody" return 1 fi + luac -p /etc/jabber/prosody.cfg.lua + return $? } start() { checkconfig || return 1 checkpath -q -d -m 0770 -o jabber:jabber /var/run/jabber + checkpath -q -d -m 0750 -o jabber:jabber /var/log/jabber ebegin "Starting Prosody XMPP Server" - start-stop-daemon --start -b --pidfile ${PIDFILE} \ - --make-pidfile --user ${USER} --exec ${COMMAND} + prosodyctl start eend $? } stop() { ebegin "Stopping Prosody XMPP Server" - start-stop-daemon --stop --pidfile ${PIDFILE} \ - --user ${USER} --exec ${COMMAND} + prosodyctl stop eend $? } reload() { + checkconfig || return 1 ebegin "Reloading configuration of Prosody XMPP Server" - start-stop-daemon --pidfile ${PIDFILE} --signal HUP + prosodyctl reload eend $? } diff --git a/net-im/prosody/files/prosody.initd.old b/net-im/prosody/files/prosody.initd.old new file mode 100644 index 000000000000..25fc6bb43e1f --- /dev/null +++ b/net-im/prosody/files/prosody.initd.old @@ -0,0 +1,47 @@ +#!/sbin/runscript +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/files/prosody.initd.old,v 1.1 2014/01/27 02:21:51 zx2c4 Exp $ + +description="Prosody is a server for Jabber/XMPP written in Lua." +description_reload="Reload configuration and reopen log files." +extra_started_commands="reload" + +PIDFILE="/var/run/jabber/prosody.pid" +USER="jabber" +COMMAND="/usr/bin/prosody" + +depend() { + use dns + need net + provide jabber-server +} + +checkconfig() { + if [ ! -e /etc/jabber/prosody.cfg.lua ] ; then + eerror "You need a /etc/jabber/prosody.cfg.lua file to run prosody" + return 1 + fi +} + +start() { + checkconfig || return 1 + checkpath -q -d -m 0770 -o jabber:jabber /var/run/jabber + ebegin "Starting Prosody XMPP Server" + start-stop-daemon --start -b --pidfile ${PIDFILE} \ + --make-pidfile --user ${USER} --exec ${COMMAND} + eend $? +} + +stop() { + ebegin "Stopping Prosody XMPP Server" + start-stop-daemon --stop --pidfile ${PIDFILE} \ + --user ${USER} --exec ${COMMAND} + eend $? +} + +reload() { + ebegin "Reloading configuration of Prosody XMPP Server" + start-stop-daemon --pidfile ${PIDFILE} --signal HUP + eend $? +} diff --git a/net-im/prosody/metadata.xml b/net-im/prosody/metadata.xml index d346a54c6dd4..dbc499ac34ae 100644 --- a/net-im/prosody/metadata.xml +++ b/net-im/prosody/metadata.xml @@ -7,8 +7,12 @@ <maintainer> <email>klausman@gentoo.org</email> </maintainer> + <maintainer> + <email>zx2c4@gentoo.org</email> + </maintainer> <use> <flag name="libevent">Use libevent for event handling</flag> <flag name="zlib">Support for compressing XMPP streams with mod_compression</flag> + <flag name="jit">Use LuaJIT instead of vanilla Lua</flag> </use> </pkgmetadata> diff --git a/net-im/prosody/prosody-0.8.1.ebuild b/net-im/prosody/prosody-0.8.1.ebuild index b6fe869527b9..395ce15fa68d 100644 --- a/net-im/prosody/prosody-0.8.1.ebuild +++ b/net-im/prosody/prosody-0.8.1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.1.ebuild,v 1.3 2012/03/06 11:06:26 klausman Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.1.ebuild,v 1.4 2014/01/27 02:21:51 zx2c4 Exp $ EAPI="2" @@ -59,7 +59,7 @@ src_configure() { src_install() { DESTDIR="${D}" emake install || die "make failed" - newinitd "${FILESDIR}/${PN}".initd ${PN} + newinitd "${FILESDIR}/${PN}".initd.old ${PN} } src_test() { diff --git a/net-im/prosody/prosody-0.8.2-r1.ebuild b/net-im/prosody/prosody-0.8.2-r1.ebuild index 10e102067dbb..5eacef7f01d2 100644 --- a/net-im/prosody/prosody-0.8.2-r1.ebuild +++ b/net-im/prosody/prosody-0.8.2-r1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.2-r1.ebuild,v 1.4 2013/09/22 06:50:14 ago Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.2-r1.ebuild,v 1.5 2014/01/27 02:21:51 zx2c4 Exp $ EAPI="5" @@ -63,7 +63,7 @@ src_configure() { src_install() { DESTDIR="${D}" emake install - newinitd "${FILESDIR}/${PN}".initd ${PN} + newinitd "${FILESDIR}/${PN}".initd.old ${PN} systemd_dounit "${FILESDIR}/${PN}".service systemd_newtmpfilesd "${FILESDIR}/${PN}".tmpfilesd "${PN}".conf } diff --git a/net-im/prosody/prosody-0.8.2.ebuild b/net-im/prosody/prosody-0.8.2.ebuild index 4d610d53e7f8..9ea6853c4d0a 100644 --- a/net-im/prosody/prosody-0.8.2.ebuild +++ b/net-im/prosody/prosody-0.8.2.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.2.ebuild,v 1.5 2013/07/13 05:46:32 ago Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.8.2.ebuild,v 1.6 2014/01/27 02:21:51 zx2c4 Exp $ EAPI="2" @@ -59,7 +59,7 @@ src_configure() { src_install() { DESTDIR="${D}" emake install || die "make failed" - newinitd "${FILESDIR}/${PN}".initd ${PN} + newinitd "${FILESDIR}/${PN}".initd.old ${PN} } src_test() { diff --git a/net-im/prosody/prosody-0.9.1-r1.ebuild b/net-im/prosody/prosody-0.9.1-r1.ebuild index 5af5f580311a..a00c1c9dcac8 100644 --- a/net-im/prosody/prosody-0.9.1-r1.ebuild +++ b/net-im/prosody/prosody-0.9.1-r1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.9.1-r1.ebuild,v 1.2 2013/11/01 20:33:25 hasufell Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.9.1-r1.ebuild,v 1.3 2014/01/27 02:21:51 zx2c4 Exp $ EAPI=5 @@ -66,7 +66,7 @@ src_configure() { src_install() { emake DESTDIR="${D}" install - newinitd "${FILESDIR}/${PN}".initd ${PN} + newinitd "${FILESDIR}/${PN}".initd.old ${PN} } src_test() { diff --git a/net-im/prosody/prosody-0.9.1.ebuild b/net-im/prosody/prosody-0.9.1.ebuild index 6e2925263d9b..3c26584f4fe1 100644 --- a/net-im/prosody/prosody-0.9.1.ebuild +++ b/net-im/prosody/prosody-0.9.1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.9.1.ebuild,v 1.4 2013/11/01 20:33:25 hasufell Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.9.1.ebuild,v 1.5 2014/01/27 02:21:51 zx2c4 Exp $ EAPI="5" @@ -58,7 +58,7 @@ src_configure() { src_install() { emake DESTDIR="${D}" install - newinitd "${FILESDIR}/${PN}".initd ${PN} + newinitd "${FILESDIR}/${PN}".initd.old ${PN} } src_test() { diff --git a/net-im/prosody/prosody-0.9.2.ebuild b/net-im/prosody/prosody-0.9.2.ebuild new file mode 100644 index 000000000000..7b87cb7e4e4a --- /dev/null +++ b/net-im/prosody/prosody-0.9.2.ebuild @@ -0,0 +1,81 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-im/prosody/prosody-0.9.2.ebuild,v 1.1 2014/01/27 02:21:51 zx2c4 Exp $ + +EAPI=5 + +inherit flag-o-matic multilib versionator + +MY_PV=$(replace_version_separator 3 '') +MY_P="${PN}-${MY_PV}" +DESCRIPTION="Prosody is a flexible communications server for Jabber/XMPP written in Lua." +HOMEPAGE="http://prosody.im/" +SRC_URI="http://prosody.im/tmp/${MY_PV}/${MY_P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~x86" +IUSE="ipv6 libevent mysql postgres sqlite ssl zlib jit" + +DEPEND="net-im/jabber-base + !jit? ( >=dev-lang/lua-5.1 ) + jit? ( dev-lang/luajit ) + >=net-dns/libidn-1.1 + >=dev-libs/openssl-0.9.8" +RDEPEND="${DEPEND} + dev-lua/luaexpat + dev-lua/luafilesystem + ipv6? ( >=dev-lua/luasocket-3 ) + !ipv6? ( dev-lua/luasocket ) + libevent? ( >=dev-lua/luaevent-0.4.3 ) + mysql? ( dev-lua/luadbi[mysql] ) + postgres? ( dev-lua/luadbi[postgres] ) + sqlite? ( dev-lua/luadbi[sqlite] ) + ssl? ( dev-lua/luasec ) + zlib? ( dev-lua/lua-zlib )" + +S=${WORKDIR}/${MY_P} + +JABBER_ETC="/etc/jabber" +JABBER_SPOOL="/var/spool/jabber" + +src_prepare() { + epatch "${FILESDIR}/${PN}-0.9.2-cfg.lua.patch" + sed -i -e "s!MODULES = \$(DESTDIR)\$(PREFIX)/lib/!MODULES = \$(DESTDIR)\$(PREFIX)/$(get_libdir)/!"\ + -e "s!SOURCE = \$(DESTDIR)\$(PREFIX)/lib/!SOURCE = \$(DESTDIR)\$(PREFIX)/$(get_libdir)/!"\ + -e "s!INSTALLEDSOURCE = \$(PREFIX)/lib/!INSTALLEDSOURCE = \$(PREFIX)/$(get_libdir)/!"\ + -e "s!INSTALLEDMODULES = \$(PREFIX)/lib/!INSTALLEDMODULES = \$(PREFIX)/$(get_libdir)/!"\ + Makefile || die +} + +src_configure() { + # the configure script is handcrafted (and yells at unknown options) + # hence do not use 'econf' + append-cflags -D_GNU_SOURCE + luajit="" + if use jit; then + luajit="--runwith=luajit" + fi + ./configure \ + --ostype=linux $luajit \ + --prefix="/usr" \ + --sysconfdir="${JABBER_ETC}" \ + --datadir="${JABBER_SPOOL}" \ + --with-lua-include=/usr/include \ + --with-lua-lib=/usr/$(get_libdir)/lua \ + --cflags="${CFLAGS} -Wall -fPIC" \ + --ldflags="${LDFLAGS} -shared" \ + --c-compiler="$(tc-getCC)" \ + --linker="$(tc-getCC)" \ + --require-config || die "configure failed" +} + +src_install() { + emake DESTDIR="${D}" install + newinitd "${FILESDIR}/${PN}".initd ${PN} +} + +src_test() { + cd tests || die + ./run_tests.sh || die +} |