Native compiling on router

hi, as i still can not bring together cross compiling a package on a standalone host linux pc i ask for another approach.
i red a lot about extroot. just beef up my router with external drive usb pen-drive or ssd (as usb pen-drives so far no have wear leveling implemented i rather would go with an ssd with swap partition).
after the beef up to setup build environment on the router directly and install apps from source natively without generating a mips_24kc.ipk first.
just like on any desktop linux pc.
if such tools / configuration available under LEDE/Openwrt or i have to figure out that nasty cross toolchain work finally?
i just want mdk3, dsniff and ettercap to run (none of them have mips_24kc.ipk available for recent hardware, found packages with mipsel or ar71xx.ipk deny install due to wrong architecture)

I suppose it could be done on the device provided you have enough RAM and HD space. Plus a lot of coffee to wait for the whole process to be completed on a simple SoC.

But whats the problem with just building a package?? Do you need a package that is currently not available?

In that case you need to create a small makefile for your source and you can compile it with the OpenWRT tool chain. If it’s a package you think might be interesting to other people, don’t hesitate to post your makefile.

make package/yoursrc/{clean,compile}

Should do the trick. For the makefile itself, please refer to the wiki pages on creating packages.

thanx drbrain, i began this tour ca. 2 weeks ago, so i'm a complete n00b. those apps i mentioned mdk3, dsniff, ettercap somebody compiled already for different architectures but looks to me they abandoned their projects and nobody maintaining those packages any more in a manner of simple opkg install mip_24kc.ipk form. i found dozens of makefiles tailored for openwrt for the given source file (mdk3-v6.tar.bz2). i have both buildroot openwrt and a "lede-sdk-17.01.4-ar71xx-generic-gcc-5.4.0_musl-1.1.16.Linux-x86_64" installed on my pc running kali linux rolling 2018.2 version. (can be a problem if i'm root user???). i'm struggling a good week already 24/7 to find out how to compile this tar.bz2 to a mips_24kc.ipk. something wrong with my understanding of those wiki pages. i would welcome some step-by-step example with such source file.

Have a look at the R7800 community build as hnyman has a script callew that installs everthing necessary on Ubuntu to cross compile

thanx philjohn, it looks my lede sdk is up. i succeeded to place mdk3-v6 with some sdk compatible makefile in package folder. where "feeds update" found it. once succeeded "feeds install mdk3". since mdk3 shows up with "feeds list" and make menuconfig>network>wireless mdk3 shown with .
but then make package/mdk3/compile is a rush of misery. probably my source is a common linux package to install on x86_64 based distro. i don't know these pen test tools are so widely available for common distros but no one openwrt guru turned them into mips_24kc.ipk (ready ipk with mips, mipsel, ar71xx format i found from few years back).
in a desperate moment i even unpacked them on the router by hand but each gave some errors (unexcpected this and that).