Port-powerpc archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Support for relocation type 10 in ld.elf_so
On Sat, Jun 15, 2002 at 08:38:12PM -0700, Matt Thomas wrote:
> >I was looking at PR pkg/13771 which complains that Apache's mod_perl is
> >not usable because:
> >
> ># apachectl configtest
> >Syntax error on line 1220 of /usr/pkg/etc/httpd/httpd.conf:
> >Cannot load /usr/pkg/lib/httpd/mod_perl.so into server:
> >/usr/pkg/lib/httpd/mod_perl.so: Unsupported relocation type 10 in non-PLT
> >relocations
>
> This tells me that the .so was compiled -fpic or -fPIC.
As far as I can tell, Apache, perl, libperl, and mod_perl are all
compiled -fPIC. If you have any suggestions on how to help track
down where the compilation problem is, I'd love to hear them.
Here's the oh-so-helpful ld.elf_so debugging information:
# apachectl start
[...]
added path "/usr/pkg/lib"
added path "/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE"
0x41b9c000 .. 0x41c31fff: /usr/pkg/lib/httpd/mod_perl.so
WARNING: /usr/pkg/lib/httpd/mod_perl.so has impure text
load by name libperl.so 0x0
Searching for "libperl.so" (0x418bfa00)
Trying "/usr/pkg/lib/libperl.so"
Trying "/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libperl.so"
added path "/usr/pkg/lib"
0x41c32000 .. 0x41d6ffff:
/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libperl.so
load by name libm.so.0 0x0
Searching for "libm.so.0" (0x418bfa00)
Trying "/usr/pkg/lib/libm.so.0"
Trying "/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libm.so.0"
Trying "/usr/lib/libm.so.0"
added path "/usr/lib"
0x41d70000 .. 0x41dcffff: /usr/lib/libm.so.0
load by name libcrypt.so.0 0x0
Searching for "libcrypt.so.0" (0x418bfa00)
Trying "/usr/pkg/lib/libcrypt.so.0"
Trying "/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libcrypt.so.0"
Trying "/usr/lib/libcrypt.so.0"
Syntax error on line 1238 of /usr/pkg/etc/httpd/httpd.conf:
Cannot load /usr/pkg/lib/httpd/mod_perl.so into server:
/usr/pkg/lib/httpd/mod_perl.so: Unsupported relocation type 10 in non-PLT
relocations
rtld_exit()
/usr/pkg/sbin/apachectl start: httpd could not be started
# ldd /usr/pkg/sbin/httpd
/usr/pkg/sbin/httpd:
-lcrypt.0 => /usr/lib/libcrypt.so.0
-lmm.11 => /usr/pkg/lib/libmm.so.11
-lexpat.1 => /usr/pkg/lib/libexpat.so.1
-lc.12 => /usr/lib/libc.so.12
# ldd /usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libperl.so
/usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libperl.so:
# ldd /usr/pkg/lib/httpd/mod_perl.so
/usr/pkg/lib/httpd/mod_perl.so:
-lperl => /usr/pkg/lib/perl5/5.6.1/powerpc-netbsd/CORE/libperl.so
-lm.0 => /usr/lib/libm.so.0
-lcrypt.0 => /usr/lib/libcrypt.so.0
This was freshly built from a -current pkgsrc on a fresh 1.5.3
installation.
Granted, WARNING: /usr/pkg/lib/httpd/mod_perl.so has impure text
looks a bit interesting, but I'm not sure how one fixes that.
> >I'm not sure how we're getting the R_PPC_REL24 relocations in
> >mod_perl.so, but that's really kind of unacceptable behavior.
> >Todd V. mentioned that, well, ld.elf_so could always be taught
> >about this relocation type, and I think the following patch
> >does this.
>
> I disagree. If you are shared libraries and compiling PIC, bad things
> will happen.
That's kind of what I thought, but it wasn't clear where the error
was in this case. There should probably be some better way to track
this down. It works on x86, of course...
-allen
--
Allen Briggs briggs%wasabisystems.com@localhost
http://www.wasabisystems.com/ Quality NetBSD CDs, Sales, Support, Service
NetBSD development for Alpha, ARM, M68K, MIPS, PowerPC, SuperH, XScale, etc...
Home |
Main Index |
Thread Index |
Old Index