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 2A0A67FACD for ; Fri, 19 Sep 2014 00:29:01 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of gregoire.henry@ocamlpro.com) identity=pra; client-ip=194.254.61.138; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gregoire.henry@ocamlpro.com"; x-sender="gregoire.henry@ocamlpro.com"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of gregoire.henry@ocamlpro.com) identity=mailfrom; client-ip=194.254.61.138; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gregoire.henry@ocamlpro.com"; x-sender="gregoire.henry@ocamlpro.com"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@korolev.univ-paris7.fr) identity=helo; client-ip=194.254.61.138; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="gregoire.henry@ocamlpro.com"; x-sender="postmaster@korolev.univ-paris7.fr"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: At0BAMNbG1TC/j2KnGdsb2JhbABg1U8BgQwWAREBAQEBAQgLCQkUKoQEAQEDATIBRgULCyElDy0bBohJDMJQGI93B4MugR0FklGKOgGZKIM0AQEB X-IPAS-Result: At0BAMNbG1TC/j2KnGdsb2JhbABg1U8BgQwWAREBAQEBAQgLCQkUKoQEAQEDATIBRgULCyElDy0bBohJDMJQGI93B4MugR0FklGKOgGZKIM0AQEB X-IronPort-AV: E=Sophos;i="5.04,550,1406584800"; d="scan'208";a="79980833" Received: from korolev.univ-paris7.fr ([194.254.61.138]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 19 Sep 2014 00:29:00 +0200 Received: from mailhub.math.univ-paris-diderot.fr (mailhub.math.univ-paris-diderot.fr [81.194.30.253]) by korolev.univ-paris7.fr (8.14.4/8.14.4/relay1/46573) with ESMTP id s8IMT0bU026636; Fri, 19 Sep 2014 00:29:00 +0200 Received: from mailhub.math.univ-paris-diderot.fr (localhost [127.0.0.1]) by mailhub.math.univ-paris-diderot.fr (Postfix) with ESMTP id 121E32D5DF9; Fri, 19 Sep 2014 00:29:00 +0200 (CEST) X-Virus-Scanned: amavisd-new at math.univ-paris-diderot.fr Received: from mailhub.math.univ-paris-diderot.fr ([127.0.0.1]) by mailhub.math.univ-paris-diderot.fr (mailhub.math.univ-paris-diderot.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id VkPex_SShLL8; Fri, 19 Sep 2014 00:28:58 +0200 (CEST) Received: from melquiades (81-64-137-19.rev.numericable.fr [81.64.137.19]) (Authenticated sender: henry) by mailhub.math.univ-paris-diderot.fr (Postfix) with ESMTPSA id 9EC6E2D22B1; Fri, 19 Sep 2014 00:28:58 +0200 (CEST) Received: from greg by melquiades with local (Exim 4.84) (envelope-from ) id 1XUkC9-0003Ox-I3; Fri, 19 Sep 2014 00:28:57 +0200 Date: Fri, 19 Sep 2014 00:28:57 +0200 From: =?iso-8859-1?Q?Gr=E9goire?= Henry To: Yotam Barnoy Cc: OCaml Mailing List Message-ID: <20140918222857.GA12277@mlqds.hnr.gr> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.7 (korolev.univ-paris7.fr [194.254.61.138]); Fri, 19 Sep 2014 00:29:00 +0200 (CEST) X-Miltered: at korolev with ID 541B5CAC.000 by Joe's j-chkmail (http : // j-chkmail dot ensmp dot fr)! X-j-chkmail-Enveloppe: 541B5CAC.000 from mailhub.math.univ-paris-diderot.fr/mailhub.math.univ-paris-diderot.fr/null/mailhub.math.univ-paris-diderot.fr/ X-j-chkmail-Score: MSGID : 541B5CAC.000 on korolev.univ-paris7.fr : j-chkmail score : . : R=. U=. O=. B=0.000 -> S=0.000 X-j-chkmail-Status: Ham Subject: Re: [Caml-list] opam local switch Hi, > My question is, if I set OPAMSWITCH, will I then be able to run regular > (non-opam) ocaml build commands in the local shell in the given compiler, > while running commands in a different shell with a different compiler? No, it is not. But, what you are looking for is probably: eval $(opam config env --switch 3.12.1) This will setup the proper environment for ocaml-3.12.1 in the current terminal (including the OPAMSWITCH variable) without changing the "global default switch". The previous command is equivalent to: export OPAMSWITCH=3.12.1 eval $(opam config env) -- Grégoire