diff options
| author | ruki <[email protected]> | 2023-04-14 00:38:45 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2023-04-14 00:38:45 +0800 |
| commit | 9385a3b2784284512d7799493a1ebf154edfeeae (patch) | |
| tree | e78a5b1e8d29c82d68080a4b30d827012206d444 | |
| parent | 9b7b385d97e7e6a7750a6d3c1f54a434b635cc9e (diff) | |
update changelog and add some comments for #3628
| -rw-r--r-- | CHANGELOG.md | 2 | ||||
| -rwxr-xr-x | core/src/demo/xmake.sh | 10 |
2 files changed, 12 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index b88360600..c65468c4e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ * [#3596](https://github.com/xmake-io/xmake/issues/3596): Fix check_cxxfuncs and check_cxxsnippets * [#3603](https://github.com/xmake-io/xmake/issues/3603): Fix `xmake update` * [#3614](https://github.com/xmake-io/xmake/issues/3614): Fix qt envirnoment when running target +* [#3628](https://github.com/xmake-io/xmake/issues/3628): Fix msys2/mingw setenv and os.exec issue * Fix setenv for msys/mingw ## v2.7.8 @@ -1576,6 +1577,7 @@ * [#3596](https://github.com/xmake-io/xmake/issues/3596): 修复 check_cxxfuncs 和 check_cxxsnippets * [#3603](https://github.com/xmake-io/xmake/issues/3603): 修复 xmake update 的无效 url * [#3614](https://github.com/xmake-io/xmake/issues/3614): 修复 xmake run 对 Qt 环境的加载 +* [#3628](https://github.com/xmake-io/xmake/issues/3628): 修复 msys2/mingw 下 os.exec 总是优先查找错误的可执行程序 * 修复 msys/mingw 下环境变量设置问题 ## v2.7.8 diff --git a/core/src/demo/xmake.sh b/core/src/demo/xmake.sh index 1c0bca6bf..9233f1c30 100755 --- a/core/src/demo/xmake.sh +++ b/core/src/demo/xmake.sh @@ -28,6 +28,16 @@ target "demo" add_installfiles "${projectdir}/(xmake/templates/**)" "share" add_installfiles "${projectdir}/scripts/xrepo.sh" "bin" "xrepo" + # fix os.exec() call incorrect program from /mingw64/bin. e.g. python, .. + # + # because xmake is installed to /mingw64/bin/xmake, + # os.exec/CreateProcess always gives the highest priority to finding the process from /mingw64/bin (if it exists), + # rather than from the $PATH environment variable. + # + # we install the xmake executable into a separate directory to ensure + # that os.exec() does not look for additional executables. + # + # @see https://github.com/xmake-io/xmake/issues/3628 if is_host "msys"; then add_installfiles "${projectdir}/scripts/msys/xmake.sh" "bin" "xmake" add_installfiles "${buildir}/xmake.exe" "share/xmake" |
