Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 46 lines 1.0 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 installShellFiles, 6}: 7 8stdenv.mkDerivation (finalAttrs: { 9 pname = "dxa"; 10 version = "0.1.5"; 11 12 src = fetchurl { 13 urls = [ 14 "https://www.floodgap.com/retrotech/xa/dists/dxa-${finalAttrs.version}.tar.gz" 15 "https://www.floodgap.com/retrotech/xa/dists/unsupported/dxa-${finalAttrs.version}.tar.gz" 16 ]; 17 hash = "sha256-jkDtd4FlgfmtlaysLtaaL7KseFDkM9Gc1oQZOkWCZ5k="; 18 }; 19 20 nativeBuildInputs = [ installShellFiles ]; 21 22 dontConfigure = true; 23 24 postPatch = '' 25 substituteInPlace Makefile \ 26 --replace "CC = gcc" "CC = ${stdenv.cc.targetPrefix}cc" 27 ''; 28 29 installPhase = '' 30 runHook preInstall 31 32 install -Dm755 -T dxa $out/bin/dxa 33 installManPage dxa.1 34 35 runHook postInstall 36 ''; 37 38 meta = { 39 homepage = "https://www.floodgap.com/retrotech/xa/"; 40 description = "Andre Fachat's open-source 6502 disassembler"; 41 mainProgram = "dxa"; 42 license = lib.licenses.gpl2Plus; 43 maintainers = with lib.maintainers; [ ]; 44 platforms = with lib.platforms; unix; 45 }; 46})