3 let target = ref "main.otarget"
5 let profile = ref false
6 let verbose = ref false
9 for i = 1 to Array.length Sys.argv - 1 do
10 match Sys.argv.(i) with
11 | "-d" -> debug := true
12 | "-p" -> profile := true
13 | "-v" -> verbose := true
17 let oprofile = if !profile then " -tag profile " else ""
18 let odebug = if !profile then " -tag debug " else ""
19 let otarget = if !target = "clean" then " -clean " else !target
20 let overbose = if !verbose then " -classic-display " else ""
22 let cmd = "ocamlbuild -use-ocamlfind " ^ overbose ^ oprofile ^ odebug ^ otarget
23 let _ = Sys.command cmd