Compiling MIPS

From Leo's Notes
Revision as of 02:38, 28 January 2019 by 184.64.117.27 (talk) (Created page with " == 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 endi...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
This page was last edited on 28 January 2019, at 02:38.

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