1 |
commit: 672482e9799801839773c26a248ebe3fca6c6ef1 |
2 |
Author: Conrad Kostecki <conikost <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Oct 3 13:23:08 2020 +0000 |
4 |
Commit: Conrad Kostecki <conikost <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Oct 3 13:43:37 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=672482e9 |
7 |
|
8 |
net-im/prosody: bump to version 0.11.7 |
9 |
|
10 |
Changes: |
11 |
Dropped useflag ipv6, |
12 |
since old non ipv6 dependency does not exist anymore. |
13 |
Renamed lua to luajit to use gentoos default. |
14 |
Added optional postgresql dependency to init script. |
15 |
Overhauled ebuild. |
16 |
Dropped multilib inherit, as it's not being used. |
17 |
Updated deps for correct luaexpat. |
18 |
|
19 |
Closes: https://bugs.gentoo.org/564434 |
20 |
Closes: https://bugs.gentoo.org/674842 |
21 |
Closes: https://bugs.gentoo.org/740662 |
22 |
Package-Manager: Portage-3.0.8, Repoman-3.0.1 |
23 |
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org> |
24 |
|
25 |
net-im/prosody/Manifest | 1 + |
26 |
net-im/prosody/files/prosody.initd-r3 | 46 ++++++++++++++++++++ |
27 |
net-im/prosody/prosody-0.11.7.ebuild | 79 +++++++++++++++++++++++++++++++++++ |
28 |
3 files changed, 126 insertions(+) |
29 |
|
30 |
diff --git a/net-im/prosody/Manifest b/net-im/prosody/Manifest |
31 |
index a0adccc1337..ded27dd5ec2 100644 |
32 |
--- a/net-im/prosody/Manifest |
33 |
+++ b/net-im/prosody/Manifest |
34 |
@@ -1 +1,2 @@ |
35 |
DIST prosody-0.11.5.tar.gz 425122 BLAKE2B d65720a0c9d533a4be70847b690ecf037ae4b2fcbd090c81e2346d515599f3f148061103df2ffe46122a55694a3d35d53ab2b379fb5fb317e3b84a0ff5e82c29 SHA512 43a9facee8d61b69e277e7e8a9091fbfa60be71d6141195dff991f6020c8afadacce26f356b869cb2d7edd9be285e9ce1bcd822f9628cc845d91757e818a0dff |
36 |
+DIST prosody-0.11.7.tar.gz 429369 BLAKE2B 8ef7377810702d5e1f480d84c09d6e3cc6aab674cca56fc1ce5e211d32df63ffeb57869c9d98429a81ea715ee19fca2ac015daa6b88b8c140efbeccb906defa6 SHA512 923aa92598ef851ed8408931942859f78f1e3d700fee251f4f5ca67abdcdae43448318ed90a9a1cdc7824d5f4dc5a4732fad4b9ed36d97455fa9b3bff0881a20 |
37 |
|
38 |
diff --git a/net-im/prosody/files/prosody.initd-r3 b/net-im/prosody/files/prosody.initd-r3 |
39 |
new file mode 100644 |
40 |
index 00000000000..3126cc8e1e2 |
41 |
--- /dev/null |
42 |
+++ b/net-im/prosody/files/prosody.initd-r3 |
43 |
@@ -0,0 +1,46 @@ |
44 |
+#!/sbin/openrc-run |
45 |
+# Copyright 1999-2020 Gentoo Authors |
46 |
+# Distributed under the terms of the GNU General Public License v2 |
47 |
+ |
48 |
+description="Prosody is a server for Jabber/XMPP written in Lua." |
49 |
+description_reload="Reload configuration and reopen log files." |
50 |
+extra_started_commands="reload" |
51 |
+pidfile="/var/run/jabber/prosody.pid" |
52 |
+ |
53 |
+depend() { |
54 |
+ need net |
55 |
+ provide jabber-server |
56 |
+ use dns postgresql |
57 |
+} |
58 |
+ |
59 |
+checkconfig() { |
60 |
+ if [ ! -e /etc/jabber/prosody.cfg.lua ] ; then |
61 |
+ eerror "You need a /etc/jabber/prosody.cfg.lua file to run prosody" |
62 |
+ return 1 |
63 |
+ fi |
64 |
+ luac -p /etc/jabber/prosody.cfg.lua |
65 |
+ return $? |
66 |
+} |
67 |
+ |
68 |
+start() { |
69 |
+ checkconfig || return 1 |
70 |
+ checkpath -q -d -m 0770 -o jabber:jabber "$(dirname ${pidfile})" |
71 |
+ checkpath -q -f -m 0770 -o jabber:jabber "${pidfile}" |
72 |
+ checkpath -q -d -m 0750 -o jabber:jabber /var/log/jabber |
73 |
+ ebegin "Starting Prosody XMPP Server" |
74 |
+ prosodyctl start |
75 |
+ eend $? |
76 |
+} |
77 |
+ |
78 |
+stop() { |
79 |
+ ebegin "Stopping Prosody XMPP Server" |
80 |
+ prosodyctl stop |
81 |
+ eend $? |
82 |
+} |
83 |
+ |
84 |
+reload() { |
85 |
+ checkconfig || return 1 |
86 |
+ ebegin "Reloading configuration of Prosody XMPP Server" |
87 |
+ prosodyctl reload |
88 |
+ eend $? |
89 |
+} |
90 |
|
91 |
diff --git a/net-im/prosody/prosody-0.11.7.ebuild b/net-im/prosody/prosody-0.11.7.ebuild |
92 |
new file mode 100644 |
93 |
index 00000000000..7d39dc0434f |
94 |
--- /dev/null |
95 |
+++ b/net-im/prosody/prosody-0.11.7.ebuild |
96 |
@@ -0,0 +1,79 @@ |
97 |
+# Copyright 1999-2020 Gentoo Authors |
98 |
+# Distributed under the terms of the GNU General Public License v2 |
99 |
+ |
100 |
+EAPI=7 |
101 |
+ |
102 |
+inherit systemd toolchain-funcs |
103 |
+ |
104 |
+DESCRIPTION="Prosody is a flexible communications server for Jabber/XMPP written in Lua" |
105 |
+HOMEPAGE="https://prosody.im/" |
106 |
+SRC_URI="https://prosody.im/downloads/source/${P}.tar.gz" |
107 |
+ |
108 |
+LICENSE="MIT" |
109 |
+SLOT="0" |
110 |
+KEYWORDS="~amd64 ~arm ~x86" |
111 |
+IUSE="libevent libressl luajit mysql postgres sqlite ssl test zlib" |
112 |
+RESTRICT="!test? ( test )" |
113 |
+ |
114 |
+COMMON_DEPEND=" |
115 |
+ dev-lua/LuaBitOp |
116 |
+ net-dns/libidn |
117 |
+ net-im/jabber-base |
118 |
+ libressl? ( dev-libs/libressl:= ) |
119 |
+ !libressl? ( dev-libs/openssl:0= ) |
120 |
+ luajit? ( dev-lang/luajit:2 ) |
121 |
+ !luajit? ( dev-lang/lua:0 ) |
122 |
+" |
123 |
+ |
124 |
+DEPEND=" |
125 |
+ ${COMMON_DEPEND} |
126 |
+ test? ( dev-lua/busted ) |
127 |
+" |
128 |
+ |
129 |
+RDEPEND=" |
130 |
+ ${COMMON_DEPEND} |
131 |
+ ~dev-lua/luaexpat-1.3.0 |
132 |
+ dev-lua/luafilesystem |
133 |
+ dev-lua/luasocket |
134 |
+ libevent? ( dev-lua/luaevent ) |
135 |
+ mysql? ( dev-lua/luadbi[mysql] ) |
136 |
+ postgres? ( dev-lua/luadbi[postgres] ) |
137 |
+ sqlite? ( dev-lua/luadbi[sqlite] ) |
138 |
+ ssl? ( dev-lua/luasec ) |
139 |
+ zlib? ( dev-lua/lua-zlib ) |
140 |
+" |
141 |
+ |
142 |
+PATCHES=( "${FILESDIR}/prosody_cfg-0.11.2-r1.patch" ) |
143 |
+ |
144 |
+src_configure() { |
145 |
+ local myconfargs=( |
146 |
+ --c-compiler="$(tc-getCC)" |
147 |
+ --datadir="${EPREFIX}/var/spool/jabber" |
148 |
+ --libdir="${EPREFIX}/usr/$(get_libdir)" |
149 |
+ --linker="$(tc-getCC)" |
150 |
+ --ostype="linux" |
151 |
+ --prefix="${EPREFIX}/usr" |
152 |
+ --runwith="$(usex luajit luajit lua)" |
153 |
+ --sysconfdir="${EPREFIX}/etc/jabber" |
154 |
+ --with-lua-include="${EPREFIX}/usr/include" |
155 |
+ --with-lua-lib="${EPREFIX}/usr/$(get_libdir)/lua" |
156 |
+ ) |
157 |
+ |
158 |
+ ./configure ${myconfargs[@]} --cflags="${CFLAGS} -Wall -fPIC" --ldflags="${LDFLAGS} -shared" || die |
159 |
+ |
160 |
+ rm makefile || die |
161 |
+ mv GNUmakefile Makefile || die |
162 |
+} |
163 |
+ |
164 |
+src_install() { |
165 |
+ emake DESTDIR="${D}" install |
166 |
+ |
167 |
+ keepdir /var/spool/jabber |
168 |
+ |
169 |
+ newinitd "${FILESDIR}"/prosody.initd-r3 prosody |
170 |
+ |
171 |
+ systemd_dounit "${FILESDIR}"/prosody.service |
172 |
+ systemd_newtmpfilesd "${FILESDIR}"/prosody.tmpfilesd prosody.conf |
173 |
+ |
174 |
+ newinitd "${FILESDIR}"/prosody.initd-r3 prosody |
175 |
+} |