caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Building a cross-compiling ocaml
@ 2000-03-06 21:30 Matthew S. Harris
  2000-03-07  8:24 ` Sven LUTHER
  2000-03-07 10:54 ` Xavier Leroy
  0 siblings, 2 replies; 7+ messages in thread
From: Matthew S. Harris @ 2000-03-06 21:30 UTC (permalink / raw)
  To: caml-list

I am trying to get ocaml to produce code that can be linked against
the libc of a different operating system (the University of Utah's
OSKit project, for those who may know it).  The key facts are:

  - The target architecture is the same, so all the normal build tools
    and commands work; I just need to add some compile-time and
    link-time options so gcc will use the proper header files and
    libraries.

  - I'm using a different libc than the native (Linux) one, so the
    ocamlrun produced in this manner cannot be run locally.  In other
    words, the normal build process gives me a broken ocamlc.

I am not very familiar with the OCaml architecture because I am only
trying to link with some functions written in OCaml.  I tried
following the directions given by Xavier a year ago
<http://pauillac.inria.fr/caml/caml-list/1160.html>, which involved
changing NATIVECCCOMPOPTS and NATIVECCLINKOPTS in config/Makefile, but
the make procedure for stdlib/ involves running ocamlrun, which was
linked with the byterun/* files produced with these options.

My understanding is that bytecode files are entirely
system-independent, so I should just need to get the byterun/* files
built with the alternate library.  But since ocamlrun, which is used
by ocamlc, is built from these files, I have a circular dependency: I
need to run an ocamlc under Linux to produce the files that I will
link with the alternate libc.  What is the best way to resolve this?


Matthew



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2000-03-10  8:06 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-03-06 21:30 Building a cross-compiling ocaml Matthew S. Harris
2000-03-07  8:24 ` Sven LUTHER
2000-03-08 17:46   ` Benjamin C. Pierce
2000-03-08 17:55   ` Olivier Bouyssou
2000-03-08 18:20   ` Francois Rouaix
2000-03-09  7:02     ` Sven LUTHER
2000-03-07 10:54 ` Xavier Leroy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).