[ELDK] ppc_6xx link segmentation fault

Gabriel Johnson johnsoga at gmail.com
Wed Jan 6 21:12:25 CET 2010


>>> This is where we should wonder if this is normal - a sinle command
>>> line too long to be included in an email message?
>>>
>>> I confirm that the command line is extreme - IIRC it was way over 50kB
>>> big. By splitting the single link command (for example, by collecting
>>> the single onbject files in question into an "ar" archive, and then
>>> linking gainst this "library") we can work around the problem.
>
> So I edited the Makefile so that it creates an "ar" archive before I
> like the Webkit library but it doesn't look like the link command
> isn't actually liking the file.  Can someone tell me what I am doing
> wrong?
>
> I replaced:
> $(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(LIBS) $(OBJCOMP)
> with:
> $(AR) obj/libs.a $(OBJECTS)
> $(LINK) $(LFLAGS) -o $(TARGET) obj/libs.a $(LIBS) $(OBJCOMP)
>
> LINK = powerpc-linux-g++
> LFLAGS = -Wl,-rpath-link,/opt/trolltech/qte-4.6.0-powerpc/lib
> -fno-exceptions -Wl,--gc-sections -Wl,-O1 -shared
> -Wl,-soname,libQtWebKit.so.4
> TARGET = libQtWebKit.so.4.6.0
> OBJECTS = <A sh*t ton of object files>
> LIBS = -L/opt/trolltech/qte-4.6.0-powerpc/lib -lQtGui
> -L/opt/trolltech/qte-4.6.0-powerpc/lib -lQtNetwork -lQtCore -ldbus-1
> -lpthread
> AR = powerpc-linux-ar cqs
>

I figured out the correct link command to use the libs.a,
$(LINK) $(LFLAGS) -o $(TARGET) -Wl,-whole-archive obj/libs.a
-Wl,-no-whole-archive $(LIBS) $(OBJCOMP)

Unfortunately I still get a signal 11 segfault.


More information about the eldk mailing list