contrast: port away from buildRustPackage

The new setup hooks compose better with Meson setup hooks.

Needed to add libsass – not sure how sass-sys crate built without it before.

+13 -10
+13 -10
pkgs/applications/accessibility/contrast/default.nix
··· 1 - { lib 2 , fetchFromGitLab 3 , cairo 4 , dbus ··· 7 , glib 8 , gtk3 9 , libhandy_0 10 , meson 11 , ninja 12 , pango 13 , pkg-config 14 , python3 15 - , rustc 16 , rustPlatform 17 , wrapGAppsHook 18 }: 19 20 - rustPlatform.buildRustPackage rec { 21 pname = "contrast"; 22 version = "0.0.3"; 23 ··· 30 sha256 = "0kk3mv7a6y258109xvgicmsi0lw0rcs00gfyivl5hdz7qh47iccy"; 31 }; 32 33 - cargoSha256 = "0vi8nv4hkhsgqgz36xacwkk5cxirg6li44nbmk3x7vx7c64hzybq"; 34 35 nativeBuildInputs = [ 36 desktop-file-utils ··· 39 ninja 40 pkg-config 41 python3 42 wrapGAppsHook 43 glib # for glib-compile-resources 44 ]; ··· 49 glib 50 gtk3 51 libhandy_0 52 pango 53 ]; 54 55 postPatch = '' 56 patchShebangs build-aux/meson_post_install.py 57 ''; 58 - 59 - # Don't use buildRustPackage phases, only use it for rust deps setup 60 - configurePhase = null; 61 - buildPhase = null; 62 - checkPhase = null; 63 - installPhase = null; 64 65 meta = with lib; { 66 description = "Checks whether the contrast between two colors meet the WCAG requirements";
··· 1 + { stdenv 2 + , lib 3 , fetchFromGitLab 4 , cairo 5 , dbus ··· 8 , glib 9 , gtk3 10 , libhandy_0 11 + , libsass 12 , meson 13 , ninja 14 , pango 15 , pkg-config 16 , python3 17 , rustPlatform 18 , wrapGAppsHook 19 }: 20 21 + stdenv.mkDerivation rec { 22 pname = "contrast"; 23 version = "0.0.3"; 24 ··· 31 sha256 = "0kk3mv7a6y258109xvgicmsi0lw0rcs00gfyivl5hdz7qh47iccy"; 32 }; 33 34 + cargoDeps = rustPlatform.fetchCargoTarball { 35 + inherit src; 36 + name = "${pname}-${version}"; 37 + hash = "sha256-ePkPiWGn79PHrMsSEql5OXZW5uRMdTP+w0/DCcm2KG4="; 38 + }; 39 40 nativeBuildInputs = [ 41 desktop-file-utils ··· 44 ninja 45 pkg-config 46 python3 47 + rustPlatform.rust.cargo 48 + rustPlatform.cargoSetupHook 49 + rustPlatform.rust.rustc 50 wrapGAppsHook 51 glib # for glib-compile-resources 52 ]; ··· 57 glib 58 gtk3 59 libhandy_0 60 + libsass 61 pango 62 ]; 63 64 postPatch = '' 65 patchShebangs build-aux/meson_post_install.py 66 ''; 67 68 meta = with lib; { 69 description = "Checks whether the contrast between two colors meet the WCAG requirements";