hivex: build OCaml bindings

These are used by libguestfs's optional appliance builder program.  I
haven't been able to get that working yet, but this is a prerequisite.
This commit is contained in:
Alyssa Ross 2022-12-02 11:56:56 +00:00 committed by Alyssa Ross
parent 22f9452996
commit 94ba105523

View File

@ -1,5 +1,5 @@
{ lib, stdenv, fetchurl, pkg-config, autoreconfHook, makeWrapper, perlPackages
, libxml2, libintl
, ocamlPackages, libxml2, libintl
}:
stdenv.mkDerivation rec {
@ -13,8 +13,14 @@ stdenv.mkDerivation rec {
patches = [ ./hivex-syms.patch ];
postPatch = ''
substituteInPlace ocaml/Makefile.am \
--replace '$(DESTDIR)$(OCAMLLIB)' '$(out)/lib/ocaml/${ocamlPackages.ocaml.version}/site-lib'
'';
strictDeps = true;
nativeBuildInputs = [ autoreconfHook makeWrapper perlPackages.perl pkg-config ];
nativeBuildInputs = [ autoreconfHook makeWrapper perlPackages.perl pkg-config ]
++ (with ocamlPackages; [ ocaml findlib ]);
buildInputs = [
libxml2
]