Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4595782
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T23:01:16+00:00 2026-05-21T23:01:16+00:00

I have downloaded xml-light for ocaml and try to compile it, but it has

  • 0

I have downloaded xml-light for ocaml and try to compile it, but it has never been succeeded, the problem is as follow.

When I input ocamlopt dtd.ml, there will be an error Unbound module Xml.
Then I input ocamlopt xml.ml, there will be an error Unbound value XmlParser.make.
Then I input ocamlopt xmlParser.ml, there will be an error Unbound module Dtd.

is there actually a way to compile them together? I feel so stupid because of this.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T23:01:17+00:00Added an answer on May 21, 2026 at 11:01 pm

    It is not so trivial, nothing surprising. Here is the output of make (from mingw/cygwin ocaml distribution):

    ocamlyacc xml_parser.mly
    ocamlc  xml.mli
    ocamlc  dtd.mli
    ocamlc  xml_parser.mli
    ocamlc  -c xml_parser.ml
    ocamllex xml_lexer.mll
    ocamlc  xml_lexer.mli
    ocamlc  -c xml_lexer.ml
    ocamlc  -c dtd.ml
    ocamlc  xmlParser.mli
    ocamlc  -c xmlParser.ml
    ocamlc  -c xml.ml
    ocamlc -o xml-light.cma -a  xml_parser.cmo xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo
    

    And the test:

    ocamlc xml-light.cma test.ml -o test.exe
    

    make install output:

    ocamlopt  -c xml_parser.ml
    ocamlopt  -c xml_lexer.ml
    ocamlopt  -c dtd.ml
    ocamlopt  -c xmlParser.ml
    ocamlopt  -c xml.ml
    ocamlopt -o xml-light.cmxa -a  xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
    
    cp xml-light.cmxa xml-light.a xml-light.cma xml.mli xmlParser.mli dtd.mli xml.cmi xmlParser.cmi dtd.cmi xml.cmx dtd.cmx xmlParser.cmx `ocamlc -where`
    

    Note the last line (i’ve separated it with newline): you probably won’t have cp command; just create %OCAMLLIB%\xml-light directory manually and copy listed files there. Then you can build your project like this:

    ocamlopt -I +xml-light xml-light.cmxa foo.ml -o foo.exe
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to parse an Atom feed programmatically. I have the atom XML downloaded
I have downloaded the silver light from this http://www.microsoft.com/silverlight// I need to use this
I have the following mapping in my Castle Windsor xml file which has worked
Suppose I have downloaded a valid XML document via Ajax (var docum = request.responseXML;).
Suppose I have downloaded a valid XML document via Ajax (var docum = request.responseXML;).
I have downloaded Subsonic 3.0.0.3 and I have a XML DataType in my MSSQL
I have a few views which parse xml downloaded from the internet. The instruments
I have the following collection in an XML document: <events> <event> <type>Downloaded</type> <result>Sucess</result> </event>
I have downloaded the xml dump of the Stack Over Flow site. While transferring
I have downloaded a module from a blog and it works fine. but i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.