From 501ed1ab1319905a2f362628632aec0b2d3edf88 Mon Sep 17 00:00:00 2001 From: Brian Smith Date: Mon, 29 Aug 2022 18:22:25 -0500 Subject: [PATCH] No Issue - Fix building on MacOS Big Sur. The python binary copied reports a valid signature on Big Sur and thus codesign fails. Add the -f option so it overwrites the supposedly valid signature. Other versions are either already unsigned or the install_name_tool invalidates the signature. --- python/virtualenv/virtualenv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/virtualenv/virtualenv.py b/python/virtualenv/virtualenv.py index d22207e257..60a42e4dcb 100644 --- a/python/virtualenv/virtualenv.py +++ b/python/virtualenv/virtualenv.py @@ -1346,7 +1346,7 @@ def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear, sy raise # Resign the executable, since install_name_tool invalidates the signature - call_subprocess(["codesign", "-s", "-", py_executable]) + call_subprocess(["codesign", "-fs", "-", py_executable]) if not is_win: # Ensure that 'python', 'pythonX' and 'pythonX.Y' all exist