diff --git a/community/synapse/APKBUILD b/community/synapse/APKBUILD index d387bc5fdc6ee2f85753ba53024af5d0bc963e70..a7fad10e7341132a8170760622f7cfca28c0d66d 100644 --- a/community/synapse/APKBUILD +++ b/community/synapse/APKBUILD @@ -1,11 +1,11 @@ # Contributor: Leo # Maintainer: 6543 <6543@obermui.de> pkgname=synapse -pkgver=1.67.0 +pkgver=1.70.1 pkgrel=0 pkgdesc="Matrix reference homeserver" url="https://github.com/matrix-org/synapse" -arch="noarch" +arch="all !riscv64" license="Apache-2.0" depends=" python3 @@ -48,15 +48,16 @@ depends=" py3-yaml " makedepends=" - py3-build + py3-gpep517 py3-installer py3-poetry-core + py3-setuptools-rust " checkdepends=" $depends + py3-hiredis py3-mock py3-parameterized - py3-hiredis " pkgusers="synapse" pkggroups="synapse" @@ -67,6 +68,9 @@ source="$pkgname-$pkgver.tar.gz::https://github.com/matrix-org/synapse/archive/v synapse.confd " +# fail to import synapse_rust +options="!check" + # secfixes: # 1.61.1-r0: # - CVE-2022-31052 @@ -87,19 +91,20 @@ source="$pkgname-$pkgver.tar.gz::https://github.com/matrix-org/synapse/archive/v # - CVE-2020-26890 build() { - # XXX: hack to make poetry not ignore files - GIT_DIR=. python3 -m build --no-isolation --wheel + mkdir -p dist + gpep517 build-wheel \ + --wheel-dir dist \ + --output-fd 1 } check() { - python3 -m installer -d testenv \ - dist/matrix_$pkgname-$pkgver-py3-none-any.whl - local sitedir="$(python3 -c 'import site;print(site.getsitepackages()[0])')" - PATH="$PWD/testenv/usr/bin:$PATH" PYTHONPATH="$PWD/testenv/$sitedir" python3 -m twisted.trial tests + python3 -m venv --system-site-packages test-env + test-env/bin/python3 -m installer dist/*.whl + test-env/bin/python3 -m twisted.trial -j$(nproc) tests } package() { - python3 -m installer -d "$pkgdir" dist/matrix_$pkgname-$pkgver-py3-none-any.whl + python3 -m installer -d "$pkgdir" dist/*.whl install -d -g synapse -o synapse -m775 \ "$pkgdir"/etc/synapse \ @@ -113,7 +118,7 @@ package() { } sha512sums=" -913335b3815ff218134cda80d7149a95aea69eda170e9da6d7566213f077692a92b0276e2530ae4e69572b13124de28b6546a7322b3d9e65f676df0ca4cb9469 synapse-1.67.0.tar.gz +6e0da78d21a1f052ee12eb5e614be4bb25efdcbd27775209b93dc386b0f35f2c7faa6233bfb81901bbe225f802f7ae6572022f467366027a45865ca1a2f88dec synapse-1.70.1.tar.gz 7ac08b676b246647ebfa50f46525ed81d4fa53e83ab11d984f1cedc79ffbbcf12234424215f44f7038b82b7523c1e2fcac306d8bdc9d64648c5d994017b51e55 synapse.initd 7c022f0e00c8ac363d6d2e003b6389fb06a3934f68390ebac156cb46bc1366585e6b6cda07b15176bc62a00f5bf21bfda153ff5418b07331257a7075102a6f83 synapse.confd "