diff --git a/otherlibs/stdune/src/proc.ml b/otherlibs/stdune/src/proc.ml index fe7e4bc66d50..e3232a6b69b3 100644 --- a/otherlibs/stdune/src/proc.ml +++ b/otherlibs/stdune/src/proc.ml @@ -11,9 +11,7 @@ let restore_cwd_and_execve prog argv ~env = (* run at_exit before changing the working directory *) Stdlib.do_at_exit (); Sys.chdir (Path.External.to_string Path.External.initial_cwd); - let os_haiku = Sys.os_type == "BeOS" || (try ignore(Sys.getenv "BE_HOST_CPU");true with Not_found -> false) - in - if Sys.win32 || os_haiku + if Sys.win32 || Platform.OS.value == Platform.OS.Haiku then ( let pid = Unix.create_process_env prog argv env Unix.stdin Unix.stdout Unix.stderr in match snd (Unix.waitpid [] pid) with