- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, I have a problem with -static-intel option. there is a link error.
ifort -O2 -fpic -shared -nofor_main -Wl,-rpath,'$ORIGIN' -o libFBAPICS.so -L/opt/intel/composer_xe_2011_sp1.9.293/mkl/include -L. -lstdc++ -static-intel /opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libifcore_pic.a /opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libifport.a /opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libimf.a /opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libsvml.a ADDRESS.o ld: /opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libifcore.a(for_close.o): relocation R_X86_64_32 against `.rodata.str1.4' can not be used when making a shared object; recompile with -fPIC
/opt/intel/composer_xe_2011_sp1.9.293/compiler/lib/intel64/libifcore.a: could not read symbols: Bad value
make: *** [FBAPICS] Error 1
i have tried libifcoremt_pic.a also but it doesnt work.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for your kind answer. It works.
Can I ask you one more?
Actually, I want to make my so linked statically. Intel fortran's library is removed with your help.
But there are still these libraries.
linux-vdso.so.1 => (0x00007fff5f9ff000)
libm.so.6 => /lib64/libm.so.6 (0x00007f11f5b4f000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f11f5931000)
libc.so.6 => /lib64/libc.so.6 (0x00007f11f55d3000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007f11f53cf000)
/lib64/ld-linux-x86-64.so.2 (0x00007f11f6ef1000)
I have tried -static-libgcc // -no-cxxlib but it doesnt work.
Am i missing something?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The -static option will cause ld to prefer the static library alternative to the linux shared libraries, if both are installed. Lately, several major linux distros have been set up so that several of those static libraries will not be installed by default. You would need to search your linux installation media and online upgrade repositories to find them.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page