[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-kbuild
Subject:    [PATCH 2/2] Makefile.build: Fix built-in.o linking errors EABI version
From:       "Jiafu He" <jay () goldhive ! com>
Date:       2009-12-18 1:30:17
Message-ID: 20091217183017.0b50c25debf12a9aa545bf810459b532.ce89a43b17.wbe () email ! secureserver ! net
[Download RAW message or body]

Michal wrote:
> 
> Ack on this part, I need to think a bit more about the second part :).
> Could you please send two separate patches, they fix two independent
> issues after all.
> 
Here it the 2nd patch resent. Thanks.

This patch fixes the EABI version mismatch link error "built-in.o has
EABI version 0, but ... has EABI verion 4". The problem happens when
linking the child builtin.o's using arm-xscale-linux-gnueabi linker. The
cause is built-in.o created by $(AR) has an EABI verison 0, while the
non-empty built-in.o's have EABI version 4. Use $(CC) to create the
empty built-in.o fixes the problem.

Signed-off-by: Jiafu He <jay@goldhive.com>
-----
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index 341b589..6a990ef 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -291,7 +291,7 @@ quiet_cmd_link_o_target = LD      $@
 cmd_link_o_target = $(if $(strip $(obj-y)),\
                      $(LD) $(ld_flags) -r -o $@ $(filter $(obj-y), $^)
\
                      $(cmd_secanalysis),\
-                     rm -f $@; $(AR) rcs $@)
+                     rm -f $@; $(CC) -c -xassembler /dev/null -o $@)
 
 $(builtin-target): $(obj-y) FORCE
        $(call if_changed,link_o_target)
-----

--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic