Skip to content

cannot install ocamlbuild with opam on ocaml 4.02.3 switch, cygwin-32 system #84

Closed

Description

@pela9

I get the following error when trying to install ocamlbuild on a cygwin-32 system using the new ocaml 4.03.0 compiler. I have had no problems with this on the 4.02.3 switch.

genovese[getline]$ opam switch show
4.03.0
genovese[getline]$ uname -rsv
CYGWIN_NT-10.0-WOW 2.5.1(0.297/5/3) 2016-04-21 22:12
genovese[getline]$ opam install ocamlbuild
The following actions will be performed:
  ∗  install ocamlbuild 0.9.2

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ocamlbuild] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of ocamlbuild failed at "make check-if-preinstalled all opam-install".

#=== ERROR while installing ocamlbuild.0.9.2 ==================================#
# opam-version 1.2.2
# os           cygwin
# command      make check-if-preinstalled all opam-install
# path         /home/pela/.opam/4.03.0/build/ocamlbuild.0.9.2
# compiler     4.03.0
# exit-code    2
# env-file     /home/pela/.opam/4.03.0/build/ocamlbuild.0.9.2/ocamlbuild-11048-58c514.env
# stdout-file  /home/pela/.opam/4.03.0/build/ocamlbuild.0.9.2/ocamlbuild-11048-58c514.out
# stderr-file  /home/pela/.opam/4.03.0/build/ocamlbuild.0.9.2/ocamlbuild-11048-58c514.err
### stdout ###
# [...]
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild_plugin.ml
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild_executor.mli
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild_executor.ml
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild_unix_plugin.mli
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild_unix_plugin.ml
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild.mli
# ocamlc.opt -w L -w R -w Z -I src -I +unix -safe-string -c src/ocamlbuild.ml
# ocamlc.opt -I +unix -I src -o ocamlbuild.byte \
#           unix.cma ocamlbuild_pack.cmo src/ocamlbuild_plugin.cmo src/ocamlbuild_executor.cmo src/ocamlbuild_unix_plugin.cmo src/ocamlbuild.cmo
# Makefile:125: recipe for target 'ocamlbuild.byte' failed
### stderr ###
# [...]
# Use Char.lowercase_ascii instead.
# File "src/ocaml_specific.ml", line 895, characters 50-64:
# Warning 3: deprecated: Char.lowercase
# Use Char.lowercase_ascii instead.
# File "src/ocaml_specific.ml", line 896, characters 40-54:
# Warning 3: deprecated: Char.lowercase
# Use Char.lowercase_ascii instead.
# File "_none_", line 1:
# Error: Error on dynamically loaded library: /home/pela/.opam/4.03.0/lib/ocaml/stublibs/dllunix.so: Cannot resolve caml_debugger_cleanup_fork
# make: *** [ocamlbuild.byte] Error 2



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  ∗  install ocamlbuild 0.9.2
No changes have been performed

Activity

  1. pela9 commented on May 15, 2016

    @pela9
    Author

    Sorry, title is wrong, Imeant 4.03.0 switch, as explained in the meassage

  2. gasche commented on May 16, 2016

    @gasche
    Member

    The error you get seems to be:

    # Error: Error on dynamically loaded library: /home/pela/.opam/4.03.0/lib/ocaml/stublibs/dllunix.so:
    Cannot resolve caml_debugger_cleanup_fork
    

    This is extremely strange, and I am not sure it is related to ocamlbuild itself, or something in the compiler distribution that is not compiled/linked/installed correctly under cygwin-32.

    Could you try, independently of ocamlbuild, to compile and run a program using the Unix module?

    (* foo.ml *)
    let () = print_float (Unix.gettimeofday ()); print_newline ()
    ocamlc.opt -I +unix -c foo.ml
    ocamlc.opt -I +unix unix.cma foo.cmo -o foo
    ./foo
    
  3. pela9 commented on May 16, 2016

    @pela9
    Author

    Thanks, for your attention. I followed your instructions above and indeed got a similar error:

    $ ocamlc.opt -I +unix unix.cma foo.cmo -o foo
    File "none", line 1:
    Error: Error on dynamically loaded library: /home/pela/.opam/4.03.0/lib/ocaml/stublibs/dllunix.so: Cannot resolve caml_debugger_cleanup_fork

    So, obviously this has nothing to do with ocamlbuild but is a problem with installing the new 4.03.0 compiler on cygwin32 with opam. I will report this elsewhere.

  4. gasche commented on May 16, 2016

    @gasche
    Member

    I think that the compiler distribution bugtracker would probably be the right place to report this.

  5. pela9 commented on May 16, 2016

    @pela9
    Author

    Thanks for your help

  6. aantron commented on May 19, 2016

    @aantron

    @pela9 Was this reported on Mantis? I was not able to find an issue, but if it's there, could you please link it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions