Relocation R_X86_64_32S error during compile

  • dna

    dna - 2005-02-10

    using the staden 1.5.3 source on a AMD 64 Debian Sarge linux box with gcc and g77 3.3.5 and the included third party utilities

    I manually set the MACHINE=linux for the compilation

    the third party utilities compiled just fine, however the make for standen failed in the io_lib section the compilation. see error below:
    "/usr/bin/ld: ../lib/linux-binaries/libz.a(deflate.o): relocation R_X86_64_32S can not be used when making a shared object; recompile with -fPIC
    ../lib/linux-binaries/libz.a: could not read symbols: Bad value"

    I had already turned on the both -fPIC options in my file and recompiling zlib with it made no difference.

    I also tried the compile using my working local libz.a (zlib 1.2.2-3) however this generated the same error.


    • James Bonfield

      James Bonfield - 2005-02-25

      I have managed an AMD64 build at some stage. Looking at my I see I used -fPIC instead of -fpic, but I assume you've done this already:

      SHLIB_CFLAGS            = -fPIC
      SHLIB_FFLAGS            = -fPIC

      I also defined



    • dna

      dna - 2005-02-25

      Thanks for the tip, however as you surmised my:

      I had no need to alter XBIN as this was correct

      A further note on this, is the error may be made to go a way by altering io_libs make file and not adding zlib support, although this may prevent -fPIC failure, it adds other errors later in things that depend on that...


    • Mohd Noor

      Mohd Noor - 2005-03-17

      I have tried to compile it on Fedora Core 2 on my AMD64, same error also come out, but once I copied my /usr/lib64/libz.a to lib/linux-binaries (note: it will overide the existing one) . compilation managed to overcome that error.... but other error came out .... the error as below

      "/usr/bin/ld: linux-binaries/align.o: relocation R_X86_64_32S can not be used when making a shared object; recompile with -fPIC 
      inux-binaries/align.o: could not read symbols: Bad value"


Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks