Add net-im/dendrite

Signed-off-by: Shin'ya Minazuki <shinyoukai@laidback.moe>
This commit is contained in:
Shin'ya Minazuki
2026-05-09 13:24:00 -03:00
parent c0d91e1449
commit c7b0a3e426
6 changed files with 96 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
# Copyright 2026 Shin'ya Minazuki
EAPI=8
inherit go-module optfeature
DESCRIPTION="Second-generation Matrix homeserver"
HOMEPAGE="https://github.com/element-hq/dendrite"
SRC_URI="
https://mirror.chaotic.ninja/software/${PN}/${P}.tar.gz
https://mirror.chaotic.ninja/software/${PN}/${P}-deps.tar.gz
"
# There are several other licenses around for the dependencies
# Not mentioning them here, it would get too long
LICENSE="AGPL-3+"
SLOT="0"
KEYWORDS="~amd64"
RESTRICT="mirror"
DEPEND="${RDEPEND}"
RDEPEND="
acct-user/dendrite
acct-group/dendrite
"
src_compile() {
ego build -tags goolm -trimpath -v -o bin/ ./cmd/...
}
src_install() {
newsbin bin/${PN} "${PN}"
newsbin bin/create-account "${PN}-create-account"
newsbin bin/generate-config "${PN}-generate-config"
newsbin bin/generate-keys "${PN}-generate-keys"
newsbin bin/resolve-state "${PN}-resolve-state"
newinitd "${FILESDIR}/${PN}.initd-r0" "${PN}"
}
pkg_postinst() {
optfeature "running a server in production environments" dev-db/postgresql
}