Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib
2, stdenvNoCC
3, coreutils
4}:
5
6{ version
7, src
8, patches ? [ ]
9}:
10
11stdenvNoCC.mkDerivation {
12 inherit patches src version;
13
14 pname = "fedora${lib.versions.major version}-backgrounds";
15
16 dontBuild = true;
17
18 postPatch = ''
19 for f in default/Makefile extras/Makefile; do
20 substituteInPlace $f \
21 --replace "usr/share" "share" \
22 --replace "/usr/bin/" "" \
23 --replace "/bin/" ""
24 done
25
26 for f in $(find . -name '*.xml'); do
27 substituteInPlace $f \
28 --replace "/usr/share" "$out/share"
29 done;
30 '';
31
32 installFlags = [
33 "DESTDIR=$(out)"
34
35 # The Xfce background directory is assumed to be in installed in an
36 # FHS-compliant system. This is only effective for v36.0.0 and later
37 # versions where the following variable is used.
38 "WP_DIR_LN=$(DESTDIR)/share/backgrounds/$(WP_NAME)"
39 ];
40
41 meta = with lib; {
42 homepage = "https://github.com/fedoradesign/backgrounds";
43 description = "Set of default and supplemental wallpapers for Fedora";
44 license = licenses.cc-by-sa-40;
45 platforms = platforms.unix;
46 maintainers = [ ];
47 };
48}