caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Philippe Strauss <philippe@strauss-engineering.ch>
To: caml-list@inria.fr
Subject: [Caml-list] dune or opam bug ??
Date: Fri, 13 Dec 2019 22:18:55 +0100	[thread overview]
Message-ID: <34AC0664-EE0C-40EF-AE0A-2E098FD2C8C9@strauss-engineering.ch> (raw)

Hello the list,

I have a strange behavior from my opam setup recently, I’ll reproduce the steps that trigger this singularity :

1.a. it does happen at least when trying to compile examples of a jane-street new package, the bonsai incremental web framework.
1.b. it shows only when trying the production profile with dune : « dune build --profile=release ./hello_world.bc.js »

2. here we go with the command sequence :

philou@air:~/mysrc/tmp/time$ dune build --profile=release ./hello_world.bc.js

(the build start, and fail before completion with the following err msg :)

File "_none_", line 1:
Error: Error on dynamically loaded library: /Users/philou/.opam/4.09.0/lib/stublibs/dllcore_kernel_stubs.so: dlopen(/Users/philou/.opam/4.09.0/lib/stublibs/dllcore_kernel_stubs.so, 10): Symbol not found: _caml_stat_heap_size
  Referenced from: /Users/philou/.opam/4.02.3/lib/stublibs/dllcore_kernel_stubs.so
  Expected in: flat namespace
 in /Users/philou/.opam/4.02.3/lib/stublibs/dllcore_kernel_stubs.so

(notice the opam switch complete mixing of switch 4.09.0 w 4.02.3)
(jane-street support then asked me to try the following: open a bash without profile or run-command execution, for compiling bonsai examples later)

philou@air:~/mysrc/tmp/time$ bash --noprofile --norc
bash-3.2$ pwd
/Users/philou/mysrc/tmp/time

(let’s try it : )

bash-3.2$ dune build --profile=release ./hello_world.bc.js

(and it builds to completion without a glitch :)

bash-3.2$ ls -altr _build/default/
total 92752
drwxr-xr-x  3 philou  staff       102 27 nov 21:33 .ppx
-rw-r--r--  1 philou  staff         0 27 nov 21:33 .merlin-exists
-rw-r--r--  1 philou  staff      7340 27 nov 21:33 .merlin
-rw-r--r--  1 philou  staff       331 27 nov 21:33 hello_world.ml
-rw-r--r--  1 philou  staff       867 27 nov 21:33 hello_world.pp.mli
-rw-r--r--  1 philou  staff      2361 27 nov 21:33 hello_world.pp.ml
-rw-r--r--  1 philou  staff        45 27 nov 21:33 hello_world.mli
drwxr-xr-x  3 philou  staff       238 27 nov 21:33 .hello_world.eobjs
drwxr-xr-x  3 philou  staff       272 27 nov 21:33 ..
-rwxr-xr-x  1 philou  staff  46513032 28 nov 13:55 hello_world.bc
-rw-r--r--  1 philou  staff    946640 28 nov 13:56 hello_world.bc.js
drwxr-xr-x  4 philou  staff       408 28 nov 13:56 .

bash-3.2$ ln -s _build/default/hello_world.bc.js hello_world.bc.js
bash-3.2$ open index.html

(works as expected!)


Q: what happened to my opam setup, and is this a dune or opam « bug » ?

TIA.
Regards 

--
Philippe Strauss
https://www.strauss-engineering.ch




             reply	other threads:[~2019-12-13 21:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-13 21:18 Philippe Strauss [this message]
2019-12-13 21:27 ` orbifx

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=34AC0664-EE0C-40EF-AE0A-2E098FD2C8C9@strauss-engineering.ch \
    --to=philippe@strauss-engineering.ch \
    --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).