OCamlPro / ocp-indent

Indentation tool for OCaml, to be used from editors like Emacs and Vim.
http://www.typerex.org/ocp-indent.html
Other
200 stars 63 forks source link

Cannot install ocp-indent #269

Closed yannl35133 closed 4 years ago

yannl35133 commented 6 years ago

I cannot install ocp-indent on my Cygwin setup. The bug may come from ocp-build, I have opened the same issue there, but this directory looks more active and the same people run both, so I post here as well. Error report :

me@MY-PC ~
$ opam config list

<><> Global opam variables ><><><><><><><><><><><><><><><><><><><><><><><><><><>
arch              x86_32                # Inferred from system
jobs              1                     # The number of parallel jobs set up in opam configuration
make              make                  # The 'make' command to use
opam-version      2.0.0                 # The currently running opam version
os                cygwin                # Inferred from system
os-distribution   cygwin                # Inferred from system
os-family         windows               # Inferred from system
os-version        unknown               # Inferred from system
root              /home/me/.opam # The current opam root directory
switch            4.07.0                # The identifier of the current switch
sys-ocaml-version 4.07.0                # OCaml version present on your system independently of opam, if any

<><> Configuration variables from the current switch ><><><><><><><><><><><><><>
prefix   /home/me/.opam/4.07.0
lib      /home/me/.opam/4.07.0/lib
bin      /home/me/.opam/4.07.0/bin
sbin     /home/me/.opam/4.07.0/sbin
share    /home/me/.opam/4.07.0/share
doc      /home/me/.opam/4.07.0/doc
etc      /home/me/.opam/4.07.0/etc
man      /home/me/.opam/4.07.0/man
toplevel /home/me/.opam/4.07.0/lib/toplevel
stublibs /home/me/.opam/4.07.0/lib/stublibs
user     me
group    My Group

<><> Package variables ('opam config list PKG' to show) <><><><><><><><><><><><>
PKG:name       # Name of the package
PKG:version    # Version of the package
PKG:depends    # Resolved direct dependencies of the package
PKG:installed  # Whether the package is installed
PKG:enable     # Takes the value "enable" or "disable" depending on whether the package is installed
PKG:pinned     # Whether the package is pinned
PKG:bin        # Binary directory for this package
PKG:sbin       # System binary directory for this package
PKG:lib        # Library directory for this package
PKG:man        # Man directory for this package
PKG:doc        # Doc directory for this package
PKG:share      # Share directory for this package
PKG:etc        # Etc directory for this package
PKG:build      # Directory where the package was built
PKG:hash       # Hash of the package archive
PKG:dev        # True if this is a development package
PKG:build-id   # A hash identifying the precise package version with all its dependencies

me@MY-PC ~
$ opam remove ocp-indent ocp-build
[NOTE] ocp-indent is not installed.

The following actions will be performed:
  ⊘ remove ocp-pp    1.99.19-beta [uses ocp-build]
  ⊘ remove ocp-build 1.99.19-beta
===== ⊘ 2 =====
Do you want to continue? [Y/n]

<><> Gathering sources ><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[ocp-build.1.99.19-beta] found in cache

<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
⊘ removed   ocp-pp.1.99.19-beta
⊘ removed   ocp-build.1.99.19-beta
Done.

me@MY-PC ~
$ opam install ocp-indent
The following actions will be performed:
  ∗ install ocp-build  1.99.20-beta [required by ocp-indent]
  ∗ install ocp-indent 1.6.1
===== ∗ 2 =====
Do you want to continue? [Y/n]

<><> Gathering sources ><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[ocp-build.1.99.20-beta] found in cache
[ocp-indent.1.6.1] found in cache

<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
∗ installed ocp-build.1.99.20-beta
[ERROR] The compilation of ocp-indent failed at "/usr/bin/make".

#=== ERROR while compiling ocp-indent.1.6.1 ===================================#
# context     2.0.0 | cygwin/x86_32 | ocaml-base-compiler.4.07.0 | https://opam.ocaml.org/2.0#87ff3872
# path        ~/.opam/4.07.0/.opam-switch/build/ocp-indent.1.6.1
# command     /usr/bin/make
# exit-code   2
# env-file    ~/.opam/log/ocp-indent-7092-d0f245.env
# output-file ~/.opam/log/ocp-indent-7092-d0f245.out
### output ###
# Error: you need ocp-build >= 1.99.
# make: *** [Makefile:92: ocp-build.root] Error 1

<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
┌─ The following actions failed
│ λ build ocp-indent 1.6.1
└─
┌─ The following changes have been performed
│ ∗ install ocp-build 1.99.20-beta
└─

The former state can be restored with:
    opam switch import "/home/me/.opam/4.07.0/.opam-switch/backup/state-20180816135323.export"
Or you can retry to install your package selection with:
    opam install --restore
theAkito commented 5 years ago

Any updates?

yannl35133 commented 5 years ago

Since then I went to Linux, no problem there. I can retry this on the old setup, but not currently

AltGr commented 4 years ago

Now compiles with dune, so I don't think this should be a problem anymore. Thanks for reporting

yannl35133 commented 4 years ago

Just reinstalled ocp-indent through Cygwin and opam: no problem (at least for ocp-indent)