mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-07 14:04:43 +02:00
82 lines
2.7 KiB
Text
82 lines
2.7 KiB
Text
# Maintainer: Noel Kuntze <noel.kuntze@contauro.com>
|
|
pkgname=jitsi-meet
|
|
pkgver=1.0.8384
|
|
_tag="jitsi-meet_10008"
|
|
pkgrel=0
|
|
pkgdesc="WebRTC JavaScript video conferences"
|
|
url="https://github.com/jitsi/jitsi-meet"
|
|
arch="x86_64 aarch64 s390x"
|
|
license="Apache-2.0"
|
|
depends="nginx"
|
|
_depends_prosody="$pkgname prosody lua-basexx lua-inspect lua-ossl"
|
|
makedepends="npm"
|
|
subpackages="$pkgname-doc $pkgname-prosody"
|
|
source="$pkgname-$pkgver.tar.gz::https://github.com/jitsi/jitsi-meet/archive/stable/$_tag.tar.gz"
|
|
|
|
builddir="$srcdir/$pkgname-stable-$_tag"
|
|
options="!check" # No test suite
|
|
|
|
build() {
|
|
npm ci
|
|
make
|
|
make source-package
|
|
}
|
|
|
|
package() {
|
|
DESTDIR="$pkgdir"/usr/share/webapps/$pkgname
|
|
CONFDIR="$pkgdir"/etc/jitsi/meet
|
|
|
|
install -d "$DESTDIR"
|
|
install -d "$CONFDIR"
|
|
|
|
tar -xjf "$pkgname.tar.bz2" -C "$DESTDIR" --strip 1
|
|
install -Dm644 -t "$DESTDIR" manifest.json
|
|
|
|
# Hack https://github.com/jitsi/jitsi-meet/pull/6925
|
|
for l in $(node -p "Object.keys(require('./lang/languages.json')).join(' ')"); do
|
|
c=${l:0:2}
|
|
if [ -f "node_modules/i18n-iso-countries/langs/$c.json" ]; then
|
|
install -m644 "node_modules/i18n-iso-countries/langs/$c.json" "$DESTDIR/lang/countries-$l.json"
|
|
fi
|
|
done
|
|
|
|
# get rid of all local references
|
|
find "$DESTDIR" -type f -name "*.js" -exec sed -i "s#$builddir##g" "{}" \+
|
|
|
|
# Non-deterministic race in npm gives 777 permissions to random directories.
|
|
# See https://github.com/npm/npm/issues/9359 for details.
|
|
chmod -R 755 "$DESTDIR"
|
|
|
|
# configuration files
|
|
for i in interface_config.js config.js; do
|
|
install -Dm644 "$DESTDIR/$i" "$CONFDIR/$i"
|
|
ln -sf "/etc/jitsi/meet/$i" "$DESTDIR/$i"
|
|
done
|
|
|
|
# general documentation
|
|
install -Dm644 -t "$pkgdir/usr/share/doc/$pkgname" doc/debian/jitsi-meet/jitsi-meet.example doc/debian/jitsi-meet/jitsi-meet.example-apache config.js
|
|
sed -i "s@/usr/share/$pkgname@/usr/share/webapps/$pkgname@" "$pkgdir/usr/share/doc/$pkgname/"*
|
|
|
|
# npm gives ownership of ALL FILES to build user
|
|
# https://bugs.archlinux.org/task/63396
|
|
chown -R root:root "$pkgdir"
|
|
}
|
|
|
|
prosody() {
|
|
pkgdesc="Jitsi Meet Prosody Plugins"
|
|
depends="$_depends_prosody"
|
|
|
|
cd "$builddir"
|
|
DESTDIR="$subpkgdir/usr/share/$pkgname"
|
|
install -d "$DESTDIR"
|
|
cp -r resources/prosody-plugins "$DESTDIR"
|
|
|
|
# prosody documentation
|
|
install -Dm644 -t "$pkgdir-doc/usr/share/doc/$pkgname" doc/debian/jitsi-meet-prosody/prosody.cfg.lua-jvb.example doc/debian/jitsi-meet-prosody/jaas.cfg.lua
|
|
sed -i 's@/usr/share/jitsi-meet/prosody-plugins/@/usr/lib/'$pkgname'@' "$pkgdir-doc/usr/share/doc/$pkgname/prosody.cfg.lua-jvb.example"
|
|
|
|
}
|
|
|
|
sha512sums="
|
|
7f447b75fc84baa2e248f28fa90515813453214a6d9614f8ca8bf6489ce8039a3564b10ae4c8bcca5d05d3c99e59635a06f31865a0d15117a496da71a0152d31 jitsi-meet-1.0.8384.tar.gz
|
|
"
|