LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 10-17-2005, 11:52 AM   #1
yekrahs
Member
 
Registered: Aug 2005
Location: England
Distribution: SUSE 10.0, LiMP (Linux Multimedia Player)
Posts: 86

Rep: Reputation: 15
Thumbs down libstdc++ : circular dependencies?


_PREAMBLE_:
I recently tried to install TSE3 (as part of pckg dependency for Noteedit music software).

It said it needed
libstdc++.so.6(GLIBCXX_3.4.5)

So I searched that on http://www.rpmfind.net and http://rpm.pbone.net
and they suggested:
libstdc++-4.0.1-4.fc4.i386.rpm

*PROBLEM*:
When I tried to intsall this libstdc++ package, it said that it was dependent on the package libstdc++!!
How can a package be dependent on itself???
Exact dependency message:
libstdc++ required by (‘libstdc++-devel’, ‘4.0.0’, ‘8’)
libstdc++ required by (‘gcc-c++’, ‘4.0.0’, ‘8’)



So was libstdc++-4.0.1-4.fc4.i386.rpm the right package I needed for libstdc++.so.6(GLIBCXX_3.4.5), as the rpm search websites suggested? Or where else can I get it? And why am I getting these circular dependencies? What's going on?


+++Will Someone *please* dig me out of this hole!+++
(I've been trying to get NoteEdit working for weeks: there's always some other dependency! Compiling it from source failed: it only recognises gcc3 or gcc2, while fc4 comes with gcc4)

PS. Before you ask, I'd use yum to install NoteEdit and all these other packages, but I don't have the internet on my home computer.

All help appreciated.
 
Old 10-17-2005, 03:59 PM   #2
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
libstdc++ is a part of the compiler gcc

Quote:

It said it needed
libstdc++.so.6(GLIBCXX_3.4.5)


that doesn't make any sense as glibc does not contain libstdc++
although libstdc is linked to glibc like everything else
also current state of developement of glibc is 2.3.5 and there is no glibc 3.4.5
also libstdc++.so.6 is just a symbolic link to libstdc and it exists for older compilers as well

Quote:

Compiling it from source failed: it only recognises gcc3 or gcc2, while fc4 comes with gcc4


what do you mean it only recognises ?
what are the exact error messages
what you are saying is i have to upgrade my compiler to run something that only compiles on older compilers. That's a huge contradiction.
if the fedora people can compile it on gcc4 then so can you
 
Old 10-17-2005, 04:15 PM   #3
spooon
Senior Member
 
Registered: Aug 2005
Posts: 1,755

Rep: Reputation: 48
Re: libstdc++ : circular dependencies?

Quote:
Originally posted by yekrahs
*PROBLEM*:
When I tried to intsall this libstdc++ package, it said that it was dependent on the package libstdc++!!
How can a package be dependent on itself???
Exact dependency message:
libstdc++ required by (‘libstdc++-devel’, ‘4.0.0’, ‘8’)
libstdc++ required by (‘gcc-c++’, ‘4.0.0’, ‘8’)
You have some gcc 4.0.0 packages that requires libstdc++ version 4.0.0 exactly (so causes problems when you update libstdc++). You should do "yum update libstdc++" or "yum update" so that it updates all relevant packages.
 
Old 10-17-2005, 04:32 PM   #4
General
Member
 
Registered: Aug 2005
Distribution: Debian 6.0
Posts: 465

Rep: Reputation: 31
You can install multiple packages at the same time in this sort of situation:
$ rpm -Uvh package1.rpm package2.rpm package3.rpm
 
Old 10-17-2005, 06:42 PM   #5
tuxdev
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 2,012

Rep: Reputation: 111Reputation: 111
the easy way would be to copy it out of an openoffice.org installation.
 
Old 10-18-2005, 09:13 AM   #6
yekrahs
Member
 
Registered: Aug 2005
Location: England
Distribution: SUSE 10.0, LiMP (Linux Multimedia Player)
Posts: 86

Original Poster
Rep: Reputation: 15
response to foo_bar_foo

*MOST OF THE BELOW IS IRRELEVANT. But then I had to respond to foo_bar_foo. I guess there's a time to provide extra background detail, and a time not to (I guess this my first post should have been the second type). THE REAL ISSUE is that I'm just trying to get the libstdc++ package to install, WITHOUT USING *YUM*, as I don't have the internet on my home computer

So please skip to the next post if this one is too long...



Thank you foo_bar_foo, but I think you've mixed up GLIBCXX_3.4.5 with GLIBC: I think they're different.
AS you said, the

"current state of developement of glibc is 2.3.5 and there is no glibc 3.4.5"

...so GLIBCXX is something different entirely: its current development is GLIBCXX 3.4.5.
Part of what the libstdc++ package provides is GLIBCXX, which is the whole reason I was trying to download libstdc++, to get this GLIBCXX 3.4.5, as the package manager told me. It DOES make sense, honestly: try this link below from rpm.pbone.net, you'll see that GLIBCXX_3.4.5 is provided by libstdc++ ('bout halfway down)
http://rpm.pbone.net/index.php3/stat....i386.rpm.html

Quote:
also libstdc++.so.6 is just a symbolic link to libstdc and it exists for older compilers as well
I know, but when I tried to install this tse3 package, the libstdc version I have clearly isn't new enough.

Quote:
what you are saying is i have to upgrade my compiler to run something that only compiles on older compilers. That's a huge contradiction. if the fedora people can compile it on gcc4 then so can you
You misunderstand me here a little... I'm not trying to get a newer version of libstdc so that I can compile this software. This libstdc++ is a package dependency. I've given up trying to compile noteedit, the libstdc++ package has nothing to do with it. The only reason I mentioned it is so nobody tells me to "go and compile it", becuase I _have_ tried to. The libstdcc is a dependency of the tse3 rpm.
For some reason, the noteedit tarball that was made will only recognise gcc3 and gcc2. Don't ask me why. HOWEVER, as a completely separate and totally different issue, the noteedit rpm is dependent on the tse3 rpm, which is dependent on a new version of libstdc++.

Does that make sense?
The only reason I can think of that the fedora people were able to compile it is if they were using an older version of tse3, which does not require the new libstdc++

Last edited by yekrahs; 10-18-2005 at 09:33 AM.
 
Old 10-18-2005, 09:32 AM   #7
yekrahs
Member
 
Registered: Aug 2005
Location: England
Distribution: SUSE 10.0, LiMP (Linux Multimedia Player)
Posts: 86

Original Poster
Rep: Reputation: 15
Thank you all, but I think I've realised the real problem...

I have libstdc++-4.0.0-8 installed on my computer, so I realised I have 4.0.0 exactly already (I forgot to put that down, sorry spooon).

Libstdc++-4.0.0-8 only comes with GLIBCXX_3.4.4, and I need 3.4.5. But as I said, when I manually try and install a slightly newer package, e.g. 4.0.1-4, it says I need '4.0.0' '8', which is the 4.0.0-8 package that I already have installed!!! Why won't it upgrade?

There are lots of programs that use libstdc (as I found when I tried to rpm -e uninstall and reinstall it), and they're running fine, so it can't be that fedora isn't recoginsing it for some reason.

***I'd really love to get yum to do it all for me, but as I said spooon, I don't have the internet on my home computer.
***I'm also not quite sure what you mean, General. How would that help me?

***Thank you also tuxdex, but I have the rpm that I want already (straight off the official fedora download server, and I aready have Open Office 2.0 installed)



------> So, does anyone know why this is happening? Why does the newer version of libstdc++ say I need this older version, when I have it installed already? Has no-one else using fedora encountered this problem?!!!
 
Old 10-18-2005, 11:39 AM   #8
tuxdev
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 2,012

Rep: Reputation: 111Reputation: 111
I just think it is Fedora madness. You should almost never need to upgrade gcc or glibc and if you really do, dependencies are practically meaningless cause you get into a chicken-or-the-egg problem that you are currently experiencing.

A little more elaboration on my original instruction:
The general idea is to get the libstdc++.so.6 file into a location that ld and ldconfig can find. Therefore, you need to do something like
Code:
cp /opt/OpenOffice2/program/libstdc++.so.6 /usr/local/lib
the directories might be different cause Fedora likes putting things in odd places. I just keep the file somewhere I know cause it is kinda rare and I don't want to go searching for it again. I generally do the same for most of the files that I have to go looking around for.
 
Old 10-18-2005, 01:17 PM   #9
spooon
Senior Member
 
Registered: Aug 2005
Posts: 1,755

Rep: Reputation: 48
Quote:
Originally posted by yekrahs
I have libstdc++-4.0.0-8 installed on my computer, so I realised I have 4.0.0 exactly already (I forgot to put that down, sorry spooon).

Libstdc++-4.0.0-8 only comes with GLIBCXX_3.4.4, and I need 3.4.5. But as I said, when I manually try and install a slightly newer package, e.g. 4.0.1-4, it says I need '4.0.0' '8', which is the 4.0.0-8 package that I already have installed!!! Why won't it upgrade?
It won't upgrade because "libstdc++-devel" and "gcc-c++" version 4.0.0 both want the 4.0.0 version of libstdc++. You can get the updated versions of these packages also and try to update the three of them at the same time.
 
Old 10-18-2005, 03:17 PM   #10
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
like i said before -- all of this is just gcc package and nothing more.
__GLIBCXX__ is just a macro name in the gcc source code.
used to be __GLIBCPP__ in earlier versions.

you can compile a new gcc in /opt and copy the libs like tuxdev says
the link libstdc++.so.6 will be a problem

you can put a needed lib in the same directory as an executable and put a "./" at the start of LD_LIBRARY_PATH and it will use said lib so that is a solution.

It is extreemly important to realize irregardless of the lame crap put out by fedora there absolutely is no package or library GLIBCXX ! you are talking about gcc here. You can have compatability libs on yoou system for running apps compiled with a different compiler but they can't all be linked to libstdc++.so.6.

it sounds like fedora sucks
 
Old 10-18-2005, 03:32 PM   #11
tuxdev
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 2,012

Rep: Reputation: 111Reputation: 111
I don't think he needs to recompile gcc. When I did the copy in Slackware, NoteEdit and Xfe worked fine without any gcc related problems. Not sure what Fedora brings to the equation, but it can't be so bad that he has to recompile gcc.
 
Old 10-18-2005, 08:58 PM   #12
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 51
Quote:
Originally posted by tuxdev
it can't be so bad that he has to recompile gcc.
not recompile system gcc.
i mean compile other newer/older versions of gcc needed to get the libs
this is the common way to do it for compatability.
that must be what you get when you download versions of precompiled libstdc++
or appearently install openoffice with your distribution.
Quote:

But as I said, when I manually try and install a slightly newer package, e.g. 4.0.1-4, it says I need '4.0.0' '8', which is the 4.0.0-8 package that I already have installed!!! Why won't it upgrade?
it won't upgrade cause you can't fart around with gcc libs without making it so everything is broken.
so Fedora has not figured out how to have these various libs that all are linked to libstdc++.so.6
coexist if it is even possible

this solution
Quote:

cp /opt/OpenOffice2/program/libstdc++.so.6 /usr/local/lib
if in fact that is somehow the proper libstdc++ he will then have two libstdc++.so.6 -- one in /usr/lib and one in /usr/local/lib
this could work with constant wrangling with LD_LIBRARY_PATH
this is the same as compiling the libs yourself if the version is correct
with more constant wrangling with LD_LIBRARY_PATH because of two libstdc++.so.6

it really should be the distribution that compiles a bunch of gcc versions but what it seems is a garbled mess from fedora with confusing/vague and/or misleading error messages.

The real problem is trying to install a binary compiled with a newer compiler than is the one used by the system and that is what the rpm messages should be saying to you so you understand.
you can't upgrade your compiler without borking everything.
NEW ERROR MESSAGE
(can't install gcc 4.0.1 because everything on your system is compiled with gcc-4.0.0 and we havn't figured out how to have the two coexist yet)

two solutions:
1) compile the program with the proper compiler
(this is obviously the correct solution for open source apps)
so we should be talking about how to compile TSE3

2) compile or download or copy newer libs as tuxdev said from newer compiler
(something that only seems correct for proprietary binary only no access to sourcecode situations)
 
Old 10-19-2005, 06:16 AM   #13
yekrahs
Member
 
Registered: Aug 2005
Location: England
Distribution: SUSE 10.0, LiMP (Linux Multimedia Player)
Posts: 86

Original Poster
Rep: Reputation: 15
Hmmm... I get now that the libstdc++ package was all part of the gcc compiler, and that my gcc4.0.0 is too old.
AS to the two solutions:

2) I'm not sure I'd be able to compile the newer 4.0.1 version of gcc in a different location to my gcc4.0.0 system compiler without borking everything.

Also, although copying across the newer 4.0.1version of libstdc++.so.6 from openoffice to a different folder from my existing libstdc++.so.6 would be a good solution, it'd be too fiddly for me: I wouldn't be able to competently wrangle with LD_LIBRARY_PATH.


So I think'll I have to try compiling again. Stupid Fedora. Perhaps I should submit a report, becuase this is a serious programming flaw... (Would I have had this problem by the way if I'd installed Noteedit using yum? Would it have updated my gcc to 4.0.1, or what would have happened?).



*HERE'S THE REASON I DIDN'T COMPILE*:
(besides the fact that I avoid messing with sourcecode when I can help it)
AS I said, compiling tse3 itself wasn't a problem, just compiling noteedit was. It only recognises gcc2 or gcc3. However, somebody *did* post a patch for using it on gcc4 on the noteedit website, but there was no instructions there, and I don't know what to do with it.

The link to the patch is on this page: http://developer.berlios.de/patch/?group_id=2232
Basically, what is this patch? Is it a list of instructions? Do I have to copy the contents of this file somewhere? etc.

Here's the patch itself:


diff -Naur noteedit-2.8.0-orig/configure noteedit-2.8.0/configure
--- noteedit-2.8.0-orig/configure 2005-07-11 19:17:01.000000000 +0200
+++ noteedit-2.8.0/configure 2005-09-02 14:24:01.000000000 +0200
@@ -31041,6 +31041,14 @@
_ACEOF

rm -f compvers.cc compvers.o compvers
+ elif test "X$ccversion" = "X4"
+ then
+
+cat >>confdefs.h <<\_ACEOF
+#define GCC_MAJ_VERS 4
+_ACEOF
+
+ rm -f compvers.cc compvers.o compvers
else
echo ""
echo "Cannot determine g++ version"

Last edited by yekrahs; 10-19-2005 at 06:18 AM.
 
Old 10-19-2005, 10:09 AM   #14
tuxdev
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 2,012

Rep: Reputation: 111Reputation: 111
you have to run patch
Code:
patch -p(n) < gcc4.patch
(n) represesents a strip number, probably 0, but may be 1.
You should only need to copy libstdc++.so.6 anywhere in your ld path though. And the problems with .so files in Fedora are by design, a really bad design.

Last edited by tuxdev; 10-19-2005 at 10:10 AM.
 
Old 10-20-2005, 07:41 AM   #15
yekrahs
Member
 
Registered: Aug 2005
Location: England
Distribution: SUSE 10.0, LiMP (Linux Multimedia Player)
Posts: 86

Original Poster
Rep: Reputation: 15
Thank you v much.

I didn't know Fedora had these problems. I picked it because it was a mainstream distribution (and because you can get a "For Dummies" book for it!), and because I'd heard it's not to bad for newtorking, which I may need at some point in the future.

I'm guessing other main distros don't have these issues?
I might switch to Debian, though I don't like the fact that it uses all completely non-commercial software... I'd use MEPIS instead for this, but my computer is too old.
 
  


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
FC4 doesn't have libstdc++.so.5 but libstdc++.so.6 baosheng Fedora 14 04-06-2008 10:08 AM
How to install modules? (circular dependencies!) redss Linux - Software 1 01-07-2005 03:11 PM
mismatched rpm versions of libstdc++ and libstdc++-devel pcweirdo Linux - Software 8 11-29-2004 09:30 AM
sash glibc circular dependencies twosider Mandriva 2 08-09-2004 03:58 AM
Circular dependency c0d1f1ed Linux - Software 16 03-21-2004 06:01 AM


All times are GMT -5. The time now is 10:55 PM.

Main Menu
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