48 lines
1.7 KiB
Bash
48 lines
1.7 KiB
Bash
# Template file for 'riot-desktop'
|
|
pkgname=riot-desktop
|
|
version=1.4.2
|
|
revision=1
|
|
archs="i686 x86_64"
|
|
wrksrc="riot-web-${version}"
|
|
conf_files="/etc/${pkgname}/config.json"
|
|
hostmakedepends="git nodejs yarn"
|
|
depends="c-ares ffmpeg gtk+3 http-parser libevent libxslt minizip nss re2 snappy"
|
|
short_desc="Glossy Matrix collaboration client, desktop version"
|
|
maintainer="Bendodroid <bendodroid@icloud.com>"
|
|
license="Apache-2.0"
|
|
homepage="https://riot.im"
|
|
distfiles="https://github.com/vector-im/riot-web/archive/v${version}.tar.gz"
|
|
checksum=0d8ce20912ea8c6961ff04a3e3231da1f77ec18cfdc5000a1f01d19eec9ad51c
|
|
nocross=yes
|
|
nostrip=yes
|
|
shlib_provides="libGLVESv2.so"
|
|
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
i686*) broken="/void-packages/srcpkgs/riot-desktop/template: line 20: 390 Segmentation fault" ;;
|
|
esac
|
|
|
|
do_build() {
|
|
npm install
|
|
npm run build
|
|
npm install electron
|
|
npm run install:electron
|
|
}
|
|
|
|
do_install() {
|
|
vmkdir usr/lib/riot-desktop
|
|
vmkdir etc/riot-desktop
|
|
vcopy node_modules/electron/dist /usr/lib/riot-desktop/
|
|
vcopy electron_app /usr/lib/riot-desktop/
|
|
vcopy webapp /usr/lib/riot-desktop
|
|
vcopy origin_migrator /usr/lib/riot-desktop
|
|
vinstall config.sample.json 664 /etc/riot-desktop/ config.json
|
|
vlicense LICENSE
|
|
ln -s /etc/riot-desktop/config.json $DESTDIR/usr/lib/riot-desktop/config.json
|
|
vbin ${FILESDIR}/riot-desktop.sh riot-desktop
|
|
vinstall ${FILESDIR}/riot-desktop.desktop 644 /usr/share/applications/ riot-desktop.desktop
|
|
vinstall res/themes/riot/img/logos/riot-im-logo.svg 644 /usr/share/icons/hicolor/scalable/apps/ riot.svg
|
|
for i in 16 24 48 64 96 128 256 512; do
|
|
vinstall electron_app/build/icons/${i}x${i}.png 644 /usr/share/icons/hicolor/${i}x${i}/apps/ riot.png
|
|
done
|
|
}
|