hrev46138 adds 1 changeset to branch 'master' old head: 4a3649a4ac79df61bcc9a269f0ef1a736bc2519f new head: 5e0e2739c95093a2702ea108ec49d7cce8d4bcc6 overview: http://cgit.haiku-os.org/haiku/log/?qt=range&q=5e0e273+%5E4a3649a ---------------------------------------------------------------------------- 5e0e273: ARM: work around too many libgcc objects when linking libroot jam fails in execve() trying to run the command due to a too large arguments list because of the many objects in libgcc. We split them into two intermediate objects, then we link them to libroot. [ François Revol <revol@xxxxxxx> ] ---------------------------------------------------------------------------- Revision: hrev46138 Commit: 5e0e2739c95093a2702ea108ec49d7cce8d4bcc6 URL: http://cgit.haiku-os.org/haiku/commit/?id=5e0e273 Author: François Revol <revol@xxxxxxx> Date: Sun Sep 29 22:37:06 2013 UTC ---------------------------------------------------------------------------- 1 file changed, 28 insertions(+), 2 deletions(-) src/system/libroot/Jamfile | 30 ++++++++++++++++++++++++++++-- ---------------------------------------------------------------------------- diff --git a/src/system/libroot/Jamfile b/src/system/libroot/Jamfile index 719da31..9a5991b 100644 --- a/src/system/libroot/Jamfile +++ b/src/system/libroot/Jamfile @@ -14,6 +14,32 @@ for architectureObject in [ MultiArchSubDirSetup ] { # we need to link against libgcc.a objects and make # it available to other applications as in BeOS + # workaround for ARM having waaaaay too many objects in libgcc + # which fails execve() with too large argument list + # when linking them directly into libroot. + local libgccObjects1 = + $(HAIKU_GCC_LIBGCC_OBJECTS_$(architecture)[1-800]) ; + local libgccObjects2 = + $(HAIKU_GCC_LIBGCC_OBJECTS_$(architecture)[801-]) ; + + local librootLibgccObjects = + <$(architecture)>libgcc_part1_$(TARGET_ARCH).o ; + + MergeObject <$(architecture)>libgcc_part1_$(TARGET_ARCH).o : + : + $(libgccObjects1) + ; + + if $(libgccObjects2) { + librootLibgccObjects += + <$(architecture)>libgcc_part2_$(TARGET_ARCH).o ; + + MergeObject <$(architecture)>libgcc_part2_$(TARGET_ARCH).o : + : + $(libgccObjects2) + ; + } + local librootObjects = os_main.o os_arch_$(TARGET_ARCH).o @@ -70,7 +96,7 @@ for architectureObject in [ MultiArchSubDirSetup ] { : libroot_init.c : - $(HAIKU_GCC_LIBGCC_OBJECTS_$(architecture)) + $(librootLibgccObjects) $(librootObjects) $(librootNoDebugObjects) $(HAIKU_STATIC_LIBSUPC++_$(architecture)) @@ -84,7 +110,7 @@ for architectureObject in [ MultiArchSubDirSetup ] { : libroot_init.c : - $(HAIKU_GCC_LIBGCC_OBJECTS_$(architecture)) + $(librootLibgccObjects) $(librootObjects) $(librootDebugObjects) $(HAIKU_STATIC_LIBSUPC++_$(architecture))