widevine update?
This commit is contained in:
parent
a435fa66d8
commit
dfc6793a92
|
@ -5,41 +5,44 @@
|
||||||
python3,
|
python3,
|
||||||
# Depends on kernel used, in kb
|
# Depends on kernel used, in kb
|
||||||
pageSize ? 4,
|
pageSize ? 4,
|
||||||
}:
|
}: let
|
||||||
stdenv.mkDerivation {
|
lacrosVersion = "128.0.6613.119";
|
||||||
pname = "widevine-aarch64-${toString pageSize}k";
|
widevineVersion = "4.10.2662.3";
|
||||||
version = "4.10.2662.3";
|
in
|
||||||
|
stdenv.mkDerivation {
|
||||||
|
pname = "widevine-aarch64-${toString pageSize}k";
|
||||||
|
version = "4.10.2662.3";
|
||||||
|
|
||||||
srcs = fetchurl {
|
srcs = fetchurl {
|
||||||
url = "https://commondatastorage.googleapis.com/chromeos-localmirror/distfiles/chromeos-lacros-arm64-squash-zstd-120.0.6098.0";
|
url = "https://commondatastorage.googleapis.com/chromeos-localmirror/distfiles/chromeos-lacros-arm64-squash-zstd-${lacrosVersion}";
|
||||||
hash = "sha256-OKV8w5da9oZ1oSGbADVPCIkP9Y0MVLaQ3PXS3ZBLFXY=";
|
hash = "sha256-Q3g2npzSh9imzn36AR8EDWB5LS9MlhRBEqalNCLDxHI=";
|
||||||
};
|
};
|
||||||
|
|
||||||
unpackPhase = ":";
|
unpackPhase = ":";
|
||||||
sourceRoot = ".";
|
sourceRoot = ".";
|
||||||
|
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
unsquashfs -q $srcs 'WidevineCdm/*'
|
unsquashfs -q $srcs 'WidevineCdm/*'
|
||||||
env TARGET_PAGE_SIZE=${toString (pageSize * 1024)} python3 "${./widevine_fixup.py}" squashfs-root/WidevineCdm/_platform_specific/cros_arm64/libwidevinecdm.so libwidevinecdm.so
|
env TARGET_PAGE_SIZE=${toString (pageSize * 1024)} python3 ${./widevine_fixup.py} squashfs-root/WidevineCdm/_platform_specific/cros_arm64/libwidevinecdm.so libwidevinecdm.so
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# TODO: systemwide install
|
# TODO: systemwide install
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
install -d -m 0755 "$out"
|
install -d -m 0755 "$out"
|
||||||
install -p -m 0755 -t "$out" libwidevinecdm.so
|
install -p -m 0755 -t "$out" libwidevinecdm.so
|
||||||
install -p -m 0644 -t "$out" squashfs-root/WidevineCdm/manifest.json
|
install -p -m 0644 -t "$out" squashfs-root/WidevineCdm/manifest.json
|
||||||
install -p -m 0644 -t "$out" squashfs-root/WidevineCdm/LICENSE
|
install -p -m 0644 -t "$out" squashfs-root/WidevineCdm/LICENSE
|
||||||
|
|
||||||
mkdir -p "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_arm64"
|
mkdir -p "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_arm64"
|
||||||
mkdir -p "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_x64"
|
mkdir -p "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_x64"
|
||||||
# Hack because Chromium hardcodes a check for this right now...
|
# Hack because Chromium hardcodes a check for this right now...
|
||||||
touch "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so"
|
touch "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so"
|
||||||
ln -sf ../../../../manifest.json "$out/share/google/chrome/WidevineCdm"
|
ln -sf ../../../../manifest.json "$out/share/google/chrome/WidevineCdm"
|
||||||
ln -sf ../../../../../../libwidevinecdm.so "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_arm64/"
|
ln -sf ../../../../../../libwidevinecdm.so "$out/share/google/chrome/WidevineCdm/_platform_specific/linux_arm64/"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
squashfsTools
|
squashfsTools
|
||||||
python3
|
python3
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue