[opam-devel] opam getting compiler version wrong

Ashish Agarwal agarwal1975 at gmail.com
Thu Dec 22 17:44:35 GMT 2016


Thanks, that works (though I get a different compile error now). I'll add
issues to the repo.


On Wed, Dec 21, 2016 at 6:32 PM, Louis Gesbert <louis.gesbert at ocamlpro.com>
wrote:

> On lundi 19 décembre 2016 17:17:55 CET Ashish Agarwal wrote:
> > I'm trying the option of doing `opam-admin upgrade-format`, but what's
> the
> > best way to get `opam-admin`? Is it by chance available as a pre-compiled
> > binary like `opam` is?
> >
> > I'm trying to compile opam myself, but getting this:
> >
> > ocamlfind ocamlc -package
> > unix,bigarray,extlib,re,re.str,re.pcre,re.glob,cmdliner,ocam
> lgraph,cudf,dose
> > 3.common,dose3.algo,jsonm,no -c -g -w +a-4-44-48 -bin-annot -short-paths
> > -safe-string -I core -I format -I solver -I repository -I state -I client
> > -I core/ core/opamCompat.mli ocamlfind: Package `no' not found
> >
> > Unfortunately "no" isn't very easy to search for. Is that really the name
> > of an ocamlfind package?
>
> You need to install the `opam-file-format` package, which has been
> separated
> from opam itself. `./configure` should warn about this, but I remember it
> was
> missing a check at some point.
>
> Yes, providing pre-compiled libraries would be useful, I'll see if they can
> easily be added to the release process.
>
> >
> > On Tue, Dec 13, 2016 at 6:46 AM, <louis.gesbert at ocamlpro.com> wrote:
> > > That's not true. opam won't upgrade your repositories implicitely at
> the
> > > moment (I am considering it, but am afraid it may lead to more
> difficult
> > > to
> > > track errors). The only thing it rewrites is opam files found in source
> > > trees
> > > when you pin them.
> > >
> > > I will add a warning in opam2 when use of a 1.2 repository is detected.
> > >
> > > Best,
> > > Louis Gesbert - OCamlPro
> > >
> > > On samedi 10 décembre 2016 21:36:08 CET Drup wrote:
> > > > opam 2.0 upgrades the format automatically when pinning a repository
> > > > with an older opam format.
> > > >
> > > > Le 10/12/2016 à 21:05, Anil Madhavapeddy a écrit :
> > > > > You can run "opam admin upgrade-format" to upgrade the repository,
> but
> > >
> > > I'm
> > >
> > > > > not sure of how to convert individual `opam` files.  This seems
> like
> > > > > it
> > > > > would be useful in order to upgrade working repositories for
> pinning
> > > > > purposes...
> > > > >
> > > > > Anil
> > > > >
> > > > >> On 7 Dec 2016, at 21:52, Ashish Agarwal <agarwal1975 at gmail.com>
> > >
> > > wrote:
> > > > >> Seems the issue is mis-interpretation of a deprecated constraint.
> I'm
> > > > >> using Jane Street's opam repository [1], which contains
> constraints
> > > > >> like:
> > > > >>
> > > > >> available: [ ocaml-version >= "4.03.0" ]
> > > > >>
> > > > >> After replacing this with a normal constraint in the `depends`
> field,
> > >
> > > it
> > >
> > > > >> worked fine. Is there a tool to convert old opam files?
> > > > >>
> > > > >> [1] https://github.com/janestreet/opam-repository
> > > > >>
> > > > >>
> > > > >> On Wed, Dec 7, 2016 at 8:04 AM, Ashish Agarwal <
> agarwal1975 at gmail.com
> > > > >>
> > > > >> wrote: I'm getting this:
> > > > >>
> > > > >> $ opam install ppx_sexp_conv.114.10+84
> > > > >> [ERROR] ppx_sexp_conv.114.10+84 has unmet availability conditions:
> > > > >> ocaml-version >= "4.03.0"
> > > > >>
> > > > >> So opam thinks my ocaml version is < 4.03.0, but I'm in a 4.03.0
> > >
> > > switch.
> > >
> > > > >> I've certainly run "eval `opam config env`". I created a new
> switch
> > >
> > > with
> > >
> > > > >> 4.03.0 to try it from scratch, but get the same issue.
> > > > >>
> > > > >> Sanity checks:
> > > > >>
> > > > >> $ ocaml -version
> > > > >> The OCaml toplevel, version 4.03.0
> > > > >>
> > > > >> $ opam info ocaml | grep all-installed-versions
> > > > >> all-installed-versions 4.03.0 [4.03.0]  4.04.0 [4.04.0]
> > > > >>
> > > > >> Incidentally, I'm confused about the output of `opam info ocaml`.
> I
> > >
> > > have
> > >
> > > > >> 6 switches on this computer. How come only 2 are listed above?
> > > > >>
> > > > >> $ opam --version
> > > > >> 2.0~alpha5
> > > > >>
> > > > >>
> > > > >> _______________________________________________
> > > > >> opam-devel mailing list
> > > > >> opam-devel at lists.ocaml.org
> > > > >> http://lists.ocaml.org/listinfo/opam-devel
> > > > >
> > > > > _______________________________________________
> > > > > opam-devel mailing list
> > > > > opam-devel at lists.ocaml.org
> > > > > http://lists.ocaml.org/listinfo/opam-devel
> > > >
> > > > _______________________________________________
> > > > opam-devel mailing list
> > > > opam-devel at lists.ocaml.org
> > > > http://lists.ocaml.org/listinfo/opam-devel
> > >
> > > _______________________________________________
> > > opam-devel mailing list
> > > opam-devel at lists.ocaml.org
> > > http://lists.ocaml.org/listinfo/opam-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ocaml.org/pipermail/opam-devel/attachments/20161222/67cf0fb7/attachment.html>


More information about the opam-devel mailing list