REQUIRES = http helm-cic_textual_parser helm-cic_proof_checking \
helm-xml gdome2-xslt helm-cic_unification helm-mathql \
- helm-mathql_interpreter helm-mathql_generator netclient
+ helm-mathql_interpreter helm-mathql_generator
OCAMLOPTIONS = -package "$(REQUIRES)" -pp camlp4o -I ../gTopLevel
OCAMLC = ocamlfind ocamlc $(OCAMLOPTIONS)
OCAMLOPT = ocamlfind ocamlopt $(OCAMLOPTIONS)
if List.mem server_and_port valid_servers then
Http_daemon.respond
~headers:["Content-Type", "text/html"]
- ~body:(Http_client.Convenience.http_get url)
+ ~body:(Http_client.http_get url)
outchan
else
Http_daemon.respond
let set_metasenv metasenv =
CicTextualParser0.metasenv := metasenv
- let output_html = prerr_endline
+ let output_html ?(append_NL = true) html_msg =
+ let rec collect_string = function
+ | `BR -> "\n"
+ | `T s -> s
+ | `L tags -> String.concat "" (List.map collect_string tags)
+ in
+ match html_msg with
+ | `Error msg | `Msg msg ->
+ (if append_NL then prerr_endline else prerr_string)
+ (collect_string msg ^ (if append_NL then "\n" else ""))
let interactive_user_uri_choice
~selection_mode ?ok