nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 mkKdeDerivation,
4 runCommandLocal,
5 makeWrapper,
6 glib,
7 gsettings-desktop-schemas,
8 replaceVars,
9 util-linux,
10 pkg-config,
11 qtsvg,
12 qtwayland,
13 breeze,
14 SDL2,
15 xkeyboard_config,
16 xorg,
17 libcanberra,
18 libwacom,
19 libxkbfile,
20 ibus,
21}:
22let
23 # run gsettings with desktop schemas for using in "kcm_access" kcm
24 # and in kaccess
25 gsettings-wrapper = runCommandLocal "gsettings-wrapper" { nativeBuildInputs = [ makeWrapper ]; } ''
26 mkdir -p $out/bin
27 makeWrapper ${glib}/bin/gsettings $out/bin/gsettings --prefix XDG_DATA_DIRS : ${gsettings-desktop-schemas.out}/share/gsettings-schemas/${gsettings-desktop-schemas.name}
28 '';
29in
30mkKdeDerivation {
31 pname = "plasma-desktop";
32
33 patches = [
34 (replaceVars ./hwclock-path.patch {
35 hwclock = "${lib.getBin util-linux}/bin/hwclock";
36 })
37 (replaceVars ./kcm-access.patch {
38 gsettings = "${gsettings-wrapper}/bin/gsettings";
39 })
40 ./tzdir.patch
41 ./no-discover-shortcut.patch
42 (replaceVars ./wallpaper-paths.patch {
43 wallpapers = "${lib.getBin breeze}/share/wallpapers";
44 })
45 ];
46
47 extraNativeBuildInputs = [ pkg-config ];
48 extraBuildInputs = [
49 qtsvg
50 qtwayland
51
52 SDL2
53 libcanberra
54 libwacom
55 libxkbfile
56 xkeyboard_config
57
58 xorg.libXcursor
59 xorg.libXft
60 xorg.xf86inputlibinput
61 xorg.xf86inputevdev
62 xorg.xorgserver
63
64 ibus
65 ];
66
67 # wrap kaccess with wrapped gsettings so it can access accessibility schemas
68 qtWrapperArgs = [ "--prefix PATH : ${lib.makeBinPath [ gsettings-wrapper ]}" ];
69}