nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 17.09 40 lines 1.2 kB view raw
1{ stdenv, lib, fetchurl, makeWrapper, yacc, gcc 2, withISpin ? true, tk, swarm, graphviz }: 3 4let 5 binPath = stdenv.lib.makeBinPath [ gcc ]; 6 ibinPath = stdenv.lib.makeBinPath [ gcc tk swarm graphviz tk ]; 7 8in stdenv.mkDerivation rec { 9 name = "spin-${version}"; 10 version = "6.4.7"; 11 url-version = stdenv.lib.replaceChars ["."] [""] version; 12 13 src = fetchurl { 14 url = "http://spinroot.com/spin/Src/spin${url-version}.tar.gz"; 15 sha256 = "17m2xaag0jns8hsa4466zxq35ylg9fnzynzvjjmx4ympbiil6mqv"; 16 }; 17 18 nativeBuildInputs = [ makeWrapper ]; 19 buildInputs = [ yacc ]; 20 21 sourceRoot = "Spin/Src${version}"; 22 23 installPhase = '' 24 install -Dm755 spin $out/bin/spin 25 wrapProgram $out/bin/spin \ 26 --prefix PATH : ${binPath} 27 '' + lib.optionalString withISpin '' 28 install -Dm755 ../iSpin/ispin.tcl $out/bin/ispin 29 wrapProgram $out/bin/ispin \ 30 --prefix PATH ':' "$out/bin:${ibinPath}" 31 ''; 32 33 meta = with stdenv.lib; { 34 description = "Formal verification tool for distributed software systems"; 35 homepage = http://spinroot.com/; 36 license = licenses.free; 37 platforms = platforms.linux; 38 maintainers = with maintainers; [ mornfall pSub ]; 39 }; 40}