summaryrefslogtreecommitdiff
path: root/ocamlbuild/my_std.ml
diff options
context:
space:
mode:
Diffstat (limited to 'ocamlbuild/my_std.ml')
-rw-r--r--ocamlbuild/my_std.ml7
1 files changed, 3 insertions, 4 deletions
diff --git a/ocamlbuild/my_std.ml b/ocamlbuild/my_std.ml
index 78286b53c8..3ba8550242 100644
--- a/ocamlbuild/my_std.ml
+++ b/ocamlbuild/my_std.ml
@@ -249,18 +249,17 @@ let sys_command =
| "Win32" -> fun cmd ->
if cmd = "" then 0 else
let cmd = "bash -c "^Filename.quote cmd in
- (* FIXME fix Filename.quote for windows *)
- let cmd = String.subst "\"&\"\"&\"" "&&" cmd in
Sys.command cmd
| _ -> fun cmd -> if cmd = "" then 0 else Sys.command cmd
(* FIXME warning fix and use Filename.concat *)
let filename_concat x y =
if x = Filename.current_dir_name || x = "" then y else
- if x.[String.length x - 1] = '/' then
+ if Sys.os_type = "Win32" && (x.[String.length x - 1] = '\\') || x.[String.length x - 1] = '/' then
if y = "" then x
else x ^ y
- else x ^ "/" ^ y
+ else
+ x ^ "/" ^ y
(* let reslash =
match Sys.os_type with