public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] toolchain.eclass and gcc 4.1 snapshots
@ 2006-03-25 13:12 Simon Strandman
  2006-03-26  3:20 ` [gentoo-dev] " R Hill
  0 siblings, 1 reply; 4+ messages in thread
From: Simon Strandman @ 2006-03-25 13:12 UTC (permalink / raw
  To: gentoo-dev

It seems like toolchain.eclass does something wrong when configuring gcc 
4.1 snapshots. I decided to try gcc 4.1 on my server so I created a 
gcc-4.1.1.20060324 ebuild and defined the SNAPSHOT variable in it 
(current cvs has a lot of bugfixes since the release). This is the way 
I've done it with gcc 4.0 and I never had any problems then. The ebuild 
emerges without problems but it installs files in both 
/usr/lib/gcc/i686-pc-linux-gnu/4.1.1-20060324 and 
/usr/lib/gcc/i686-pc-linux-gnu/4.1.1. So when I try to emerge anything 
it always fails with errors like this:

configure:2239: i686-pc-linux-gnu-gcc -O2 -march=pentium3 -pipe 
-fomit-frame-pointer -D_FORTIFY_SOURCE=1   conftest.c  >&5
/usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: 
cannot find -lgcc_s
collect2: ld returned 1 exit status

Just copying over the files from one dir to the other and then 
symlinking it works around the problems. Any ideas?
-- 
gentoo-dev@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [gentoo-dev]  Re: toolchain.eclass and gcc 4.1 snapshots
  2006-03-25 13:12 [gentoo-dev] toolchain.eclass and gcc 4.1 snapshots Simon Strandman
@ 2006-03-26  3:20 ` R Hill
  2006-03-27  8:54   ` Simon Strandman
  0 siblings, 1 reply; 4+ messages in thread
From: R Hill @ 2006-03-26  3:20 UTC (permalink / raw
  To: gentoo-dev

Simon Strandman wrote:
> It seems like toolchain.eclass does something wrong when configuring gcc 
> 4.1 snapshots. I decided to try gcc 4.1 on my server so I created a 
> gcc-4.1.1.20060324 ebuild and defined the SNAPSHOT variable in it 
> (current cvs has a lot of bugfixes since the release). This is the way 
> I've done it with gcc 4.0 and I never had any problems then. The ebuild 
> emerges without problems but it installs files in both 
> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1-20060324 and 
> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1. So when I try to emerge anything 
> it always fails with errors like this:
> 
> configure:2239: i686-pc-linux-gnu-gcc -O2 -march=pentium3 -pipe 
> -fomit-frame-pointer -D_FORTIFY_SOURCE=1   conftest.c  >&5
> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: 
> cannot find -lgcc_s
> collect2: ld returned 1 exit status
> 
> Just copying over the files from one dir to the other and then 
> symlinking it works around the problems. Any ideas?

This is caused by changes to the build system in 4.1 and GCC's BASE-VER not 
matching portage's ${PV} in snapshot builds.  Most of the system directories are 
set up by portage during configure using ${PV} as part of the dirname. (eg. 
includedir=/usr/<lib>/gcc/<chost>/${PV}/include).  However, libdir and 
libexecdir aren't set by portage (because they generate really strange paths w/ 
--enable-version-specific-runtime-libs in GCC 3.3/3.4) and default to 
/usr/<lib>/gcc/<chost>/BASE-VER/blah.  When ${PV} != BASE-VER, wackiness ensues.

Try this in your ebuild:

src_unpack() {
	toolchain_src_unpack

	echo ${PV/_/-} > "${S}"/gcc/BASE-VER
	echo "" > "${S}"/gcc/DATESTAMP
}

--de.

-- 
gentoo-dev@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [gentoo-dev]  Re: toolchain.eclass and gcc 4.1 snapshots
  2006-03-26  3:20 ` [gentoo-dev] " R Hill
@ 2006-03-27  8:54   ` Simon Strandman
  2006-03-27 10:09     ` Simon Strandman
  0 siblings, 1 reply; 4+ messages in thread
From: Simon Strandman @ 2006-03-27  8:54 UTC (permalink / raw
  To: gentoo-dev

R Hill skrev:
> Simon Strandman wrote:
>> It seems like toolchain.eclass does something wrong when configuring 
>> gcc 4.1 snapshots. I decided to try gcc 4.1 on my server so I created 
>> a gcc-4.1.1.20060324 ebuild and defined the SNAPSHOT variable in it 
>> (current cvs has a lot of bugfixes since the release). This is the 
>> way I've done it with gcc 4.0 and I never had any problems then. The 
>> ebuild emerges without problems but it installs files in both 
>> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1-20060324 and 
>> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1. So when I try to emerge 
>> anything it always fails with errors like this:
>>
>> configure:2239: i686-pc-linux-gnu-gcc -O2 -march=pentium3 -pipe 
>> -fomit-frame-pointer -D_FORTIFY_SOURCE=1   conftest.c  >&5
>> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: 
>> cannot find -lgcc_s
>> collect2: ld returned 1 exit status
>>
>> Just copying over the files from one dir to the other and then 
>> symlinking it works around the problems. Any ideas?
>
> This is caused by changes to the build system in 4.1 and GCC's 
> BASE-VER not matching portage's ${PV} in snapshot builds.  Most of the 
> system directories are set up by portage during configure using ${PV} 
> as part of the dirname. (eg. 
> includedir=/usr/<lib>/gcc/<chost>/${PV}/include).  However, libdir and 
> libexecdir aren't set by portage (because they generate really strange 
> paths w/ --enable-version-specific-runtime-libs in GCC 3.3/3.4) and 
> default to /usr/<lib>/gcc/<chost>/BASE-VER/blah.  When ${PV} != 
> BASE-VER, wackiness ensues.
>
> Try this in your ebuild:
>
> src_unpack() {
>     toolchain_src_unpack
>
>     echo ${PV/_/-} > "${S}"/gcc/BASE-VER
>     echo "" > "${S}"/gcc/DATESTAMP
> }
>
> --de.
>
Thanks for the help! But now it fails with this error:

<built-in>:1: internal compiler error: in define__GNUC__, at c-cppbuiltin.c:296
Please submit a full bug report,


This has been reported in gcc bug #19372 and apperantly it has something 
to do with the version string. :(
-- 
gentoo-dev@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [gentoo-dev]  Re: toolchain.eclass and gcc 4.1 snapshots
  2006-03-27  8:54   ` Simon Strandman
@ 2006-03-27 10:09     ` Simon Strandman
  0 siblings, 0 replies; 4+ messages in thread
From: Simon Strandman @ 2006-03-27 10:09 UTC (permalink / raw
  To: gentoo-dev

Simon Strandman skrev:
> R Hill skrev:
>> Simon Strandman wrote:
>>> It seems like toolchain.eclass does something wrong when configuring 
>>> gcc 4.1 snapshots. I decided to try gcc 4.1 on my server so I 
>>> created a gcc-4.1.1.20060324 ebuild and defined the SNAPSHOT 
>>> variable in it (current cvs has a lot of bugfixes since the 
>>> release). This is the way I've done it with gcc 4.0 and I never had 
>>> any problems then. The ebuild emerges without problems but it 
>>> installs files in both /usr/lib/gcc/i686-pc-linux-gnu/4.1.1-20060324 
>>> and /usr/lib/gcc/i686-pc-linux-gnu/4.1.1. So when I try to emerge 
>>> anything it always fails with errors like this:
>>>
>>> configure:2239: i686-pc-linux-gnu-gcc -O2 -march=pentium3 -pipe 
>>> -fomit-frame-pointer -D_FORTIFY_SOURCE=1   conftest.c  >&5
>>> /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: 
>>> cannot find -lgcc_s
>>> collect2: ld returned 1 exit status
>>>
>>> Just copying over the files from one dir to the other and then 
>>> symlinking it works around the problems. Any ideas?
>>
>> This is caused by changes to the build system in 4.1 and GCC's 
>> BASE-VER not matching portage's ${PV} in snapshot builds.  Most of 
>> the system directories are set up by portage during configure using 
>> ${PV} as part of the dirname. (eg. 
>> includedir=/usr/<lib>/gcc/<chost>/${PV}/include).  However, libdir 
>> and libexecdir aren't set by portage (because they generate really 
>> strange paths w/ --enable-version-specific-runtime-libs in GCC 
>> 3.3/3.4) and default to /usr/<lib>/gcc/<chost>/BASE-VER/blah.  When 
>> ${PV} != BASE-VER, wackiness ensues.
>>
>> Try this in your ebuild:
>>
>> src_unpack() {
>>     toolchain_src_unpack
>>
>>     echo ${PV/_/-} > "${S}"/gcc/BASE-VER
>>     echo "" > "${S}"/gcc/DATESTAMP
>> }
>>
>> --de.
>>
> Thanks for the help! But now it fails with this error:
>
> <built-in>:1: internal compiler error: in define__GNUC__, at 
> c-cppbuiltin.c:296
> Please submit a full bug report,
>
>
> This has been reported in gcc bug #19372 and apperantly it has 
> something to do with the version string. :(
I opened a bug about it:
http://bugs.gentoo.org/show_bug.cgi?id=127724
-- 
gentoo-dev@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-03-27 10:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-25 13:12 [gentoo-dev] toolchain.eclass and gcc 4.1 snapshots Simon Strandman
2006-03-26  3:20 ` [gentoo-dev] " R Hill
2006-03-27  8:54   ` Simon Strandman
2006-03-27 10:09     ` Simon Strandman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox