From: Tom Murray <yozhik@computer.org>
To: caml-announce@inria.fr
Subject: [Caml-list] Automake support for OCaml
Date: Sun, 21 Dec 2003 23:48:10 -0800 [thread overview]
Message-ID: <307FE372-3453-11D8-BA54-000A9577557E@computer.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 1517 bytes --]
Bonjour--
I've been working on a patch to automake to support packages with Caml
code.
Current features include compilation of programs and libraries,
possibly with mixed Caml and C code, automatic dependency generation,
and both bytecode and native code compilation. To get an idea, here is
a sample Makefile.am:
CAML_INCLUDES = -I ../ -pp "camlp4o pa_extend.cmo"
CAML_LDADD = unix.cma
bin_MLPROGRAMS = myprog
lib_MLLIBRARIES = mylib.cma
myprog_SOURCES = myprog.mli myprog.ml myprog_c.c
mylib_cma_SOURCES = mylib1.ml mylib2.ml
mylib_cma_LIBADD = otherlib.cma
This defines a program and a library to be built. Typing "make all"
will build myprog and mylib.cma. Typing "make opt" will build
myprog.opt and mylib.cmxa. The CAML_INCLUDES variable applies the -I
flag and an invocation of Camlp4 to all targets. The CAML_LDADD links
in unix.cma with bytecode targets, unix.cmxa with native code. Also
note that myprog includes an interface file myprog.mli that is compiled
to myprog.cmi, but of course excluded from the link. The mylib.cma
library also links in otherlib.cma (or otherlib.cmxa).
The main things left to do are:
* install support (I plan to use ocamlfind)
* m4 macros to ease searching for Caml libraries on the system
* support for more tools such as ocamllex/ocamlyacc (you _can_ do this
manually now, of course)
* improved integration with C
A little page and download are at
http://www.lemurz.org/projects/autocaml/
Your comments and suggestions are appreciated.
Enjoy!
tm
[-- Attachment #2: Type: text/enriched, Size: 1572 bytes --]
Bonjour--
I've been working on a patch to automake to support packages with Caml
code.
Current features include compilation of programs and libraries,
possibly with mixed Caml and C code, automatic dependency generation,
and both bytecode and native code compilation. To get an idea, here is
a sample Makefile.am:
<fontfamily><param>Courier</param>CAML_INCLUDES = -I ../ -pp "camlp4o
pa_extend.cmo"
CAML_LDADD = unix.cma
bin_MLPROGRAMS = myprog
lib_MLLIBRARIES = mylib.cma
myprog_SOURCES = myprog.mli myprog.ml myprog_c.c
mylib_cma_SOURCES = mylib1.ml mylib2.ml
mylib_cma_LIBADD = otherlib.cma
</fontfamily>This defines a program and a library to be built. Typing
"make all" will build myprog and mylib.cma. Typing "make opt" will
build myprog.opt and mylib.cmxa. The CAML_INCLUDES variable applies
the -I flag and an invocation of Camlp4 to all targets. The CAML_LDADD
links in unix.cma with bytecode targets, unix.cmxa with native code.
Also note that myprog includes an interface file myprog.mli that is
compiled to myprog.cmi, but of course excluded from the link. The
mylib.cma library also links in otherlib.cma (or otherlib.cmxa).
The main things left to do are:
* install support (I plan to use ocamlfind)
* m4 macros to ease searching for Caml libraries on the system
* support for more tools such as ocamllex/ocamlyacc (you _can_ do this
manually now, of course)
* improved integration with C
A little page and download are at
http://www.lemurz.org/projects/autocaml/
Your comments and suggestions are appreciated.
Enjoy!
tm
next reply other threads:[~2003-12-22 8:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-22 7:48 Tom Murray [this message]
2003-12-22 10:36 ` Stefano Zacchiroli
2003-12-22 17:43 ` Tom Murray
2003-12-22 18:25 ` skaller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=307FE372-3453-11D8-BA54-000A9577557E@computer.org \
--to=yozhik@computer.org \
--cc=caml-announce@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox