Hi, I'm using OCaml 3.11 on Mac OS X leopard and linux (debian, 2.6.29).
Here's my problem: this small ocaml programme here below... Thread.delay 0.3;; Printf.printf "exit status = %d\n" (Sys.command "ls");; ...has a very different behavior on OS X and on Linux ! compile command: ocamlopt -thread unix.cmxa threads.cmxa small_prog.ml The Thread.delay is here just to make sure the Threads library is linked. This programme works fine on Linux, prints directory listing and then prints "exit status = 0". But on OS X, the Sys.command exits and the programme only prints "exit status = 127". execv functions have the same issue. If I remove the call to the Threads library, it works as expected on OS X. I know it's supposed to be evil to mix up threads and processes, I just need to execute an external programme from a multi-threaded programme. Any idea? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "ocaml-developer" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/ocaml-developer?hl=en For other OCaml forums, see http://caml.inria.fr/resources/forums.en.html -~----------~----~----~----~------~----~------~--~---
