You've already forked KernelSU-Next
mirror of
https://github.com/KernelSU-Next/KernelSU-Next.git
synced 2025-08-27 23:46:34 +00:00
a46d4ecd3e
Because some stock mounts are difficult to remount it back, so we bind mount it to somewhere else before overlayfs mount. And then use move mount to mount it back.
29 lines
1.2 KiB
Rust
29 lines
1.2 KiB
Rust
use const_format::concatcp;
|
|
|
|
pub const ADB_DIR: &str = "/data/adb/";
|
|
pub const WORKING_DIR: &str = concatcp!(ADB_DIR, "ksu/");
|
|
pub const BINARY_DIR: &str = concatcp!(WORKING_DIR, "bin/");
|
|
|
|
pub const KSURC_PATH: &str = concatcp!(WORKING_DIR, ".ksurc");
|
|
pub const STOCK_MNT_ROOT: &str = concatcp!(WORKING_DIR, ".mnt");
|
|
pub const DAEMON_PATH: &str = concatcp!(ADB_DIR, "ksud");
|
|
|
|
#[cfg(target_os = "android")]
|
|
pub const DAEMON_LINK_PATH: &str = concatcp!(BINARY_DIR, "ksud");
|
|
|
|
pub const MODULE_DIR: &str = concatcp!(ADB_DIR, "modules/");
|
|
pub const MODULE_IMG: &str = concatcp!(WORKING_DIR, "modules.img");
|
|
pub const MODULE_UPDATE_IMG: &str = concatcp!(WORKING_DIR, "modules_update.img");
|
|
|
|
pub const MODULE_UPDATE_TMP_IMG: &str = concatcp!(WORKING_DIR, "update_tmp.img");
|
|
|
|
// warning: this directory should not change, or you need to change the code in module_installer.sh!!!
|
|
pub const MODULE_UPDATE_TMP_DIR: &str = concatcp!(ADB_DIR, "modules_update/");
|
|
|
|
pub const DISABLE_FILE_NAME: &str = "disable";
|
|
pub const UPDATE_FILE_NAME: &str = "update";
|
|
pub const REMOVE_FILE_NAME: &str = "remove";
|
|
|
|
pub const VERSION_CODE: &str = include_str!(concat!(env!("OUT_DIR"), "/VERSION_CODE"));
|
|
pub const VERSION_NAME: &str = include_str!(concat!(env!("OUT_DIR"), "/VERSION_NAME"));
|