Merge pull request #279461 from Stunkymonkey/quake3e-desktop-icon

quake3e: add desktop-icon
This commit is contained in:
Pol Dellaiera 2024-01-08 20:14:27 +01:00 committed by GitHub
commit 91785be5f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,5 +1,19 @@
{ lib, stdenv, fetchFromGitHub, makeWrapper
, curl, libGL, libX11, libXxf86dga, alsa-lib, libXrandr, libXxf86vm, libXext, SDL2, glibc
{ lib
, stdenv
, fetchFromGitHub
, makeWrapper
, curl
, libGL
, libX11
, libXxf86dga
, alsa-lib
, libXrandr
, libXxf86vm
, libXext
, SDL2
, glibc
, copyDesktopItems
, makeDesktopItem
}:
stdenv.mkDerivation rec {
@ -13,7 +27,7 @@ stdenv.mkDerivation rec {
sha256 = "0qd13fndbhgkkmhxbprpzmj2l2v9ihacxagpdqi9sg9nrzvahr9h";
};
nativeBuildInputs = [ makeWrapper ];
nativeBuildInputs = [ makeWrapper copyDesktopItems ];
buildInputs = [ curl libGL libX11 libXxf86dga alsa-lib libXrandr libXxf86vm libXext SDL2 glibc ];
env.NIX_CFLAGS_COMPILE = "-I${SDL2.dev}/include/SDL2";
enableParallelBuilding = true;
@ -36,11 +50,22 @@ stdenv.mkDerivation rec {
'';
installPhase = ''
runHook preInstall
make install DESTDIR=$out/lib
makeWrapper $out/lib/quake3e.x64 $out/bin/quake3e
makeWrapper $out/lib/quake3e.ded.x64 $out/bin/quake3e.ded
runHook postInstall
'';
desktopItems = [
(makeDesktopItem {
name = "Quake3e";
exec = "quake3e";
desktopName = "Quake3e";
categories = [ "Game" ];
})
];
meta = with lib; {
homepage = "https://github.com/ec-/Quake3e";
description = "Improved Quake III Arena engine";