MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / parseLddMissingLibs

Function parseLddMissingLibs

packages/cli/src/browser/linuxDeps.ts:296–308  ·  view source on GitHub ↗
(lddOutput: string)

Source from the content-addressed store, hash-verified

294 * A line like `libnss3.so => not found` means the loader can't find it.
295 */
296export function parseLddMissingLibs(lddOutput: string): SharedLibProbeResult {
297 const missing: string[] = [];
298 for (const rawLine of lddOutput.split("\n")) {
299 const line = rawLine.trim();
300 // Match the exact unresolved marker `=> not found` — NOT a bare "not found"
301 // substring, which would false-positive on a resolved lib whose path
302 // happens to contain that text (e.g. `libfoo.so => /opt/not found/...`).
303 if (!/=>\s*not found\b/.test(line)) continue;
304 const soname = line.split("=>")[0]?.trim();
305 if (soname) missing.push(soname);
306 }
307 return { ok: missing.length === 0, missing, probeUnavailable: false };
308}
309
310/**
311 * True when an error message is the "Chrome couldn't load its shared libraries"

Callers 2

linuxDeps.test.tsFile · 0.85
probeChromeSharedLibsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected