1 { jre, lib, stdenv, fetchurl, makeWrapper, makeDesktopItem }:
5 desktopItem = makeDesktopItem rec {
9 comment = "A multi-agent programmable modeling environment";
10 desktopName = "NetLogo";
11 categories = [ "Science" ];
16 stdenv.mkDerivation rec {
21 url = "https://ccl.northwestern.edu/netlogo/${version}/NetLogo-${version}-64.tgz";
22 sha256 = "1j08df68pgggxqkmpzd369w4h97q0pivmmljdb48hjghx7hacblp";
27 url = "https://netlogoweb.org/assets/images/desktopicon.png";
28 sha256 = "1i43lhr31lzva8d2r0dxpcgr58x496gb5vmb0h2da137ayvifar8";
31 nativeBuildInputs = [ makeWrapper ];
34 mkdir -pv $out/share/netlogo $out/share/icons/hicolor/256x256/apps $out/share/applications $out/share/doc
35 cp -rv app $out/share/netlogo
36 cp -v readme.md $out/share/doc/
38 # launcher with `cd` is required b/c otherwise the model library isn't usable
39 makeWrapper "${jre}/bin/java" "$out/bin/netlogo" \
40 --chdir "$out/share/netlogo/app" \
41 --add-flags "-jar netlogo-${version}.jar"
43 cp $src1 $out/share/icons/hicolor/256x256/apps/netlogo.png
44 cp ${desktopItem}/share/applications/* $out/share/applications
48 description = "Multi-agent programmable modeling environment";
49 mainProgram = "netlogo";
51 NetLogo is a multi-agent programmable modeling environment. It is used by
52 many tens of thousands of students, teachers and researchers worldwide.
54 homepage = "https://ccl.northwestern.edu/netlogo/index.shtml";
55 sourceProvenance = with sourceTypes; [ binaryBytecode ];
56 license = licenses.gpl2;
57 maintainers = [ maintainers.dpaetzel ];
58 platforms = platforms.linux;