fix: test bundle ovr lib

This commit is contained in:
rs189
2025-07-21 16:26:26 +09:00
committed by Natsumi
parent e2b1948159
commit b25e264171
3 changed files with 14 additions and 3 deletions
+9 -3
View File
@@ -92,14 +92,16 @@
"src-electron/*", "src-electron/*",
"VRCX.png", "VRCX.png",
"images/tray.png", "images/tray.png",
"Version" "Version",
"src-electron/libs/linux/libopenvr_api.so"
], ],
"asarUnpack": [ "asarUnpack": [
"node_modules/node-api-dotnet/**/*", "node_modules/node-api-dotnet/**/*",
"node_modules/node-api-dotnet/net9.0/**/*", "node_modules/node-api-dotnet/net9.0/**/*",
"build/Electron/*", "build/Electron/*",
"build/Electron/**", "build/Electron/**",
"build/Electron/dotnet-runtime/**/*" "build/Electron/dotnet-runtime/**/*",
"src-electron/libs/linux/libopenvr_api.so"
], ],
"extraResources": [ "extraResources": [
{ {
@@ -121,6 +123,10 @@
{ {
"from": "build/Electron/dotnet-runtime/", "from": "build/Electron/dotnet-runtime/",
"to": "dotnet-runtime/" "to": "dotnet-runtime/"
},
{
"from": "src-electron/libs/linux/libopenvr_api.so",
"to": "bin/libopenvr_api.so"
} }
], ],
"directories": { "directories": {
@@ -161,4 +167,4 @@
"hazardous": "^0.3.0", "hazardous": "^0.3.0",
"node-api-dotnet": "^0.9.12" "node-api-dotnet": "^0.9.12"
} }
} }
Binary file not shown.
+5
View File
@@ -26,6 +26,11 @@ if (process.platform === 'linux') {
process.env.DOTNET_ROOT = bundledDotNetPath; process.env.DOTNET_ROOT = bundledDotNetPath;
process.env.PATH = `${bundledDotNetPath}:${process.env.PATH}`; process.env.PATH = `${bundledDotNetPath}:${process.env.PATH}`;
} }
const openvrLibPath = path.join(process.resourcesPath, '..', 'bin');
if (fs.existsSync(openvrLibPath)) {
process.env.LD_LIBRARY_PATH = `${openvrLibPath}:${process.env.LD_LIBRARY_PATH || ''}`;
}
} else if (process.platform === 'darwin') { } else if (process.platform === 'darwin') {
const dotnetPath = path.join('/usr/local/share/dotnet'); const dotnetPath = path.join('/usr/local/share/dotnet');
const dotnetPathArm = path.join('/usr/local/share/dotnet/x64'); const dotnetPathArm = path.join('/usr/local/share/dotnet/x64');