uClibc-0.9.32-use-arch-pt-initfini_c.patch 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. SH provides a pt-initfini.c, so use that instead of
  2. libpthread/nptl/sysdeps/pthread/pt-initfini.c
  3. This prevents:
  4. libpthread/nptl/sysdeps/pthread/crti.S: Assembler messages:
  5. libpthread/nptl/sysdeps/pthread/crti.S:25: Error: pcrel too far
  6. libpthread/nptl/sysdeps/pthread/crti.S:26: Error: pcrel too far
  7. libpthread/nptl/sysdeps/pthread/crti.S:28: Error: pcrel too far
  8. libpthread/nptl/sysdeps/pthread/crti.S:53: Error: pcrel too far
  9. libpthread/nptl/sysdeps/pthread/crti.S:56: Error: pcrel too far
  10. make[1]: *** [libpthread/nptl/sysdeps/pthread/crti.o] Error 1
  11. There is probably a better way to handle this... but since 9381d622e2411a35a5fd7
  12. I do not want to even try.
  13. --- uClibc-0.9.32/libpthread/nptl/sysdeps/pthread/Makefile.in 2011-06-11 00:58:59.539341382 -0400
  14. +++ uClibc-0.9.32/libpthread/nptl/sysdeps/pthread/Makefile.in 2011-06-11 00:57:52.848172407 -0400
  15. @@ -76,12 +76,21 @@
  16. ASFLAGS-crti.S = -g0
  17. ASFLAGS-crtn.S = -g0
  18. +ifneq ($(wildcard $(top_srcdir)libpthread/nptl/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/pt-initfini.c),)
  19. +$(libpthread_pthread_OUT)/pt-initfini.s: $(top_srcdir)libpthread/nptl/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/pt-initfini.c
  20. + $(compile.c)
  21. +$(libpthread_pthread_OUT)/defs.h: $(top_srcdir)libpthread/nptl/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/pt-initfini.c
  22. + $(do_sed) -n -e '/@TESTS_BEGIN/,/@TESTS_END/p' $< | \
  23. + $(AWK) -f $(top_srcdir)extra/scripts/defs.awk > $@.tmp
  24. + $(Q)mv $@.tmp $@
  25. +else
  26. $(libpthread_pthread_OUT)/pt-initfini.s: $(libpthread_pthread_DIR)/pt-initfini.c
  27. $(compile.c)
  28. $(libpthread_pthread_OUT)/defs.h: $(libpthread_pthread_DIR)/pt-initfini.c
  29. $(do_sed) -n -e '/@TESTS_BEGIN/,/@TESTS_END/p' $< | \
  30. $(AWK) -f $(top_srcdir)extra/scripts/defs.awk > $@.tmp
  31. $(Q)mv $@.tmp $@
  32. +endif
  33. $(libpthread_pthread_OUT)/crti.S: $(libpthread_pthread_OUT)/pt-initfini.s $(libpthread_pthread_OUT)/defs.h
  34. $(do_sed) -n -e '/[ ]*\.file/d' \