[Development] how to reduce the relocation <-- Use static qt libraries

Thiago Macieira thiago.macieira at intel.com
Tue Jul 24 12:15:35 CEST 2012


On terça-feira, 24 de julho de 2012 06.40.15, song.7.liu at nokia.com wrote:
> This paintEvent is implemented inside the analogclock.cpp, but "readelf -r
> analogclock" shows that:
> 
> Relocation section '.rel.dyn' at offset 0x1b08 contains 72
> entries:                                  
> Offset     Info    Type            Sym.Value  Sym. Name
> ... ...
> 0000b090  00006f02 R_ARM_ABS32       00002933   _ZN11AnalogClock10pain
> ... ...
> 
> We think this is not expected, so is there a way to avoid such unnecessary
> relocation ?

Hint 1: don't look at symbols from the executable itself. The executables are 
position-dependent so they can get away from having relocations.

Hint 2: use eu-readelf or instead add the -W flag to readelf to print the full 
symbol name.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120724/97939ad7/attachment.sig>


More information about the Development mailing list