[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: correct cohttp opamconstraints

> depends: [ "ocamlfind" "re" "uri" {>="1.3.2"} "ounit" ]
> depopts: [ "async" {="108.00.02"} "lwt" {>="2.4.1"} "mirage-net" ]
> However, cohttp requires Lwt AND SSL to be installed, or it fails (since SSL 
> is not yet optional).
> Is there any way to express this in the CNF? I tried:

Currently this not possible (as depopts are OR constraints only), but I guess I 
could add that in 0.8 if you open an issue for that :-)

> depopts: [ "async" {="108.00.02"} ("lwt" {>="2.4.1"} "ssl") "mirage-net" ]

I think I will go with the following syntax:
depopts: [ "async" {="108.00.02"} ("lwt" {>="2.4.1"} & "ssl") "mirage-net" ]
as this is kind of dual with 'depends' where you express AND constraints, and 
use '|' for OR.

The other solution is to put the constraints in the 'depends' field directly:
depends: [ "ocamlfind" "re" "uri" {>="1.3.2"} "ounit"  ("async" {="108.00.02"} 
| ("lwt" {>="2.4.1"} "ssl") | "mirage-net") ]

(not sure that nested constraints currently work correctly though).




Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.