开发者

XML Parser in OCaml for Windows

开发者 https://www.devze.com 2023-03-02 14:43 出处:网络
I have found several libraries for XML Parser in OCaml, such as PXP or XML-Light. Anyone knows such a thing that can be used easily in Windows? I found that in XML-Light, they have several .ml and .ml

I have found several libraries for XML Parser in OCaml, such as PXP or XML-Light. Anyone knows such a thing that can be used easily in Windows? I found that in XML-Light, they have several .ml and .mli files, I try to copy it to the lib folder of my ocaml, but it d开发者_StackOverflow中文版oesn't work. Any advice how to do this correctly?

Thank you a bunch.

NB: I don't use cygwin either. I use a MSVC version of OCaml.


I've used xmlm for xml parsing. For simplest installation scenario you can download its distribution and copy src\xmlm.ml into your project directory.

Alternatively, you may compile it using:

ocamlopt -c xmlm.mli
ocamlopt -c xmlm.ml

and put the resulting files into %OCAMLLIB%\xmlm directory. Then you can compile your project like this:

ocamlopt -I +xmlm xmlm.cmx foo.ml -o bar
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号