2022-01-13 20:06:32 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, omake, ocaml, flex, bison }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "teyjus";
|
2023-01-20 10:41:00 +00:00
|
|
|
version = "unstable-2019-07-26";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "teyjus";
|
|
|
|
repo = "teyjus";
|
2023-01-20 10:41:00 +00:00
|
|
|
rev = "e63f40aa9f1d0ea5e7bac41aae5e479c3616545c";
|
|
|
|
sha256 = "sha256-gaAWKd5/DZrIPaaQzx9l0KtCMW9LPw17vvNPsnopZA0=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
patches = [
|
|
|
|
./fix-lex-to-flex.patch
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
postPatch = ''
|
|
|
|
sed -i "/TST/d" source/OMakefile
|
|
|
|
rm -rf source/front/caml
|
|
|
|
'';
|
|
|
|
|
|
|
|
strictDeps = true;
|
|
|
|
|
|
|
|
nativeBuildInputs = [ omake ocaml flex bison ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
hardeningDisable = [ "format" ];
|
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = "-I${ocaml}/include";
|
2023-01-20 10:41:00 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
buildPhase = "omake all";
|
|
|
|
|
|
|
|
checkPhase = "omake check";
|
|
|
|
|
|
|
|
installPhase = "mkdir -p $out/bin && cp tj* $out/bin";
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "An efficient implementation of the Lambda Prolog language";
|
|
|
|
homepage = "https://github.com/teyjus/teyjus";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = lib.licenses.gpl3;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = [ maintainers.bcdarwin ];
|
2023-01-20 10:41:00 +00:00
|
|
|
platforms = platforms.unix;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|