diff options
-rw-r--r-- | arch/mips/functions | 6 | ||||
-rw-r--r-- | scripts/functions | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/arch/mips/functions b/arch/mips/functions index 91a1d9a9..4bf0501d 100644 --- a/arch/mips/functions +++ b/arch/mips/functions @@ -3,4 +3,10 @@ CT_DoArchValues() { # The architecture part of the tuple: CT_TARGET_ARCH="${CT_ARCH}${target_endian_el}" + + # Override CFLAGS for endianness: + case "${CT_ARCH_BE},${CT_ARCH_LE}" in + y,) CT_ARCH_ENDIAN_CFLAG="-EB";; + ,y) CT_ARCH_ENDIAN_CFLAG="-EL";; + esac } diff --git a/scripts/functions b/scripts/functions index 13fa1590..03c5596a 100644 --- a/scripts/functions +++ b/scripts/functions @@ -542,6 +542,7 @@ CT_DoBuildTargetTuple() { CT_ARCH_TARGET_CFLAGS="${CT_ARCH_TARGET_CFLAGS} ${CT_ARCH_TUNE_CFLAG}" CT_ARCH_TARGET_CFLAGS="${CT_ARCH_TARGET_CFLAGS} ${CT_ARCH_FPU_CFLAG}" CT_ARCH_TARGET_CFLAGS="${CT_ARCH_TARGET_CFLAGS} ${CT_ARCH_FLOAT_CFLAG}" + CT_ARCH_TARGET_CFLAGS="${CT_ARCH_TARGET_CFLAGS} ${CT_ARCH_ENDIAN_CFLAG}" } # This function does pause the build until the user strikes "Return" |