Hi,
I was wondering about something (logic since i post here)
I recently installed the intel c++ compiler and for this i need to set some environment variables. I have to add the libraries of intel to LD_LIBRARY_PATH. Now here is the thing I was wondering about.
If I set this environment, how does this thing know if it has to use the libraries of gnu or those from intel?
The reason i ask this is that intel does not use its own libraries. Compiling a simple program clearly showed this.
Code:
#include<iostream>
int main(void) {
std::cout << "flubber" << std::endl;
return 1;
}
Checking the used shared libraries gave the following
Code:
[]$ g++ hello.cpp
[]$ ldd a.out
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00002afd01552000)
libm.so.6 => /lib64/libm.so.6 (0x00002afd01753000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00002afd018a9000)
libc.so.6 => /lib64/libc.so.6 (0x00002afd019b7000)
/lib64/ld-linux-x86-64.so.2 (0x00002afd01437000)
[]$ icpc hello.cpp
[]$ ldd a.out
libm.so.6 => /lib64/libm.so.6 (0x00002b5cb279e000)
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00002b5cb28f4000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00002b5cb2af5000)
libcxaguard.so.5 => /usr/local/intel/cce/9.1.042/lib/libcxaguard.so.5 (0x00002b5cb2c03000)
libc.so.6 => /lib64/libc.so.6 (0x00002b5cb2d04000)
libdl.so.2 => /lib64/libdl.so.2 (0x00002b5cb2f3e000)
/lib64/ld-linux-x86-64.so.2 (0x00002b5cb2683000)
You see that intel uses all the gnu libraries and links them together with libcxaguard. The question is, why? could anybody help me out here?