From 9c6be76276f0f318ccdd48c6f551a54977e5a4a9 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Wed, 9 May 2018 16:38:47 +0000 Subject: [PATCH] ocamlPackages.gapi_ocaml: disable for OCaml < 4.02 --- pkgs/development/ocaml-modules/gapi-ocaml/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/ocaml-modules/gapi-ocaml/default.nix b/pkgs/development/ocaml-modules/gapi-ocaml/default.nix index b4e06d3c999..a7c32a069fc 100644 --- a/pkgs/development/ocaml-modules/gapi-ocaml/default.nix +++ b/pkgs/development/ocaml-modules/gapi-ocaml/default.nix @@ -1,5 +1,9 @@ { stdenv, fetchFromGitHub, ocaml, findlib, jbuilder, opam, ocurl, cryptokit, ocaml_extlib, yojson, ocamlnet, xmlm }: +if !stdenv.lib.versionAtLeast ocaml.version "4.02" +then throw "gapi-ocaml is not available for OCaml ${ocaml.version}" +else + stdenv.mkDerivation rec { name = "gapi-ocaml-${version}"; version = "0.3.6";