How to build your own OpenWrt maintaining kernel compatibility with official 19.07.3 packages

Built my own 19.07.3. Vanilla but with new regdb and one extra package. Now the official 19.07.3 kernel packages complain that kernel is not exactly the same.
(Version is the same, hashcode part is not)

Is there a way to fix that?

Thanks.

No, if you build your own kernel it becomes incompatible with the release package feeds. In most cases you can still force a update/install and it will work, if the actual kernel version is the same.

You have to use the released SDK's for your target version and not build from the latest master/19.07.x git branches, this way you end-up with compatible kernel hashes.

If you only want small modifications to packages or add a patch, you can try my package builder, which uses the SDK's.

2 Likes

You also have to select he same (all) kernel modules as the release builds. This is mostly archived by selecting CONFIG_ALL_KMODS in make menuconfig.

The easiest solution is to use the config.buildinfo file of the release build as base for your .config.
For example on ath79:

cd path/to/openwrt
wget -O .config https://downloads.openwrt.org/releases/19.07.3/targets/ath79/generic/config.buildinfo
make defconfig
make menuconfig
1 Like

Before that, you must also ensure that all potential kmods from external feeds are installed as well (./scripts/feeds update; ./scripts/feeds install -a)

1 Like

Thanks everyone. Managed to use SDK to rebuild a few packages.