Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, stdenv 3, fetchFromGitHub 4}: 5 6stdenv.mkDerivation (finalAttrs: { 7 pname = "jwasm"; 8 version = "2.17"; 9 10 src = fetchFromGitHub { 11 owner = "Baron-von-Riedesel"; 12 repo = "JWasm"; 13 rev = "v${finalAttrs.version}"; 14 hash = "sha256-22eNtHXF+RQT4UbXIVjn1JP/s6igp5O1oQT7sVl7c1U="; 15 }; 16 17 outputs = [ "out" "doc" ]; 18 19 dontConfigure = true; 20 21 preBuild = '' 22 cp ${if stdenv.cc.isClang then "CLUnix.mak" else "GccUnix.mak"} Makefile 23 substituteInPlace Makefile \ 24 --replace "/usr/local/bin" "${placeholder "out"}/bin" 25 ''; 26 27 postInstall = '' 28 install -Dpm644 $src/Html/License.html \ 29 $src/Html/Manual.html \ 30 $src/Html/Readme.html \ 31 -t $doc/share/doc/jwasm/ 32 ''; 33 34 meta = with lib; { 35 homepage = "https://github.com/Baron-von-Riedesel/JWasm/"; 36 description = "A MASM-compatible x86 assembler"; 37 changelog = "https://github.com/Baron-von-Riedesel/JWasm/releases/tag/v${finalAttrs.version}"; 38 license = licenses.gpl2Plus; 39 maintainers = with maintainers; [ AndersonTorres ]; 40 platforms = platforms.unix; 41 broken = stdenv.isDarwin; 42 }; 43}) 44# TODO: generalize for Windows builds