From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1436167-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 81F71158094
	for <garchives@archives.gentoo.org>; Wed, 14 Sep 2022 22:33:12 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 63745E09F5;
	Wed, 14 Sep 2022 22:33:11 +0000 (UTC)
Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 3BD03E09EA
	for <gentoo-commits@lists.gentoo.org>; Wed, 14 Sep 2022 22:33:11 +0000 (UTC)
Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 540D9340F39
	for <gentoo-commits@lists.gentoo.org>; Wed, 14 Sep 2022 22:33:10 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 8B9635CD
	for <gentoo-commits@lists.gentoo.org>; Wed, 14 Sep 2022 22:33:08 +0000 (UTC)
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" <sam@gentoo.org>
Message-ID: <1663194526.26b193798f83ca3b988b60383158b5da6edf42aa.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: net-im/synapse/
X-VCS-Repository: repo/gentoo
X-VCS-Files: net-im/synapse/Manifest net-im/synapse/synapse-1.67.0.ebuild
X-VCS-Directories: net-im/synapse/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: 26b193798f83ca3b988b60383158b5da6edf42aa
X-VCS-Branch: master
Date: Wed, 14 Sep 2022 22:33:08 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: c0f212f7-a3cb-433a-838f-fc067a783834
X-Archives-Hash: 862d05e18fdef81733638d1b8cc912c9

commit:     26b193798f83ca3b988b60383158b5da6edf42aa
Author:     Petr Vaněk <arkamar <AT> atlas <DOT> cz>
AuthorDate: Tue Sep 13 11:12:07 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Sep 14 22:28:46 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=26b19379

net-im/synapse: add 1.67.0

Changes from previous version:
- long command line options are used for postgres related commands
- add link to a documentation how to run tests under postgres
- differentiate messages for first install and regular update

Signed-off-by: Petr Vaněk <arkamar <AT> atlas.cz>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-im/synapse/Manifest              |   1 +
 net-im/synapse/synapse-1.67.0.ebuild | 135 +++++++++++++++++++++++++++++++++++
 2 files changed, 136 insertions(+)

diff --git a/net-im/synapse/Manifest b/net-im/synapse/Manifest
index fe06e89a3bd2..a7c37b2879b0 100644
--- a/net-im/synapse/Manifest
+++ b/net-im/synapse/Manifest
@@ -2,3 +2,4 @@ DIST synapse-1.62.0.gh.tar.gz 7841903 BLAKE2B f3002798a3fccd1b7fc4a1a302d12dd094
 DIST synapse-1.63.1.gh.tar.gz 7861575 BLAKE2B 7f69f2620289aa2c6b846514ce086e0ce20d559179cded20cda43b6c2ef2ad36d3b3f3fd6b139d2237a4c002c92a820a4150e5d8b25218b17bf22b9999638c67 SHA512 eb3bfb22081e932b2b7168a2b656b2ba7cc656bffbf60eb169b8d187d2a742809e2c0d6170afcea2bcf40ae5042a7b2ce7d7438294167bcc48def71e2488e338
 DIST synapse-1.65.0.gh.tar.gz 7895758 BLAKE2B 1c816dfb7982fc0462a4a3b84c19dd144e7ac16d6cadf1e73dc71002c234eed5945ad8162d69960eff1bab80a3396a1b78e0be2cc2dfee314f6fb39d0b91b098 SHA512 3ba9751f707d41a9e18d9fe63f9652c36712451d42953e2bd4add8c142418a2a47a2ce75da893832af9225b944dd7b275f6d744f6e70d468b7f143dd5ccb9137
 DIST synapse-1.66.0.gh.tar.gz 7916982 BLAKE2B 116d9f7dfd046ddc245ef1375bb3f01aad126fab8dedeb0e9172ce9b4bfa6c9757e241d9f0b2bad07525657e7a1f378d9385401436132c4ee6046629792a9840 SHA512 ebe8ab787d72592b395226490414f7dce5c250173be654dc6ce63deec3a7d718f8400cdc81dfb73ae331632bed4dfb5c6f09c64538f4bda8546db8fb75d728b7
+DIST synapse-1.67.0.gh.tar.gz 7933047 BLAKE2B 8fd6b48198256c8cbe4a2a1d5215e1eb34084065056dd251a19b01c44e7f193b612f49a8fce74498d406e338dba3c6f4a0db384f323d5e4174d181de8478ef24 SHA512 913335b3815ff218134cda80d7149a95aea69eda170e9da6d7566213f077692a92b0276e2530ae4e69572b13124de28b6546a7322b3d9e65f676df0ca4cb9469

diff --git a/net-im/synapse/synapse-1.67.0.ebuild b/net-im/synapse/synapse-1.67.0.ebuild
new file mode 100644
index 000000000000..17b22a83c544
--- /dev/null
+++ b/net-im/synapse/synapse-1.67.0.ebuild
@@ -0,0 +1,135 @@
+# Copyright 2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{9..10} )
+DISTUTILS_SINGLE_IMPL=1
+DISTUTILS_USE_PEP517=poetry
+
+inherit distutils-r1 multiprocessing optfeature systemd
+
+DESCRIPTION="Reference implementation of Matrix homeserver"
+HOMEPAGE="
+	https://matrix.org/
+	https://github.com/matrix-org/synapse/
+"
+
+if [[ ${PV} == 9999 ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://github.com/matrix-org/${PN}.git"
+else
+	MY_PV="${PV/_rc/rc}"
+	SRC_URI="https://github.com/matrix-org/${PN}/archive/v${MY_PV}.tar.gz -> ${P}.gh.tar.gz"
+	S="${WORKDIR}/${PN}-${MY_PV}"
+	KEYWORDS="~amd64 ~ppc64"
+fi
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="postgres systemd test"
+RESTRICT="!test? ( test )"
+
+DEPEND="
+	acct-user/synapse
+	acct-group/synapse
+"
+RDEPEND="${DEPEND}
+	$(python_gen_cond_dep '
+		dev-python/attrs[${PYTHON_USEDEP}]
+		dev-python/bcrypt[${PYTHON_USEDEP}]
+		dev-python/bleach[${PYTHON_USEDEP}]
+		dev-python/canonicaljson[${PYTHON_USEDEP}]
+		dev-python/cryptography[${PYTHON_USEDEP}]
+		dev-python/frozendict[${PYTHON_USEDEP}]
+		dev-python/ijson[${PYTHON_USEDEP}]
+		>=dev-python/jinja-3.0[${PYTHON_USEDEP}]
+		dev-python/jsonschema[${PYTHON_USEDEP}]
+		>=dev-python/matrix-common-1.2.1[${PYTHON_USEDEP}]
+		dev-python/msgpack[${PYTHON_USEDEP}]
+		dev-python/netaddr[${PYTHON_USEDEP}]
+		dev-python/packaging[${PYTHON_USEDEP}]
+		dev-python/phonenumbers[${PYTHON_USEDEP}]
+		dev-python/pillow[${PYTHON_USEDEP},webp]
+		dev-python/prometheus_client[${PYTHON_USEDEP}]
+		dev-python/pyasn1-modules[${PYTHON_USEDEP}]
+		dev-python/pyasn1[${PYTHON_USEDEP}]
+		dev-python/pydantic[${PYTHON_USEDEP}]
+		dev-python/pymacaroons[${PYTHON_USEDEP}]
+		dev-python/pyopenssl[${PYTHON_USEDEP}]
+		dev-python/pyyaml[${PYTHON_USEDEP}]
+		dev-python/service_identity[${PYTHON_USEDEP}]
+		dev-python/signedjson[${PYTHON_USEDEP}]
+		dev-python/sortedcontainers[${PYTHON_USEDEP}]
+		dev-python/treq[${PYTHON_USEDEP}]
+		dev-python/twisted[${PYTHON_USEDEP}]
+		dev-python/typing-extensions[${PYTHON_USEDEP}]
+		dev-python/unpaddedbase64[${PYTHON_USEDEP}]
+		postgres? ( dev-python/psycopg:2[${PYTHON_USEDEP}] )
+		systemd? ( dev-python/python-systemd[${PYTHON_USEDEP}] )
+	')
+"
+BDEPEND="
+	test? (
+		$(python_gen_cond_dep '
+			dev-python/idna[${PYTHON_USEDEP}]
+			dev-python/parameterized[${PYTHON_USEDEP}]
+		')
+		postgres? ( dev-db/postgresql[server] )
+	)
+"
+
+src_test() {
+	if use postgres; then
+		initdb --pgdata="${T}/pgsql" || die
+		pg_ctl --wait --pgdata="${T}/pgsql" start \
+			--options="-h '' -k '${T}'" || die
+		createdb --host="${T}" synapse_test || die
+
+		# See https://matrix-org.github.io/synapse/latest/development/contributing_guide.html#running-tests-under-postgresql
+		local -x SYNAPSE_POSTGRES=1
+		local -x SYNAPSE_POSTGRES_HOST="${T}"
+	fi
+
+	distutils-r1_src_test
+
+	if use postgres; then
+		pg_ctl --wait --pgdata="${T}/pgsql" stop || die
+	fi
+}
+
+python_test() {
+	"${EPYTHON}" -m twisted.trial -j "$(makeopts_jobs)" tests || die "Tests failed with ${EPYTHON}"
+}
+
+python_install() {
+	distutils-r1_python_install
+	keepdir /var/{lib,log}/synapse /etc/synapse
+	fowners synapse:synapse /var/{lib,log}/synapse /etc/synapse
+	fperms 0750 /var/{lib,log}/synapse /etc/synapse
+	newinitd "${FILESDIR}/${PN}.initd" "${PN}"
+	systemd_dounit "${FILESDIR}/synapse.service"
+}
+
+pkg_postinst() {
+	optfeature "VoIP relaying on your homeserver with turn" net-im/coturn
+
+	if [[ -z "${REPLACING_VERSIONS}" ]]; then
+		einfo
+		elog "In order to generate initial configuration run:"
+		elog "sudo -u synapse synapse_homeserver \\"
+		elog "    --server-name matrix.domain.tld \\"
+		elog "    --config-path /etc/synapse/homeserver.yaml \\"
+		elog "    --generate-config \\"
+		elog "    --data-directory /var/lib/synapse \\"
+		elog "    --report-stats=no"
+		einfo
+	else
+		einfo
+		einfo "Please refer to upgrade notes if any special steps are required"
+		einfo "to upgrade from the version you currently have installed:"
+		einfo
+		einfo "  https://github.com/matrix-org/synapse/blob/develop/docs/upgrade.md"
+		einfo
+	fi
+}