2021-01-22 11:25:31 +00:00
|
|
|
{ lib, stdenv, fetchurl, zlib }:
|
2016-05-26 20:36:15 +00:00
|
|
|
|
2020-11-21 03:00:57 +00:00
|
|
|
let
|
|
|
|
ARCH = {
|
|
|
|
i686-linux = "linux32";
|
|
|
|
x86_64-linux = "linux64";
|
|
|
|
aarch64-linux = "linux64";
|
|
|
|
}."${stdenv.hostPlatform.system}" or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
|
|
|
|
in
|
2016-05-26 20:36:15 +00:00
|
|
|
stdenv.mkDerivation {
|
2020-01-18 14:55:23 +00:00
|
|
|
pname = "picat";
|
2021-01-15 18:03:57 +00:00
|
|
|
version = "3.0p4";
|
2016-05-26 20:36:15 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-01-15 18:03:57 +00:00
|
|
|
url = "http://picat-lang.org/download/picat30_4_src.tar.gz";
|
|
|
|
sha256 = "1rwin44m7ni2h2v51sh2r8gj2k6wm6f86zgaylrria9jr57inpqj";
|
2016-05-26 20:36:15 +00:00
|
|
|
};
|
|
|
|
|
2020-01-18 14:55:23 +00:00
|
|
|
buildInputs = [ zlib ];
|
|
|
|
|
2020-11-21 03:00:57 +00:00
|
|
|
inherit ARCH;
|
2016-05-26 20:36:15 +00:00
|
|
|
|
2016-05-31 12:57:28 +00:00
|
|
|
hardeningDisable = [ "format" ];
|
2020-09-30 02:20:05 +00:00
|
|
|
enableParallelBuilding = true;
|
2016-05-31 12:57:28 +00:00
|
|
|
|
2020-11-20 13:32:14 +00:00
|
|
|
buildPhase = "cd emu && make -j $NIX_BUILD_CORES -f Makefile.$ARCH";
|
2020-11-21 03:00:57 +00:00
|
|
|
installPhase = "mkdir -p $out/bin && cp picat $out/bin/picat";
|
2016-05-26 20:36:15 +00:00
|
|
|
|
2021-01-22 11:25:31 +00:00
|
|
|
meta = with lib; {
|
2016-05-26 20:36:15 +00:00
|
|
|
description = "Logic-based programming langage";
|
2020-11-20 13:32:14 +00:00
|
|
|
homepage = "http://picat-lang.org/";
|
|
|
|
license = licenses.mpl20;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ earldouglas thoughtpolice ];
|
2016-05-26 20:36:15 +00:00
|
|
|
};
|
|
|
|
}
|