kernel: fix build

This commit is contained in:
shirkneko
2025-11-27 20:33:01 +08:00
parent f81023246f
commit 45ea8455fc
4 changed files with 12 additions and 13 deletions

View File

@@ -180,6 +180,8 @@ int ksu_handle_execve_sucompat(const char __user **filename_user,
*filename_user = ksud_user_path(); *filename_user = ksud_user_path();
escape_with_root_profile(); escape_with_root_profile();
return 0;
} }
// sucompat: permitted process can execute 'su' to gain root access. // sucompat: permitted process can execute 'su' to gain root access.

View File

@@ -5,7 +5,7 @@ import android.system.Os
import androidx.lifecycle.ViewModelProvider import androidx.lifecycle.ViewModelProvider
import androidx.lifecycle.ViewModelStore import androidx.lifecycle.ViewModelStore
import androidx.lifecycle.ViewModelStoreOwner import androidx.lifecycle.ViewModelStoreOwner
import me.weishu.kernelsu.ui.viewmodel.SuperUserViewModel import com.sukisu.ultra.ui.viewmodel.SuperUserViewModel
import okhttp3.Cache import okhttp3.Cache
import okhttp3.OkHttpClient import okhttp3.OkHttpClient
import java.io.File import java.io.File

View File

@@ -714,7 +714,7 @@ private fun rememberSusfsInfo(
manualHookLabel: String, manualHookLabel: String,
inlineHookLabel: String, inlineHookLabel: String,
): SusfsInfoState { ): SusfsInfoState {
var susfsInfo by remember { mutableStateOf(SusfsInfoState(status = SusfsStatus.Loading)) } val susfsInfo = remember { mutableStateOf(SusfsInfoState(status = SusfsStatus.Loading)) }
LaunchedEffect(manualHookLabel, inlineHookLabel) { LaunchedEffect(manualHookLabel, inlineHookLabel) {
val info = withContext(Dispatchers.IO) { val info = withContext(Dispatchers.IO) {
@@ -730,7 +730,9 @@ private fun rememberSusfsInfo(
}.takeIf { it.isNotBlank() }?.let { "($it)" }.orEmpty() }.takeIf { it.isNotBlank() }?.let { "($it)" }.orEmpty()
SusfsInfoState( SusfsInfoState(
status = SusfsStatus.Supported, status = SusfsStatus.Supported,
detail = listOf(version, hookLabel).filter { it.isNotBlank() }.joinToString(" ") detail = listOf(version, hookLabel)
.filter { it.isNotBlank() }
.joinToString(" ")
) )
} else { } else {
SusfsInfoState( SusfsInfoState(
@@ -742,10 +744,8 @@ private fun rememberSusfsInfo(
SusfsInfoState(status = SusfsStatus.Error) SusfsInfoState(status = SusfsStatus.Error)
} }
} }
if (susfsInfo != info) { susfsInfo.value = info
susfsInfo = info
}
} }
return susfsInfo return susfsInfo.value
} }

View File

@@ -6,7 +6,7 @@ ksp = "2.3.2"
compose-bom = "2025.11.01" compose-bom = "2025.11.01"
lifecycle = "2.10.0" lifecycle = "2.10.0"
navigation = "2.9.6" navigation = "2.9.6"
activity-compose = "1.11.0" activity-compose = "1.12.0"
kotlinx-coroutines = "1.10.2" kotlinx-coroutines = "1.10.2"
coil-compose = "2.7.0" coil-compose = "2.7.0"
compose-destination = "2.3.0" compose-destination = "2.3.0"
@@ -58,7 +58,6 @@ com-github-topjohnwu-libsu-io = { group = "com.github.topjohnwu.libsu", name = "
dev-rikka-rikkax-parcelablelist = { module = "dev.rikka.rikkax.parcelablelist:parcelablelist", version.ref = "parcelablelist" } dev-rikka-rikkax-parcelablelist = { module = "dev.rikka.rikkax.parcelablelist:parcelablelist", version.ref = "parcelablelist" }
gson = { module = "com.google.code.gson:gson", version.ref = "gson" }
io-coil-kt-coil-compose = { group = "io.coil-kt", name = "coil-compose", version.ref = "coil-compose" } io-coil-kt-coil-compose = { group = "io.coil-kt", name = "coil-compose", version.ref = "coil-compose" }
kotlinx-coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "kotlinx-coroutines" } kotlinx-coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "kotlinx-coroutines" }
@@ -76,7 +75,5 @@ miuix = { module = "top.yukonga.miuix.kmp:miuix-android", version.ref = "miuix"
haze = { module = "dev.chrisbanes.haze:haze-android", version.ref = "haze" } haze = { module = "dev.chrisbanes.haze:haze-android", version.ref = "haze" }
capsule = { module = "io.github.kyant0:capsule", version.ref = "capsule" } capsule = { module = "io.github.kyant0:capsule", version.ref = "capsule" }
gson = { module = "com.google.code.gson:gson", version.ref = "gson" }
twain = { module = "com.colintheshots:twain", version.ref = "twain" } androidx-documentfile = { group = "androidx.documentfile", name = "documentfile", version.ref = "documentfile" }
androidx-documentfile = { group = "androidx.documentfile", name = "documentfile", version.ref = "documentfile" }