840-armv4_pass_fix-v4bx_to_ld.patch 727 B

123456789101112131415161718
  1. --- a/gcc/config/arm/linux-eabi.h
  2. +++ b/gcc/config/arm/linux-eabi.h
  3. @@ -67,10 +67,14 @@
  4. #undef MUSL_DYNAMIC_LINKER
  5. #define MUSL_DYNAMIC_LINKER "/lib/ld-musl-arm.so.1"
  6. +/* For armv4 we pass --fix-v4bx to linker to support EABI */
  7. +#undef TARGET_FIX_V4BX_SPEC
  8. +#define TARGET_FIX_V4BX_SPEC " %{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4:--fix-v4bx}"
  9. +
  10. /* At this point, bpabi.h will have clobbered LINK_SPEC. We want to
  11. use the GNU/Linux version, not the generic BPABI version. */
  12. #undef LINK_SPEC
  13. -#define LINK_SPEC BE8_LINK_SPEC \
  14. +#define LINK_SPEC BE8_LINK_SPEC TARGET_FIX_V4BX_SPEC \
  15. LINUX_OR_ANDROID_LD (LINUX_TARGET_LINK_SPEC, \
  16. LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)