Mark cached_git_executable global
diff --git a/emsdk.py b/emsdk.py index 9ed3a88..90b4c55 100644 --- a/emsdk.py +++ b/emsdk.py
@@ -743,6 +743,7 @@ # If true, the search is required to succeed, and the execution # will terminate with sys.exit(1) if not found. def GIT(must_succeed=True): + global cached_git_executable if cached_git_executable is not None: return cached_git_executable # The order in the following is important, and specifies the preferred order