let project_dirs = [ src_path; include_path ]
let cxx_include_flags = _S cxx_includes
let cxx_link_flags = ref [ _S cxx_lpaths; _S cxx_libs]
let native_link_flags = ref (List.map (fun s -> s ^ ".cmxa") ocaml_link)
let byte_link_flags = ref ("-custom" :: (List.map (fun s -> s ^ ".cma") ocaml_link))
let link_flags = [ A"-linkpkg" ]
let project_dirs = [ src_path; include_path ]
let cxx_include_flags = _S cxx_includes
let cxx_link_flags = ref [ _S cxx_lpaths; _S cxx_libs]
let native_link_flags = ref (List.map (fun s -> s ^ ".cmxa") ocaml_link)
let byte_link_flags = ref ("-custom" :: (List.map (fun s -> s ^ ".cma") ocaml_link))
let link_flags = [ A"-linkpkg" ]
compile_flags @= [A "-noassert"];
pp_macro_options @= [ A "-unsafe" ];
native_compile_flags @= [ A "-inline"; A ocaml_inline ];
compile_flags @= [A "-noassert"];
pp_macro_options @= [ A "-unsafe" ];
native_compile_flags @= [ A "-inline"; A ocaml_inline ];
rule "c++: cpp & depends -> o" ~prod:"%.o" ~deps:[ "%.cpp" ] cxx_compile;
let syntax_flags = S ([ A "-syntax"; A "camlp4o";
S (ppopt [A "-printer" ; A"Camlp4OCamlAstDumper"]);
S (ppopt !pp_macro_options) ])
in
flag [ "ocaml"; "ocamldep"] syntax_flags;
rule "c++: cpp & depends -> o" ~prod:"%.o" ~deps:[ "%.cpp" ] cxx_compile;
let syntax_flags = S ([ A "-syntax"; A "camlp4o";
S (ppopt [A "-printer" ; A"Camlp4OCamlAstDumper"]);
S (ppopt !pp_macro_options) ])
in
flag [ "ocaml"; "ocamldep"] syntax_flags;
Quote (S [ _S cstub_lib; S !cxx_link_flags]) ]);
flag [ "ocaml"; "byte"; "link" ] (_S !byte_link_flags);
flag [ "ocaml"; "native"; "link" ] (_S !native_link_flags);
Quote (S [ _S cstub_lib; S !cxx_link_flags]) ]);
flag [ "ocaml"; "byte"; "link" ] (_S !byte_link_flags);
flag [ "ocaml"; "native"; "link" ] (_S !native_link_flags);