nongnu: Add chromium-widevine.
* nongnu/packages/chromium.scm (chromium-widevine): New variable.
This commit is contained in:
parent
9cf7157308
commit
9523218112
|
@ -1,5 +1,6 @@
|
||||||
;;; GNU Guix --- Functional package management for GNU
|
;;; GNU Guix --- Functional package management for GNU
|
||||||
;;; Copyright © 2022 Pierre Neidhardt <mail@ambrevar.xyz>
|
;;; Copyright © 2022 Pierre Neidhardt <mail@ambrevar.xyz>
|
||||||
|
;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is not part of GNU Guix.
|
;;; This file is not part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -18,6 +19,7 @@
|
||||||
|
|
||||||
(define-module (nongnu packages chromium)
|
(define-module (nongnu packages chromium)
|
||||||
#:use-module ((guix licenses) #:prefix license:)
|
#:use-module ((guix licenses) #:prefix license:)
|
||||||
|
#:use-module ((nonguix licenses) #:prefix license-nonfree:)
|
||||||
#:use-module (guix packages)
|
#:use-module (guix packages)
|
||||||
#:use-module (guix gexp)
|
#:use-module (guix gexp)
|
||||||
#:use-module (guix download)
|
#:use-module (guix download)
|
||||||
|
@ -28,6 +30,7 @@
|
||||||
#:use-module (gnu packages base)
|
#:use-module (gnu packages base)
|
||||||
#:use-module (gnu packages cmake)
|
#:use-module (gnu packages cmake)
|
||||||
#:use-module (gnu packages cups)
|
#:use-module (gnu packages cups)
|
||||||
|
#:use-module (gnu packages freedesktop)
|
||||||
#:use-module (gnu packages gcc)
|
#:use-module (gnu packages gcc)
|
||||||
#:use-module (gnu packages gl)
|
#:use-module (gnu packages gl)
|
||||||
#:use-module (gnu packages glib)
|
#:use-module (gnu packages glib)
|
||||||
|
@ -161,3 +164,68 @@ applications.
|
||||||
@end itemize\n")
|
@end itemize\n")
|
||||||
(home-page "https://bitbucket.org/chromiumembedded/cef")
|
(home-page "https://bitbucket.org/chromiumembedded/cef")
|
||||||
(license license:bsd-3))))
|
(license license:bsd-3))))
|
||||||
|
|
||||||
|
(define-public chromium-widevine
|
||||||
|
(let ((version "4.10.2449.0")
|
||||||
|
(chromium-version "103.0.5060.114"))
|
||||||
|
(package
|
||||||
|
(name "chromium-widevine")
|
||||||
|
(version version)
|
||||||
|
(source (origin
|
||||||
|
(method url-fetch)
|
||||||
|
(uri (string-append
|
||||||
|
"https://dl.google.com/linux/deb/pool/main/g/google-chrome-stable/google-chrome-stable_"
|
||||||
|
chromium-version "-1_amd64.deb"))
|
||||||
|
(sha256
|
||||||
|
(base32
|
||||||
|
"1qxbnnnq0miizazprwynvxxvgaaw9dd9y7bssybvmga3g2c00fk9"))))
|
||||||
|
(build-system binary-build-system)
|
||||||
|
(arguments
|
||||||
|
(list
|
||||||
|
;; #:patchelf-plan
|
||||||
|
;; #~`(("" ("gcc"
|
||||||
|
;; "glib"
|
||||||
|
;; "glibc"
|
||||||
|
;; "nspr"
|
||||||
|
;; ("nss" "/lib/nss")
|
||||||
|
;; "pango")))
|
||||||
|
#:install-plan #~`(("opt/google/chrome" "usr/"))
|
||||||
|
#:phases #~(modify-phases %standard-phases
|
||||||
|
(replace 'unpack
|
||||||
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
|
(invoke "ar" "x"
|
||||||
|
#$source)
|
||||||
|
(invoke "tar" "xJf" "data.tar.xz")))
|
||||||
|
(add-after 'install 'xdg-utils
|
||||||
|
(lambda* _
|
||||||
|
(let* ((chrome (string-append #$output
|
||||||
|
"/usr/chrome/"))
|
||||||
|
(xdg-mime (string-append chrome
|
||||||
|
"/xdg-mime"))
|
||||||
|
(xdg-settings (string-append chrome
|
||||||
|
"/xdg-settings")))
|
||||||
|
(delete-file xdg-mime)
|
||||||
|
(delete-file xdg-settings)
|
||||||
|
(symlink (string-append #$xdg-utils
|
||||||
|
"/bin/xdg-utils")
|
||||||
|
xdg-mime)
|
||||||
|
(symlink (string-append #$xdg-utils
|
||||||
|
"/bin/xdg-settings")
|
||||||
|
xdg-settings)))))))
|
||||||
|
;; TODO: attempt to replace libvulkan.so.1 from vulkan-loader
|
||||||
|
;; TODO: attempt to replace also chrome with our own
|
||||||
|
;; -> learn how the WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so
|
||||||
|
;; works - is it loaded by Chrome as it scans the dirs or does the chrome
|
||||||
|
;; binary in this package have additional code which loads it
|
||||||
|
(inputs (list `(,gcc "lib")
|
||||||
|
wayland
|
||||||
|
glib
|
||||||
|
nspr
|
||||||
|
nss
|
||||||
|
xdg-utils))
|
||||||
|
(synopsis "Embed Chromium-based browsers in other applications")
|
||||||
|
(supported-systems '("armhf-linux" "aarch64-linux" "x86_64-linux"))
|
||||||
|
(description "")
|
||||||
|
(home-page "https://www.widevine.com")
|
||||||
|
(license (license-nonfree:nonfree
|
||||||
|
"https://developers.google.com/widevine/drm/overview#issuing_widevine_licenses")))))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user