caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Sean McLaughlin" <seanmcl@gmail.com>
To: "Caml List" <caml-list@inria.fr>
Subject: ocamlbuild with pack
Date: Sun, 17 Jun 2007 08:36:31 -0400	[thread overview]
Message-ID: <6579f8680706170536g534c9577qa5fb73384ce7eb27@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 948 bytes --]

Hello

I've run into a problem with ocamlbuild and -pack.
It will build bytecode packages, but not native ones.
E.g.,

I have 2 files:

$ cat a.ml <http://a.ml> :

type t = int

$ cat lib.mlpack:

A

Then the bytecode package works

$ ocamlbuild -classic-display lib.byte
/sw/bin/ocamldep.opt -modules a.ml > a.ml.depends
/sw/bin/ocamlc.opt -c -o a.cmo a.ml
/sw/bin/ocamlc.opt -pack a.cmo -o lib.cmo
/sw/bin/ocamlc.opt lib.cmo -o lib.byte

but not the native code

~/tmp/tmp2
$ ocamlbuild -classic-display lib.native
/sw/bin/ocamlopt.opt -c -o a.cmx a.ml
touch lib.mli  ; if  /sw/bin/ocamlopt.opt -pack a.cmx -o lib.cmx  ; then  rm
-f lib.mli  ; else  rm -f lib.mli  ; exit 1; fi
+ touch lib.mli  ; if  /sw/bin/ocamlopt.opt -pack a.cmx -o lib.cmx  ; then
rm -f lib.mli  ; else  rm -f lib.mli  ; exit 1; fi
File a.cmx was not compiled with the `-for-pack Lib' option
Command exited with code 1.


What am I doing wrong?

Thanks for your time,

Sean

[-- Attachment #2: Type: text/html, Size: 1345 bytes --]

             reply	other threads:[~2007-06-17 12:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-17 12:36 Sean McLaughlin [this message]
2007-06-18 19:25 ` [Caml-list] " Nicolas Pouillard

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=6579f8680706170536g534c9577qa5fb73384ce7eb27@mail.gmail.com \
    --to=seanmcl@gmail.com \
    --cc=caml-list@inria.fr \
    --cc=seanmcl@cmu.edu \
    /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).