xearth: build fix with gcc 14, refactor (#388565)

This commit is contained in:
kirillrdy
2025-03-10 20:06:10 +11:00
committed by GitHub
+8 -5
View File
@@ -14,13 +14,16 @@ stdenv.mkDerivation rec {
src = fetchurl {
url = "http://xearth.org/${pname}-${version}.tar.gz";
sha256 = "bcb1407cc35b3f6dd3606b2c6072273b6a912cbd9ed1ae22fb2d26694541309c";
hash = "sha256-vLFAfMNbP23TYGssYHInO2qRLL2e0a4i+y0maUVBMJw=";
};
postPatch = "sed -i '48i #include <stdlib.h>' gifout.c";
nativeBuildInputs = [
imake
gccmakedep
];
buildInputs = [
libXt
libXext
@@ -31,12 +34,13 @@ stdenv.mkDerivation rec {
"BINDIR=bin"
"MANDIR=man/man1"
];
installTargets = [
"install"
"install.man"
];
meta = with lib; {
meta = {
description = "sets the X root window to an image of the Earth";
mainProgram = "xearth";
homepage = "https://xearth.org";
@@ -45,13 +49,12 @@ stdenv.mkDerivation rec {
correctly shaded for the current position of the Sun.
By default, xearth updates the displayed image every five minutes.
'';
maintainers = [ maintainers.mafo ];
maintainers = with lib.maintainers; [ mafo ];
license = {
fullName = "xearth license";
url = "https://xearth.org/copyright.html";
free = true;
};
platforms = platforms.unix;
platforms = lib.platforms.unix;
};
}