winpaths.py
author Edouard Tisserant <edouard.tisserant@gmail.com>
Mon, 13 Feb 2023 22:10:58 +0100
changeset 116 dc462ee1c0f5
child 120 02e37d9e96a9
permissions -rw-r--r--
Windows installer: add winpaths.py to extend %PATH% so that build find msys2 binaries including Make.
import os

PATH = os.environ["PATH"]
instdir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
os.environ["PATH"] = ';'.join([
    os.path.join(instdir, "msys2", "bin"),
    os.path.join(instdir, "msys2", "usr", "bin"),
    os.path.join(instdir, "msys2", "mingw32", "bin"),
    PATH
])