diff --git a/pkgs/data/icons/bibata-cursors/default.nix b/pkgs/data/icons/bibata-cursors/default.nix index 04fb6281f253..15905bec3a97 100644 --- a/pkgs/data/icons/bibata-cursors/default.nix +++ b/pkgs/data/icons/bibata-cursors/default.nix @@ -1,51 +1,54 @@ -{ lib, stdenvNoCC, fetchFromGitHub, gnome-themes-extra, inkscape, xcursorgen, python3 }: +{ lib +, stdenv +, fetchFromGitHub +, fetchurl +, clickgen +, unzip +}: -let - py = python3.withPackages(ps: [ ps.pillow ]); -in stdenvNoCC.mkDerivation rec { +stdenv.mkDerivation rec { pname = "bibata-cursors"; - version = "0.4.2"; + version = "1.1.2"; src = fetchFromGitHub { - owner = "KaizIqbal"; + owner = "ful1e5"; repo = "Bibata_Cursor"; rev = "v${version}"; - sha256 = "1f7i5jkl21fvrr45zpcj40avkc7camjb1ddrrdlaabbplgz5mcgn"; + sha256 = "1q2wdbrmdnr9mwiilm5cc9im3zwbl7yaj1zpy5wwn44ypq3hcngy"; }; - postPatch = '' - patchShebangs . - substituteInPlace build.sh --replace "sudo" "" + bitmaps = fetchurl { + url = "https://github.com/ful1e5/Bibata_Cursor/releases/download/v${version}/bitmaps.zip"; + sha256 = "1pcn6par0f0syyhzpzmqr3c6b9ri4lprkdd2ncwzdas01p2d9v1i"; + }; - # Don't generate windows cursors, - # they aren't used and aren't installed - # by the project's install script anyway. - echo "exit 0" > w32-make.sh - ''; + nativeBuildInputs = [ unzip ]; - nativeBuildInputs = [ - gnome-themes-extra - inkscape - xcursorgen - py - ]; + buildInputs = [ clickgen ]; buildPhase = '' - HOME="$NIX_BUILD_ROOT" ./build.sh + mkdir bitmaps + unzip $bitmaps -d bitmaps + rm -rf themes + cd builder && make build_unix ''; installPhase = '' install -dm 0755 $out/share/icons - for x in Bibata_*; do - cp -pr $x/out/X11/$x $out/share/icons/ - done + cd ../ + cp -rf themes/* $out/share/icons/ + ''; + + postPatch = '' + substituteInPlace "builder/Makefile" \ + --replace "/bin/bash" "bash" ''; meta = with lib; { - description = "Material Based Cursor"; - homepage = "https://github.com/KaizIqbal/Bibata_Cursor"; + description = "Material Based Cursor Theme"; + homepage = "https://github.com/ful1e5/Bibata_Cursor"; license = licenses.gpl3; platforms = platforms.linux; - maintainers = with maintainers; [ rawkode ]; + maintainers = with maintainers; [ rawkode AdsonCicilioti ]; }; }