Posted: Sat Jul 03, 2021 11:56 Post subject: Toolchain for the dd-wrt builds? (for kmod compilation)
I am currently using the r47000 build (on my Netgear R7000), and wanted to build some additional kernel modules for it...
...And I can't seem to find where to get the toolchain. Querying /proc/version yields
Code:
Linux version 4.4.273 (root@linux) (gcc version 11.1.0 (OpenWrt GCC 11.1.0 r16592-aabc632023) ) #3542 SMP Mon Jun 28 09:28:51 +07 2021
Now, I checked OpenWrt toolchains, and it seems you can only build it up to gcc 10, but gcc 11.1 is nowhere to be found. Where can I get it?
Thanks, I will try first to build the 10.3 toolchain first... All the other toolchains I used ended up crashing the kernel after insmoding the compiled module.
Can you please hint about what should be tweaked in the toolchain?
It's... Weird... To say the least...
But okay.
Could you please compile compatible macvlan, ipvlan, vxlan, veth kmods for the R7000 on build 47000?
I compiled them but the result was the same - either "unrecognized symbol" or just plain crash/reboot.
Surprisingly enough, I managed to compile some modules on the device itself (with the help of Entware's Gcc 7.4.0). So the version of gcc is definitely of no concern for kmods, and something other was buggying.
Yep definitely building on the device itself works quite well (although kinda slow, but not horribly slow). It required tinkering around with bypassing ccache, but overall it wasn't hard.
Yep definitely building on the device itself works quite well (although kinda slow, but not horribly slow). It required tinkering around with bypassing ccache, but overall it wasn't hard.
If you could describe in detail how you managed to accomplish this (apart from the obvious #opkg install gcc), it could be quite useful for many folks on this forum, including me. _________________ - Linksys EA8500: I-Gateway, WAP/VAP 5ghz only. Features: VLANs, Samba, WG, Entware - r60xxx
- Linksys EA8500: 802.11s Secondary w/VLAN Trunk over 5ghz - r60xxx
- Linksys MX4300: 802.11s Primary w/VLAN Trunk over 5ghz. 2.4ghz WAP/VAP only - r60xxx
- Linksys MX4300: (WAP/VAP (7)) Multiple VLANs over single trunk port. Entware/Samba r60xxx
- Linksys MR7350: WDS Station for extended Ethernet r60xxx
- Linksys MR7500, MX8500: None in production. Just testing. r60xxx
- OSes: Fedora 40, 10 RPis (2,3,4,5), 23 ESP8266s: Straight from Amiga to Linux in '95, never having owned a Windows PC.
- Forum member #248
Cool. I guess I was just more curious about which kernel headers you used to build against. Did you use the official kernel headers or the openwrt kernel headers? _________________ - Linksys EA8500: I-Gateway, WAP/VAP 5ghz only. Features: VLANs, Samba, WG, Entware - r60xxx
- Linksys EA8500: 802.11s Secondary w/VLAN Trunk over 5ghz - r60xxx
- Linksys MX4300: 802.11s Primary w/VLAN Trunk over 5ghz. 2.4ghz WAP/VAP only - r60xxx
- Linksys MX4300: (WAP/VAP (7)) Multiple VLANs over single trunk port. Entware/Samba r60xxx
- Linksys MR7350: WDS Station for extended Ethernet r60xxx
- Linksys MR7500, MX8500: None in production. Just testing. r60xxx
- OSes: Fedora 40, 10 RPis (2,3,4,5), 23 ESP8266s: Straight from Amiga to Linux in '95, never having owned a Windows PC.
- Forum member #248
I cloned the whole dd-wrt repo up to the revision of my firmware and built the modules out of it using the cross-compiler path from Entware's staging dir toolchain location. Smth like that.
More modules. Now I added the zram-related ones, for people who struggles with RAM.
Modules list:
ipvlan.ko
lz4.ko
lz4_compress.ko
lz4_decompress.ko
macvlan.ko
macvtap.ko
veth.ko
vxlan.ko
xz.ko
zram.ko
zsmalloc.ko
(see following posts for an updated version)
Last edited by Evengard on Mon Jul 26, 2021 17:36; edited 1 time in total