#Packager: Dimitris Tzemos pkgname=brave-browser pkgver=1.20.110 pkgrel=1dj arch=${arch:-x86_64} url="https://brave.com/" source=("https://github.com/brave/brave-browser/releases/download/v${pkgver}/brave-browser-${pkgver}-1.x86_64.rpm") doinst() { # update the mime desktop database if [ -x /usr/bin/update-desktop-database ]; then /usr/bin/update-desktop-database -q fi # update the mime database if [ -x /usr/bin/update-mime-database ]; then /usr/bin/update-mime-database usr/share/mime > /dev/null 2>&1 fi } slackdesc=\ ( #|-----handy-ruler------------------------------------------------------| "brave-browser (a safer, faster, and better Web browsing experience)" "Brave is a free and open-source web browser developed by Brave" "Software, Inc. based on the Chromium web browser." "" "https://brave-browser.com" ) build() { # we don't need cflags since nothing is being compiled here. # we do need to check the architecture though and abort when it's not # supported. if [ ! "$arch" = "x86_64" ]; then echo "Sorry, binary packages are available only for x86_64. Aborting." exit 1 fi cd $SRC/ rpm2cpio < $SRC/$pkgname-$pkgver-1.${arch}.rpm | cpio -imdv # create directories mkdir -p $PKG/opt || return 1 mkdir -p $PKG/usr/bin || return 1 mkdir -p $PKG/usr/share/applications || return 1 # install brave browser into /opt cp -ap usr opt $PKG/ || return 1 # Slackware doesn't ship a GNOME desktop so I don't see any reason for gnome-control-center rm -rf $PKG/usr/share/gnome-control-center # Move icon into place mkdir -p $PKG/usr/share/pixmaps cp opt/brave.com/brave/*.xpm $PKG/usr/share/pixmaps/brave-browser.xpm # Place man page(s) where The Man likes 'em mv $PKG/usr/share/man $PKG/usr/man }