Re: unresolvable R_X86_64_PLT32

230 views
Skip to first unread message

Joel Dice

unread,
Mar 12, 2013, 10:54:12 AM3/12/13
to av...@googlegroups.com
On Tue, 12 Mar 2013, the....@gmail.com wrote:

> I'm new to Avian so I tried to build it. The simple make build works
> (although untested)
> However when I try to make with openjdk and openjdk-src, I get:
>
> linking build/linux-x86_64-openjdk-src/avian
> /usr/bin/ld: /tmp/cc3mw6KJ.ltrans0.ltrans.o(.text+0xc2b7): unresolvable
> R_X86_64_PLT32 relocation against symbol `scalbn@@GLIBC_2.2.5'
> /usr/bin/ld: final link failed: Nonrepresentable section on output
> collect2: error: ld returned 1 exit status
>
> any idea ?
>
> (build on Fedora against a fresh build of the latest opendjk7 version)

Can you give me a complete list of steps for reproducing this, including
the exact versions of OpenJDK and Fedora you're using, as well as the
command you used to build OpenJDK?

Thanks.

Joel Dice

unread,
Mar 28, 2013, 4:35:03 PM3/28/13
to av...@googlegroups.com
On Tue, 12 Mar 2013, the....@gmail.com wrote:

> I'm new to Avian so I tried to build it. The simple make build works
> (although untested)
> However when I try to make with openjdk and openjdk-src, I get:
>
> linking build/linux-x86_64-openjdk-src/avian
> /usr/bin/ld: /tmp/cc3mw6KJ.ltrans0.ltrans.o(.text+0xc2b7): unresolvable
> R_X86_64_PLT32 relocation against symbol `scalbn@@GLIBC_2.2.5'
> /usr/bin/ld: final link failed: Nonrepresentable section on output
> collect2: error: ld returned 1 exit status

I finally had a chance to set up a Fedora system to reproduce this.
Here's what I discovered:

* specifying "use-lto=false" to make fixes the problem

* a Google search for the message doesn't tell me much, except that using
gold instead of the default linker may help:
https://developer.mozilla.org/en-US/docs/Building_Firefox_with_Address_Sanitizer

* the same "unresolvable ..." message is printed on Debian Wheezy, but it
doesn't cause linking to fail

My guess is that it's a bug in GCC's link time optimization, so I
recommend disabling LTO when you build, e.g.:

make openjdk=/home/max/jdk7/latest/build/linux-amd64/j2sdk-image
openjdk-src=/home/max/jdk7/latest/jdk/src use-lto=false
Reply all
Reply to author
Forward
0 new messages