mirror of
https://github.com/okhsunrog/vpnhide.git
synced 2026-04-28 22:52:15 +00:00
refactor: overhaul kmod build system, fix kernel module bugs
Build system: - Replace hardcoded paths in Makefile with env vars (KERNEL_SRC, CLANG_DIR) - Add .env.example and .envrc for direnv-based config - Simplify build-zip.sh to delegate to make instead of duplicating build command - Rewrite BUILDING.md: 5-step happy path with direnv, standalone prep as appendix - Remove redundant quick-reference script and step 7 (manual module.lds hack) Kernel module (vpnhide_kmod.c): - Fix fib_route_seq_show hook: save seq_file pointer and buffer position in entry handler instead of reading regs->regs[0] in return handler (which holds the return value on arm64, not the original argument). Rewrite buffer scanning as clean forward iteration with memmove compaction. - Remove dead SIOCGIFCONF case from dev_ioctl hook (confirmed in kernel source: SIOCGIFCONF goes through sock_ioctl -> dev_ifconf, not dev_ioctl on GKI 6.1) - Fix header comment: remove false tcp4_seq_show claim, correct rtnl symbol name Test app: - Auto-run checks on launch (LaunchedEffect) for easier adb-driven testing
This commit is contained in:
parent
60b3235dc0
commit
e35cf1a6b9
8 changed files with 277 additions and 305 deletions
8
kmod/.env.example
Normal file
8
kmod/.env.example
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
# Copy to .env and adjust paths for your setup.
|
||||
# direnv loads these automatically (see .envrc).
|
||||
|
||||
# Kernel source / prepared headers directory
|
||||
KERNEL_SRC=~/pixel-kernel-headers
|
||||
|
||||
# Clang toolchain bin directory (must contain clang, ld.lld, llvm-ar, etc.)
|
||||
CLANG_DIR=~/pixel-kernel/prebuilts/clang/host/linux-x86/clang-r487747c/bin
|
||||
Loading…
Add table
Add a link
Reference in a new issue