MCPcopy Create free account
hub / github.com/FastLED/FastLED / _get_platform_info

Function _get_platform_info

ci/wasm_tools.py:46–67  ·  view source on GitHub ↗

Detect platform and architecture without importing clang_tool_chain.

()

Source from the content-addressed store, hash-verified

44
45
46def _get_platform_info() -> tuple[str, str]:
47 """Detect platform and architecture without importing clang_tool_chain."""
48 system = platform.system().lower()
49 machine = platform.machine().lower()
50
51 if system == "windows":
52 platform_name = "win"
53 elif system == "linux":
54 platform_name = "linux"
55 elif system == "darwin":
56 platform_name = "darwin"
57 else:
58 raise RuntimeError(f"Unsupported platform: {system}")
59
60 if machine in ("x86_64", "amd64"):
61 arch = "x86_64"
62 elif machine in ("arm64", "aarch64"):
63 arch = "arm64"
64 else:
65 raise RuntimeError(f"Unsupported architecture: {machine}")
66
67 return platform_name, arch
68
69
70def setup_emscripten_env() -> bool:

Callers 1

setup_emscripten_envFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected