undeclared identifier '__builtin_ia32_addss'

Hi,

I am trying to a big program. It has a lot of files and so can't upload the code. One of the file called is the emmintrin.h which calls xmmintrin.h. Both these files are include files gcc.

When i run my code on red hat linux, i do not get any compile time error.
When i run my code on a mac os x, however, i get a list of errors

/usr/lib/gcc/i686-apple-darwin11/4.2.1/include/xmmintrin.h:128:19: error: use of undeclared identifier
'__builtin_ia32_addss'
return (__m128) __builtin_ia32_addss ((__v4sf)__A, (__v4sf)__B);
^
/usr/lib/gcc/i686-apple-darwin11/4.2.1/include/xmmintrin.h:136:19: error: use of undeclared identifier
'__builtin_ia32_subss'
return (__m128) __builtin_ia32_subss ((__v4sf)__A, (__v4sf)__B);
^
/usr/lib/gcc/i686-apple-darwin11/4.2.1/include/xmmintrin.h:144:19: error: use of undeclared identifier
'__builtin_ia32_mulss'
return (__m128) __builtin_ia32_mulss ((__v4sf)__A, (__v4sf)__B);

Does any one know how to fix this ? emmintrin.h is called through a file from the opencv library.
Thanks!!

~Fred
Thanks
I have not installed clang myself and don't think the library is using it (unless i am mistaken) since the opencv library was installed without any problems.
I had read the clang post earlier but frankly could not understand what solution it suggests or how i can make use of the solution for my own.

One other thing is that I can't see the declaration of the functions in any other files when i do a grep in that directory '/usr/lib/gcc/i686-apple-darwin11/4.2.1/include'.
Do i need to install something else for this ?


Xcode will have installed clang for you.

I don't know what your program requirements are, so I can't really comment on whether you need to install something or not. But the error isn't related to missing things (I think), it relates to project config but I can't be sure because you've not described your environment.
Topic archived. No new replies allowed.