Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchurl, 5}: 6 7stdenv.mkDerivation { 8 pname = "f2c"; 9 version = "20240312"; 10 11 src = fetchurl { 12 url = "https://www.netlib.org/f2c/src.tgz"; 13 sha256 = "sha256-TTPve2fe31/Ad+xFAWy6NUIes2QyUi6NjFucN0pdb5k="; 14 }; 15 16 makeFlags = [ 17 "-f" 18 "makefile.u" 19 ]; 20 21 # Ensure xsum binary is built from scratch 22 preBuild = "rm xsum"; 23 24 installPhase = '' 25 runHook preInstall 26 27 mkdir -p $out/bin $out/share/man/man1 28 install -m755 f2c $out/bin 29 install -m755 xsum $out/bin 30 install f2c.1t $out/share/man/man1 31 32 runHook postInstall 33 ''; 34 35 meta = with lib; { 36 description = "Convert Fortran 77 source code to C"; 37 homepage = "https://www.netlib.org/f2c/"; 38 license = licenses.mit; 39 maintainers = [ maintainers.markuskowa ]; 40 platforms = platforms.unix; 41 }; 42}