Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 14 additions & 17 deletions .nix/pkgs/graphite-cef.nix
Original file line number Diff line number Diff line change
@@ -1,30 +1,27 @@
{ pkgs, ... }:

let
version = "149.0.5+g6770623+chromium-149.0.7827.197";
hashes = {
aarch64-linux = "sha256-cBAvcvs1rAg5EKJkCt81RZYupCWpUNIC/nLt3PJow7Q=";
x86_64-linux = "sha256-OPGMBJmvvLiLdBDniBQwx7LmTGGI59AcesJdILSeqcs=";
};
version = "149.7827.0";
upstream = "149.0.5+g6770623+chromium-149.0.7827.197";

selectSystem =
attrs:
attrs.${pkgs.stdenv.hostPlatform.system}
or (throw "Unsupported system ${pkgs.stdenv.hostPlatform.system}");

src = pkgs.fetchurl {
url = "https://cef-builds.spotifycdn.com/cef_binary_${version}_${
selectSystem {
aarch64-linux = "linuxarm64";
x86_64-linux = "linux64";
}
}_minimal.tar.bz2";
hash = selectSystem hashes;
src = selectSystem {
x86_64-linux = pkgs.fetchurl {
url = "https://github.com/timon-schelling/graphite-cef/releases/download/v${version}/graphite_cef_x86-64_linux.tar.xz";
hash = "sha256-aXOlu1045CB3UWSNIIzg2EoQ2D79DYAoZ0FOnCgYWZg=";
};
aarch64-linux = pkgs.fetchurl {
url = "https://cef-builds.spotifycdn.com/cef_binary_${upstream}_linuxarm64_minimal.tar.bz2";
hash = "sha256-cBAvcvs1rAg5EKJkCt81RZYupCWpUNIC/nLt3PJow7Q=";
};
};
in
pkgs.cef-binary.overrideAttrs (finalAttrs: {
version = builtins.head (builtins.split "\\+" version);
inherit src;
pkgs.cef-binary.overrideAttrs (_: {
inherit src version;
Comment thread
timon-schelling marked this conversation as resolved.
postInstall = ''
rm -r $out/* $out/.* || true
strip ./Release/*.so*
Expand All @@ -38,7 +35,7 @@ pkgs.cef-binary.overrideAttrs (finalAttrs: {
echo '${
builtins.toJSON {
type = "minimal";
name = builtins.baseNameOf finalAttrs.src.url;
name = "cef_binary_${upstream}";
sha1 = "";
}
}' > $out/archive.json
Expand Down
Loading