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

Unable to install ocamlfind #5880

Closed
hgouraud opened this Issue Mar 4, 2016 · 12 comments

Comments

Projects
None yet
8 participants
@hgouraud
Contributor

hgouraud commented Mar 4, 2016

Opam installed succesfully on a Mac Air, El Capitan (10.11)
Ocaml and camlp5 installed succesfully.
Failed to install ocamlfinf!!!

MacAir-H:~ Henri$ opam install ocamlfind
The following actions will be performed:
  ∗  install conf-pkg-config 1.0              [required by conf-ncurses]
  ∗  install conf-ncurses    1                [required by ocamlfind]
  ∗  install ocamlfind       1.6.1
===== ∗  3 =====
Do you want to continue ? [Y/n] y

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=  🐫 
[ocamlfind] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=  🐫 
[ERROR] The compilation of conf-pkg-config failed at "pkg-config --help".

#=== ERROR while installing conf-pkg-config.1.0 ===============================#
# opam-version 1.2.2
# os           darwin
# command      pkg-config --help
# path         /Users/Henri/ocamlbrew/ocaml-4.02.3/.opam/4.02.1/build/conf-pkg-config.1.0
# compiler     4.02.1
# exit-code    127
# env-file     /Users/Henri/ocamlbrew/ocaml-4.02.3/.opam/4.02.1/build/conf-pkg-config.1.0/conf-pkg-config-79808-7afd23.env
# stdout-file  /Users/Henri/ocamlbrew/ocaml-4.02.3/.opam/4.02.1/build/conf-pkg-config.1.0/conf-pkg-config-79808-7afd23.out
# stderr-file  /Users/Henri/ocamlbrew/ocaml-4.02.3/.opam/4.02.1/build/conf-pkg-config.1.0/conf-pkg-config-79808-7afd23.err



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=  🐫 
The following actions were aborted
  ∗  install conf-ncurses 1    
  ∗  install ocamlfind    1.6.1
The following actions failed
  ∗  install conf-pkg-config 1.0
No changes have been performed

=-=- conf-pkg-config.1.0 troobleshooting =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=  🐫 
=> This package relies on external (system) dependencies that may be missing. `opam depext conf-pkg-config.1.0' may help you find the correct installation for your
   system.
MacAir-H:~ Henri$ 

Running opam depext shows no dependency missing

Regards
Henri

@micksulley

This comment has been minimized.

Show comment
Hide comment
@micksulley

micksulley Mar 6, 2016

I have the same issue on Raspbian. opam install conf-m4.1 fails

=-=- conf-m4.1 troobleshooting =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
=> This package relies on external (system) dependencies that may be missing. `opam depext
   conf-m4.1' may help you find the correct installation for your system.

 but

pi@raspberrypi:~/geneweb $ opam depext
# Detecting depexts using flags: arm armv7 linux raspbian
# No extra OS packages requirements found.

micksulley commented Mar 6, 2016

I have the same issue on Raspbian. opam install conf-m4.1 fails

=-=- conf-m4.1 troobleshooting =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
=> This package relies on external (system) dependencies that may be missing. `opam depext
   conf-m4.1' may help you find the correct installation for your system.

 but

pi@raspberrypi:~/geneweb $ opam depext
# Detecting depexts using flags: arm armv7 linux raspbian
# No extra OS packages requirements found.
@avsm

This comment has been minimized.

Show comment
Hide comment
@avsm

avsm Mar 6, 2016

Member

The issue is here is that raspbian is not a recognised external OS. It ought to be mapped onto debian for now.

Member

avsm commented Mar 6, 2016

The issue is here is that raspbian is not a recognised external OS. It ought to be mapped onto debian for now.

@pirbo

This comment has been minimized.

Show comment
Hide comment
@pirbo

pirbo Mar 7, 2016

Contributor

Same issue!
I would say that the problem is that the "build" command of cons-ncurses is

["pkg-config" "ncurses"] { os != "darwin" & os != "freebsd" & os != "netbsd" & os != "openbsd" }

therefore the depend line should be

"conf-pkg-config" { os != "darwin" & os != "freebsd" & os != "netbsd" & os != "openbsd" }

which is not possible I guess (I don't find the formal description of in opam manual)

Anyway, this is super annoying to have lost ocamlfind and all these reverse dependencies with no possible foldback !!!

Contributor

pirbo commented Mar 7, 2016

Same issue!
I would say that the problem is that the "build" command of cons-ncurses is

["pkg-config" "ncurses"] { os != "darwin" & os != "freebsd" & os != "netbsd" & os != "openbsd" }

therefore the depend line should be

"conf-pkg-config" { os != "darwin" & os != "freebsd" & os != "netbsd" & os != "openbsd" }

which is not possible I guess (I don't find the formal description of in opam manual)

Anyway, this is super annoying to have lost ocamlfind and all these reverse dependencies with no possible foldback !!!

OCamlPro-Henry pushed a commit to OCamlPro-Henry/opam-repository that referenced this issue Mar 7, 2016

OCamlPro-Henry pushed a commit to OCamlPro-Henry/opam-repository that referenced this issue Mar 7, 2016

@OCamlPro-Henry

This comment has been minimized.

Show comment
Hide comment
@OCamlPro-Henry

OCamlPro-Henry Mar 7, 2016

Contributor

Well, the constraint in the depends is possible and should have been there already... It should be fixed by #5898.

Contributor

OCamlPro-Henry commented Mar 7, 2016

Well, the constraint in the depends is possible and should have been there already... It should be fixed by #5898.

@OCamlPro-Henry

This comment has been minimized.

Show comment
Hide comment
@OCamlPro-Henry

OCamlPro-Henry Mar 7, 2016

Contributor

I am surprised this error has not been caught by the CI.

Contributor

OCamlPro-Henry commented Mar 7, 2016

I am surprised this error has not been caught by the CI.

@pirbo

This comment has been minimized.

Show comment
Hide comment
@pirbo

pirbo Mar 7, 2016

Contributor

Thanks very much for reactivity!
Well I've been bitten by that already: travis OS X nodes install their dependencies through homebrew
and as soon as you've installed something through home-brew, you've got pkg-config :-)

Contributor

pirbo commented Mar 7, 2016

Thanks very much for reactivity!
Well I've been bitten by that already: travis OS X nodes install their dependencies through homebrew
and as soon as you've installed something through home-brew, you've got pkg-config :-)

@OCamlPro-Henry

This comment has been minimized.

Show comment
Hide comment
@OCamlPro-Henry

OCamlPro-Henry Mar 7, 2016

Contributor

Hmm, I might have spoken too fast (or too late in the evening) :-( adding the "os" predicate in depends made the dependency ignored on linux too.

@AltGr what am I missing here ?

Contributor

OCamlPro-Henry commented Mar 7, 2016

Hmm, I might have spoken too fast (or too late in the evening) :-( adding the "os" predicate in depends made the dependency ignored on linux too.

@AltGr what am I missing here ?

OCamlPro-Henry pushed a commit to OCamlPro-Henry/opam-repository that referenced this issue Mar 8, 2016

conf-ncurses: Do not depend on `conf-pkg-config` when not required
This is a fix for:

  ocaml#5880 (comment)

A simpler fix would be to have a single package, and to add a "filter"
on the `conf-pkg-config` dependency. Unfortunatly, this kind of filter
is not yet possible.
@rathereasy

This comment has been minimized.

Show comment
Hide comment
@rathereasy

rathereasy Mar 27, 2016

I'm on Ubuntu 15.04 and I'm getting the "The compilation of conf-pkg-config.1.0 failed" error. Is there a quick fix to this?

rathereasy commented Mar 27, 2016

I'm on Ubuntu 15.04 and I'm getting the "The compilation of conf-pkg-config.1.0 failed" error. Is there a quick fix to this?

@jstolarek

This comment has been minimized.

Show comment
Hide comment
@jstolarek

jstolarek May 30, 2016

Contributor

Getting the same error on openSUSE 11.4. I have pkg-config and development versions of ncurses installed.

Contributor

jstolarek commented May 30, 2016

Getting the same error on openSUSE 11.4. I have pkg-config and development versions of ncurses installed.

@jstolarek

This comment has been minimized.

Show comment
Hide comment
@jstolarek

jstolarek May 31, 2016

Contributor

I have diagnosed the cause, at least on my system. It turns out that older versions of ncurses (5.7 on my machine) don't come with *.pc files for pkg-config. A workaround for me was to get sources of ncurses 6.0 and build it with --enable-pc-files. For some reason on my machine the script generated by make to create the *.pc files (located at misc/gen-pkgconfig) did not have permissions to execute and so the files were not generated during the build. I had to run the script manually. Then I had to edit the *pc files to match version of ncurses installed on my machine (obtained with ncurses5-config --version) and copy those files to /usr/share/pkgconfig.

Contributor

jstolarek commented May 31, 2016

I have diagnosed the cause, at least on my system. It turns out that older versions of ncurses (5.7 on my machine) don't come with *.pc files for pkg-config. A workaround for me was to get sources of ncurses 6.0 and build it with --enable-pc-files. For some reason on my machine the script generated by make to create the *.pc files (located at misc/gen-pkgconfig) did not have permissions to execute and so the files were not generated during the build. I had to run the script manually. Then I had to edit the *pc files to match version of ncurses installed on my machine (obtained with ncurses5-config --version) and copy those files to /usr/share/pkgconfig.

@gasche

This comment has been minimized.

Show comment
Hide comment
@gasche

gasche Jun 1, 2016

Member

It seems that older versions of ncurses use a special-purpose ncurses5-config script instead of pkg-config. So we could alternatively try that instead of pkg-config in the conf-ncurses package. I don't have the time to try to implement such a package right now, but if I (or someone else) does it, would you maybe be able to test the result?

Member

gasche commented Jun 1, 2016

It seems that older versions of ncurses use a special-purpose ncurses5-config script instead of pkg-config. So we could alternatively try that instead of pkg-config in the conf-ncurses package. I don't have the time to try to implement such a package right now, but if I (or someone else) does it, would you maybe be able to test the result?

@hgouraud

This comment has been minimized.

Show comment
Hide comment
@hgouraud

hgouraud Jun 1, 2016

Contributor

Yes, to the best of my ability, which is limited!!

Henri

Envoyé de mon iPhone

Le 1 juin 2016 à 04:14, Gabriel Scherer notifications@github.com a écrit :

It seems that older versions of ncurses use a special-purpose ncurses5-config script instead of pkg-config. So we could alternatively try that instead of pkg-config in the conf-ncurses package. I don't have the time to try to implement such a package right now, but if I (or someone else) does it, would you maybe be able to test the result?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.

Contributor

hgouraud commented Jun 1, 2016

Yes, to the best of my ability, which is limited!!

Henri

Envoyé de mon iPhone

Le 1 juin 2016 à 04:14, Gabriel Scherer notifications@github.com a écrit :

It seems that older versions of ncurses use a special-purpose ncurses5-config script instead of pkg-config. So we could alternatively try that instead of pkg-config in the conf-ncurses package. I don't have the time to try to implement such a package right now, but if I (or someone else) does it, would you maybe be able to test the result?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.

gasche added a commit to gasche/opam-repository that referenced this issue Jun 2, 2016

ocamlfind does not depend on ncurses
There have been several installation issues with ocamlfind recently due
to the fact that conf-ncurses uses pkg-config to check installability,
which is only valid under recent ncurses versions. But in fact ocamlfind
does not depend on ncurses at all (I just checked with Gerd Stolpmann),
so there is no reason for the dependency in the first place.

fixes #5880

@lefessan lefessan closed this in #6657 Jun 5, 2016

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