# Maintainer: BlackIkeEagle # Contributor: TZ86 pkgname=vivaldi-snapshot _rpmversion=2.2.1388.6-1 pkgver=2.2.1388.6 pkgrel=1 pkgdesc='An advanced browser made with the power user in mind. Snapshot' url="https://vivaldi.com" options=(!strip !zipman) license=('custom') arch=('x86_64') depends=('gtk3' 'libcups' 'nss' 'alsa-lib' 'libxss' 'ttf-font' 'desktop-file-utils' 'shared-mime-info' 'hicolor-icon-theme') makedepends=('w3m' 'imagemagick') optdepends=( 'vivaldi-snapshot-ffmpeg-codecs: playback of proprietary video/audio' 'pepper-flash: flash support' 'google-chrome: Widevine DRM Plugin' 'vivaldi-widevine: Widevine DRM Plugin' 'libnotify: native notifications' ) source=("https://downloads.vivaldi.com/snapshot/vivaldi-snapshot-${_rpmversion}.x86_64.rpm") sha512sums=('ab8d9f88bd3f2c6bc53fe1eddffa3f7965a5f62f93086323a6adcf8a28986abf7578701cc2380b2abe1fcce04d85ec057878e675096c36b3188d972e5c9f35d1') package() { cp -a {opt,usr} "$pkgdir" # suid sandbox chmod 4755 "$pkgdir/opt/$pkgname/vivaldi-sandbox" # make /usr/bin/vivaldi-snapshot available binf="$pkgdir/usr/bin/$pkgname" if [[ ! -e "$binf" ]] && [[ ! -f "$binf" ]] && [[ ! -L "$binf" ]]; then install -dm755 "$pkgdir/usr/bin" ln -s /opt/$pkgname/$pkgname "$binf" fi # 256 and 24 are proper colored icons for res in 128 64 48 32; do convert "$pkgdir/opt/$pkgname/product_logo_256.png" \ -resize ${res}x${res} \ "$pkgdir/opt/$pkgname/product_logo_$res.png" done for res in 22 16; do convert "$pkgdir/opt/$pkgname/product_logo_24.png" \ -resize ${res}x${res} \ "$pkgdir/opt/$pkgname/product_logo_$res.png" done # install icons for res in 16 22 24 32 48 64 128 256; do install -Dm644 "$pkgdir/opt/$pkgname/product_logo_${res}.png" \ "$pkgdir/usr/share/icons/hicolor/${res}x${res}/apps/$pkgname.png" done # license install -dm755 "$pkgdir/usr/share/licenses/$pkgname" strings "$pkgdir/opt/$pkgname/locales/en-US.pak" \ | tr '\n' ' ' \ | sed -rne 's/.*(.*html>).*/\1/p' \ | w3m -I 'utf-8' -T 'text/html' \ > "$pkgdir/usr/share/licenses/$pkgname/eula.txt" }