# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/thunderbird/hotfix-PATH.patch # Copyright (C) 2026 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- --- a/build/moz.configure/toolchain.configure 2026-09-01 14:38:48.553859259 +0200 +++ b/build/moz.configure/toolchain.configure 2026-09-01 14:38:48.554603823 +0200 @@ -836,6 +836,14 @@ def altered_path( get_virtualenv_base_dir(build_env.topsrcdir) ) + # The normalized form is only a comparison key: emitting entries with a + # trailing slash breaks tools matching PATH entries verbatim, e.g. compiler + # wrappers removing their own directory before exec'ing the real compiler. + def denormalize(path): + if len(path) > 1 and path.endswith("/") and not path.endswith(":/"): + return path[:-1] + return path + seen = set() altered_path = [] for p in mozillabuild_bin_paths + path: @@ -845,7 +853,7 @@ def altered_path( if normalized.startswith(venv_prefix): continue seen.add(normalized) - altered_path.append(normalized) + altered_path.append(denormalize(normalized)) return os.pathsep.join(altered_path)