feat(dx/desktop): support raw NixOS via LD_LIBRARY_PATH injection

This commit is contained in:
Elian Doran
2025-09-02 12:18:22 +03:00
parent 7fdea613ff
commit bd349f5abc
2 changed files with 18 additions and 2 deletions

View File

@@ -32,6 +32,17 @@ function rebuildNativeDependencies() {
buildPath: desktopProjectRoot,
electronVersion
});
if (isNixOS()) {
console.log("Patching ELF...");
return execSync(`nix-shell -p auto-patchelf gcc.cc.lib --run "auto-patchelf --paths node_modules/better-sqlite3/build/Release/better_sqlite3.node --libs ${libStdPath}"`, {
cwd: desktopProjectRoot,
stdio: "inherit"
});
}
}
function determineElectronVersion() {