caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Manfred Lotz <manfred.lotz@web.de>
To: caml-list@inria.fr
Subject: [Caml-list] Re: (Newbie question): link problem
Date: Sat, 01 Nov 2003 16:27:37 +0100	[thread overview]
Message-ID: <pan.2003.11.01.15.27.37.427907@web.de> (raw)
In-Reply-To: <m2y8v0yyf6.fsf@tornado.force>

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


      reply	other threads:[~2003-11-01 15:39 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-01 13:07 [Caml-list] " Manfred Lotz
2003-11-01 14:07 ` Kamil Shakirov
2003-11-01 15:27   ` Manfred Lotz [this message]

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=pan.2003.11.01.15.27.37.427907@web.de \
    --to=manfred.lotz@web.de \
    --cc=caml-list@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;
as well as URLs for NNTP newsgroup(s).