summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
authorVincent Laporte <Vincent.Laporte@gmail.com>2020-01-14 22:15:43 +0100
committerVincent Laporte <vbgl@users.noreply.github.com>2020-01-20 10:18:53 +0100
commit6b023dc690f50121bfa535f31c62d5edf0ec66a2 (patch)
tree060dd331262c24e66ef514c4fe616632e602ffb2 /pkgs/development
parent6cc43ee38ce79cea3fa82ed0d6b888a03be7d7f6 (diff)
downloadnixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar.gz
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar.bz2
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar.lz
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar.xz
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.tar.zst
nixpkgs-6b023dc690f50121bfa535f31c62d5edf0ec66a2.zip
ocamlPackages.re2: fix building with clang
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/ocaml-modules/janestreet/0.12.nix4
1 files changed, 4 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/janestreet/0.12.nix b/pkgs/development/ocaml-modules/janestreet/0.12.nix
index f912bdaa21f..4585a3b8596 100644
--- a/pkgs/development/ocaml-modules/janestreet/0.12.nix
+++ b/pkgs/development/ocaml-modules/janestreet/0.12.nix
@@ -398,6 +398,10 @@ rec {
     hash = "1sw32lb0y501y971ij7287796lvfhs0nfgla895r74ymfks2rcjb";
     meta.description = "OCaml bindings for RE2, Google's regular expression library";
     propagatedBuildInputs = [ core_kernel ];
+    prePatch = ''
+      substituteInPlace src/re2_c/dune --replace 'CXX=g++' 'CXX=c++'
+      substituteInPlace src/dune --replace '(cxx_flags (:standard \ -pedantic) (-I re2_c/libre2))' '(cxx_flags (:standard \ -pedantic) (-I re2_c/libre2) (-x c++))'
+    '';
   };
 
   shell = janePackage {