...
This commit is contained in:
+23
-1
@@ -49,6 +49,28 @@ import ui.SettingsScreen
|
||||
// 화면 상태 정의
|
||||
enum class AppScreen { Settings, Dashboard }
|
||||
|
||||
|
||||
fun getLlamaBinPath(): String {
|
||||
val os = System.getProperty("os.name").lowercase()
|
||||
val arch = System.getProperty("os.arch").lowercase()
|
||||
val basePath = "./src/main/resources/bin"
|
||||
|
||||
return when {
|
||||
// Apple Silicon (M1/M2/M3)
|
||||
os.contains("mac") && (arch.contains("aarch64") || arch.contains("arm64")) -> {
|
||||
"$basePath/mac-arm64/llama-server"
|
||||
}
|
||||
// Intel Mac (2017)
|
||||
os.contains("mac") -> {
|
||||
"$basePath/mac-x64/llama-server"
|
||||
}
|
||||
// Windows NUC
|
||||
os.contains("win") -> {
|
||||
"$basePath/win-x64/llama-server.exe"
|
||||
}
|
||||
else -> "$basePath/llama-server"
|
||||
}
|
||||
}
|
||||
fun main() = application {
|
||||
SystemSleepPreventer.start()
|
||||
|
||||
@@ -69,7 +91,7 @@ fun main() = application {
|
||||
})
|
||||
}
|
||||
// 앱 실행 시 필요한 바이너리 경로 (실행 파일 위치)
|
||||
val binPath = "./src/main/resources/bin/llama-server"
|
||||
val binPath = getLlamaBinPath()
|
||||
val windowState = rememberWindowState(
|
||||
placement = WindowPlacement.Maximized
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user