From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=209.132.183.28; helo=mx1.redhat.com; envelope-from=lersek@redhat.com; receiver=edk2-devel@lists.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id CA3A321B02822 for ; Tue, 8 Jan 2019 09:23:05 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 40D57C057E18; Tue, 8 Jan 2019 17:23:05 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-197.rdu2.redhat.com [10.10.120.197]) by smtp.corp.redhat.com (Postfix) with ESMTP id 66E615C3FA; Tue, 8 Jan 2019 17:23:03 +0000 (UTC) To: "Gao, Liming" , "Ni, Ray" , "edk2-devel@lists.01.org" , "leif.lindholm@linaro.org" , "afish@apple.com" , "Kinney, Michael D" References: <4A89E2EF3DFEDB4C8BFDE51014F606A14E39130F@SHSMSX104.ccr.corp.intel.com> <2b49bd5c-968e-d7b0-e975-9d3da2101bc3@Intel.com> <4A89E2EF3DFEDB4C8BFDE51014F606A14E3AD26C@SHSMSX152.ccr.corp.intel.com> <5e943b6c-6df2-fe06-198e-5ff5ab43c9a0@redhat.com> <4A89E2EF3DFEDB4C8BFDE51014F606A14E3ADC62@SHSMSX152.ccr.corp.intel.com> From: Laszlo Ersek Message-ID: <71e550b6-2541-3b7f-5ff7-b66514f2c140@redhat.com> Date: Tue, 8 Jan 2019 18:22:57 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <4A89E2EF3DFEDB4C8BFDE51014F606A14E3ADC62@SHSMSX152.ccr.corp.intel.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Tue, 08 Jan 2019 17:23:05 +0000 (UTC) Subject: Re: [RFC] Edk2 BaseTools Python3 Migration Update X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Jan 2019 17:23:06 -0000 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 01/08/19 15:22, Gao, Liming wrote: > Laszlo: > Yes. This can be supported. But, I don't know what purpose to > specify python minor version of Python3. Current implementation in > Python3 branch always tries to find the high version installed in > OS. For example, Python3.4, Python3.7 are both installed, Python3.7 > will be chosen. Does this policy meet with your usage? Not really; please see paragraph (c) in my other reply at . The rationale is given in the blog post at , near the "platform-python" mentions. Basically the OS should be able to offer different Python3 installations (at the same time) to end-users and internally to OS-level packages. Thanks! Laszlo >> -----Original Message----- >> From: Laszlo Ersek [mailto:lersek@redhat.com] >> Sent: Tuesday, January 8, 2019 3:04 AM >> To: Gao, Liming ; Ni, Ray ; >> edk2-devel@lists.01.org; leif.lindholm@linaro.org; afish@apple.com; >> Kinney, Michael D >> Subject: Re: [edk2] [RFC] Edk2 BaseTools Python3 Migration Update >> >> On 01/07/19 14:41, Gao, Liming wrote: >>> Ray: >>> I think this proposal is good to recommend Python3 as the default >>> interpreter. I summary the updated proposal. >>> >>> 1. PYTHON3_ENABLE env is not set. edksetup.bat/edksetup.sh will find >>> higher version python installed in OS. If Python3 is found, Python3 >>> will be used. Then, if python2 is found, and python2 is used. If not >>> found, report error and stop build. This will change the default >>> python interpreter from Python2 to Python3 when they both are >>> installed. >>> 2. PYTHON3_EANBLE env is set to TRUE. edksetup.bat/edksetup.sh will >>> find Python3. If Python3 is found, Python3 will be used. If not >>> found, report error and stop build. >>> 3. PYTHON3_ENABLE env is set to not TRUE. edksetup.bat/edksetup.sh >>> will find Python2. If Python2 is found, Python2 will be used. If not >>> found, report error and stop build. Once Python is found, >>> edksetup.bat/edksetup.sh and build tool will both print message to >>> let user aware which version python tool is used in this build. >> >> If we're going for this level of flexibility, I'd like to suggest / >> request another improvement. Some Linux distros intend to accommodate >> multiple Python3 versions at the same time (this is not a typo; I >> don't mean Python2+Python3, but multiple Python3 versions). So >> basically I'd suggest that we offer a method for specifying a python >> version (2/3/auto-detect), plus, in case a specific major version is >> specified, that we allow the user to specify the precise interpreter >> pathname too. >> >> Thanks, >> Laszlo