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

'opam install ocamlfind' fails on Cygwin #16457

Closed
yannl35133 opened this issue May 16, 2020 · 1 comment
Closed

'opam install ocamlfind' fails on Cygwin #16457

yannl35133 opened this issue May 16, 2020 · 1 comment

Comments

@yannl35133
Copy link

On a fresh Cygwin 64 (Win10) with opam 2.0.4, with default switch OCaml 4.10.0, ocamlfind cannot be installed.
This is certainly linked to #11453 as it is the same error message.

Their proposed solution, installing ocaml-compiler-libs, worked for me. Maybe you could edit the error message to mention this dependency (or add it as a dependency for opam in Cygwin) ?

See the console :

Me@My-PC ~
$ opam --version
2.0.4


Me@My-PC ~
$ opam switch
#  switch   compiler             description
→  default  ocaml-system.4.10.0  default


Me@My-PC ~
$ opam install ocamlfind
The following actions will be performed:
  ∗ install ocamlfind 1.8.1

<><> Gathering sources ><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[ocamlfind.1.8.1] found in cache

<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[ERROR] The compilation of ocamlfind failed at "/usr/bin/make all".

#=== ERROR while compiling ocamlfind.1.8.1 ====================================#
# context     2.0.4 | cygwin/x86_64 | ocaml-system.4.10.0 | https://opam.ocaml.org#513d3767
# path        ~/.opam/default/.opam-switch/build/ocamlfind.1.8.1
# command     /usr/bin/make all
# exit-code   2
# env-file    ~/.opam/log/ocamlfind-6417-c61e7b.env
# output-file ~/.opam/log/ocamlfind-6417-c61e7b.out
### output ###
# [...]
# Use Bytes.create instead.
# ocamlc -I +compiler-libs  -o ocamlfind.exe -g findlib.cma unix.cma \
#            ocaml_args.cmo frontend.cmo
# ocamlc -I +compiler-libs -opaque -c topfind.mli
# ocamlc -I +compiler-libs -opaque -g -c topfind.ml
# File "topfind.ml", line 55, characters 12-41:
# 55 |   let ph = !Toploop.parse_toplevel_phrase l in
#                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# Error: Unbound module Toploop
# make[1]: *** [Makefile:165 : topfind.cmo] Erreur 2
# make[1] : on quitte le répertoire « /home/me/.opam/default/.opam-switch/build/ocamlfind.1.8.1/src/findlib »
# make: *** [Makefile:13 : all] Erreur 2



<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
┌─ The following actions failed
│ λ build ocamlfind 1.8.1
└─
╶─ No changes have been performed

after I installed ocaml-compiler-libs

Me@My-PC ~
$ opam install ocamlfind
The following actions will be performed:
  ∗ install ocamlfind 1.8.1

<><> Gathering sources ><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[ocamlfind.1.8.1] found in cache

<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
∗ installed ocamlfind.1.8.1
Done.
@dra27
Copy link
Member

dra27 commented May 28, 2020

Just FTR, the report is affected by ocaml/opam#3954 so this is in fact opam 2.0.5!

This is a packaging problem on Cygwin - I've sent a message to the Cygwin list asking for a dependency on ocaml-compiler-libs to be added either to the ocaml or opam package in Cygwin to fix this.

@dra27 dra27 closed this as completed May 28, 2020
andyli added a commit to andyli/opam-cygwin that referenced this issue Jul 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants