nixpkgs/pkgs/by-name/eu/eureka-editor/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

38 lines
1.2 KiB
Nix

{ lib, stdenv, fetchzip, fltk, zlib, xdg-utils, xorg, libjpeg, libGLU }:
stdenv.mkDerivation rec {
pname = "eureka-editor";
version = "1.27b";
src = fetchzip {
url = "mirror://sourceforge/eureka-editor/Eureka/${lib.versions.majorMinor version}/eureka-${version}-source.tar.gz";
sha256 = "075w7xxsgbgh6dhndc1pfxb2h1s5fhsw28yl1c025gmx9bb4v3bf";
};
buildInputs = [ fltk zlib xdg-utils libjpeg xorg.libXinerama libGLU ];
enableParallelBuilding = true;
postPatch = ''
substituteInPlace src/main.cc --replace /usr/local $out
substituteInPlace Makefile --replace /usr/local $out
'';
preInstall = ''
mkdir -p $out/bin $out/share/applications $out/share/icons $out/man/man6
cp misc/eureka.desktop $out/share/applications
cp misc/eureka.ico $out/share/icons
cp misc/eureka.6 $out/man/man6
'';
meta = with lib; {
homepage = "https://eureka-editor.sourceforge.net";
description = "Map editor for the classic DOOM games, and a few related games such as Heretic and Hexen";
mainProgram = "eureka";
license = licenses.gpl2Plus;
platforms = platforms.all;
badPlatforms = platforms.darwin;
maintainers = with maintainers; [ neonfuz ];
};
}