nixpkgs/pkgs/tools/misc/xdaliclock/default.nix
Jan Tojnar eb04659fc2 treewide: wrapGAppsHook → wrapGAppsHook3
This was achieved using the following command:

    sd 'wrapGAppsHook\b' wrapGAppsHook3 (rg -l 'wrapGAppsHook\b')

And then manually reverted the following changes:

- alias in top-level.nix
- function name in wrap-gapps-hook.sh
- comment in postFixup of at-spi2-core
- comment in gtk4
- comment in preFixup of 1password-gui/linux.nix
- comment in postFixup of qgis/unwrapped-ltr.nix and qgis/unwrapped.nix
- comment in postFixup of telegram-desktop
- comment in postFixup of fwupd
- buildCommand of mongodb-compass
- postFixup of xflux-gui
- comment in a patch in kdePackages.kde-gtk-config and plasma5Packages.kde-gtk-config
- description of programs.sway.wrapperFeatures.gtk NixOS option (manual rebuild)
2024-04-27 02:23:22 +02:00

48 lines
1.3 KiB
Nix

{ lib, stdenv, fetchurl
, gtk3
, wrapGAppsHook3
, pkg-config }:
stdenv.mkDerivation rec {
pname = "xdaliclock";
version = "2.48";
src = fetchurl {
url = "https://www.jwz.org/xdaliclock/${pname}-${version}.tar.gz";
hash = "sha256-BZiqjTSSAgvT/56OJDcKh4pDP9uqVhR5cCx89H+5FLQ=";
};
# Note: don't change this to set sourceRoot, or updateAutotoolsGnuConfigScriptsHook
# on aarch64 doesn't find the files to patch and the aarch64 build fails!
preConfigure = "cd X11";
nativeBuildInputs = [
pkg-config
wrapGAppsHook3
];
buildInputs = [
gtk3
];
preInstall = ''
mkdir -vp $out/bin $out/share/man/man1 $out/share/gsettings-schemas/$name/glib-2.0/schemas $out/share/pixmaps $out/share/applications
# https://www.jwz.org/blog/2022/08/dali-clock-2-45-released/#comment-236762
gappsWrapperArgs+=(--set MESA_GL_VERSION_OVERRIDE 3.1)
'';
installFlags = [
"GTK_ICONDIR=${placeholder "out"}/share/pixmaps/"
"GTK_APPDIR=${placeholder "out"}/share/applications/"
];
meta = with lib; {
description = "A clock application that morphs digits when they are changed";
maintainers = with maintainers; [ raskin ];
platforms = with platforms; linux ++ freebsd;
license = licenses.free; #TODO BSD on Gentoo, looks like MIT
downloadPage = "http://www.jwz.org/xdaliclock/";
mainProgram = "xdaliclock";
};
}