LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices



Reply
 
Search this Thread
Old 06-15-2012, 03:00 PM   #1
volkerdi
Slackware Maintainer
 
Registered: Dec 2002
Location: Minnesota
Distribution: Slackware! :-)
Posts: 877

Rep: Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827
gcc-4.7.1


Howdy folks!

Has anyone here successfully compiled gcc-4.7.1 yet? I'm trying on x86_64, but keep running into failures with gnat linking its shared libraries. The error in question is this:

/usr/x86_64-slackware-linux/bin/ld: adadecode.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
adadecode.o: could not read symbols: Bad value

Indeed, looking earlier in the log, adadecode.c does not appear to be compiled using -fPIC in spite of it appearing in CFLAGS. I tried adding --with-pic to the ./configure options with no noticeable change. Suspecting something had changed in ld, I tried earlier versions of binutils (as -current has a binutils package newer than gcc), but that did not help either. So, I tried compiling gcc-4.7.0 again to see if it would fail. It did not. It also does not seem to be using -fPIC, but it doesn't create a compile error in this case and the gnat package contains all the expected files.

Any help appreciated. Meanwhile it looks like we'll be sticking with 4.7.0.
 
Old 06-15-2012, 03:20 PM   #2
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
I've not tried yet a build, but looking at its git I suspect (but it's just a suspect ) this commit is involved

http://gcc.gnu.org/git/?p=gcc.git;a=...38ebcf41e6d4b6

EDIT: seems that in a later one (8 hours ago) they readded some
http://gcc.gnu.org/git/?p=gcc.git;a=...70703e2ad90958

Last edited by ponce; 06-15-2012 at 03:36 PM.
 
Old 06-15-2012, 03:49 PM   #3
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
it can be (still wild guess), that this patch derived from that post release commit can fix the build (but I haven't tested yet).

EDIT: seems there's a related message on the mailing list.

Last edited by ponce; 06-15-2012 at 03:59 PM.
 
1 members found this post helpful.
Old 06-15-2012, 04:07 PM   #4
volkerdi
Slackware Maintainer
 
Registered: Dec 2002
Location: Minnesota
Distribution: Slackware! :-)
Posts: 877

Original Poster
Rep: Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827Reputation: 1827
Thanks ponce! I kludged -fPIC into the adalib/Makefile.in GNATLIBCFLAGS and it appears to have built correctly. But I'll try the post release patch (which seems to revert part of the previous change) and use that instead if it works.
 
Old 06-15-2012, 04:13 PM   #5
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
thanks to you for providing us the new gcc!

Matteo
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] SEGMENTATION FAULT using gcc 4.4.4 -O2 , works with gcc 4.1.0 -O2 or gcc 4.4.4 -O1 amir1981 Programming 36 07-26-2010 07:07 PM
Installing vmware on Open Suse 11.1 - Requires original gcc 4.32 - gcc now 4.3 cyclops.matrix Linux - Software 2 08-31-2009 03:52 PM
yum install gcc doesn't set the lastest gcc ver 4.3.x kim,jw Linux - Newbie 3 12-23-2008 12:51 AM
gcc wont install, 'failed dependencies: glibc-devel is needed by gcc-3.3.3-41' TdlSnare Suse/Novell 3 11-29-2004 03:13 PM


All times are GMT -5. The time now is 09:08 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration