- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have software I compile on both itaniums and pc's with the intel C and Fortran compilers
My problem is with compiling a dynamic library on an itanium ( on a i686 this works) using the latest v8 compiler. "intel-ifort8-8.0-57.ia64 .rpm"
I have a library consisting of mainly fortran objects and one c object -> all compiled with intel compilers with the -fpic options set.
but at the linking stage all I get either a :
a) "ld: cfile.o: @gprel relocation against dynamic symbol c_variable" ERROR
b) the linker pauses indefinitely ( until I kill it > 1 hour )
I have tried various options such as using either ifort or ld as the linker and also passing the options -i_dynamic and -nofor_main. I always pass the option -shared.
but no luck with these incantations.
I passed the -v option to the linker (ifort) and the following is the result ( have removed some o files for clarity.)
ld /usr/lib/crti.o /home/me/opt/intel_fc_80/lib/crtxi.o -shared --version-script /home/me/opt/intel_fc_80/lib/icrt.internal.map -o libmine.so -relax addme.o edgend4.o -Qy -L/home/me/opt/intel_fc_80/lib -L/usr/lib -lifport -lifcoremt -ldl -limf -lm -lcxa -lunwind -u __pthread_once -lpthread -lirc -lc -lirc /home/me/opt/intel_fc_80/lib/crtxn.o /usr/lib/crtn.o
ld: edgend4.o: @gprel relocation against dynamic symbol Rnd64_fact
"Rnd64_fact" is a variable declared in my c file.
any ideas ?
J
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
gprel relocation
Error Messages on Itanium-based Linux Systems
On Itanium-based systems running Linux, when the -shared switch is used to create a Dynamic Shared Object (.so), there may be some "relocation against dynamic symbol" messages generated during the ld phase, similar to:
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__segv_default_msg
...
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_fpe_mask
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_undcnt
To fix this problem, add the switches -i_dynamic
and -nofor_main
to the command line.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
they didn't help.
- 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
Thanks anyway Steve, sorry I was a bit short earlier - late nights & these problems don't mix :/
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
gprel relocation
Error Messages on Itanium-based Linux Systems
On Itanium-based systems running Linux, when the -shared switch is used to create a Dynamic Shared Object (.so), there may be some "relocation against dynamic symbol" messages generated during the ld phase, similar to:
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__segv_default_msg
...
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_fpe_mask
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_undcnt
To fix this problem, add the switches -i_dynamic
and -nofor_main
to the command line.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
gprel relocation
Error Messages on Itanium-based Linux Systems
On Itanium-based systems running Linux, when the -shared switch is used to create a Dynamic Shared Object (.so), there may be some "relocation against dynamic symbol" messages generated during the ld phase, similar to:
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__segv_default_msg
...
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_fpe_mask
/usr/bin/ld: for_init.o: @gprel relocation against dynamic symbol for__l_undcnt
To fix this problem, add the switches -i_dynamic
and -nofor_main
to the command line.
if you are using intel fortran comiler "ifort" then this switch i.e. -i_dynamic and -nofor_main will work and if you are using gcc compiler then you should use -fPIC switch whilecompiling for object file .o file and then go forshared object file.so file.
thanks....
![](/skins/images/DC0E2679F7049B943291D1ED082A478E/responsive_peak/images/icon_anonymous_message.png)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page