From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by c5ff346549e7 (Postfix) with ESMTPS id E58D05D4 for ; Sat, 29 Feb 2020 08:41:34 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.70,499,1574118000"; d="scan'208";a="438140882" Received: from sympa.inria.fr ([193.51.193.213]) by mail2-relais-roc.national.inria.fr with ESMTP; 29 Feb 2020 09:41:32 +0100 Received: by sympa.inria.fr (Postfix, from userid 20132) id 618DB7F444; Sat, 29 Feb 2020 09:41:32 +0100 (CET) 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 BEE1E7F3B1 for ; Sat, 29 Feb 2020 09:41:26 +0100 (CET) Authentication-Results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=rich@annexia.org; spf=Pass smtp.mailfrom=rich@annexia.org; spf=None smtp.helo=postmaster@mail.annexia.org IronPort-PHdr: =?us-ascii?q?9a23=3Ao1M7Kh8uxhtDUf9uRHKM819IXTAuvvDOBiVQ1KB3?= =?us-ascii?q?1+0cTK2v8tzYMVDF4r011RmVBNmduqMP0rOG+4nbGkU+or+5+EgYd5JNUxJXwe?= =?us-ascii?q?43pCcHRPC/NEvgMfTxZDY7FskRHHVs/nW8LFQHUJ2mPw6arXK99yMdFQviPgRp?= =?us-ascii?q?OOv1BpTSj8Oq3Oyu5pHfeQpFiCeybL9oKBi7qQrdutQLjYZhN6081gbHrnxUdu?= =?us-ascii?q?tZwm9lOUidlAvm6Meq+55j/SVQu/Y/+MNFTK73Yac2Q6FGATo/K2w669HluhfF?= =?us-ascii?q?TQuU+3sTSX4WnQZSAwjE9x71QJH8uTbnu+Vn2SmaOcr2Ta0oWTmn8qxmRgPkhD?= =?us-ascii?q?sBOjUk9mzcl85+g79BoB+5qRJxw5DabpyWOvpwcazSYc4VS2VDUclfTCFBHoCx?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kQIeriBbOzyujRbgPmO7SCQ=3D=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0AoEQDnIlpeW+ZTu1FmHQEBAQkBEQUFA?= =?us-ascii?q?YF7AoInJgFlVRKNQYV7AU0DAwaBN5lXgWcJAQMBDC8EAQGEQAKCBx8HAQQ0EwI?= =?us-ascii?q?QAQEFAQEBAgECAwQBBhoVhUFYQhYBgWIigwcBBTIBIzMLGAkTEg8FGA0KGgGGD?= =?us-ascii?q?ymvb4pGgTgBjDgGeT5JgUeCMC4+hBErg1KCLASOHqF9BwOCPJZZDBybMY5wm3C?= =?us-ascii?q?BaYF6fQg7gm1PGA2OVY4QRItYggmCQQEB?= X-IPAS-Result: =?us-ascii?q?A0AoEQDnIlpeW+ZTu1FmHQEBAQkBEQUFAYF7AoInJgFlVRK?= =?us-ascii?q?NQYV7AU0DAwaBN5lXgWcJAQMBDC8EAQGEQAKCBx8HAQQ0EwIQAQEFAQEBAgECA?= =?us-ascii?q?wQBBhoVhUFYQhYBgWIigwcBBTIBIzMLGAkTEg8FGA0KGgGGDymvb4pGgTgBjDg?= =?us-ascii?q?GeT5JgUeCMC4+hBErg1KCLASOHqF9BwOCPJZZDBybMY5wm3CBaYF6fQg7gm1PG?= =?us-ascii?q?A2OVY4QRItYggmCQQEB?= X-IronPort-AV: E=Sophos;i="5.70,499,1574118000"; d="scan'208";a="340789706" X-MGA-submission: =?us-ascii?q?MDGtx3nCNTIDe7d0gcV8AJCade5KIWW5XSND/i?= =?us-ascii?q?wzFu0BfXrwBLUo+dvaCjwfEiQiXGEzna9TJu+8hpttH/UbWuz9g0+2xg?= =?us-ascii?q?p4QBT1MN9trR1VyYctwTI7kOTelPU7V10pJsEzgm53t3nXafQoIBXo4h?= =?us-ascii?q?c6FL/d2BF3Q+KdzOXTlQUyWg=3D=3D?= Received: from 230.83.187.81.in-addr.arpa (HELO mail.annexia.org) ([81.187.83.230]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Feb 2020 09:41:26 +0100 Received: by mail.annexia.org (Postfix, from userid 1000) id 342DAAC00D14; Sat, 29 Feb 2020 08:41:24 +0000 (GMT) Date: Sat, 29 Feb 2020 08:41:24 +0000 From: "Richard W.M. Jones" To: "francois.pottier@inria.fr" , caml users Message-ID: <20200229084124.GC11122@rich.annexia.org> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Subject: Re: [Caml-list] (dune/opam) Proper way of vendoring a library inside an application? Reply-To: "Richard W.M. Jones" X-Loop: caml-list@inria.fr X-Sequence: 18027 Errors-to: caml-list-owner@inria.fr Precedence: list Precedence: bulk Sender: caml-list-request@inria.fr X-no-archive: yes List-Id: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Fri, Jan 31, 2020 at 09:48:48AM +0100, François Pottier wrote: > > Dear fellow OCaml users, > > I am trying to figure out how to "vendor" (embark) a private > copy of a library inside a project. (Concretely, I would like > to vendor Fix inside Menhir.) I want this fact to remain > invisible, that is, installing Menhir should not result > in installing or upgrading the user's public copy of Fix. > > I have copied the source tree for Fix inside the source tree > for Menhir, and added a (vendored_dirs fix) stanza in Menhir's > toplevel "dune" file. > > Compilation works fine, but installation does not seem to work > the way I wish: > > * "dune install" installs Menhir *and Fix*, though I would like > it to install Menhir only. > > * Attempting to pin Menhir using "opam pin" fails because opam > cannot find Fix (inded, Fix is not globally installed). > > I have tried removing (public_name fix) from fix/src/dune, but > then the compilation of Menhir fails (Fix cannot be found). > > I am confused... what's the proper way of embarking a private > library inside an application without installing it globally? I wish you wouldn't do this. Bundling libraries like this causes problems for packagers because we can never be sure what (possibly out of date or insecure) version of a library that we package elsewhere has been bundled in another place. As is this is already in opam, what are you trying to achieve here? Rich.