[opam-devel] the available field in 1.1.1

Anil Madhavapeddy anil at recoil.org
Sun Aug 31 15:11:49 BST 2014


On 31 Aug 2014, at 15:03, Anil Madhavapeddy <anil at recoil.org> wrote:

> On 31 Aug 2014, at 13:35, Thomas Gazagnaire <thomas at gazagnaire.org> wrote:
> 
>>>> +available: [ !preinstalled & ocaml-version = "4.02.0" ]
>>>> 
>>>> This works fine OPAM 1.2, but OPAM 1.1.1 complains with a parse error.  Is there
>>>> anything that'll work for both?
>>> 
>>> The parser in 1.1.1 was a bit dumb, you need to add parenthesis:
>>> 
>>> available: [ !preinstalled & (ocaml-version = "4.02.0")
>>> ]
>> 
>> Actually, 1.1.1 parser is very broken ... You should use:
>> [ (preinstalled = false) & (ocaml-version = "4.02.0") ]
> 
> Thanks, this is now pushed and building in the pull request (along with a help message to point people at camlp4 binaries).

Can't get this to work, see below for two attempts:

+available: [ (preinstalled = "false") & (ocaml-version = "4.02.0") ]
To Build:
atdgen
camlp4
build one: atdgen
default    Synchronizing with /home/travis/build/ocaml/opam-repository
Updating ~/.opam/repo/compiler-index ...
Updating ~/.opam/compilers/ ...
Updating ~/.opam/repo/package-index ...
Updating ~/.opam/packages/ ...
Creating a cache of metadata in ~/.opam/state.cache ...
[ERROR] 'preinstalled' has type bool, but a env element of type string was expected.

+available: [ (preinstalled = false) & (ocaml-version = "4.02.0") ]
To Build:
atdgen
camlp4
build one: atdgen
default    Synchronizing with /home/travis/build/ocaml/opam-repository
Updating ~/.opam/repo/compiler-index ...
Updating ~/.opam/compilers/ ...
Updating ~/.opam/repo/package-index ...
Updating ~/.opam/packages/ ...
Creating a cache of metadata in ~/.opam/state.cache ...
[ERROR] 'false' has type bool, but a env element of type string was expected.

(from the relevant Travis builds...)

-anil


More information about the opam-devel mailing list