mashu: Add a patched version of libwacom

This commit is contained in:
PapaTutuWawa 2021-09-06 21:13:35 +02:00
parent 92bfd590f4
commit f61c62266f
3 changed files with 39 additions and 1 deletions

View File

@ -5,7 +5,7 @@ let
in mkHost config {
userName = "alexander";
hostName = "mashu";
overlays = [ "nur" "unstable" "simple" "custom" ];
overlays = [ "nur" "unstable" "simple" "custom" "surface" ];
hardwareImports = [
"intel"
"wifi"

View File

@ -14,4 +14,5 @@
unstable = import ./unstable.nix pkgs;
custom = import ./custom.nix pkgs;
simple = import ./simple.nix pkgs;
surface = import ./surface.nix pkgs;
}

37
overlays/surface.nix Normal file
View File

@ -0,0 +1,37 @@
pkgs: final: prev:
let
libwacomPatchesCommit = "f811946d7d8bacb3b9ee75f08c150c435ad59331";
mkPatch = name: sha256: pkgs.fetchpatch {
name = "${name}.patch";
url = "https://raw.githubusercontent.com/linux-surface/libwacom-surface/${libwacomPatchesCommit}/${name}.patch";
sha256 = sha256;
};
in {
libwacom = prev.libwacom.overrideAttrs (old: rec {
version = "1.12";
src = prev.fetchFromGitHub {
owner = "linuxwacom";
repo = "libwacom";
rev = "libwacom-${version}";
sha256 = "130jqzyb3v0knn0i8qib5rdndabj15r66ccj264gg2i53nab88x4";
};
patches = [
(mkPatch "0001-Add-support-for-BUS_VIRTUAL" "1x8jd062gz5jbddj7nm38irfy50092balsrcsjxfd07sqc6f1z7m")
(mkPatch "0002-Add-support-for-Intel-Management-Engine-bus" "0cz7ps9b8p0x62rpi2drhkwifvp99rngvz40qrlm5x2bi1drgavk")
(mkPatch "0003-data-Add-Microsoft-Surface-pro-4" "0f2kn8d25n3zr1j3xvaa50b6jf4gj8kd6pd5vp5vvl9bgs2m9l0j")
(mkPatch "0004-data-Add-Microsoft-Surface-pro-5" "17llns4kmf5hm7h5k6xnhnwxdwfyqlrqzkfr7gml89l0vr1xh194")
(mkPatch "0005-data-Add-Microsoft-Surface-pro-6" "0li3a5j8pdsa5xj69pva7008izkz4gf4vhxmwxflix0isi208ay0")
(mkPatch "0006-data-Add-Microsoft-Surface-pro-7" "0i79ja6yxm99q1xg916105k6j9m1slm7nba6h3q8z7dcj0x6ndsy")
(mkPatch "0007-data-Add-Microsoft-Surface-Book" "15hqyc6853rjd33gcnq59rl5wc42fj1xm1iin2l3f95nqk5fyqfc")
(mkPatch "0008-data-Add-Microsoft-Surface-Book-2-13.5" "1sx7v849fv225avhpi73dnf0azgwk570fv8r6ypvc5kzxz8ljjmj")
(mkPatch "0009-data-Add-Microsoft-Surface-Book-2-15" "00vyjlmgh7ziic77k5vfp9y02fdqqdc1f729y30plyvjy6vxmw11")
(mkPatch "0010-data-Add-Microsoft-Surface-Book-3-13.5" "10w6npa8lsikxjwvfzz3jhwj9dx1zg3djaq0jkmns2qqbs23s9ml")
(mkPatch "0011-data-Add-Microsoft-Surface-Book-3-15" "03yl4v9b160rbynj1zpsg3xjysj269yawz1x8jjkr6j4ka3l0ldx")
];
# TODO: ???
buildInputs = old.buildInputs ++ [prev.python3];
});
}