withmykey / google-breakpad

Automatically exported from code.google.com/p/google-breakpad
0 stars 0 forks source link

libbreakpad_client.a(exception_handler.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC #459

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Compile google-breakpad from svn and install
2. Attempt to compile Secondlife viewer, or anything else that references 
google-breakpad libraries I suppose

What is the expected output? What do you see instead?
Expected: Program compiles just fine.
Actual: I receive the error:
/usr/lib/gcc/x86_64-pc-linux-gnu/4.5.3/../../../../x86_64-pc-linux-gnu/bin/ld: 
/usr/local/lib64/libbreakpad_client.a(exception_handler.o): relocation 
R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared 
object; recompile with -fPIC
/usr/local/lib64/libbreakpad_client.a: could not read symbols: Bad value

What version of the product are you using? On what operating system?
I'm using the latest SVN version, compiling on x64 Gentoo.

Please provide any additional information below.

I watched the library compile with -fPIC, I even made sure it did by setting 
CXXFLAGS, but regardless of what I do, I still get that error.

Original issue reported on code.google.com by Dan.ori...@gmail.com on 19 Dec 2011 at 2:46

GoogleCodeExporter commented 9 years ago
Hello, 
I have the same issue and I produce a little patch to solve it (see issue 469).
The workaround for this issue need to use some compile flags.
In order you need to recompile the libbreakpad:

1) make distclean
2) ./configure CXXFLAGS=-fPIC CPPFLAGS=-fPIC CFLAGS=-fPIC
3) make
4) sudo make install

Regards

Raffaele

Original comment by raffa...@techsquare.a-tono.net on 24 Feb 2012 at 10:25

GoogleCodeExporter commented 9 years ago

Original comment by thestig@chromium.org on 18 Dec 2013 at 2:15