[gentoo-user] gcc 4 and 3.4 in parallel
Hi, I'd like to use gcc 4 to compile some of my own software but still use 3.4 for everything else (all ebuilds etc). Now I simply emerged gcc4 (its slotted) and then as my user I did export the variables a gcc-config -E x86_64-pc-linux-gnu-4.0.1-pre20050616 printed out. This way I successfully compiled and linked my programm with gcc4. Now my problem is that I can't execute it. If I give it a try I'm getting this error: [EMAIL PROTECTED] ~/ $ ./foo ./foo: /usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3/libstdc++.so.6: version `GLIBCXX_3.4.4' not found (required by ./foo) This is strange since for one its still using something from the 3.4.3 profile and also I've just upgraded (with the gcc upgrade) to glibc 3.5. If I switch my profile with gcc-config to the gcc4 profile everything works. So my querstion now is what else gets changed by gcc-config, and is there a chance to have the 3.4 gcc profile selected but still run programs compiled with gcc 4? kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] gcc 4 and 3.4 in parallel
Hans-Werner Hilse wrote: > Hi, > > On Mon, 27 Jun 2005 19:01:01 +0200 > Philip Lawatsch <[EMAIL PROTECTED]> wrote: > > >>Now I simply emerged gcc4 (its slotted) and then as my user I did export >>the variables a >> >>gcc-config -E x86_64-pc-linux-gnu-4.0.1-pre20050616 >> >>printed out. >> >>This way I successfully compiled and linked my programm with gcc4. >> >>Now my problem is that I can't execute it. >>[...] >>So my querstion now is what else gets changed by gcc-config, and is >>there a chance to have the 3.4 gcc profile selected but still run >>programs compiled with gcc 4? > > > LDPATH. Have a look at /etc/env.d/05gcc. Hm, strange enough, this never shows up in my environment. Neither with gcc3 or gcc4 profiles. I'll give it a try as soon as my current compilation finishes. Thanx for the help. kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] gcc 4 and 3.4 in parallel
Philip Lawatsch wrote: > Hans-Werner Hilse wrote: > >>Hi, >> >>On Mon, 27 Jun 2005 19:01:01 +0200 >>Philip Lawatsch <[EMAIL PROTECTED]> wrote: >> >> >> >>>Now I simply emerged gcc4 (its slotted) and then as my user I did export >>>the variables a >>> >>>gcc-config -E x86_64-pc-linux-gnu-4.0.1-pre20050616 >>> >>>printed out. >>> >>>This way I successfully compiled and linked my programm with gcc4. >>> >>>Now my problem is that I can't execute it. >>>[...] >>>So my querstion now is what else gets changed by gcc-config, and is >>>there a chance to have the 3.4 gcc profile selected but still run >>>programs compiled with gcc 4? >> >> >>LDPATH. Have a look at /etc/env.d/05gcc. > > > Hm, strange enough, this never shows up in my environment. Neither with > gcc3 or gcc4 profiles. > > I'll give it a try as soon as my current compilation finishes. Nope, didnt help. I did the following icefox gentoo-64 # gcc-config 1 * Sw * If you intend to use the gcc from the new profile in an already * running shell, please remember to do: * # source /etc/profile icefox gentoo-64 # . /etc/profile icefox gentoo-64 # gcc-config -E 5 export PATH="/usr/x86_64-pc-linux-gnu/gcc-bin/4.0.1-pre20050616:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/sbin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/3.4.3:/opt/Acrobat5:/opt/blackdown-jdk-1.4.2.02/bin:/opt/blackdown-jdk-1.4.2.02/jre/bin:/usr/qt/3/bin:/usr/kde/3.4/sbin:/usr/kde/3.4/bin" icefox gentoo-64 # export PATH="/usr/x86_64-pc-linux-gnu/gcc-bin/4.0.1-pre20050616:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/sbin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/3.4.3:/opt/Acrobat5:/opt/blackdown-jdk-1.4.2.02/bin:/opt/blackdown-jdk-1.4.2.02/jre/bin:/usr/qt/3/bin:/usr/kde/3.4/sbin:/usr/kde/3.4/bin" icefox gentoo-64 # export LDPATH="/usr/lib/gcc/x86_64-pc-linux-gnu/4.0.1-pre20050616:/usr/lib/gcc/x86_64-pc-linux-gnu/4.0.1-pre20050616/32:/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3:/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3/32" icefox gentoo-64 # ./foo ./foo: /usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3/libstdc++.so.6: version `GLIBCXX_3.4.4' not found (required by ./foo) Any other ideas? kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] gcc 4 and 3.4 in parallel
Luigi Pinna wrote: > Alle 19:01, lunedì 27 giugno 2005, Philip Lawatsch ha scritto: > >>Hi, >> >> >>I'd like to use gcc 4 to compile some of my own software but still >>use 3.4 for everything else (all ebuilds etc). >> >>Now I simply emerged gcc4 (its slotted) and then as my user I did >>export the variables a > Have you run the script fix_libtool_files.sh? > After a gcc emerge (if it removes an old version) you must use always > the command: > fix_libtool_files.sh oldgcc > Try now! Won't help / matter since I want to use 3.4.x as the default gcc used by portage and everything else on my system. I did _not_ upgrade this one but instead also installed gcc 4. So afaik nothing has to be fixed. kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] gcc 4 and 3.4 in parallel
Richard Fish wrote: > Philip Lawatsch wrote: > > >>So my querstion now is what else gets changed by gcc-config, and is >>there a chance to have the 3.4 gcc profile selected but still run >>programs compiled with gcc 4? >> >> > > > I haven't verified this (try switching configs back and forth to > verify), but I believe the problem is in /etc/ld.so.conf. This file > tells the dynamic linker what directories to search for a library. > > You can do one of two things: > > 1. Export "LD_LIBRARY_PATH" to point to the directory where the gcc4 > stdc++ library is > 2. Add the same directory to /etc/ld.so.conf. > > The problem with #2 is that I am pretty sure that if you switch > gcc-configs too many times, you will end up removing your edits. The real problem is not ld.so.conf but that the lib dirs of the selected gcc-profile are first in the list and that the others come later. Now when I manually set ld_library_path as you suggested it works fine. Thanks a bunch! kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] gcc 4 and 3.4 in parallel
Hans-Werner Hilse wrote: > Hi, > > On Mon, 27 Jun 2005 19:33:25 +0200 > Philip Lawatsch <[EMAIL PROTECTED]> wrote: > > >>>LDPATH. Have a look at /etc/env.d/05gcc. >> >>Hm, strange enough, this never shows up in my environment. Neither with >>gcc3 or gcc4 profiles. > > > Aaargh, my fault. This is used by env-update and gets - *grep, grep, > grep* - written by it to /etc/ld.so.conf. > > After reading "man ld.so" I remember the LD_LIBRARY_PATH environment > variable ;-) > > You've got to set it to the corresponding dir in /usr/... (that LD_PATH > setting). I'm still wondering why I have to do it though. I also upgraded my glibc while upgrading gcc. If recompiling libstdc++ (for does not fix the problem (without setting LD_PATH) I'll file a bug about gcc-config -E not printig out a correct LD_LIBRARY_PATH setting. kind regards Philip -- gentoo-user@gentoo.org mailing list
[gentoo-user] Problem unmasking packages
Hi, I'd like to unmask (-*) certain versions of a package (gcc). I'd like to keep the defaults for everything but I'd like to unmask gcc-4.0.1_pre* I've already tried to unmask ~sys-devel/gcc-4.0.1_pre20050616 -* and also ~sys-devel/gcc-4.0.1 -* but it didnt work. The first only only unmasked this one package and the second one didnt unmask anything. I really do not want to unmask with <= foo and >= bar because I do not want to change any other defaults. I'd really appreciate any pointers as to how I might do this one. kind regards Philip -- gentoo-user@gentoo.org mailing list
[gentoo-user] Different Slots for ebuilds
Hi, another problem I've just run into: I'd like to have gcc 3.4.x, 4.0.1_pre* and 4.1.* installed at the same time. However all gcc-4.* versions do not seem to use different slots (eg one 4.0.* and one 4.1.* slot). Is there any way I can force slots without creating my own ebuilds in the overlay? (which would force me to update them everytime a new version is available.) kind regards Philip -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Problem unmasking packages
Edward Catmur wrote: >>I'd like to unmask (-*) certain versions of a package (gcc). >> >>I'd like to keep the defaults for everything but I'd like to unmask >> >>gcc-4.0.1_pre* >> > > Try > > =sys-devel/gcc-4.0.1* -* > > or > > =sys-devel/gcc-4.0.1_pre* -* > > Remember that ~ only matches -r* revisions of a package, not _pre, > _alpha, _beta etc. This is covered (not all that clearly, admittedly) in > ebuild(5). Now I really feel stupid :( Thanks a lot! kind regards Philip -- gentoo-user@gentoo.org mailing list
[gentoo-user] Strange gdm problems
Hi, I've got two machines, both have gdm-2.8.0.1-r1. On one machine, a 32 bit one gdm works as normal and reads its config files from /etc/X11/gdm. On my other machine (amd64) however, gdm does _not_ read it from /etc/X11/gdm but instead tries to read them from /etc/gdm. Took me quite a while to figure out what was going on. So the question is, what could I have done wrong on this machine? I've tried reemerging gdm but it didn't change anything. Still gdm wants it's config in /etc/gdm. I'd appreciate and help. kind regards Philip -- gentoo-user@gentoo.org mailing list
[gentoo-user] Evironment variables breaking ebuilds
Hi, I've just noticed that one of the environment variables I (have to) have set causes troubles with an ebuild. In my case I have set the environment variable "PLATFORM" (for my user). If I now just su to root and then emerge mono the emerge will fail because mono also seems to make use of $PLATFORM but does not seem to overwrite it if it is already set. -> Is this a bug in the mono ebuild or is this just a fsckup on my part? I do think that all environment variables besides the stuff in the profile and the things in make.conf / make.globals should be dropped by emerge. So, should I submit a bug for the mono ebuild or is this breakage (in my case) expected behaviour? (I know that I could just use "su -" or something else which would get rid of my users environment variables, but this does not fix the problem and also I sometimes simply forget about it) kind regards Philip -- gentoo-user@gentoo.org mailing list