2021-03-15 08:37:03 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchFromGitLab
|
|
|
|
, cairo
|
2023-05-24 13:37:59 +00:00
|
|
|
, cargo
|
2020-04-24 23:36:52 +00:00
|
|
|
, desktop-file-utils
|
|
|
|
, gettext
|
|
|
|
, glib
|
2022-02-10 20:34:41 +00:00
|
|
|
, gtk4
|
|
|
|
, libadwaita
|
2020-04-24 23:36:52 +00:00
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, pango
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
, rustPlatform
|
2023-05-24 13:37:59 +00:00
|
|
|
, rustc
|
2022-02-10 20:34:41 +00:00
|
|
|
, wrapGAppsHook4
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "contrast";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "0.0.8";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitLab {
|
|
|
|
domain = "gitlab.gnome.org";
|
|
|
|
group = "World";
|
|
|
|
owner = "design";
|
|
|
|
repo = "contrast";
|
|
|
|
rev = version;
|
2023-05-24 13:37:59 +00:00
|
|
|
hash = "sha256-5OFmLsP+Xk3sKJcUG/s8KwedvfS8ri+JoinliyJSmrY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
|
|
|
inherit src;
|
|
|
|
name = "${pname}-${version}";
|
2023-05-24 13:37:59 +00:00
|
|
|
hash = "sha256-8WukhoKMyApkwqPQ6KeWMsL40sMUcD4I4l7UqXf2Ld0=";
|
2021-03-15 08:37:03 +00:00
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
desktop-file-utils
|
|
|
|
gettext
|
|
|
|
meson
|
|
|
|
ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2023-05-24 13:37:59 +00:00
|
|
|
cargo
|
2021-03-15 08:37:03 +00:00
|
|
|
rustPlatform.cargoSetupHook
|
2023-05-24 13:37:59 +00:00
|
|
|
rustc
|
2022-02-10 20:34:41 +00:00
|
|
|
wrapGAppsHook4
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
cairo
|
|
|
|
glib
|
2022-02-10 20:34:41 +00:00
|
|
|
gtk4
|
|
|
|
libadwaita
|
2020-04-24 23:36:52 +00:00
|
|
|
pango
|
|
|
|
];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Checks whether the contrast between two colors meet the WCAG requirements";
|
|
|
|
homepage = "https://gitlab.gnome.org/World/design/contrast";
|
2022-02-10 20:34:41 +00:00
|
|
|
license = licenses.gpl3Plus;
|
2023-05-24 13:37:59 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2022-02-10 20:34:41 +00:00
|
|
|
platforms = platforms.unix;
|
2022-12-17 10:02:37 +00:00
|
|
|
# never built on aarch64-darwin, x86_64-darwin since first introduction in nixpkgs
|
|
|
|
broken = stdenv.isDarwin;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|