I noted this error was reported before. I updated to OpenSuse 12.3 and when I try to compile one of my codes I get this error.
/usr/lib64/gcc/x86_64-suse-linux/4.7/…/…/…/…/x86_64-suse-linux/bin/ld: con_var.o: undefined reference to symbol ‘dlclose@@GLIBC_2.2.5’
/usr/lib64/gcc/x86_64-suse-linux/4.7/…/…/…/…/x86_64-suse-linux/bin/ld: note: ‘dlclose@@GLIBC_2.2.5’ is defined in DSO /lib64/libdl.so.2 so try adding it to the linker command line
/lib64/libdl.so.2: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status’
Did you run configure previously against an earlier version of glibc prior to your upgrade to Suse 12.3 (which also upgraded your version of libc)? If so, your make might be trying to reference an earlier glibc version.
Can you do a make clean and a new configure?
If that does not work, can you verify what version of glibc your using with ldconfig --version and provide more information on what you are compiling?
No. I did not. I am rather new to this. How I do a make clean?
As I was looking into a similar issue I did try to add the option -ldl to my flags and that seems to work, but I am not sure why.
ULFLAGS="-L/usr/X11R6/lib -lm -lX11 -lrt -ldl"
However I am afraid that the options does something unxpected. Do you think there is a way to get the old library. I am pretty sure the compilation worked wha I had OS 11.4
I am now suspecting the problem is in the intel compiler that may be pointing to an old version of the library not in sync which opensuse 12.3 which is based off glibc 2.17
Can that be possible?
If adding -ldl allowed it to link, they your likely not having an issue with the version of glibc as it compiled okay, and the linker found all the libs. What issue are you still seeing?
While technically you can build an older version of glibc and link against it, I really don’t think that is the direction you should take.
I’m also just sort of shooting in the dark here, as I don’t know what your compiling and have no output, etc.
Does the software your building have a ‘configure’ script to run? Or is it built with some other build system, etc.?
If you have a configure script (and want to try a new build) then I would suggest running make clean, followed my ./configure and then make. Doing so may locate the correct lib locations, etc. during the configure.