[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: shlib-with-non-pic-code

On Tue, Aug 29, 2006 at 01:16:40AM +0200, Michael Biebl wrote:
> Matthew Palmer wrote:
> > On Mon, Aug 28, 2006 at 07:57:27PM +0200, Michael Biebl wrote:
> >> Now lintian complains about the files in /usr/lib/kde3:
> >>
> >> E: kdesvn-kio-plugins: shlib-with-non-pic-code usr/lib/kde3/kded_kdesvnd.so
> >> E: kdesvn-kio-plugins: shlib-with-non-pic-code usr/lib/kde3/kio_ksvn.so
> >> E: kdesvn: shlib-with-non-pic-code usr/lib/kde3/libkdesvnpart.so
> >>
> >> Looking at the corresponding check, lintian greps for TEXTREL in objdump
> >> -x and indead, this section is there. Can someone explain what this
> >> section is for, google was not very helpful there.
> >>
> >> The command line when linking the modules is
> >> /usr/bin/c++  -fPIC -g -Wall -O2 -Wnon-virtual-dtor -Wno-long-long -ansi
> >> -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W
> >> -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -fno-exceptions
> >> -fno-check-new -fno-common -fexceptions -fstack-protector  -shared
> >> -Wl,-soname,kded_kdesvnd.so -o ../../lib/kded_kdesvnd.so
> > 
> > More important than the linker command line is the compilation command line. 
> > You need to make sure that all of the source files that make up those .so
> > files were built with -fPIC in their command lines.
> Hi Matt,
> thanks for your advice but it seems that they all are built with -fPIC.
> The command line for a source file looks like this:
>  /usr/bin/c++   -Dkded_kdesvnd_EXPORTS -g -Wall -O2 -Wnon-virtual-dtor
> -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts
> -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security
> -fno-exceptions -fno-check-new -fno-common -fexceptions
> -fstack-protector -fPIC -I/usr/include/kde -I/usr/share/qt3/include

Bugger.  That's the only thing that I've ever had to check.  Mike Hommey
appears to have deeper knowledge of why things can end up being
non-position-independent than me, so I'll leave the tricky debugging work to

- Matt

Reply to: