mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
ocamlPackages.nbd: init at 1.20.2
This commit is contained in:
parent
0a3cdcf4e5
commit
f6f24b0bbb
@ -6,13 +6,19 @@
|
||||
pkg-config,
|
||||
perl,
|
||||
buildPythonBindings ? false,
|
||||
buildOcamlBindings ? false,
|
||||
ocamlPackages,
|
||||
python3,
|
||||
libxml2,
|
||||
fuse,
|
||||
fuse3,
|
||||
gnutls,
|
||||
autoreconfHook,
|
||||
}:
|
||||
|
||||
lib.throwIf (buildOcamlBindings && !lib.versionAtLeast ocamlPackages.ocaml.version "4.05")
|
||||
"OCaml binding are not available for OCaml < 4.05"
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libnbd";
|
||||
version = "1.20.2";
|
||||
@ -22,11 +28,21 @@ stdenv.mkDerivation rec {
|
||||
hash = "sha256-7DgviwGPPLccTPvomyH+0CMknXmR2wENsxpXD97OP84=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
bash-completion
|
||||
pkg-config
|
||||
perl
|
||||
] ++ lib.optionals buildPythonBindings [ python3 ];
|
||||
nativeBuildInputs =
|
||||
[
|
||||
bash-completion
|
||||
pkg-config
|
||||
perl
|
||||
autoreconfHook
|
||||
]
|
||||
++ lib.optionals buildPythonBindings [ python3 ]
|
||||
++ lib.optionals buildOcamlBindings (
|
||||
with ocamlPackages;
|
||||
[
|
||||
findlib
|
||||
ocaml
|
||||
]
|
||||
);
|
||||
|
||||
buildInputs = [
|
||||
fuse
|
||||
@ -35,6 +51,11 @@ stdenv.mkDerivation rec {
|
||||
libxml2
|
||||
];
|
||||
|
||||
postPatch = lib.optionalString buildOcamlBindings ''
|
||||
substituteInPlace ocaml/Makefile.am \
|
||||
--replace-fail '$(DESTDIR)$(OCAMLLIB)' '$(out)/lib/ocaml/${ocamlPackages.ocaml.version}/site-lib'
|
||||
'';
|
||||
|
||||
configureFlags = lib.optionals buildPythonBindings [
|
||||
"--with-python-installdir=${placeholder "out"}/${python3.sitePackages}"
|
||||
];
|
||||
@ -75,4 +96,4 @@ stdenv.mkDerivation rec {
|
||||
}
|
||||
# TODO: package the 1.6-stable version too
|
||||
# TODO: git version needs ocaml
|
||||
# TODO: bindings for go and ocaml
|
||||
# TODO: bindings for go
|
||||
|
@ -1229,6 +1229,11 @@ let
|
||||
|
||||
### N ###
|
||||
|
||||
nbd = pkgs.libnbd.override {
|
||||
ocamlPackages = self;
|
||||
buildOcamlBindings = true;
|
||||
};
|
||||
|
||||
netchannel = callPackage ../development/ocaml-modules/netchannel { };
|
||||
|
||||
ninja_utils = callPackage ../development/ocaml-modules/ninja_utils { };
|
||||
|
Loading…
Reference in New Issue
Block a user