Re: [PATCH 2/2 uClibc++] Fix ARM EABI build failure in include/unwind-cxx.h
On 12/06/2012 16.19, Bernhard Reutner-Fischer wrote: On 12 June 2012 14:23, Felix Fietkau n...@openwrt.org wrote: uClibc++ current does not build using an ARM EABI toolchain with the following build failure: eh_alloc.cpp In file included from ../include/basic_definitions:21:0, from ../include/cstdlib:20, from eh_alloc.cpp:20: ../include/system_configuration.h:17:0: warning: __WARNINGS__ redefined [enabled by default] /opt/toolchains/armeabi-uclibc-std-0.9.30.2-gcc-4.6.0-binutils-2.20.1/arm-linux-uclibcgnueabi/sysroot/usr/include/bits/uClibc_config.h:223:0: note: this is the location of the previous definition In file included from eh_alloc.cpp:25:0: ../include/unwind-cxx.h:176:36: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:177:36: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:178:35: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:179:41: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:180:40: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:181:39: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:182:38: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' ../include/unwind-cxx.h:183:37: error: ISO C++ forbids casting to an array type '_Unwind_Exception_Class' make[1]: *** [eh_alloc.o] Error 1 make[1]: Leaving directory `/home/florian/dev/uclibcxx/uClibc++/src' Workaround this by direclty using the string GNUC++. Signed-off-by: Felix Fietkau n...@openwrt.org Signed-off-by: Florian Fainelli flor...@openwrt.org --- include/unwind-cxx.h |4 1 file changed, 4 insertions(+) diff --git a/include/unwind-cxx.h b/include/unwind-cxx.h index a5f6440..cd5a58e 100644 --- a/include/unwind-cxx.h +++ b/include/unwind-cxx.h @@ -173,6 +173,7 @@ extern std::unexpected_handler __unexpected_handler; // This is the exception class we report -- GNUCC++\0. const _Unwind_Exception_Class __gxx_exception_class +#ifndef __ARM_EABI_UNWINDER__ = _Unwind_Exception_Class) 'G' 8 | (_Unwind_Exception_Class) 'N') 8 | (_Unwind_Exception_Class) 'U') @@ -181,6 +182,9 @@ const _Unwind_Exception_Class __gxx_exception_class 8 | (_Unwind_Exception_Class) '+') 8 | (_Unwind_Exception_Class) '+') 8 | (_Unwind_Exception_Class) '\0'); +#else += GNUC++; IIRC this should be GNUCC++, no? Seems like nobody needs dependent exceptions? *phew* :) I'll push a fixed version of this.. Thanks for the patch! Hi Bernard, this fix is needed to me too, could you apply it asap ? thanks, carmelo ___ uClibc mailing list uClibc@uclibc.org http://lists.busybox.net/mailman/listinfo/uclibc ___ uClibc mailing list uClibc@uclibc.org http://lists.busybox.net/mailman/listinfo/uclibc
Re: [PATCH] buildsys: clean up libubacktrace linker script handling
On Wed, Jun 13, 2012 at 12:58 AM, Bernhard Reutner-Fischer rep.dot@gmail.com wrote: On Tue, Jun 12, 2012 at 04:52:21PM +0100, Carmelo AMOROSO wrote: On 07/06/2012 19.32, Kevin Cernekee wrote: Move the AS_NEEDED insertion into libc/Makefile.in, and add a case to the HARDWIRED_ABSPATH substitution command so libubacktrace is handled the same way as the other libraries listed in the script. Looks fine to me. Applied, thanks! Unfortunately it looks like this could cause some problems when bootstrapping a new toolchain. If the libc.so script references libubacktrace, but libubacktrace.so.0 is not yet installed anywhere, gcc will throw an error during the final link on the other shared libraries: rm -f lib/libdl.so lib/libdl.so.0 lib/libdl-0.9.32.1.so arm-linux-uclibcgnueabi-gcc -Wl,-EL -shared -Wl,--warn-common -Wl,--warn-once -Wl,-z,combreloc -Wl,-z,relro -Wl,-z,defs -Wl,-fini,dl_cleanup -Wl,-soname=libdl.so.0 -nostdlib -o lib/libdl-0.9.32.1.so -Wl,--whole-archive ldso/libdl/libdl_so.a -Wl,--no-whole-archive ./lib/interp.os -L./lib ./lib/libc.so ./lib/ld-uClibc.so.0 /ssd/test/bin/../lib/gcc/arm-linux-uclibcgnueabi/4.5.3/libgcc.a /ssd/test/bin/../lib/gcc/arm-linux-uclibcgnueabi/4.5.3/libgcc_eh.a /ssd/test/bin/../lib/gcc/arm-linux-uclibcgnueabi/4.5.3/../../../../arm-linux-uclibcgnueabi/bin/ld: cannot find libubacktrace.so.0 collect2: ld returned 1 exit status make[1]: *** [lib/libdl.so] Error 1 I did not see this earlier because -nostdlib doesn't actually keep gcc from passing ld -L arguments pointing into the sysroot directories. So it saw my existing libubacktrace.so.0 from the installed sysroot and did not complain that libubacktrace.so.0 was missing from the uClibc build tree. Maybe we will need to revert back to this technique, at least in some form? -# Add the AS_NEEDED entry for libubacktrace.so - if [ -f $(top_builddir)lib/libc.so -a -f $(PREFIX)$(RUNTIME_PREFIX)$(MULTILIB_DIR)/$(SHARED_LIBNAME) ] ; then \ - echo GROUP ( $(UBACKTRACE_ASNEEDED) ) $(PREFIX)$(DEVEL_PREFIX)$(MULTILIB_DIR)/libc.so; \ - fi -endif I would appreciate any feedback/suggestions. ___ uClibc mailing list uClibc@uclibc.org http://lists.busybox.net/mailman/listinfo/uclibc