|
[Sponsors] |
January 4, 2010, 02:56 |
Gnuplot installation on Ubuntu 9.10
|
#1 |
Senior Member
|
Happy new year, everyone:
I install gnuplot using: sudo apt-get install gnuplot When I begin to run the application, I get an error, saying: gnuplot: /home/energeticsaerosol/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux/lib/libstdc++.so.6: version `GLIBCXX_3.4.11' not found (required by /usr/lib/libwx_baseu-2.8.so.0) At the same time, I get the same error after I install octave: octave3.2: /home/energeticsaerosol/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux/lib/libstdc++.so.6: version `GLIBCXX_3.4.11' not found (required by /usr/lib/octave-3.2.2/liboctinterp.so) If anyone who has the similar experience, please give me a hand. Thank you. Bin |
|
January 4, 2010, 06:05 |
|
#2 | |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,715
Rep Power: 40 |
Quote:
I do not use Debian/Ubuntu, nor have I encountered this error yet, but googling with "ubuntu GLIBCXX_3.4.11 not found" I very quickly found this on the forum: http://www.cfd-online.com/Forums/openfoam-installation/69536-1-6-ubuntu-9-10-64bit-glibcxx_3-4-11-not-found.html It even has "glibcxx_3.4.11 not found" in the URL. Did you already try this? If so, and it didn't work, why didn't you post your question there instead of starting a new thread? |
||
January 4, 2010, 22:15 |
|
#3 | |
Senior Member
|
Quote:
I followed that post, and find the solution there, now I post it here so that anyone who will encounter the similar problem, just do as following: cd /home/USER_NAME/OpenFOAM/ThirdParty-1.6.x/gcc-4.3.3/platforms/linux64/lib64 sudo mv libstdc++.so.6 libstdc++.so.6.orig sudo ln -s /usr/lib/libstdc++.so.6.0.10 libstdc++.so.6 sudo mv libgcc_s.so.1 libgcc_s.so.1.orig sudo ln -s /lib/libgcc_s.so.1 check the version of libstdc++.so.6.0.x before typing and put your USER_NAME in the path. This solution is suggested by piprus. Have a good new year. Bin |
||
January 5, 2010, 21:48 |
|
#4 |
Senior Member
Hua Zen
Join Date: Mar 2009
Posts: 138
Rep Power: 17 |
Re-compiling gcc may be one better solution in my opinion.
|
|
January 19, 2010, 21:06 |
Explanation
|
#5 |
New Member
Join Date: Jan 2010
Posts: 1
Rep Power: 0 |
Under certain conditions, GCC creates a dynamic link dependency to its own internal glibc library (the one built at the time GCC was built). For example, the following code triggers the issue when compiled with -O2 (but not -O1).
#include <iostream> int main(int, char*[]){ std::cout << std::endl; return 0} If you remove the std::endl, then the dependency is not triggered. The fix is to tell the runtime linker where to find the library (libstdc++.so). You can do this in several ways. One way is to compile the search path right into the binary by adding the following flag to LDFLAGS: -Wl,-rpath,/Path/To/GCC/lib/ Another way is to add the search path when you execute the program: LD_LIBRARY_PATH="/Path/To/GCC/lib/:$LD_LIBRARY_PATH" ./some_program So to summarize, a runtime link dependency snuck into your build. The real bummer here is that it's not predictable -- you can't really know when GCC will insert this dependency. The same program compiled with different optimization flags yields a binary that no longer "runs". Some folks would call that a break in the optimization... but that's a debate for another day. The fix is band-aid the dependency by adding the runtime link path. Hope this helps to explain what happened. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Problem Installing OF 1.6 Ubuntu 9.10 (64 bit) - How to use GCC 4.4.1 | Future Science | OpenFOAM Installation | 43 | November 10, 2011 08:17 |
Installing Code_Saturne 2.0.0b on an Ubuntu 9.10 Karmic 64bits | jrmy.rbrt | Main CFD Forum | 0 | November 20, 2009 15:19 |
ubuntu 9.10 64bit - wmake missing headers | soeren87 | OpenFOAM Installation | 5 | November 11, 2009 11:01 |
OpenFOAM Installation Ubuntu 9.04 Problems | Sumontro | OpenFOAM Installation | 8 | July 21, 2009 22:40 |
Adventure of fisrst openfoam installation on Ubuntu 710 | jussi | OpenFOAM Installation | 0 | April 24, 2008 15:25 |