From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id p61FuRqH010590 for ; Fri, 1 Jul 2011 17:56:27 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqADAEHtDU7VUZiPkWdsb2JhbABSG4QnlC6PBwEBAQEJCwsHFAQhiHugao42kGyBK4ETgmiBDASSMoR2HYsg X-IronPort-AV: E=Sophos;i="4.65,458,1304287200"; d="scan'208";a="86441857" Received: from kardinal.t-com.sk (HELO smtp.t-com.sk) ([213.81.152.143]) by mail3-smtp-sop.national.inria.fr with ESMTP; 01 Jul 2011 17:56:22 +0200 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=UTF-8 Received: from [10.0.0.11] ([unknown] [178.40.223.155]) by relay2.stonline.sk (STOnline ESMTP Server) with ESMTPA id <0LNN0072MW9W1T00@relay2.stonline.sk> for caml-list@yquem.inria.fr; Fri, 01 Jul 2011 17:56:21 +0200 (CEST) Message-id: <4E0DEED4.8070409@fiit.stuba.sk> Date: Fri, 01 Jul 2011 17:59:16 +0200 From: Matej Kosik User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.16) Gecko/20110506 Icedove/3.0.11 To: caml-list@yquem.inria.fr X-Enigmail-Version: 1.0.1 OpenPGP: id=F248FE18; url=http://www2.fiit.stuba.sk/~kosik/doc/kosik.asc Subject: [Caml-list] Bitstring and toplevel Hello, Besides the standard library, I haven't use any other Ocaml libraries. Now I am testing bitstring http://people.redhat.com/~rjones/bitstring/html/Bitstring.html#2_Compiling (which is awesome). I can compile programs that take advantage of this library. I would like to create a new toplevel system with bitstring extensions included. I do not know how to do it despite the fact that there is an answer (year 2010): http://groups.google.com/group/bitstring/browse_frm/thread/859ffe46ebe9d60b When I try this: ocamlc unix.cma dynlink.cma camlp4lib.cma -I +camlp4 toplevellib.cma camlp4of.cma -I +bitstring bitstring.cma bitstring_persistent.cma pa_bitstring.cmo topstart.cmo -o mytop Camlp4Bin.cmo -linkall the command succeeds, but in the new toplevel system: kosik@debian:/tmp$ ./mytop Objective Caml version 3.11.2 Camlp4 Parsing version 3.11.2 # Bitstring.set;; Error: Unbound value Bitstring.set # let bits = BITSTRING { 1 : 4; 10 : 12 } ;; Error: Unbound constructor Bitstring.Construct_failure Bitstring-related things are undefined. Its emberassing, but I can't figure out what is wrong. Can somebody please help? Thank you very much in advance.