Merge pull request #100351 from turion/dev_add_agdarsec
agdarsec: init at 0.4.1
This commit is contained in:
commit
d3ee4ba650
|
@ -49,6 +49,7 @@ let
|
|||
, meta
|
||||
, buildInputs ? []
|
||||
, everythingFile ? "./Everything.agda"
|
||||
, includePaths ? []
|
||||
, libraryName ? pname
|
||||
, libraryFile ? "${libraryName}.agda-lib"
|
||||
, buildPhase ? null
|
||||
|
@ -57,6 +58,7 @@ let
|
|||
, ...
|
||||
}: let
|
||||
agdaWithArgs = withPackages (builtins.filter (p: p ? isAgdaDerivation) buildInputs);
|
||||
includePathArgs = concatMapStrings (path: "-i" + path + " ") (includePaths ++ [(dirOf everythingFile)]);
|
||||
in
|
||||
{
|
||||
inherit libraryName libraryFile;
|
||||
|
@ -67,7 +69,7 @@ let
|
|||
|
||||
buildPhase = if buildPhase != null then buildPhase else ''
|
||||
runHook preBuild
|
||||
agda -i ${dirOf everythingFile} ${everythingFile}
|
||||
agda ${includePathArgs} ${everythingFile}
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
|
|
28
pkgs/development/libraries/agda/agdarsec/default.nix
Normal file
28
pkgs/development/libraries/agda/agdarsec/default.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub
|
||||
, standard-library }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "agdarsec";
|
||||
version = "0.4.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "gallais";
|
||||
repo = "agdarsec";
|
||||
rev = "v${version}";
|
||||
sha256 = "02fqkycvicw6m2xsz8p01aq8n3gj2d2gyx8sgj15l46f8434fy0x";
|
||||
};
|
||||
|
||||
everythingFile = "./index.agda";
|
||||
|
||||
includePaths = [ "src" "examples" ];
|
||||
|
||||
buildInputs = [ standard-library ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://gallais.github.io/agdarsec/";
|
||||
description = "Total Parser Combinators in Agda";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ turion ];
|
||||
};
|
||||
}
|
|
@ -31,5 +31,7 @@ let
|
|||
../development/libraries/agda/functional-linear-algebra { };
|
||||
|
||||
generic = callPackage ../development/libraries/agda/generic { };
|
||||
|
||||
agdarsec = callPackage ../development/libraries/agda/agdarsec { };
|
||||
};
|
||||
in mkAgdaPackages Agda
|
||||
|
|
Loading…
Reference in a new issue