CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   code compilation problem with wmake (https://www.cfd-online.com/Forums/openfoam-programming-development/108129-code-compilation-problem-wmake.html)

bmikuz October 15, 2012 10:54

code compilation problem with wmake
 
Hello everyone,

I tried to compile a "test" program with wmake in OpenFoam1.7.1 which is installed on SUSE LINUX enterprise server 11 SP1 operating system. When I applied the wmake command, the error was found:

Quote:

/usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../x86_64-suse-linux/bin/ld: cannot find -liberty
collect2: ld returned 1 exit status
make: *** [/home/r4/mikuz/OpenFOAM/mikuz-1.7.1/applications/bin/linux64GccDPOpt/pisoFoamBlaz] Error 1
Then gdb and binutils utilities were added to the system and the error was avoided but another problem arised. Using wmake again, I get the error:

Quote:

/opt/openfoam171/lib/linux64GccDPOpt/libincompressibleTurbulenceModel.so: undefined reference to `std::ctype<char>::_M_widen_init() const@GLIBCXX_3.4.11'
collect2: ld returned 1 exit status
Does anybody know how to solve the problem? Thanks a lot for your help!
Blaz

bmikuz October 16, 2012 11:13

To be more specific: the system has installed gcc version 4.3.4 and it seems that it uses GLIBCXX_3.4.10, which is too old. So we installed gcc version 4.5.0, which uses GLIBCXX_3.4.14, but I don't know how to switch openfoam from using the older to newer gcc and GLIBCXX?
Can anybody explain how switching the gcc (and GLIBCXX) is properly done?

marupio October 17, 2012 09:30

This sounds like that linking issue, but it started with GCC4.6. It has been fixed in 2.x.x and in 1.6-ext. Here's a 1.6-ext patch I threw into the repo a while back that addressed it. Maybe it will help...?

http://openfoam-extend.git.sourcefor...ed079f96c1c0b7

-Dave


All times are GMT -4. The time now is 06:51.