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 mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id 5CD447EE35 for ; Wed, 23 Mar 2016 11:45:46 +0100 (CET) IronPort-PHdr: 9a23:epzidBYphjG3VadIsc9EiaT/LSx+4OfEezUN459isYplN5qZpcW6bnLW6fgltlLVR4KTs6sC0LqG9fm+EjVcqb+681k8M7V0HycfjssXmwFySOWkMmbcaMDQUiohAc5ZX0Vk9XzoeWJcGcL5ekGA6ibqtW1aJBzzOEJPK/jvHcaK1oLsh7D0osOYOlkArQH+SI0xBS3+lR/WuMgSjNkqAYcK4TyNnEF1ff9Lz3hjP1OZkkW0zM6x+Jl+73YY4Kp5pIZoGJ/3dKUgTLFeEC9ucyVsvJWq5lH/Sl6z5nwZW35evRNaCgfD5RDgU9+lriv9s+Nm8CaTL8T5S7k1Qznk6L1kHkzGkiACYhIw9mDajvtaGKRJpBPp8xB2xY/ZZMefKfd4bKfcVd4AX2NdX99MWmpKAtXvPMM0E+MdMLMA/MHGrFwUoE77XFH0CQ== Authentication-Results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=daniel.buenzli@erratique.ch; spf=None smtp.mailfrom=daniel.buenzli@erratique.ch; spf=None smtp.helo=postmaster@smtp.webfaction.com Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of daniel.buenzli@erratique.ch) identity=pra; client-ip=74.55.86.74; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="daniel.buenzli@erratique.ch"; x-sender="daniel.buenzli@erratique.ch"; x-conformance=sidf_compatible Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of daniel.buenzli@erratique.ch) identity=mailfrom; client-ip=74.55.86.74; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="daniel.buenzli@erratique.ch"; x-sender="daniel.buenzli@erratique.ch"; x-conformance=sidf_compatible Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@smtp.webfaction.com) identity=helo; client-ip=74.55.86.74; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="daniel.buenzli@erratique.ch"; x-sender="postmaster@smtp.webfaction.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0BTAQBPbvJWi0pWN0pehAe7XAENgXAdhXACgXcUAQEBAQEBAQEQAQEBCAsLCSEvQQwBgV+CFQEBAwEjVgULCxoCJgICRxAGG4gXCAQKryaRAAEBAQEBBQEBAQEBARYEfIlmhDqDAiuCKwWXWYVxgnMFjkMOhVSPBx4BAYJWgVKJDoFmAQEB X-IPAS-Result: A0BTAQBPbvJWi0pWN0pehAe7XAENgXAdhXACgXcUAQEBAQEBAQEQAQEBCAsLCSEvQQwBgV+CFQEBAwEjVgULCxoCJgICRxAGG4gXCAQKryaRAAEBAQEBBQEBAQEBARYEfIlmhDqDAiuCKwWXWYVxgnMFjkMOhVSPBx4BAYJWgVKJDoFmAQEB X-IronPort-AV: E=Sophos;i="5.24,382,1454972400"; d="scan'208";a="209676774" Received: from mail6.webfaction.com (HELO smtp.webfaction.com) ([74.55.86.74]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 23 Mar 2016 11:23:18 +0100 Received: from [172.20.10.2] (221.236.197.178.dynamic.wless.lssmb00p-cgnat.res.cust.swisscom.ch [178.197.236.221]) by smtp.webfaction.com (Postfix) with ESMTP id 7BBF720A3D1D; Wed, 23 Mar 2016 10:23:15 +0000 (UTC) Date: Wed, 23 Mar 2016 11:23:12 +0100 From: =?utf-8?Q?Daniel_B=C3=BCnzli?= To: Thomas Gazagnaire Cc: platform , OCaml List Message-ID: <2D9E5D6842A4484183E706191F4745A0@erratique.ch> In-Reply-To: References: <30AF5A7CB977477A9BF094F3BC19C58C@erratique.ch> X-Mailer: sparrow 1.6.4 (build 1178) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Subject: Re: [Caml-list] Package compilation and debug mode Le mercredi, 23 mars 2016 =C3=A0 11:02, Thomas Gazagnaire a =C3=A9crit : > > By default all my packages are released with -g disabled. It seems easy= enough to have an opam switch (even the official one) that automatically e= nables the flag. >=20=20 > How do you envision such a global debug flag? As far as I know, there is = no configuration-time option to enable that option in the compiler (which w= ould be the cleaner option IMHO). I'd rather avoid using OCAMLPARAM for thi= s. I don't know, I think a decent scheme should be figured out by the compiler= dev team. It seems there's more than one way of doing this at the moment, = see e.g.=20=20 https://github.com/ocaml/ocaml/pull/428 =20=20 > A new opam variable can be created and used in the opam file to pass the = debug command (or not) explicitly to the build system, but this will requir= e adapting all the build systems (and ideally a new release of opam, but we= can work-around that by setting OPAMVAR_debug in the .comp file). I don't think this is a reasonable approach. Debug/profile seems rather a p= roperty of your switch than an individual package property. Though one coul= d argue that this should still be added so that packages using other tools = than the ocaml compilers can abide to the switch property.=20=20 Daniel