LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   what is libstdc++.so file (https://www.linuxquestions.org/questions/linux-newbie-8/what-is-libstdc-so-file-604929/)

babu198649 12-06-2007 08:23 AM

what is libstdc++.so file
 
hi
what is libstc++.so file?
does it belongs to gcc.(ie )does it ships with gcc compiler

what for different versions of libstdc++.so(such as libstdc++.so.6)are for.

does all the versions of libstdc++.so.x should point to libstdc++.so

when does a link is said to be broken and what is the meaning of broken link.

why these files are always associated with linker problems.

thanks

acid_kewpie 12-06-2007 08:47 AM

libstdc++ is the standard c++ library. ie.. that's the definition of standard library functions for all code written in c++. the different versions are just that... versions, so you could need a v5 or v6 library these days depending on the code you are writing. generally you'd only require a version 5 library for older precompiled packages. anything new would just be linked against the standard version 6 object. they are often related to linker issues as that's the first and most important library for c++.

babu198649 12-06-2007 11:22 PM

thank u acid_kewpie
now i have Qt and vsipl++ libraries(both are c++ libraries)

but i can compile Qt without any problem


but linking vsipl++ libraries creates problem
it gives the following message

[bharani@localhost examples]$ ./example1 ./example1: /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by ./example1)

dwhitney67 12-07-2007 12:29 AM

Did you compile the vsipl++ library on your system, or did you just download the binaries from some website? You may want compile it (the source code) on your local system as you did Qt.

I should further add that the last statement in your post does not offer many clues at all as to which example you are attempting to run. Is it a Qt example? Or something you created? If the latter, it might be helpful to see how you compiled the executable example1.

acid_kewpie 12-07-2007 02:14 AM

you'd need to upgrade glibc to 3.4.9 to link against that. note that the libstdc++ version (6.0.3 etc...) is a different versioning scheme to the glibc package itself...

babu198649 12-07-2007 05:34 AM

yes dwhitney67 u r right .

before installing vsipl++ binary package i compiled and installed (usual procedure ./configure,make,make install) the vsipl++ library(source code package) it worked fine .

but after installing the binary package linkage error occured(i just tried installing the binary package as i had never tried installing any binary package)

Quote:

Is it a Qt example? Or something you created?
No.no problem with Qt. What i meant was both Qt and vsipl++ libraries are C++ libraries but Qt works fine whereas vsipl ++ gives linking error.


Quote:

you'd need to upgrade glibc to 3.4.9 to link against that. note that the libstdc++ version (6.0.3 etc...) is a different versioning scheme to the glibc package itself...
where to get glibc and what are the commands needed

douglasheld 09-16-2008 09:17 AM

Where to get glibc
 
"where to get glibc and what are the commands needed?"


If you can supply the Linux distribution you are running, and its version the people on this forum can tell you how to install glibc.

acid_kewpie 09-16-2008 10:13 AM

douglasheld, welcome to LQ, but i'd advise against resurrecting threads which haven't been touched for more than 6 months.

sundialsvcs 09-16-2008 08:53 PM

Here's a high-level snapshot of the most important ideas here ...
  1. All programs rely upon the existence of many libraries, which contain pre-written, presumably well-tested subroutines that the programs can therefore simply "rely upon."
  2. In the Linux/Unix systems, you can easily have multiple versions of the same library installed at the same time. Through a simple system of file-names ("that's what the '.6' is for..."), the libraries can be found without conflict by the programs that need them. Programs can be very-generic or very-specific as to their requirements. The library files themselves also contain version-information so the linker can be sure that the library-file it has found is compatible.
  3. One program might compile just fine, because the version it needs is available, while another program doesn't.
  4. A "broken link" occurs when the linker cannot find a compatible subroutine in a compatible library to fulfill the program's stated requirements.


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