fix: export PATH env to engine destination folder to have additional dlls scoped

This commit is contained in:
Louis 2024-11-07 10:10:05 +07:00
parent 0e653793eb
commit e41bcffcef
No known key found for this signature in database
GPG Key ID: 44FA9F4D33C37DE2

View File

@ -33,6 +33,11 @@ function run(systemInfo?: SystemInformation): Promise<any> {
addEnvPaths(path.join(appResourcePath(), 'shared'))
addEnvPaths(executableOptions.binPath)
addEnvPaths(executableOptions.enginePath)
// Add the cortex.llamacpp path to the PATH and LD_LIBRARY_PATH
// This is required for the cortex engine to run for now since dlls are not moved to the root
addEnvPaths(
path.join(executableOptions.enginePath, 'engines', 'cortex.llamacpp')
)
const dataFolderPath = getJanDataFolderPath()
watchdog = new ProcessWatchdog(