From 08edfb69671912c964cc734e58176c1902057ce8 Mon Sep 17 00:00:00 2001 From: Alexander Bantyev Date: Wed, 20 Nov 2019 14:31:23 +0300 Subject: [PATCH] ocaml: uchar: add the ability to build without dynamic linking --- pkgs/development/ocaml-modules/uchar/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/ocaml-modules/uchar/default.nix b/pkgs/development/ocaml-modules/uchar/default.nix index 09e9dac0902..2140871021d 100644 --- a/pkgs/development/ocaml-modules/uchar/default.nix +++ b/pkgs/development/ocaml-modules/uchar/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }: +{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline, withShared ? true }: stdenv.mkDerivation { name = "ocaml${ocaml.version}-uchar-0.0.2"; @@ -9,8 +9,8 @@ stdenv.mkDerivation { }; nativeBuildInputs = [ ocaml ocamlbuild findlib opaline ]; - buildInputs = [ findlib ]; - buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; + buildInputs = [ findlib ocaml ocamlbuild opaline ]; + buildPhase = "ocaml pkg/build.ml native=true native-dynlink=${if withShared then "true" else "false"}"; installPhase = "opaline -libdir $OCAMLFIND_DESTDIR"; configurePlatforms = [];