caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: John Skaller <skaller@ozemail.com.au>
To: caml-list@inria.fr
Subject: [Caml-list] Dumb question on bytecode compiler
Date: Tue, 17 Jun 2003 01:10:38 +1000	[thread overview]
Message-ID: <3EEDDDEE.2000100@ozemail.com.au> (raw)

This works fine with the optimising compiler:

ocamlopt.opt  -I src  -a -o src/flxlib.cmxa src/flx_version.cmx src/flx_getopt.cmx src/flx_util.cmx 
src/flx_mtypes.cmx src/flx_srcref.cmx src/flx_typing.cmx src/flx_exceptions.cmx src/flx_string.cmx 
src/flx_id.cmx src/flx_print.cmx src/flx_typing2.cmx src/flx_unify.cmx src/flx_charset.cmx 
src/flx_parse.cmx src/flx_keywords.cmx src/flx_lex.cmx src/flx_pretok.cmx src/flx_lex1.cmx 
src/flx_tok.cmx src/flx_parse_ctrl.cmx src/flx_dfa.cmx src/flx_pat.cmx src/flx_constfld.cmx 
src/flx_macro.cmx src/flx_desugar.cmx src/flx_mbind.cmx src/flx_symtab.cmx src/flx_lookup.cmx 
src/flx_bbind.cmx src/flx_use.cmx src/flx_name.cmx src/flx_cexpr.cmx src/flx_csubst.cmx 
src/flx_tgen.cmx src/flx_display.cmx src/flx_ogen.cmx src/flx_gen.cmx
ocamlopt.opt  -I src  -cclib "-Lsrc  -lnums" -o bin/flxl nums.cmxa unix.cmxa flxlib.cmxa flxl.cmx

The same code with automatically generated changes for the bytecode compiler
(not finished doing the changes yet though)

ocamlc.opt  -I src  -a -o src/flxlib.cma src/flx_version.cmo src/flx_getopt.cmo src/flx_util.cmo 
src/flx_mtypes.cmo src/flx_srcref.cmo src/flx_typing.cmo src/flx_exceptions.cmo src/flx_string.cmo 
src/flx_id.cmo src/flx_print.cmo src/flx_typing2.cmo src/flx_unify.cmo src/flx_charset.cmo 
src/flx_parse.cmo src/flx_keywords.cmo src/flx_lex.cmo src/flx_pretok.cmo src/flx_lex1.cmo 
src/flx_tok.cmo src/flx_parse_ctrl.cmo src/flx_dfa.cmo src/flx_pat.cmo src/flx_constfld.cmo 
src/flx_macro.cmo src/flx_desugar.cmo src/flx_mbind.cmo src/flx_symtab.cmo src/flx_lookup.cmo 
src/flx_bbind.cmo src/flx_use.cmo src/flx_name.cmo src/flx_cexpr.cmo src/flx_csubst.cmo 
src/flx_tgen.cmo src/flx_display.cmo src/flx_ogen.cmo src/flx_gen.cmo
ocamlc.opt  -I src  -cclib "-Lsrc  -lnums" -o bin/flxl nums.cma unix.cma flxlib.cma flxl.cmo

Error while linking src/flxlib.cma(Flx_lex):
Reference to undefined global `Flx_lex'

How can linking the module Flx_lex from file
'flx_lex' cause a reference to an undefined symbol
which is its own name?

[Yeah, I guess the -cclib stuff still needs fixing .. but I get the same
error without that stuff in the command ..]

[BTW: do I need to use  -custom to integrate nums and unix? Is
there a way to produce a platform independent system, of do I have at
least to build, on each platform, a runtime including nums and unix?]

Sorry for dumb questions: I've never use the bytecode compiler before.

FYI: the source for Flx_lex is generated by ocamllex.

-- 
John Max Skaller, mailto:skaller@ozemail.com.au
snail:10/1 Toxteth Rd, Glebe, NSW 2037, Australia.
voice:61-2-9660-0850


-------------------
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-06-16 15:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-16 15:10 John Skaller [this message]
2003-06-17 12:26 ` Damien Doligez

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=3EEDDDEE.2000100@ozemail.com.au \
    --to=skaller@ozemail.com.au \
    --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).