
Axel.Thimm at ATrpms
Sep 2, 2009, 11:24 AM
Post #6 of 9
(1246 views)
Permalink
|
On Wed, Sep 02, 2009 at 01:18:45PM -0400, Brian Long wrote: > On Wed, Sep 2, 2009 at 10:21 AM, Axel Thimm <Axel.Thimm [at] atrpms> wrote: > > > On Tue, Sep 01, 2009 at 03:15:06AM -0700, Yeechang Lee wrote: > > > Axel Thimm <Axel.Thimm [at] ATrpms> says: > > > > I think mythtv already builds with -fPIC, I'll have to check the > > > > buildlogs to be sure. > > > > > > My system indeed builds the SRPM with -fPIC. > > > > I can confirm this - and Brian's mythtv, who is using F11/i586 had > > this in the buildlog: > > > > gcc -c -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions > > -fstack-pro > > tector --param=ssp-buffer-size=4 -m32 -march=i586 -mtune=generic > > -fasynchronous- > > unwind-tables -fomit-frame-pointer -pthread -Wall -Wno-switch > > -Wdisabled-optimiz > > ation -Wpointer-arith -Wredundant-decls -Wno-pointer-sign > > -Wno-missing-prototype > > s -D_REENTRANT -DPIC -fPIC -DMMX -Di386 -D_GNU_SOURCE > > -D_FILE_OFFSET_BITS=64 -D > > QT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_PLUGIN -DQT_SHARED -DQT_TABLET_SUPPORT > > -I/u > > sr/lib/qt-3.3/mkspecs/default -I. -I/usr/include -I/usr/include > > -I/usr/include - > > I../../libs/libavcodec -I../../libs/libavutil -I../../libs/libmythtv > > -I../../lib > > s/libavcodec -I../.. -I/usr/lib/qt-3.3/include -o filter_greedyhdeint.o > > filter_g > > reedyhdeint.c > > > > So the flags are already in place. Something else seems to be wrong. > > > > Does this help? > > eu-findtextrel /usr/lib/mythtv/filters/libgreedyhdeint.so > either the file containing the function 'GreedyHDeintFilter' or the file > containing the function 'apply_chroma_filter' is not compiled with > -fpic/-fPIC > > I'm not too familiar with -fPIC and -fPIE, but I ran the utility mentioned > at the redhat.com URL and it output the above line multiple times. It > appears apply_chroma_filter is contained in color.c. Are the build logs > publicly available? No, they are not, and they should, so I don't have to dig them up :) color.c was built with the same options: gcc -c -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-pro tector --param=ssp-buffer-size=4 -m32 -march=i586 -mtune=generic -fasynchronous- unwind-tables -fomit-frame-pointer -pthread -Wall -Wno-switch -Wdisabled-optimiz ation -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wno-missing-prototype s -D_REENTRANT -DPIC -fPIC -DMMX -Di386 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D QT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_PLUGIN -DQT_SHARED -DQT_TABLET_SUPPORT -I/u sr/lib/qt-3.3/mkspecs/default -I. -I/usr/include -I/usr/include -I/usr/include - I../../libs/libavcodec -I../../libs/libavutil -I../../libs/libmythtv -I../../lib s/libavcodec -I../.. -I/usr/lib/qt-3.3/include -o color.o color.c So anything that libgreedyhdeint.so is built from is built with -fPIC, but AFAIK if there is some asm in there it can make it non-relocatable as well. And both color.c and filter_greedyhdeint.c (which includes greedyh.asm) have asm code inside. If one wants to fix this one needs to fix upstream the asm code. The Red Hat URL further quotes on that: The tool is not able to distinguish compiler-generated code from assembler code written by the programmer. In both cases the tool will print the message above since it is what is correct in 99% of all cases. If the problem is indeed the result of hand-written assembler code the solution is not as simple as adding a compiler/assembler flag. The code needs to be rewritten. This is architecture specific and can vary widely between every single instance. We are not going into those details here. Find a person with sufficient assembly programming skills if this problem appears. -- Axel.Thimm at ATrpms.net
|