depot/third_party/nixpkgs/pkgs/development/ocaml-modules/hacl-star/raw.nix
Default email 0eeabdeb66 Project import generated by Copybara.
GitOrigin-RevId: c07b471b52be8fbc49a7dc194e9b37a6e19ee04d
2022-01-24 21:21:06 -06:00

53 lines
1.1 KiB
Nix

{ lib, which, stdenv, fetchzip, ocaml, findlib, hacl-star, ctypes, cppo }:
stdenv.mkDerivation rec {
pname = "ocaml${ocaml.version}-hacl-star-raw";
version = "0.4.5";
src = fetchzip {
url = "https://github.com/project-everest/hacl-star/releases/download/ocaml-v${version}/hacl-star.${version}.tar.gz";
sha256 = "1330vgbf5krlkvifby96kyk13xhmihajk2w5hgf2761jrljmnnrs";
stripRoot = false;
};
sourceRoot = "./source/raw";
minimalOCamlVersion = "4.08";
postPatch = ''
patchShebangs ./
'';
preInstall = ''
mkdir -p $OCAMLFIND_DESTDIR/stublibs
'';
installTargets = "install-hacl-star-raw";
dontAddPrefix = true;
dontAddStaticConfigureFlags = true;
configurePlatforms = [];
buildInputs = [
which
ocaml
findlib
];
propagatedBuildInputs = [
ctypes
];
checkInputs = [
cppo
];
doCheck = true;
meta = {
description = "Auto-generated low-level OCaml bindings for EverCrypt/HACL*";
license = lib.licenses.asl20;
maintainers = [ lib.maintainers.ulrikstrid ];
platforms = ocaml.meta.platforms;
};
}