# Maintainer: Alessio Sergi pkgname=spideroak-beta _pkgname=spideroak pkgver=4.3.9936 pkgrel=1 pkgdesc="Secure file backup, sync and sharing client (beta channel)" arch=('i686' 'x86_64') url="https://spideroak.com/" license=('custom') provides=($_pkgname) conflicts=($_pkgname) options=('!strip') install=$pkgname.install [[ "$CARCH" = 'i686' ]] && _arch='i386' || _arch='x86_64' source=("${pkgname}_${pkgver}_${_arch}.deb"::"https://$_pkgname.com/directdownload?platform=ubuntulucid&arch=$_arch&revision=${pkgver##4.3.}&code=" "terms.txt") sha1sums=('6e99f717405d55bc1a5b13919d104355fe1eb721' 'f287fdbad966ac9ae4951a1932e9be7e82112728') [[ "$CARCH" = 'i686' ]] && sha1sums[0]='9a1e9b1067582078a837c491250f95b53caca6c9' package() { cd "$srcdir" # unpack bundled files tar zxf data.tar.gz # install config files install -d -m 755 "$pkgdir"/etc/{dbus-1/system.d,sysctl.d} install -m 644 etc/dbus-1/system.d/"$_pkgname".dbus.conf \ "$pkgdir/etc/dbus-1/system.d/$_pkgname.dbus.conf" install -m 644 etc/sysctl.d/30-"$_pkgname".conf \ "$pkgdir/etc/sysctl.d/30-$_pkgname.conf" # clean up a bit rm -f usr/lib/SpiderOak/lib{gcc_s,stdc++,z}.so.* rm -f usr/lib/SpiderOak/*/*/*.exe # install app in /opt install -d -m 755 "$pkgdir"/opt/SpiderOak cp -r usr/lib/SpiderOak/* "$pkgdir"/opt/SpiderOak/ # change /usr to /opt in start script file sed -i 's:/usr/lib:/opt:g' usr/bin/SpiderOak # install start script file install -d -m 755 "$pkgdir"/usr/bin install -m 755 usr/bin/SpiderOak "$pkgdir"/usr/bin/SpiderOak # fix desktop file sed -i \ -e "/Encoding=UTF-8/d" \ -e "/^Name=/s:Backup:Beta:" \ -e "/^Comment=/s:SpiderOak ::" \ -e "/^Categories=/s:SpiderOak;::" \ -e "/^Icon=/s:=.*$:=$_pkgname:" \ -e "/^Exec=/s:=.*$:=SpiderOak:" \ usr/share/applications/"$_pkgname".desktop # install desktop and pixmap files install -d -m 755 "$pkgdir"/usr/share/{applications,pixmaps} install -m 644 usr/share/applications/"$_pkgname".desktop \ "$pkgdir/usr/share/applications/$_pkgname.desktop" install -m 644 usr/share/pixmaps/"$_pkgname".png \ "$pkgdir/usr/share/pixmaps/$_pkgname.png" # install custom license file install -d -m 755 "$pkgdir/usr/share/licenses/$pkgname" install -m 644 terms.txt "$pkgdir/usr/share/licenses/$pkgname/terms.txt" } # vim:set ts=2 sw=2 et: