Compiling MIPS: Difference between revisions
From Leo's Notes
This page was last edited on 1 September 2019, at 05:09.
m Text replacement - "Category:Linux " to "Category:Linux{{Navbox Linux}} " |
m Text replacement - "Category:Linux" to "Category:Linux{{Navbox Linux}}" |
||
| Line 10: | Line 10: | ||
}} | }} | ||
[[Category:Linux]]{{Navbox Linux}} | [[Category:Linux]]{{Navbox Linux}}{{Navbox Linux}} | ||
[[Category:TODO]] | [[Category:TODO]] | ||
Revision as of 05:09, 1 September 2019
Quick Overview
Figure out what you actually want to compile and which target. There are different releases of the MIPS architecture and code could be big or little endian.
Install the cross compiler.
To compile something, such as busybox:
# make CROSS_COMPILE=mips-mti-linux-gnu- CFLAGS='-Wa,-mips32r2,-march=24kec,-mtune=24kec -mel -EL -Os -ffunction-sections -fdata-sections' LDFLAGS='-Wa,-mips32r2,-march=24kec,-mtune=24kec -mel -EL -Os -ffunction-sections -fdata-sections' ARCH=mips KBUILD_VERBOSE=1 -j 9
| ||||||||||||||||||||||||||