-
Notifications
You must be signed in to change notification settings - Fork 23
lwt's cmis magically available through ocamlfind but not its dll #44
Comments
The ocamlfind in reason-cli isn't meant to be used for anything except debugging reason-cli at the moment. OCamlfind needs to know where stuff is - and so it needs its env variables / config populated correctly. I think that every project should have its own ocamlfind dependency, and its own config that is populated correctly, for that specific project, which will avoid the problem. OPAM does this for you at the global level which causes some problems (much like the problem you are seeing here). Esy (which reason-cli is based off of) does it at the project level, for your project's specific set of dependencies. I think we should stop exposing ocamlfind from reason-cli or at least discourage it for anything other than debugging a reason-cli installation. Thoughts? |
@jordwalke Is there any way to call it something other than ocamlfind so that I don't end up accidentally using it? I want to make sure I have a correct opam install so that things don't sometimes work and sometimes not. If you think we could get away with not shipping it then that solves my problem :) |
Yeah, we can realias binaries that are only coincidentally exported to something like |
Hey sorry I didn't comment on this for a while. |
Heyyyy this hit us again, where the ocamlfind that comes with Reason-cli shadows opam’s ocamlfind which makes it unusable. |
Right now it seems like I can install
reason-cli
and getocamlfind
. Also it seems like when I runocamlfind ocamlc -package lwt.unix -package lwt.ppx
with that ocamlfind (and no opam installed at all) it will compile.That's a bit surprising and a bit annoying, because when I try to run my executable I get a runtime dll loading errors:
The reason seems to be that the env variable
CAML_LD_LIBRARY_PATH
doesn't point to anything so reason-cli's ocamlfind cannot find the lwt dll. I work around this issue by doing:I'm thinking there's two ways to go about this:
CAML_LD_LIBRARY_PATH
with lwt paths. I like this solution less because it's a bit magical that lwt happens to work but no other opam deps (well in reality anything that reason-cli depends on would work I'm guessing). But I find this solution better than the current situation.What do you all think?
The text was updated successfully, but these errors were encountered: