From 56bd759df1d0c750a065b8c845e93d5dfa6b549d Mon Sep 17 00:00:00 2001 From: "Robin H. Johnson" Date: Sat, 8 Aug 2015 13:49:04 -0700 Subject: proj/gentoo: Initial commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson X-Thanks: Alec Warner - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring - wrote much python to improve cvs2svn X-Thanks: Rich Freeman - validation scripts X-Thanks: Patrick Lauer - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed --- net-im/prosody/Manifest | 2 + net-im/prosody/files/prosody-0.9.2-cfg.lua.patch | 52 +++++++++++++++ net-im/prosody/files/prosody.initd-r2 | 47 +++++++++++++ net-im/prosody/files/prosody.service | 12 ++++ net-im/prosody/files/prosody.tmpfilesd | 1 + net-im/prosody/metadata.xml | 18 +++++ net-im/prosody/prosody-0.9.7.ebuild | 83 +++++++++++++++++++++++ net-im/prosody/prosody-0.9.8.ebuild | 84 ++++++++++++++++++++++++ 8 files changed, 299 insertions(+) create mode 100644 net-im/prosody/Manifest create mode 100644 net-im/prosody/files/prosody-0.9.2-cfg.lua.patch create mode 100644 net-im/prosody/files/prosody.initd-r2 create mode 100644 net-im/prosody/files/prosody.service create mode 100644 net-im/prosody/files/prosody.tmpfilesd create mode 100644 net-im/prosody/metadata.xml create mode 100644 net-im/prosody/prosody-0.9.7.ebuild create mode 100644 net-im/prosody/prosody-0.9.8.ebuild (limited to 'net-im/prosody') diff --git a/net-im/prosody/Manifest b/net-im/prosody/Manifest new file mode 100644 index 000000000000..b6c85f057ff2 --- /dev/null +++ b/net-im/prosody/Manifest @@ -0,0 +1,2 @@ +DIST prosody-0.9.7.tar.gz 266638 SHA256 dd4b99b39976442055898c933c013598e558beed11d7795d76ffc0f1a87e2e00 SHA512 fc1f0855e7af2132058af493bb9af20f9f1aa3051e6d8550ba9942264d85dc6840085b17e2a0226d4015745407f445c691455d998c4a43a3a9aa2d036a01ce9e WHIRLPOOL 5de40437be364856acbcaa2553aa54119bd46ed0afda9127211ff65ad9b4acea8b7a447452c7555ecfb9a58266cca319ecc2eb2a4959cb4e2390dc99dcf20b82 +DIST prosody-0.9.8.tar.gz 268716 SHA256 9470415c56e0b847089b45fabd48bc1f8211cd525fba56967409d064f4257871 SHA512 08ca8c8028a947a22d68ddc1d7eb93d3d205894102c900ece9e537ef9dd9332e8509e4b170069383e4f9717b52fd41aec2aa9d959e16ddebf0c3d54fe31aef3c WHIRLPOOL ab0b7a7e4324dd5ea59db4c6470f36cd047aa9da240cd987b9159cfa753e6f28cbf33bb726f8e89762e31ec6a09b7915162beb46e7e429159e52e6cb50dd2728 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-r2 b/net-im/prosody/files/prosody.initd-r2 new file mode 100644 index 000000000000..d88fd6f92f90 --- /dev/null +++ b/net-im/prosody/files/prosody.initd-r2 @@ -0,0 +1,47 @@ +#!/sbin/runscript +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +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" + +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 + luac -p /etc/jabber/prosody.cfg.lua + return $? +} + +start() { + checkconfig || return 1 + checkpath -q -d -m 0770 -o jabber:jabber "$(dirname ${pidfile})" + checkpath -q -f -m 0770 -o jabber:jabber "${pidfile}" + checkpath -q -d -m 0750 -o jabber:jabber /var/log/jabber + ebegin "Starting Prosody XMPP Server" + prosodyctl start + eend $? +} + +stop() { + ebegin "Stopping Prosody XMPP Server" + prosodyctl stop + eend $? +} + +reload() { + checkconfig || return 1 + ebegin "Reloading configuration of Prosody XMPP Server" + prosodyctl reload + eend $? +} diff --git a/net-im/prosody/files/prosody.service b/net-im/prosody/files/prosody.service new file mode 100644 index 000000000000..ec00e5445d51 --- /dev/null +++ b/net-im/prosody/files/prosody.service @@ -0,0 +1,12 @@ +[Unit] +Description=Prosody XMPP (Jabber) server +After=network.target + +[Service] +Type=forking +PIDFile=/var/run/jabber/prosody.pid +ExecStart=/usr/bin/prosodyctl start +ExecStop=/usr/bin/prosodyctl stop + +[Install] +WantedBy=multi-user.target diff --git a/net-im/prosody/files/prosody.tmpfilesd b/net-im/prosody/files/prosody.tmpfilesd new file mode 100644 index 000000000000..924ba434659c --- /dev/null +++ b/net-im/prosody/files/prosody.tmpfilesd @@ -0,0 +1 @@ +d /var/run/jabber 710 jabber jabber diff --git a/net-im/prosody/metadata.xml b/net-im/prosody/metadata.xml new file mode 100644 index 000000000000..dbc499ac34ae --- /dev/null +++ b/net-im/prosody/metadata.xml @@ -0,0 +1,18 @@ + + + + + rafaelmartins@gentoo.org + + + klausman@gentoo.org + + + zx2c4@gentoo.org + + + Use libevent for event handling + Support for compressing XMPP streams with mod_compression + Use LuaJIT instead of vanilla Lua + + diff --git a/net-im/prosody/prosody-0.9.7.ebuild b/net-im/prosody/prosody-0.9.7.ebuild new file mode 100644 index 000000000000..630a2db198bf --- /dev/null +++ b/net-im/prosody/prosody-0.9.7.ebuild @@ -0,0 +1,83 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +inherit flag-o-matic multilib systemd 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-1.3.0 + 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 + systemd_dounit "${FILESDIR}/${PN}".service + systemd_newtmpfilesd "${FILESDIR}/${PN}".tmpfilesd "${PN}".conf + newinitd "${FILESDIR}/${PN}".initd-r2 ${PN} +} + +src_test() { + cd tests || die + ./run_tests.sh || die +} diff --git a/net-im/prosody/prosody-0.9.8.ebuild b/net-im/prosody/prosody-0.9.8.ebuild new file mode 100644 index 000000000000..5b7fa48b9c7a --- /dev/null +++ b/net-im/prosody/prosody-0.9.8.ebuild @@ -0,0 +1,84 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +inherit flag-o-matic multilib systemd 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:0 ) + jit? ( dev-lang/luajit:2 ) + >=net-dns/libidn-1.1 + dev-libs/openssl:0" +RDEPEND="${DEPEND} + >=dev-lua/luaexpat-1.3.0 + 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="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/lib64" \ + --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 + systemd_dounit "${FILESDIR}/${PN}".service + systemd_newtmpfilesd "${FILESDIR}/${PN}".tmpfilesd "${PN}".conf + newinitd "${FILESDIR}/${PN}".initd-r2 ${PN} +} + +src_test() { + cd tests || die + ./run_tests.sh || die +} -- cgit v1.2.3