Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

optional compilation #51

Closed
vbmithr opened this issue Apr 2, 2017 · 6 comments
Closed

optional compilation #51

vbmithr opened this issue Apr 2, 2017 · 6 comments

Comments

@vbmithr
Copy link

vbmithr commented Apr 2, 2017

[vb@haramis ~/code/ocaml-websocket]% jbuilder external-lib-deps --missing @install
Error: The following required libraries are missing in the default context:
- cryptokit (optional)

I am using the following stanza:

(library
 ((name rng_cryptokit)
  (public_name websocket.rng_cryptokit)
  (modules (rng_cryptokit))
  (optional)
  (libraries (rng cryptokit))))

Why jbuilder insists on building this if it is flagged optional and that cryptokit is not installed?

@ghost
Copy link

ghost commented Apr 3, 2017

Maybe it's required by a non-optional library or an executable that is to be installed?

@vbmithr
Copy link
Author

vbmithr commented Apr 5, 2017

No, not that I can see.
Maybe you can have a look and try to compile : https://github.com/vbmithr/ocaml-websocket/tree/jbuilder

@ghost
Copy link

ghost commented Apr 5, 2017

Can you try putting the optional libraries in separate directories? It might have to do with the merging of the .merlin

@vbmithr
Copy link
Author

vbmithr commented Apr 5, 2017

This works. But still a bug.

ghost pushed a commit that referenced this issue Apr 5, 2017
@ghost
Copy link

ghost commented Apr 5, 2017

Indeed, I documented it. I'd say it's low-priority

@ghost ghost added the suspended label Jun 2, 2017
@ghost
Copy link

ghost commented Jun 2, 2017

I head that merlin should eventually read flags from .cmt[i] files directly, which will solve this issue, so it's probably best to just wait for now

andrewray added a commit to andrewray/lwt that referenced this issue Jun 7, 2017
1. remove unused files; TODO, _opam, bad_packages

2. fix library description (thread->promise) in discover.ml

3. update .gitignore

4. remove jbuilder line in readme

5. update opam file post install message and remove
   ocaml-migrate-parsetree dep, revert post install message

6. get build to work without presence of camlp4

according to ocaml/dune#51 we need to move the 3 camlp4
packages into seperate directories.

I note a general opam packing issue where if a system installed
camlp4 is in the PATH when ocamlfind is installed, it adds a META
file which pretends those packages are available and compatible with
any current OPAM switch, which it is not!

I think this is an upstream camlp4 packaging issue

7. Add a custom META file

This is only to support the correct syntax predicates for camlp4
and ocamlfind.

Also requires various exists_if clauses
rgrinberg added a commit that referenced this issue Mar 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant