diff --git a/srcpkgs/chromium/files/chromium.sh b/srcpkgs/chromium/files/chromium.sh index 92c19fc4057..8d9dd7162da 100644 --- a/srcpkgs/chromium/files/chromium.sh +++ b/srcpkgs/chromium/files/chromium.sh @@ -1,4 +1,5 @@ #!/bin/sh export CHROME_WRAPPER=/usr/lib/chromium/chromium export CHROME_DESKTOP=chromium.desktop +CHROME_FLAGS="--enable-gpu-rasterization" exec /usr/lib/chromium/chromium $CHROME_FLAGS "$@" diff --git a/srcpkgs/chromium/files/i686-patches/chromium-i686-vaapi-fpermissive.patch b/srcpkgs/chromium/files/i686-patches/chromium-i686-vaapi-fpermissive.patch new file mode 100644 index 00000000000..a099f5fac5d --- /dev/null +++ b/srcpkgs/chromium/files/i686-patches/chromium-i686-vaapi-fpermissive.patch @@ -0,0 +1,23 @@ +--- media/gpu/vaapi/BUILD.gn.i686permissive 2018-11-29 09:27:02.405909871 -0500 ++++ media/gpu/vaapi/BUILD.gn 2018-11-29 09:29:50.648259696 -0500 +@@ -10,6 +10,11 @@ import("//ui/ozone/ozone.gni") + + assert(use_vaapi) + ++config("vaapi_permissive") { ++ cflags = [ "-fpermissive" ] ++} ++ ++ + action("libva_generate_stubs") { + extra_header = "va_stub_header.fragment" + +@@ -98,6 +103,8 @@ source_set("vaapi") { + "//third_party/libyuv", + ] + ++ configs += [ ":vaapi_permissive" ] ++ + if (use_x11) { + configs += [ "//build/config/linux:x11" ] + deps += [ "//ui/gfx/x" ] diff --git a/srcpkgs/chromium/files/chromium-enable-vaapi.patch b/srcpkgs/chromium/patches/chromium-enable-vaapi.patch similarity index 100% rename from srcpkgs/chromium/files/chromium-enable-vaapi.patch rename to srcpkgs/chromium/patches/chromium-enable-vaapi.patch diff --git a/srcpkgs/chromium/template b/srcpkgs/chromium/template index af33a2aebf0..b1eed4e54c6 100644 --- a/srcpkgs/chromium/template +++ b/srcpkgs/chromium/template @@ -2,11 +2,11 @@ pkgname=chromium # See http://www.chromium.org/developers/calendar for the latest version version=70.0.3538.110 -revision=1 +revision=2 short_desc="Google's attempt at creating a safer, faster, and more stable browser" maintainer="Rasmus Thomsen " -homepage="https://www.chromium.org/" license="BSD-3-Clause" +homepage="https://www.chromium.org/" distfiles="https://commondatastorage.googleapis.com/chromium-browser-official/${pkgname}-${version}.tar.xz" checksum=445ef88fcf283206c1eba4faeb1c186c805e053d8b4ffeac1fcb88187bc1942f @@ -30,16 +30,11 @@ makedepends="libpng-devel gtk+-devel gtk+3-devel nss-devel pciutils-devel libjpeg-turbo-devel libevent-devel json-c-devel harfbuzz-devel minizip-devel jsoncpp-devel zlib-devel libcap-devel libXdamage-devel re2-devel fontconfig-devel freetype-devel harfbuzz-devel opus-devel - ffmpeg-devel" + ffmpeg-devel libva-devel" depends="libexif hwids desktop-file-utils hicolor-icon-theme" build_options_default="jumbo_build" -# Chromium's VAAPI stuff doesn't build on i686 -if [ "${XBPS_TARGET_MACHINE}" != "i686" ]; then - makedepends+=" libva-devel" -fi - post_extract() { case "${XBPS_TARGET_MACHINE}" in *-musl) @@ -48,12 +43,13 @@ post_extract() { patch -Np0 -i "$f" done ;; + i686) + for f in "${FILESDIR}"/i686-patches/*.patch; do + echo "Applying $f" + patch -Np0 -i "$f" + done esac - if [ "${XBPS_TARGET_MACHINE}" != "i686" ]; then - patch -Np0 -i "${FILESDIR}"/chromium-enable-vaapi.patch - fi - # Use the file at run time instead of effectively compiling it in sed 's|//third_party/usb_ids/usb.ids|/usr/share/hwdata/usb.ids|g' \ -i device/usb/BUILD.gn @@ -162,12 +158,10 @@ do_configure() { # Jumbo/Unity builds: https://chromium.googlesource.com/chromium/src/+/master/docs/jumbo.md conf+=( "use_jumbo_build=$(vopt_if jumbo_build true false)" ) - # Enable VAAPI. Doesn't compile on i686 - if [ "${XBPS_TARGET_MACHINE}" != "i686" ]; then - conf+=( - 'use_vaapi=true' - ) - fi + # Enable VAAPI - hardware accelerated video decoding. + conf+=( + 'use_vaapi=true' + ) # Use explicit library dependencies instead of dlopen. # GN only has "link_pulseaudio", the other options used before are not available atm