- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I'm trying to build with static link to IPP using g++. I read on this forum I need to provide the full path to lib files /opt/intel/ipp/lib/libippac.a etc. so I'm doing that. However I'm getting linker errors such as this:
Undefined symbols for architecture i386:
"___libm_sse2_atanf", referenced from:
_px_ippsArctan_32f_I in libipps.a(psatan_px---ippsArctan_32f_I.o)
What am I doing wrong?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I just solved it. I had to link to the following libraries also:
/opt/intel/composerxe/lib/libsvml.a
/opt/intel/composerxe/lib/libirc.a
/opt/intel/composerxe/lib/libimf.a
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Vilhelm,
What if you add "-lm" to the "g++" command line? That is, to add compiler's libm.a library to the linking process?
Regards,
Sergey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That doesn't help. From what I understand libm.a is not available as a separate static library on OSX, see here: http://stackoverflow.com/questions/6240639/where-is-the-standard-c-library-on-mac-os-x
The compiler should instead implicitly link to math routines in libSystem.dylib. And maybe that lib does not contain sse2-specific routines like ___libm_sse2_atanf that the linker complains about?
This document seems relevant to my problems: http://software.intel.com/en-us/articles/unresolved-external-symbol-libm-sse2
However this is for an older version of IPP and it suggests that IPP comes with special optimized version of libm.lib. But I cannot find any such files to link to in my IPP OSX install.
Here is my current command line:
g++ -shared -L/opt/intel/ipp/lib [...my .o files...] -m32 -lm /opt/intel/ipp/lib/libippcore.a /opt/intel/ipp/lib/libippi.a /opt/intel/ipp/lib/libippac.a /opt/intel/ipp/lib/libippcc.a /opt/intel/ipp/lib/libippch.a /opt/intel/ipp/lib/libippcv.a /opt/intel/ipp/lib/libippdc.a /opt/intel/ipp/lib/libippdi.a /opt/intel/ipp/lib/libippj.a /opt/intel/ipp/lib/libippm.a /opt/intel/ipp/lib/libippr.a /opt/intel/ipp/lib/libipps.a /opt/intel/ipp/lib/libippsc.a /opt/intel/ipp/lib/libippvc.a /opt/intel/ipp/lib/libippvm.a
Any other idea? I really want to get this working.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I just solved it. I had to link to the following libraries also:
/opt/intel/composerxe/lib/libsvml.a
/opt/intel/composerxe/lib/libirc.a
/opt/intel/composerxe/lib/libimf.a

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