Skip to content

Commit

Permalink
anydesk: patch pangox out
Browse files Browse the repository at this point in the history
  • Loading branch information
sgn committed Oct 17, 2020
1 parent 59a99ed commit 7ae600e
Showing 1 changed file with 26 additions and 13 deletions.
39 changes: 26 additions & 13 deletions srcpkgs/anydesk/template
@@ -1,9 +1,10 @@
# Template file for 'anydesk'
pkgname=anydesk
version=6.0.1
revision=1
revision=2
archs="i686 x86_64"
wrksrc=${pkgname}-${version}
create_wrksrc=yes
hostmakedepends="patchelf rpmextract w3m"
short_desc="Fast remote desktop application"
maintainer="mobinmob <mobinmob@disroot.org>"
license="custom:Proprietary"
Expand All @@ -12,20 +13,32 @@ homepage="https://anydesk.com/remote-desktop"
nopie=yes
restricted=yes

distfiles="https://download.anydesk.com/linux/anydesk_$version-1_$XBPS_TARGET_MACHINE.rpm"
if [ "${XBPS_TARGET_MACHINE}" = "x86_64" ] ; then
distfiles="https://download.anydesk.com/linux/anydesk-${version}-amd64.tar.gz"
checksum=b7826dcd379c27f615424d36d9383b8033c0b8c221751cad4ae7d9809f0fe5a4
checksum=df029878486944bf0400e90746fe738eee0fc3f849e7f47f19d432fcb357c03e
elif [ "${XBPS_TARGET_MACHINE}" = "i686" ]; then
distfiles="https://download.anydesk.com/linux/anydesk-${version}-i386.tar.gz"
checksum=cb22b026e2d81c0de220238fa3d4e13a6d0016787b8c680923794296bbd548e2
checksum=b92a366a8233be44f556c81f274bdce3e527591987cc4c8d2b490fcd410305ed
fi
_eula_digest=bfc62609b48b12f2c8c904e5b01b378d099836317334c6a634b2447bbf52ddcf

post_extract() {
$XBPS_FETCH_CMD -o eula.html https://anydesk.com/en/terms
< eula.html w3m -dump -I utf-8 -T text/html |
sed -n '/Terms [&] Conditions/,/envelope-p/{/envelope-p/!p}' >eula.txt

filesum="$($XBPS_DIGEST_CMD eula.txt)"
if [ "$filesum" != $_eula_digest ]; then
msg_error "EULA changed, new digest: $filesum\n"
fi
}

do_build() {
patchelf --replace-needed libpangox-1.0.so.0 libpangoxft-1.0.so.0 \
usr/bin/anydesk
}

do_install() {
vinstall icons/hicolor/256x256/apps/anydesk.png 644 /usr/share/pixmaps
vmkdir usr/share/applications
vinstall anydesk.desktop 644 usr/share/applications
vmkdir usr/share/polkit-1/actions
vcopy "polkit-1/*.policy" usr/share/polkit-1/actions
vbin anydesk
vlicense copyright
vcopy usr/share usr
vbin usr/bin/anydesk
vlicense eula.txt
}

0 comments on commit 7ae600e

Please sign in to comment.