From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA09920; Mon, 16 Jun 2003 17:11:07 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id RAA09943 for ; Mon, 16 Jun 2003 17:11:05 +0200 (MET DST) Received: from mail3.tpgi.com.au (mail.tpgi.com.au [203.12.160.59]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id h5GFB2T00182 for ; Mon, 16 Jun 2003 17:11:02 +0200 (MET DST) Received: from ozemail.com.au (203-213-127-165-syd-ts20-2600.tpgi.com.au [203.213.127.165]) (authenticated (0 bits)) by mail3.tpgi.com.au (8.11.6/8.11.6) with ESMTP id h5GFAt028013 for ; Tue, 17 Jun 2003 01:10:56 +1000 Message-ID: <3EEDDDEE.2000100@ozemail.com.au> Date: Tue, 17 Jun 2003 01:10:38 +1000 From: John Skaller User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.2.1) Gecko/20010901 X-Accept-Language: en-us MIME-Version: 1.0 To: caml-list@inria.fr Subject: [Caml-list] Dumb question on bytecode compiler Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam: no; 0.00; ozemail:01 optimising:01 ocamlopt:01 flx:01 cmx:01 util:01 srcref:01 pretok:01 tok:99 symtab:01 cexpr:01 nums:01 ocamlc:01 runtime:01 toxteth:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk 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