Our server costs ~$56 per month to run. Please consider donating or becoming a Patron to help keep the site running. Help us gain new members by following us on Twitter and liking our page on Facebook!
Current time: October 31, 2026, 5:02 pm

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Installing GCC 13.1.0
#1
Installing GCC 13.1.0
Did anybody here manage to install GCC 13.1.0 on their computer? When I try to build it from source on my 64-bit Debian Linux, I get the following error message:
Code:
/usr/bin/ld: .libs/hwasan.o: relocation R_X86_64_PC32 against undefined symbol `__ehdr_start' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: final link failed: nonrepresentable section on output collect2: error: ld returned 1 exit status make[4]: *** [Makefile:559: libhwasan.la] Error 1 make[4]: Leaving directory '/home/teo/gcc-objdir/x86_64-pc-linux-gnu/libsanitizer/hwasan' make[3]: *** [Makefile:532: all-recursive] Error 1 make[3]: Leaving directory '/home/teo/gcc-objdir/x86_64-pc-linux-gnu/libsanitizer' make[2]: *** [Makefile:419: all] Error 2 make[2]: Leaving directory '/home/teo/gcc-objdir/x86_64-pc-linux-gnu/libsanitizer' make[1]: *** [Makefile:22725: all-target-libsanitizer] Error 2 make[1]: Leaving directory '/home/teo/gcc-objdir' make: *** [Makefile:1090: all] Error 2
I configured it with:
Code:
../gcc-13.1.0/configure --enable-languages=c,c++ --disable-multilib
I currently have GCC 12.2.0.
Since this is a linker error, I suppose it may be relevant that my GNU Linked version is 2.31.1.
So, what does this error message I am getting mean? And how can I fix that?

The probability that I will manage to install GCC 13.1.0 on Windows is so low it's not even worth trying. Do you agree?
Reply
#2
RE: Installing GCC 13.1.0
You might want to consider changing your major.
[Image: extraordinarywoo-sig.jpg?rlkey=x1nmxbwrp...pouidnfvtl]
Reply
#3
RE: Installing GCC 13.1.0
It tells you the problem:

"recompile with -fPIC"

Google what that means. I've always used it in my UNIX or LINUX compiles. It doesn't make sense not to use it.
Reply
#4
RE: Installing GCC 13.1.0
Reply
#5
RE: Installing GCC 13.1.0
(May 1, 2023 at 9:03 am)Angrboda Wrote: You might want to consider changing your major.

And which major should I switch to? And isn't there too much sunk cost, now that I have only two courses left to the diploma (Communication Skills and Basics of Automatic Control)?
Reply
#6
RE: Installing GCC 13.1.0
(May 1, 2023 at 9:53 am)HappySkeptic Wrote: It tells you the problem:

"recompile with -fPIC"

Google what that means.  I've always used it in my UNIX or LINUX compiles.  It doesn't make sense not to use it.

I am not invoking GCC manually, it's the GNU Make that's invoking it. Unless I modify the Makefile, I have no control over how GNU Make invokes GCC.
Reply
#7
RE: Installing GCC 13.1.0
Is there not a pre-build package for Debian? Have you googled for this error and seen if anyone has a workaround?

Google is your friend. If you can't get a hit, you are probably doing something wrong. As for this one, the compiler you are using to do the build, and the configure script or Makefile must not work together. One solution might be to hack the configure or Makefile and add the -fPIC parameter.

Or, you can give up and try something different. Learn from Google.
Reply
#8
RE: Installing GCC 13.1.0
When I hire junior engineers, I don't care so much that they know an answer to a particular problem, but I do care that they can identify appropriate resources to leverage in order to find the correct answer.

This forum isn't it.

Try stackexchange, if you aren't utterly incompetent you should be able to find an answer in about five seconds.
Reply
#9
RE: Installing GCC 13.1.0
Reply
#10
RE: Installing GCC 13.1.0
Missed the point, as usual.
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Constantly installing "new" version of Firezilla. Gawdzilla Sama 5 1986 October 30, 2016 at 8:14 pm
Last Post: Gawdzilla Sama
  Never had that kinds of troubles with installing a new video card abaris 7 2531 September 25, 2015 at 8:19 am
Last Post: abaris



Users browsing this thread: 1 Guest(s)