push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,31 @@
{
buildDunePackage,
replaceVars,
ocaml,
menhirLib,
menhirSdk,
}:
buildDunePackage {
pname = "menhir";
minimalOCamlVersion = "4.03";
inherit (menhirLib) version src;
buildInputs = [
menhirLib
menhirSdk
];
patches = [
(replaceVars ./menhir-suggest-menhirLib.patch {
libdir = "${menhirLib}/lib/ocaml/${ocaml.version}/site-lib/menhirLib";
})
];
meta = menhirSdk.meta // {
description = "LR(1) parser generator for OCaml";
mainProgram = "menhir";
};
}

View File

@@ -0,0 +1,40 @@
{
lib,
buildDunePackage,
ocaml,
coqPackages,
version ? if lib.versionAtLeast ocaml.version "4.08" then "20250903" else "20231231",
}:
let
fetched = coqPackages.metaFetch {
release."20231231".sha256 = "sha256-veB0ORHp6jdRwCyDDAfc7a7ov8sOeHUmiELdOFf/QYk=";
release."20240715".sha256 = "sha256-9CSxAIm0aEXkwF+aj8u/bqLG30y5eDNz65EnohJPjzI=";
release."20250903".sha256 = "sha256-ap1OvcvCAuqmFDwhPwMBosHs3cm5NxPW/w1J8AzWduk=";
releaseRev = v: "${v}";
location = {
domain = "gitlab.inria.fr";
owner = "fpottier";
repo = "menhir";
};
} version;
in
buildDunePackage {
pname = "menhirLib";
inherit (fetched) version src;
minimalOCamlVersion = "4.03";
meta = with lib; {
homepage = "http://pauillac.inria.fr/~fpottier/menhir/";
description = "Runtime support library for parsers generated by Menhir";
longDescription = ''
Menhir is a LR(1) parser generator for the Objective Caml programming
language. That is, Menhir compiles LR(1) grammar specifications down
to OCaml code. Menhir was designed and implemented by François Pottier
and Yann Régis-Gianas.
'';
license = with licenses; [ lgpl2Only ];
maintainers = with maintainers; [ vbgl ];
};
}

View File

@@ -0,0 +1,19 @@
diff --git a/src/installation.ml b/src/installation.ml
index 3c64e395..be7d6e7b 100644
--- a/src/installation.ml
+++ b/src/installation.ml
@@ -39,13 +39,4 @@ let rec normalize fn =
and hope that it is of the form [.../bin/menhir]. We change this to
[.../lib/menhirLib], and hope that this is where MenhirLib is installed. *)
-let libdir () =
- let root =
- Sys.executable_name
- |> normalize
- |> Filename.dirname (* remove [menhir] *)
- |> Filename.dirname (* remove [bin] *)
- in
- Filename.concat
- root
- (Filename.concat "lib" "menhirLib")
+let libdir () = ignore normalize; "@libdir@"

View File

@@ -0,0 +1,16 @@
{
lib,
buildDunePackage,
menhirLib,
}:
buildDunePackage {
pname = "menhirSdk";
inherit (menhirLib) version src;
meta = menhirLib.meta // {
description = "Compile-time library for auxiliary tools related to Menhir";
license = with lib.licenses; [ gpl2Only ];
};
}