diff options
author Ruari Oedegaard <>2022-05-20 23:52:53 +0100
committer Willy Sudiarto Raharjo <>2022-05-21 08:25:32 +0700
commit1c53f1629e3e8a5fd45a074bf839cdf7faa4c0b6 (patch)
parent9579f9b2f4449e61fb4e0a0d9e4386a72f57b1d2 (diff)
network/vivaldi: Updated for version 5.2.2623.48.
Signed-off-by: Dave Woodfall <> Signed-off-by: Willy Sudiarto Raharjo <>
6 files changed, 68 insertions, 45 deletions
diff --git a/network/vivaldi/README b/network/vivaldi/README
index 4abc7d7eba..a6b095a1b1 100644
--- a/network/vivaldi/README
+++ b/network/vivaldi/README
@@ -5,4 +5,3 @@ Experience the web in a whole new way with Vivaldi.
Vivaldi is a browser that has the features you need, a style that fits
and values you can stand by. Your browser matters. Take control with
diff --git a/network/vivaldi/README.SBo b/network/vivaldi/README.SBo
new file mode 100644
index 0000000000..91f83743fa
--- /dev/null
+++ b/network/vivaldi/README.SBo
@@ -0,0 +1,38 @@
+# Proprietary media support
+Vivaldi does not directly bundle any library with support for
+"proprietary media" (H.264/AAC), since this would make redistribution of
+the output package difficult (due to software patent licensing).
+Instead, the script '/opt/vivaldi/update-ffmpeg' fetches a suitable lib
+from a third party (and verifies it). This can be run in two ways.
+## System-wide install
+The recommended method is for the user to run it as root (with no
+arguments) immediately after installing (or upgrading) Vivaldi, but
+before first run. The file will then be placed in '/var/opt/vivaldi' and
+found by Vivaldi when you launch it afterwards.
+Files installed this way will even be cleaned up automatically on
+uninstall by ''. Alternatively running 'update-ffmpeg' again
+(as root) with '--undo' will also remove the lib and associated
+## Per-user install
+If you do not run the 'update-ffmpeg' as root before first run, Vivaldi
+will call this script itself, automatically on first launch (with the
+option '--user'). In this case the lib will be installed into
+'~/.local/lib/vivaldi' (for each user who launches Vivaldi) and will
+then be available, from the next restart (of the browser).
+If you wish to remove the file from '~/.local/lib/vivaldi', you can run
+'update-ffmpeg' as follows:
+ /opt/vivaldi/update-ffmpeg --user --undo
+Alternatively look in '~/.local/lib/vivaldi' and remove the files
+NOTE: Keep in mind the lib will be automatically reinstalled in
+'~/.local/lib/vivaldi' if any user on the system launches Vivaldi again.
diff --git a/network/vivaldi/ b/network/vivaldi/
index 1d19707da6..65c7e2eeb9 100644
--- a/network/vivaldi/
+++ b/network/vivaldi/
@@ -7,10 +7,3 @@ if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
/usr/bin/gtk-update-icon-cache -f usr/share/icons/hicolor >/dev/null 2>&1
-# Adding a suitable with support for H.264 & AAC directly into
-# the package makes redistribution of the output package difficult.
-# The following is used in postinstall for the official rpm and debs.
-# (Cleanup on uninstall will be handled by
-nohup /opt/vivaldi/update-ffmpeg > /dev/null 2>&1 &
diff --git a/network/vivaldi/ b/network/vivaldi/
index 2ab916b6df..879cbcec64 100644
--- a/network/vivaldi/
+++ b/network/vivaldi/
@@ -1,9 +1,11 @@
-# Remove any lib fetched by update-ffmpeg, when was first run
-if ls /var/opt/vivaldi/media-codecs-*/ >/dev/null 2>&1; then
- rm /var/opt/vivaldi/media-codecs-*/
+# Remove any lib fetched by '/opt/vivaldi/update-ffmpeg' that was
+# installed system-wide into '/var/opt'
+rm -f /var/opt/vivaldi/media-codecs-*/
if [ -d /var/opt/vivaldi ]; then
# This removes directory trees that are empty or only populated by other
# empty directories.
find /var/opt/vivaldi -depth -type d -empty -exec rmdir {} \;
+ # '/var/opt' is not part of the default Slackware install, so we will
+ # remove it, if it is now empty (following the above).
+ rmdir --ignore-fail-on-non-empty /var/opt
diff --git a/network/vivaldi/vivaldi.SlackBuild b/network/vivaldi/vivaldi.SlackBuild
index e6e90a0135..7a951c7c3b 100644
--- a/network/vivaldi/vivaldi.SlackBuild
+++ b/network/vivaldi/vivaldi.SlackBuild
@@ -27,7 +27,7 @@
cd $(dirname $0) ; CWD=$(pwd)
@@ -65,17 +65,25 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-rm -r opt/vivaldi/cron
+rm -r opt/vivaldi/cron usr/share/doc
mv opt usr $PKG/
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-# Make symlinks relative
+# Create relative symlinks (first removing any potentially non-relative
+# ones).
rm -f $PKG/usr/bin/vivaldi* $PKG/opt/vivaldi/WidevineCdm
ln -s ../../opt/vivaldi/vivaldi $PKG/usr/bin/vivaldi
ln -s ../../opt/vivaldi/vivaldi $PKG/usr/bin/vivaldi-stable
-# Note that this is a broken link until the user manually installs widevineCdm
+# This following may appear as a broken/dangling symlink but it actually
+# can be used by Vivaldi as a fallback source for Widevine in cases
+# where, Google Chrome is also installed (it bundles Widevine at the
+# linked location) and the components system in the browser
+# (vivaldi://components) is non-functional.
ln -s ../google/chrome/WidevineCdm $PKG/opt/vivaldi/WidevineCdm
for res in 16 22 24 32 48 64 128 256; do
@@ -89,33 +97,14 @@ sed \
> $PKG/usr/share/applications/vivaldi.desktop
rm $PKG/usr/share/applications/vivaldi-stable.desktop
-mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-gzip -dc $PKG/usr/share/doc/vivaldi-stable/changelog.gz > \
- $PKG/usr/doc/$PRGNAM-$VERSION/ChangeLog
-rm -rf $PKG/usr/share/doc
-cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
-# Add a note about uninstall on Slackware 14.2
-cat <<EON> $PKG/usr/doc/$PRGNAM-$VERSION/UNINSTALL-Slackware-14.2.txt
-Since '${0##*/}' was created with Slackware 15 and above in mind, it
-uses the new '' script to clear down any proprietary media libs
-fetched by 'update-ffmpeg' during post install.
-If you run 14.2 (or older), make a copy of the *before* uninstall:
- cp /var/lib/pkgtools/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG .
-Then simply run it as root after uninstall.
-(If you forget it is not the end of the world, you will just potentially leave
-behind a small file [] under /var/opt/vivaldi*)
+for doc in README README.SBo $PRGNAM.SlackBuild; do
+ install -Dm644 $CWD/$doc $PKG/usr/doc/$PRGNAM-$VERSION/$doc
+lynx -dump file://$CWD/${VERSION}.html > $PKG/usr/doc/$PRGNAM-$VERSION/ChangeLog
-mkdir -p $PKG/install $PKG/var/lib/pkgtools/
-cat $CWD/slack-desc > $PKG/install/slack-desc
-cat $CWD/ > $PKG/install/
-cat $CWD/ > $PKG/var/lib/pkgtools/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG
+for meta in slack-desc; do
+ install -Dm644 $CWD/$meta $PKG/install/$meta
cd $PKG
diff --git a/network/vivaldi/ b/network/vivaldi/
index f84fe650a6..29eaeb3c5e 100644
--- a/network/vivaldi/
+++ b/network/vivaldi/
@@ -1,10 +1,12 @@
+DOWNLOAD_x86_64=" \
+MD5SUM_x86_64="a1c902fb92b9c0f5ada64cbaa5cc1138 \
+ 22723acaf3373ec3c1d1c00408214fc9"
MAINTAINER="Ruari Oedegaard"