Markup does not need any other packages besides the O'Caml core. The current version of Markup is known to work with O'Caml 3.06 and 3.07, probably it will work also with previous versions.
./conf.shTo specify a installation prefix (by default it is /usr/local):
./conf.sh -p /usr
The Makefile defines the following goals:
make allcompiles with the bytecode compiler and creates markup.cma
make optcompiles with the native compiler and creates markup.cmxa
After compiling go to directory rtests, run
makeand then
./runThere is more documentation in each directory under rtests
The Makefile defines the following goals:
make installinstalls the bytecode archive, the interface definitions, and if present, the native archive in the configured path (see option -p of conf.sh).
make uninstallremoves the files installed with
make install
There is some documentation in directory doc (README, INSTALL and design.txt). The user's guide is in HTML in directory doc/manual/html.
To generate this file and README from the xml source (format for the example readme) run
cd doc;make
The user's guide is written in DocBook. To generate versions in HTML or PostScript some programs must be installed: transfig (fig2dev), netpbm, jade, docbook-stylesheets, jadetex, dvips. Their location is detected (but not ensured) during the configuration of the sources. If the configuration detected them succesfully (verify by reading messages produced during configuration) run:
cd doc/manual;maketo generate HTML pages in directory doc/html. To generate PostScript in directory doc/ps, run:
make ps
In the "examples" directory you find some applications of Markup :
validate: XML validator. Compile with
cd examples/validate;maketo validate the source of this file run:
./validate ../../doc/INSTALL.xml
readme: DTD of simple document markup and tools to translate in plain text and HTML. Compile with
cd examples/readme; makeTo generate this file:
./readme -text ../../doc/INSTALL.xml > INSTALL
The most recent version has been compiled and tested in OpenBSD and Linux, other platforms could be used.
The "make" utility of Solaris does not work properly enough; there is a bug in it that prevents the so-called suffix rules from being recognized. There are two solutions:
Install GNU make and use it instead of Solaris make. This is the recommended way to solve the problem, as GNU make can process almost every Makefile from open source projects, and you will never have problems with building software again.
Add the following lines to Makefile.code:
%.cmx: %.ml
$(OCAMLOPT) -c $<
%.cmo: %.ml
$(OCAMLC) -c $<
%.cmi: %.mli
$(OCAMLC) -c $<
%.ml: %.mll
ocamllex $<
Note that in earlier versions of Markup than 0.2.3 there was a second problem with Solaris (and other System V systems) which does not allow ! in scripts executed by /bin/sh. Because of this, the ! command was removed from the scripts.