From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from walk.intel-email.com (walk.intel-email.com [101.227.64.242]) by mx.groups.io with SMTP id smtpd.web11.97652.1683509430234533959 for ; Sun, 07 May 2023 18:30:31 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@byosoft.com.cn header.s=cloud-union header.b=SWedGFje; spf=pass (domain: byosoft.com.cn, ip: 101.227.64.242, mailfrom: gaoliming@byosoft.com.cn) Received: from walk.intel-email.com (localhost [127.0.0.1]) by walk.intel-email.com (Postfix) with ESMTP id DB467CD1F725 for ; Mon, 8 May 2023 09:30:25 +0800 (CST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=byosoft.com.cn; s=cloud-union; t=1683509426; bh=IMAHf6UmKPiFTJCBSgzeSQHys2aYVbFgAsz2b/Pe5tw=; h=From:To:References:In-Reply-To:Subject:Date; b=SWedGFje6rj+MGzeEXfTEdD6HcvQpTSKJlY897rb4CngQs3k8JUakYNW3iG+DcBc6 /GB5w8fh9wQU5TVWxr8vkNT/7VRuCGxlUSn1HWp5mJOkjmQVBuIe5uU9mjoZe2+6Z0 ucnMMy7p58Re9qHbZghaazkIYa/TC+yOGtxBfiHo= Received: from localhost (localhost [127.0.0.1]) by walk.intel-email.com (Postfix) with ESMTP id D735CCD1F76F for ; Mon, 8 May 2023 09:30:25 +0800 (CST) Received: from walk.intel-email.com (localhost [127.0.0.1]) by walk.intel-email.com (Postfix) with ESMTP id AEAC0CD1F76C for ; Mon, 8 May 2023 09:30:25 +0800 (CST) Authentication-Results: walk.intel-email.com; none Received: from mail.byosoft.com.cn (mail.byosoft.com.cn [58.240.74.242]) by walk.intel-email.com (Postfix) with SMTP id 59D6FCD1F725 for ; Mon, 8 May 2023 09:30:23 +0800 (CST) Received: from DESKTOPS6D0PVI ([58.246.60.130]) (envelope-sender ) by 192.168.6.13 with ESMTP for ; Mon, 08 May 2023 09:30:15 +0800 X-WM-Sender: gaoliming@byosoft.com.cn X-Originating-IP: 58.246.60.130 X-WM-AuthFlag: YES X-WM-AuthUser: gaoliming@byosoft.com.cn From: "gaoliming" To: "'Rebecca Cran'" , , "'Andrew Fish'" , "'Leif Lindholm'" , "'Michael D Kinney'" , "'Bob Feng'" , "'Yuwei Chen'" References: <20230506193052.1835-1-rebecca@bsdio.com> In-Reply-To: <20230506193052.1835-1-rebecca@bsdio.com> Subject: =?UTF-8?B?5Zue5aSNOiBbUEFUQ0ggdjMgMC80XSBlZGtzZXR1cC5iYXQsIEJhc2VUb29sczogSW1wcm92ZSBXaW5kb3dzIGVudmlyb25tZW50IHNldHVwIGFuZCBCYXNlVG9vbHMgQyBjb21waWxhdGlvbg==?= Date: Mon, 8 May 2023 09:30:16 +0800 Message-ID: <008101d9814c$a5018c60$ef04a520$@byosoft.com.cn> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQD7cLOaIOMgWkBLS6jqWguJC/jZBbELt2AQ Sender: "gaoliming" Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable Content-Language: zh-cn Rebecca: This change is good to me. Reviewed-by: Liming Gao = =20 But, I see edksetup.sh also has python2 check. I think the same clean = up can be done in edksetup.sh. Thanks Liming > -----=D3=CA=BC=FE=D4=AD=BC=FE----- > =B7=A2=BC=FE=C8=CB: Rebecca Cran > =B7=A2=CB=CD=CA=B1=BC=E4: 2023=C4=EA5=D4=C27=C8=D5 3:31 > =CA=D5=BC=FE=C8=CB: devel@edk2.groups.io; Andrew Fish = ; Leif > Lindholm ; Michael D Kinney > ; Liming Gao ; > Bob Feng ; Yuwei Chen > =B3=AD=CB=CD: Rebecca Cran > =D6=F7=CC=E2: [PATCH v3 0/4] edksetup.bat, BaseTools: Improve Windows > environment setup and BaseTools C compilation >=20 > There are remnants of Python 2 support in BaseTools/toolsetup.bat that it's > probably time to remove since we only support Python 3.6 and newer = these > days. > So, remove the variables that enable Python3 support and simplify the batch > script. I've also seen errors where after running edksetup.bat the = build > command isn't available because PYTHONPATH wasn't being set, so fix = that > when the Pip BaseTools are being used. >=20 > At the same time, let's add a check that we meet the minimum version > requirement so we don't end up failing with an obscure error. >=20 > Building BaseTools causes a warning about threading.currentThread = being > deprecated, so update code in NmakeSubdirs.py to switch to > threading.current_thread. >=20 > There needs to be further work, because if PYTHON_COMMAND isn't > specified then > it defaults to "py -3", where py is C:\Windows\py.exe, which doesn't = work if > you're using a virtualenv since it installs python.exe and pythonw.exe = in > venv\Scripts. toolsetup.bat therefore fails to detect the Pip = BaseTools and > uses the in-source Basetools. >=20 > GitHub PR: https://github.com/tianocore/edk2/pull/4302 > GitHub branch: https://github.com/bcran/edk2/tree/py3 >=20 > Changes between v1 and v2 > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= >=20 > - Require Python 3.6 or newer: 3.6 was when PEP 526 was added, which = we > use. > - Fix Tests/RunTests.py on Windows. >=20 > Rebecca Cran (4): > BaseTools: Remove Python2/Python3 detection from toolset.bat > BaseTools: use threading.current_thread in NmakeSubdirs.py > edksetup.bat: if toolsetup.bat fails, just exit > BaseTools: Update toolsetup.bat and Tests/PythonTest.py to check ver >=20 > BaseTools/Source/C/Makefiles/NmakeSubdirs.py | 2 +- > BaseTools/Tests/PythonTest.py | 22 +++- > BaseTools/toolsetup.bat | 119 > ++++++++------------ > edksetup.bat | 1 + > 4 files changed, 69 insertions(+), 75 deletions(-) >=20 > -- > 2.40.0.windows.1