From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 7B2D07FCCB for ; Thu, 9 Apr 2015 15:27:54 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of gabriel.scherer@gmail.com) identity=pra; client-ip=209.85.223.180; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gabriel.scherer@gmail.com"; x-sender="gabriel.scherer@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of gabriel.scherer@gmail.com designates 209.85.223.180 as permitted sender) identity=mailfrom; client-ip=209.85.223.180; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gabriel.scherer@gmail.com"; x-sender="gabriel.scherer@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-ie0-f180.google.com) identity=helo; client-ip=209.85.223.180; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gabriel.scherer@gmail.com"; x-sender="postmaster@mail-ie0-f180.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0DwAQCjfSZVm7TfVdFcg1pcBYMQsmuOGDOBU4V9AoE3BzoSAQEBAQEBAREBAQEBAQYLCwkULoQgAQEDARIRHQEbEgsBAwELBgMCBAcaHQICIgERAQUBChIGEwgKEIdzAQMJCA2ZcpBZPjGLOIFrgnaLXwoZJwMKVIRmAQEBAQEFAQEBAQEBFgEFDosdhHgEB4JogUUFhRAKj1iGE4FXkUQSI4EMCYF9ghY8MYJDAQEB X-IPAS-Result: A0DwAQCjfSZVm7TfVdFcg1pcBYMQsmuOGDOBU4V9AoE3BzoSAQEBAQEBAREBAQEBAQYLCwkULoQgAQEDARIRHQEbEgsBAwELBgMCBAcaHQICIgERAQUBChIGEwgKEIdzAQMJCA2ZcpBZPjGLOIFrgnaLXwoZJwMKVIRmAQEBAQEFAQEBAQEBFgEFDosdhHgEB4JogUUFhRAKj1iGE4FXkUQSI4EMCYF9ghY8MYJDAQEB X-IronPort-AV: E=Sophos;i="5.11,549,1422918000"; d="scan'208";a="108981677" Received: from mail-ie0-f180.google.com ([209.85.223.180]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 09 Apr 2015 15:27:53 +0200 Received: by iedfl3 with SMTP id fl3so113095780ied.1 for ; Thu, 09 Apr 2015 06:27:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=3praUIzm/E7YGV/afQregSOSCTUv306peCSZ0+An7f4=; b=wpm/waATcb+DRaTZwPvJiyUN1OHmUxkFwNK/k5FkNsgCR/0Tdit4Uor1rU3jIDM9w8 E3JzutneQIUGoMdgz/yIBh72JgS1hX7bgeZ/UROKtvvSSkx2E1G6jvAr0AjCTOlfxzMF QK8zQMT8UxfL6StUCyAZ4Y5S71fVjntoS3HJmLcmiojA6NAgkkHqm3KFWk4v8HEZpBRw xX0X7ZhnzntCwlhvq9IuOKVwwqjAcV0raAgIw0c71+W/yqX74aJ8S00tXm8ghagrg7bQ X4oDtweuAFNGuzG26M5UL0PWZ8iX6mzdDURHT8xn7ZEalGPzW8QCkm2gzUP3df6Ppxmb RfOw== X-Received: by 10.42.114.3 with SMTP id e3mr38812796icq.27.1428586072018; Thu, 09 Apr 2015 06:27:52 -0700 (PDT) MIME-Version: 1.0 Received: by 10.36.53.10 with HTTP; Thu, 9 Apr 2015 06:27:11 -0700 (PDT) In-Reply-To: <552666C5.6070103@cea.fr> References: <552666C5.6070103@cea.fr> From: Gabriel Scherer Date: Thu, 9 Apr 2015 15:27:11 +0200 Message-ID: To: =?UTF-8?Q?Fran=C3=A7ois_Bobot?= Cc: OCaml Mailing List Content-Type: multipart/alternative; boundary=20cf303f6e205a948905134a9d15 Subject: Re: [Caml-list] META file standards for native plugins --20cf303f6e205a948905134a9d15 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable I don't understand the problem with the current semantics. The .cmxs will be linked when both predicates "archive" and "plugin" are true, and that seems correct to me (we use this when we want to link a *plugin* inside a *native* program). This is consistent with the use for example of (syntax,preprocessor,camlp4o) and (syntax,preprocessor,camlp4r) to select standard or revised syntax, or (syntax,toploop) when invoked from the toplevel. Also many packages currently use archive(byte,plugin) as well (which links to the .cma, just as with only archive(byte)). On Thu, Apr 9, 2015 at 1:47 PM, Fran=C3=A7ois Bobot wrote: > Hi, > > Another topic which need a standard is native dynamic plugins. In > fact there is a defacto standard (used by some libraries and tools, but n= ot > specified in ocamlfind documentation) but it is a bad one. > > archive(plugin,native) =3D "toto.cmxs" > > It is a bad one because the semantic of META file says that the value of > `archive(native)` can be return when you ask the value of `archive` with > the predicate `plugin` and the predicate `native` true. > > I discussed it with some people and the current proposition where > > * archive(plugin_native) > * archive(plugin) > * archive(shared) > > > I personally prefer the `shared` predicate because it corresponds to the > `-shared` option of ocamlopt that creates `.cmxs`. > > The predicate `shared` would be added to ocamlfind documentation. The > prospective `ocamlfind check META` could recommend to add an > `archive(shared)` if the `archive(native)` exists. For a transition period > `archive(plugin,native)` and `archive(shared)` would be both present in t= he > META. > > > Thoughts or suggestions? > > > Best regards, > > -- > Fran=C3=A7ois Bobot > > -- > Caml-list mailing list. Subscription management and archives: > https://sympa.inria.fr/sympa/arc/caml-list > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs > --20cf303f6e205a948905134a9d15 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I don't understand the problem with the current semant= ics. The .cmxs will be linked when both predicates "archive" and = "plugin" are true, and that seems correct to me (we use this when= we want to link a *plugin* inside a *native* program). This is consistent = with the use for example of (syntax,preprocessor,camlp4o) and (syntax,prepr= ocessor,camlp4r) to select standard or revised syntax, or (syntax,toploop) = when invoked from the toplevel. Also many packages currently use archive(by= te,plugin) as well (which links to the .cma, just as with only archive(byte= )).

On T= hu, Apr 9, 2015 at 1:47 PM, Fran=C3=A7ois Bobot <francois.bobot@cea.fr= > wrote:
Hi,

=C2=A0 =C2=A0 =C2=A0 =C2=A0 Another topic which need a standard is native d= ynamic plugins. In fact there is a defacto standard (used by some libraries= and tools, but not specified in ocamlfind documentation) but it is a bad o= ne.

=C2=A0 archive(plugin,native) =3D "toto.cmxs"

It is a bad one because the semantic of META file says that the value of `a= rchive(native)` can be return when you ask the value of `archive` with the = predicate `plugin` and the predicate `native` true.

I discussed it with some people and the current proposition where

=C2=A0 * archive(plugin_native)
=C2=A0 * archive(plugin)
=C2=A0 * archive(shared)


I personally prefer the `shared` predicate because it corresponds to the `-= shared` option of ocamlopt that creates `.cmxs`.

=C2=A0The predicate `shared` would be added to ocamlfind documentation. The= prospective `ocamlfind check META` could recommend to add an `archive(shar= ed)` if the `archive(native)` exists. For a transition period `archive(plug= in,native)` and `archive(shared)` would be both present in the META.


Thoughts or suggestions?


Best regards,

--
Fran=C3=A7ois Bobot

--
Caml-list mailing list.=C2=A0 Subscription management and archives:
ht= tps://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners<= /a>
Bug reports:
http://caml.inria.fr/bin/caml-bugs

--20cf303f6e205a948905134a9d15--