Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, stdenv 3, callPackage 4, python27 5, installShellFiles 6, rSrc 7, version 8, oildev 9, configargparse 10, binlore 11, resholve 12, resholve-utils 13}: 14 15python27.pkgs.buildPythonApplication { 16 pname = "resholve"; 17 inherit version; 18 src = rSrc; 19 20 nativeBuildInputs = [ installShellFiles ]; 21 22 propagatedBuildInputs = [ 23 oildev 24 configargparse 25 ]; 26 27 postPatch = '' 28 for file in setup.cfg _resholve/version.py; do 29 substituteInPlace $file --subst-var-by version ${version} 30 done 31 ''; 32 33 postInstall = '' 34 installManPage resholve.1 35 ''; 36 37 # Do not propagate Python; may be obsoleted by nixos/nixpkgs#102613 38 # for context on why, see abathur/resholve#20 39 postFixup = '' 40 rm $out/nix-support/propagated-build-inputs 41 ''; 42 43 passthru = { 44 inherit (resholve-utils) mkDerivation phraseSolution writeScript writeScriptBin; 45 tests = callPackage ./test.nix { inherit rSrc binlore python27 resholve; }; 46 }; 47 48 meta = with lib; { 49 description = "Resolve external shell-script dependencies"; 50 homepage = "https://github.com/abathur/resholve"; 51 license = with licenses; [ mit ]; 52 maintainers = with maintainers; [ abathur ]; 53 platforms = platforms.all; 54 knownVulnerabilities = [ '' 55 resholve depends on python27 (EOL). While it's safe to 56 run on trusted input in the build sandbox, you should 57 avoid running it on untrusted input. 58 '' ]; 59 }; 60}