updated the build script to patch for new freebsd kernels

This commit is contained in:
bwn-a1370
2026-09-01 14:43:10 +03:00
parent a8418431bb
commit 60a93e1f96
2 changed files with 39 additions and 9 deletions
+10 -2
View File
@@ -36,8 +36,10 @@ interface) is never disrupted.
(`patches/patch-*.c` and `patches/patch-Makefile`). Safe to re-run.
- `build.sh` — builds `if_bwn.ko` (`sys/modules/bwn`), `bhndb_pci.ko`
(`sys/modules/bhnd/bhndb_pci`), and `bwn_v4_n.ko` (from `src/firmware/`);
installs them to `/boot/modules` and `/boot/kernel`; and appends
`bwn_v4_n_load="YES"` to `/boot/loader.conf` if missing (Fix 5).
installs them to `/boot/modules` and `/boot/kernel`; appends
`bwn_v4_n_load="YES"` to `/boot/loader.conf` if missing (Fix 5); and
regenerates `/boot/kernel/linker.hints` and `/boot/modules/linker.hints`
with `kldxref` so the loader finds the new modules (no manual step).
### Manual build (equivalent to build.sh)
@@ -58,6 +60,12 @@ install -m 444 src/firmware/bwn_v4_n.ko /boot/modules/
# 4. loader.conf (Fix 5)
echo 'bwn_v4_n_load="YES"' >> /boot/loader.conf
# 5. Regenerate linker.hints so the loader indexes the new modules
# (else /boot/kernel/linker.hints stays empty -> 'linker.hints file
# truncated' warnings and modules fail to auto-load at boot).
kldxref /boot/kernel
kldxref /boot/modules
```
## Directory layout