caml-list - the Caml user's mailing list
 help / color / Atom feed
* [Caml-list] dune or opam bug ??
@ 2019-12-13 21:18 Philippe Strauss
  2019-12-13 21:27 ` orbifx
  0 siblings, 1 reply; 2+ messages in thread
From: Philippe Strauss @ 2019-12-13 21:18 UTC (permalink / raw)
  To: caml-list

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




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-13 21:18 [Caml-list] dune or opam bug ?? Philippe Strauss
2019-12-13 21:27 ` orbifx

caml-list - the Caml user's mailing list

Archives are clonable:
	git clone --mirror http://inbox.vuxu.org/caml-list
	git clone --mirror https://inbox.ocaml.org/caml-list

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.caml-list


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git