From 2299413926668ff322cfd139e78299b4733eacd0 Mon Sep 17 00:00:00 2001 From: letouzey Date: Sat, 12 Jan 2013 20:02:48 +0000 Subject: Envar: in w32, add .exe when searching for caml binaries Based on a patch by Pierre-Yves Strub git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@16124 85f007b7-540e-0410-9357-904b9bb8a0f7 --- lib/envars.ml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'lib/envars.ml') diff --git a/lib/envars.ml b/lib/envars.ml index a5eb827fe..8e7baa082 100644 --- a/lib/envars.ml +++ b/lib/envars.ml @@ -147,7 +147,9 @@ let coqpath = (** {2 Caml paths} *) -let guess_camlbin () = which (user_path ()) "ocamlc" +let exe s = s ^ Coq_config.exec_extension + +let guess_camlbin () = which (user_path ()) (exe "ocamlc") let camlbin () = if !Flags.camlbin_spec then !Flags.camlbin else @@ -168,7 +170,7 @@ let camllib () = (** {2 Camlp4 paths} *) -let guess_camlp4bin () = which (user_path ()) Coq_config.camlp4 +let guess_camlp4bin () = which (user_path ()) (exe Coq_config.camlp4) let camlp4bin () = if !Flags.camlp4bin_spec then !Flags.camlp4bin else @@ -176,7 +178,7 @@ let camlp4bin () = try guess_camlp4bin () with _ -> - if Sys.file_exists (camlbin () / Coq_config.camlp4) then + if Sys.file_exists (camlbin () / exe Coq_config.camlp4) then camlbin () else Coq_config.camlp4bin -- cgit v1.2.3