about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix')
-rw-r--r--nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix9
1 files changed, 6 insertions, 3 deletions
diff --git a/nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix b/nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix
index 50ad5ea94eb9..d99ec7ed3208 100644
--- a/nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix
+++ b/nixpkgs/pkgs/development/ocaml-modules/ptime/default.nix
@@ -1,4 +1,6 @@
-{ stdenv, lib, fetchurl, ocaml, findlib, ocamlbuild, topkg, result, js_of_ocaml }:
+{ stdenv, lib, fetchurl, ocaml, findlib, ocamlbuild, topkg, result, js_of_ocaml
+, jsooSupport ? true
+}:
 
 stdenv.mkDerivation rec {
   version = "0.8.5";
@@ -10,11 +12,12 @@ stdenv.mkDerivation rec {
   };
 
   nativeBuildInputs = [ ocaml findlib ocamlbuild ];
-  buildInputs = [ findlib topkg js_of_ocaml ];
+  buildInputs = [ findlib topkg ]
+    ++ lib.optional jsooSupport js_of_ocaml;
 
   propagatedBuildInputs = [ result ];
 
-  buildPhase = "${topkg.run} build --with-js_of_ocaml true";
+  buildPhase = "${topkg.run} build --with-js_of_ocaml ${lib.boolToString jsooSupport}";
 
   inherit (topkg) installPhase;