From e7f021ca93be1b4a5359dc3c9f3392b2c349c998 Mon Sep 17 00:00:00 2001 From: Johannes Frankenau Date: Fri, 11 Jan 2019 13:55:40 +0100 Subject: [PATCH] groove: init at 5.7.4 --- .../science/programming/groove/default.nix | 54 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 56 insertions(+) create mode 100644 pkgs/applications/science/programming/groove/default.nix diff --git a/pkgs/applications/science/programming/groove/default.nix b/pkgs/applications/science/programming/groove/default.nix new file mode 100644 index 000000000000..e854f20d39a3 --- /dev/null +++ b/pkgs/applications/science/programming/groove/default.nix @@ -0,0 +1,54 @@ +{ stdenv, fetchurl, unzip, makeWrapper, makeDesktopItem, icoutils, jre }: + +let + desktopItem = makeDesktopItem { + name = "groove-simulator"; + exec = "groove-simulator"; + icon = "groove"; + desktopName = "GROOVE Simulator"; + comment = "GRaphs for Object-Oriented VErification"; + categories = "Science;ComputerScience;"; + }; + +in stdenv.mkDerivation rec { + pname = "groove"; + version = "5.7.4"; + + src = fetchurl { + url = "mirror://sourceforge/groove/groove/${version}/${pname}-${builtins.replaceStrings ["."] ["_"] version}-bin.zip"; + sha256 = "1cl3xzl3n8b9a7h5pvnv31bab9j9zaw07ppk8whk8h865dcq1d10"; + }; + + nativeBuildInputs = [ unzip makeWrapper icoutils ]; + + dontBuild = true; + + installPhase = '' + mkdir -p $out/share/groove + cp -r bin lib $out/share/groove/ + + mkdir -p $out/share/doc/groove + cp CHANGES README *.pdf $out/share/doc/groove/ + + mkdir -p $out/bin + for bin in Generator Imager ModelChecker PrologChecker Simulator Viewer; do + makeWrapper ${jre}/bin/java $out/bin/groove-''${bin,,} \ + --add-flags "-jar $out/share/groove/bin/$bin.jar" + done + + mkdir -p $out/share/applications + ln -s ${desktopItem}/share/applications/* $out/share/applications/ + + mkdir -p $out/share/icons/hicolor/{16x16,32x32}/apps + icotool -x -i 1 -o $out/share/icons/hicolor/32x32/apps/groove.png groove-green-g.ico + icotool -x -i 2 -o $out/share/icons/hicolor/16x16/apps/groove.png groove-green-g.ico + ''; + + meta = with stdenv.lib; { + description = "GRaphs for Object-Oriented VErification"; + homepage = http://groove.cs.utwente.nl/; + license = licenses.asl20; + platforms = platforms.all; + maintainers = with maintainers; [ jfrankenau ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1027c62e4774..424f6c156ea9 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -21712,6 +21712,8 @@ in dafny = dotnetPackages.Dafny; + groove = callPackage ../applications/science/programming/groove { }; + plm = callPackage ../applications/science/programming/plm { }; scyther = callPackage ../applications/science/programming/scyther { };