[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: | 2003-11-01 (15:39) |
From: | Manfred Lotz <manfred.lotz@w...> |
Subject: | [Caml-list] Re: (Newbie question): link problem |
On Sat, 01 Nov 2003 17:07:57 +0300, Kamil Shakirov wrote: > Hello, > > Manfred Lotz <manfred.lotz@web.de> writes: > >> Hi there, >> I try to compile a source file which uses Num: >> ocamlc fac.ml >> >> I get: >> Error while linking fac.cmo: Reference to undefined global `Num' >> >> Ok. Now I try: >> ocamlc -cclib -lnums fac.ml >> and get the same error message as above. >> >> What can I do? >> >> Manfred > > You must compile sources which uses Num like this > ocamlc -o myprogram nums.cma mysource1.ml mysource2.ml ... > or if you want to get a native version: > ocamlopt -o myprogram nums.cmxa mysource1.ml mysource2.ml ... > Yep, that did it. > Look at the OCaml user's manual: > http://caml.inria.fr/distrib/ocaml-3.07/ocaml-3.07-refman.html.tar.gz Got it! Before I had a look at the user manual. However I only looked at chapter 8 about batch compilation where something like this was not explicitly stated. Thanks, Manfred ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners