pcbjam/wasm/stubs/python_manager_stub.cpp
Viktor Vaczi 9c271996c2 Fix KiCad WASM build and runtime errors
Build improvements:
- Change -O0 to -O1 to fix "local count too large" asyncify error
- Add wasm-emscripten-finalize to host (Docker OOMs on large WASM)
- Use -gseparate-dwarf for smaller main binary with debug info
- Build native protoc for code generation
- Add more functions to asyncify removelist

Runtime fixes:
- Add inject-dyncall-shims.sh to fix "dynCall_* is not defined" in Emscripten 4.x
- Update wxwidgets with browserInfo.name fix

New stubs and bindings:
- Add Embind bindings for JavaScript interop
- Add stubs for scripting, API plugin, PCB frame, navlib

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 16:30:53 +01:00

43 lines
1 KiB
C++

/*
* Python Manager stubs for KiCad WASM build
* Python scripting is not available in WASM
*/
#include <python_manager.h>
// Implementation
PYTHON_MANAGER::PYTHON_MANAGER( const wxString& aInterpreterPath ) :
m_interpreterPath( aInterpreterPath )
{
}
long PYTHON_MANAGER::Execute( const std::vector<wxString>& aArgs,
const std::function<void(int, const wxString&, const wxString&)>& aCallback,
const wxExecuteEnv* aEnv,
bool aSaveOutput )
{
(void)aArgs;
(void)aCallback;
(void)aEnv;
(void)aSaveOutput;
// Return 0: no process created (Python not available in WASM)
return 0;
}
wxString PYTHON_MANAGER::FindPythonInterpreter()
{
return wxEmptyString;
}
std::optional<wxString> PYTHON_MANAGER::GetPythonEnvironment( const wxString& aNamespace )
{
(void)aNamespace;
return std::nullopt;
}
std::optional<wxString> PYTHON_MANAGER::GetVirtualPython( const wxString& aNamespace )
{
(void)aNamespace;
return std::nullopt;
}