diff options
author | Xavier Leroy <xavier.leroy@inria.fr> | 2010-01-04 15:50:25 +0000 |
---|---|---|
committer | Xavier Leroy <xavier.leroy@inria.fr> | 2010-01-04 15:50:25 +0000 |
commit | 832910fa8c54e81ffaf4b1ea0409ae8475af2335 (patch) | |
tree | f294001be2a0e93f87f22284f892b5ef48ac5982 | |
parent | 4ff863c7790bd907860a8fcdc342684fe079a053 (diff) | |
download | ocaml-832910fa8c54e81ffaf4b1ea0409ae8475af2335.tar.gz |
PR#4783: no absolute path on Windows
git-svn-id: http://caml.inria.fr/svn/ocaml/version/3.11@9507 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
-rw-r--r-- | Changes | 1 | ||||
-rw-r--r-- | tools/ocamlmklib.mlp | 9 |
2 files changed, 8 insertions, 2 deletions
@@ -7,6 +7,7 @@ Bug fixes: - PR#4710, PR#4720: ocamlbuild does not use properly configuration information - PR#4750: under some Windows installations, high start-up times for Unix lib - PR#4777: problem with scanf and CRLF +- PR#4783: ocamlmklib problem under Windows - PR#4810: BSD problem with socket addresses, e.g. in Unix.getnameinfo - PR#4813: issue with parsing of float literals by the GNU assembler - PR#4816: problem with modules and private types diff --git a/tools/ocamlmklib.mlp b/tools/ocamlmklib.mlp index e902204d08..aefc93cff6 100644 --- a/tools/ocamlmklib.mlp +++ b/tools/ocamlmklib.mlp @@ -15,6 +15,11 @@ open Printf open Myocamlbuild_config +(* PR#4783: under Windows, don't use absolute paths because we do + not know where the binary distribution will be installed. *) +let compiler_path name = + if Sys.os_type = "Win32" then name else Filename.concat bindir name + let bytecode_objs = ref [] (* .cmo,.cma,.ml,.mli files to pass to ocamlc *) and native_objs = ref [] (* .cmx,.cmxa,.ml,.mli files to pass to ocamlopt *) and c_objs = ref [] (* .o, .a, .obj, .lib, .dll files to pass to mksharedlib and ar *) @@ -25,8 +30,8 @@ and failsafe = ref false (* whether to fall back on static build only *) and c_libs = ref [] (* libs to pass to mksharedlib and ocamlc -cclib *) and c_opts = ref [] (* options to pass to mksharedlib and ocamlc -ccopt *) and ld_opts = ref [] (* options to pass only to the linker *) -and ocamlc = ref (Filename.concat bindir "ocamlc") -and ocamlopt = ref (Filename.concat bindir "ocamlopt") +and ocamlc = ref (compiler_path "ocamlc") +and ocamlopt = ref (compiler_path "ocamlopt") and output = ref "a" (* Output name for Caml part of library *) and output_c = ref "" (* Output name for C part of library *) and rpath = ref [] (* rpath options *) |