-
-
Notifications
You must be signed in to change notification settings - Fork 814
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix windows wasm compilation with packages #5534
Conversation
cmake.lua error: couldn't find CMAKE_MAKE_PROGRAM |
xmake/core/platform/platform.lua
Outdated
@@ -151,7 +151,7 @@ end | |||
-- get the toolchains | |||
function _instance:toolchains(opt) | |||
local toolchains = self:_memcache():get("toolchains") | |||
if not toolchains then | |||
if not toolchains or #toolchains == 0 then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I selected wasm as the platform, the toolchains list was empty but not nil, which did not allow me to install headeronly packages, but with this change, it allowed the code to find the toolchain for wasm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it should not be empty.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't reproduce this. You can print debug.traceback() when its empty.
or revert it and open an issue first. I will merge other patches.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I got these errors before adding the line:
checking for em++.bat ... C:\Users\admin\AppData\Local\.xmake\packages\e\emscripten\3.1.55\e632956fdb43439b94196f0dfdac70b7\upstream\emscripten\em++.bat
checking for the linker (ld) ... em++.bat
error: @programdir\core\package\package.lua:2364: cannot get program for ld
stack traceback:
[C]: in function 'error'
[@programdir\core\base\os.lua:973]:
[@programdir\core\package\package.lua:2364]: in function '_generate_build_configs'
[@programdir\core\package\package.lua:2589]: in function 'check_cxxsnippets'
[....xmake\repositories\xmake-repo\packages\a\asap\xmake.lua:15]: in function 'script'
[...dir\modules\private\action\require\impl\utils\filter.lua:114]: in function 'call'
[...dir\modules\private\action\require\impl\actions\test.lua:41]:
[...\modules\private\action\require\impl\actions\install.lua:432]:
=> install asap-fork 2023.04.21 .. failed
error: @programdir\core\main.lua:329: @programdir\modules\async\runjobs.lua:325: ...\modules\private\action\require\impl\actions\install.lua:494: install failed!
stack traceback:
[C]: in function 'error'
[@programdir\core\base\os.lua:973]:
[...\modules\private\action\require\impl\actions\install.lua:494]: in function 'catch'
[@programdir\core\sandbox\modules\try.lua:123]: in function 'try'
[...\modules\private\action\require\impl\actions\install.lua:361]:
[...modules\private\action\require\impl\install_packages.lua:496]: in function 'jobfunc'
[@programdir\modules\async\runjobs.lua:241]:
stack traceback:
[C]: in function 'error'
@programdir\core\base\os.lua:973: in function 'os.raiselevel'
(...tail calls...)
@programdir\core\main.lua:329: in upvalue 'cotask'
@programdir\core\base\scheduler.lua:406: in function <@programdir\core\base\scheduler.lua:399>
error: ...amdir\core\sandbox\modules\import\core\tool\compiler.lua:37: cannot get program for cc
stack traceback:
[C]: in function 'error'
[@programdir\core\base\os.lua:973]:
[...amdir\core\sandbox\modules\import\core\tool\compiler.lua:37]: in function 'load'
[...amdir\core\sandbox\modules\import\core\tool\compiler.lua:316]:
[@programdir\modules\package\tools\cmake.lua:886]: in function '_get_envs_for_runtime_flags'
[@programdir\modules\package\tools\cmake.lua:928]: in function '_get_configs'
[@programdir\modules\package\tools\cmake.lua:1234]: in function 'install'
[...\.xmake\repositories\xmake-repo\packages\f\fmt\xmake.lua:70]: in function 'script'
[...dir\modules\private\action\require\impl\utils\filter.lua:114]: in function 'call'
[...\modules\private\action\require\impl\actions\install.lua:392]:
=> install fmt 11.0.2 .. failed
error: @programdir\core\main.lua:329: @programdir\modules\async\runjobs.lua:325: ...\modules\private\action\require\impl\actions\install.lua:494: install failed!
stack traceback:
[C]: in function 'error'
[@programdir\core\base\os.lua:973]:
[...\modules\private\action\require\impl\actions\install.lua:494]: in function 'catch'
[@programdir\core\sandbox\modules\try.lua:123]: in function 'try'
[...\modules\private\action\require\impl\actions\install.lua:361]:
[...modules\private\action\require\impl\install_packages.lua:496]: in function 'jobfunc'
[@programdir\modules\async\runjobs.lua:241]:
stack traceback:
[C]: in function 'error'
@programdir\core\base\os.lua:973: in function 'base/os.raiselevel'
(...tail calls...)
@programdir\core\main.lua:329: in upvalue 'cotask'
@programdir\core\base\scheduler.lua:406: in function <@programdir\core\base\scheduler.lua:399>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can open an issue.
No description provided.