Cross-compiling architecture discrepancy - packages not working
I've cross-compiled OpenWRT sources for a couple of packets, following the wiki instructions for configuration and build, then got my *_ar71xx.ipks aparently correct. Then copied to Onion but opkg refused to install alleging alien architecture.
A list of supported architectures show:
arch all 1
arch noarch 1
arch mipsel_24kc 10
That surprised me as ar71xx was not even mentioned. So I added it manually to opkg.conf:
arch ar71xx 100
And opkg accepted them as spected, --force not even necessary, but the installed binaries don't work. They seem not recognized as binaries
and executed as shells:
/usr/bin/mybin: line 1: syntax error: unexpected end of file
/usr/bin/mybin2: line 1: syntax error: unexpected ")"
So binary architecture seem not correct. what I'm doing wrong?
What Omgea are you talking about? The Omega1 or the Omega2? The former uses a AR9331 (ar71xx family) SoC, while the latter uses a MT7688 (mt76xx family).
I'm talking about Omega2+, I've just realized instructions are for first Omega. I cannot find that architecture on menuconfig. Is there another way to cross-compile? I've only have to compile a pair o pacakges, not the whole firmware.
I finally found compiled packages on LEDE proyect , arch is mipsel_24kc.
Sorry for the noise. Let this thread be for announcing cross-compiling instructions was for Onion I only.
@Ismas the architecture (target) in menuconfig is called "Ralink RT288x/RT3xxx", under which you find a subtarget "MT7688 based boards" and finally the Omega2 profiles.
Before starting to dig through Linux sources for these SoCs I hadn't realized how difficult it is to relate chip names to their architectures and drivers. There's little logic in it, but a lot of history.
How would one be able to guess the MediaTek 7688 goes under the "Ralink" architecture? Of course, once you know that Ralink was once a company that made MIPS based SoCs, and was aquired by MediaTek in 2011, it makes sense.
Still, support for the MT7688 can go by any names with "ralink", "rt", "mt76" "7621" and probably quite a few others. Comments in drivers often refer to subsystems that probably once were separate chips and thus had a completely different number. And all this being in the mostly proprietary SoC world (few proper datasheets) makes it hard to figure out what belongs where. So it took a while for a beginner like me to even start connecting dots...