I'm using MinGW, do I need IPP for Windows or for Linux?

I'm using MinGW, do I need IPP for Windows or for Linux?

Hello everyone!

I'm planning to use the IPP library on a MinGW environnement (GCC 4.5 on Windows).

I just want to be sure, which version of the IPP library do I actually need :

IPP for windows or IPP for linux ?

Thanks in advance for your reply!


16 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Add the following:

#ifdef __MINGW32__

#if 0
extern "C" {
int __security_cookie;

extern "C" void _fastcall __security_check_cookie(int i) {
//do nothing
extern "C" void _chkstk() {
//do nothing
extern "C" void _allmul() {
//do nothing
#endif //__MINGW32__

I remember I had to do some other changes too, specially there are some assembly lines that need to check for MingW compiler, and use the other apth.

Hello Josh,

No guarantees, since I'm not familiar with the MinGW environment, but based on the description on their web site it sounds like you should be using the Windows version of IPP. You can download and install an evaluation copy of the library to test this theory.


Hello Paul, thanks for your answer!

I've actually given a try with the windows version of IPP 6.1 (the evaluation version available just right on the intel website) and my test program using IPP linked as a charm on my MinGW32 environment (GCC 4.5) !

my makefile.am

bin_PROGRAMS = ipp_test

ipp_test_SOURCES = ipp_test.cpp
ipp_test_LDADD = -Lc:/Intel/IPP/ -lippsemerged -lippsmerged -lippcore -lm

INCLUDES = -Ic:/Intel/IPP/

my program : ipp_test.cpp (do a FFT example from the IPP manual)


#include "ipps.h"

IppStatus ftt_ipp()
Ipp32f x[8], X[10];

int i;
IppStatus status;
IppsFFTSpec_R_32f* spec;

status = ippsFFTInitAlloc_R_32f(&spec, 3, IPP_FFT_DIV_INV_BY_N, ippAlgHintNone);

for(i=0; i<8; ++i) x[i] = (float)cos(IPP_2PI * i * 16 / 64);

status = ippsFFTFwd_RToCCS_32f(x, X, spec, NULL );

ippsMagnitude_32fc((Ipp32fc*)X, x, 4 );

printf("\n\nftt_ipp_magnitude = ");
for(i=0; i<4; i++) printf("\n%d) %f", i, x[i]);

ippsFFTFree_R_32f( spec );
return status;

Have a nice week-end :)


Hello Josh,

Glad to hear that it worked! Will keep that MinGW development environment in mind as an alternative for others to try out.


I'm trying to make a similar experiment with IPP libs in MinGW.
My source file .c is simpler and contains just a call to 'ippStaticInit()' and nothing else.

I can compile and link fine and get an .exe file with no error messages. The command is:

gcc -IC:/msys/1.0/opt/intel/win/Installs/IPP -include /opt/intel/win/Installs/IPP/ipp_w7.h -march=pentium4 -o test.exe test.c -LC:/msys/1.0/opt/intel/win/Installs/IPP -lippcore -lippscmerged -lippsrmerged -lippsmerged -lm

But as I launch the .exe it prompts the error:

"This application has failed to start because ippcore-6.1.dll was not found. Re-installing the application may fix th is problem."

That .dll is just inside the path where the other .lib are.

Maybe I'm missing some environment variable?


Hello "az037sn":

The DLL files on a 6.1 installation are found in the ...\ipp\bin\ directory (within your install). The PATH environment variable needs to include this directory in the path. If you goto the ...\ipp\tools\env\ directory you'll find a batch file you can run that will setup your environment to work for development and testing.

I assume the core environment works within the MinGW environment. But since I am not experienced at using this environment, I cannot say for sure. Perhaps there are some additional steps you need to take to insure that the PATH is found? Or perhaps the MinGW environment wants to use the LD_PATH variable, which is relevant to UNIX/Linux environments but not Windows when searching for shared libraries...


Yes, it works! I added to the Path env variable the path where the dll lies.

Thanks alot, Paul.

Here me back again, I have another problem.
I'm still posting in this same thread because I guess it can deal with Msys+MinGW environment.

I'm going further with my small app. I've added further IPP api calls like

ippStaticInit, apiG729Decoder_Alloc, ippSetFlushToZero, ippsMalloc_8u, apiG729Decoder_InitBuff, apiG729Decoder_Init, G729ADecode (in file 'decg729.c), ..

My list of libs is now:

-lippscmerged -lippsrmerged -lippsmerged -lippcore -lm

when I try to compile I get a very long list of errors referring to security_cookie() and the like :

c:/intel/IPP/[_w7_ippsShortTermPostFilter_G729_16s@16]+0x28): undefined reference to `__security_cookie'
c:/intel/IPP/[_w7_ippsShortTermPostFilter_G729_16s@16]+0x186): undefined reference to `@__security_check_cookie@4'

Should I add some other lib to the list?


This is something that the compiler puts on the stack to detect buffer overruns. I believe there's a compiler library you need to link with. See this article for more information, plus I'm sure you can find something on MSDN regarding it:


I copied the MS-SDK (2002 edition) libs locally and added
to the list of libs.
Now the long list os linker messages related to security_cookie and security_check_cookie have disappeared!

But I get 4 new error messages for _allmul symbol:

c:/Program Files/Intel/IPP/[_w7_ippsLongTermPostFilter_G729_16s@20]+0x497): undefined reference to `_allmul'
c:/Program Files/Intel/IPP/[_w7_ippsLongTermPostFilter_G729_16s@20]+0x4ae): undefined reference to `_allmul'
c:/Program Files/Intel/IPP/[_w7_ippsLongTermPostFilter_G729_16s@20]+0x4f8): undefined reference to `_allmul'
c:/Program Files/Intel/IPP/[_w7_ippsLongTermPostFilter_G729_16s@20]+0x50f): undefined reference to `_allmul'
collect2: ld returned 1 exit status

I think _allmul symbol is resolved into 'msvcrt.lib' which is in the PC if you installed MS VisualStudio.
I added this file to the list:
This time I get errors like:

c:/mingw/bin/../lib/gcc/mingw32/4.4.1/../../../crt2.o:crt1.c:(.text+0x7): undefined reference to `_imp__atexit'
c:/mingw/bin/../lib/gcc/mingw32/4.4.1/../../../crt2.o:crt1.c:(.text+0x17): undefined reference to `_imp___onexit'
c:/mingw/bin/../lib/gcc/mingw32/4.4.1/../../../crt2.o:crt1.c:(.text+0xc7): undefined reference to `_imp___iob'

As an alternative, is it possible to get a version of 'ippscmerged.lib' compiled without the security cookie option? I guess the compiler option is /GS.


Based on your posts it sounds like you do not have any Microsoft compilers installed on your system. Maybe you should install the free express version of the Microsoft compiler. I've not installed it, but I assume it should contain the missing CRT and other lib files you are searching for.

As far as I know, Microsoft Visual Studio redistributable libraries available for download at Microsoft site free, for example libraries for IA32 Visual Studio 2008 available by the link below



Well, I adopted a dirty trick solution, I added a self-made 'allmul()' function to my source code and it compiles and seems to work fine!

I've got a further question.

Is there a way to link anything as static so that when the app starts doesn't need any .dll like 'ippcore-6.1.dll' ?

The command line I'm using is:

gcc -Xlinker -x -D_GNU_SOURCE -I c:/Intel/IPP/ -include c:
/Intel/IPP/ -march=pentium4 -o test test.c decg729.c encg729.c owng729.c vadg729.c aux_tbls.c -L c:/Intel/IPP/ -L c:/Intel/IPP/ -lippscmerged -lippsrm
erged -lippsmerged -lippcore -Lc:/MS_libs/sdk -lbufferoverflowU


I have no idea what "parts and pieces" are on your system as the result of using the MinGW environment, so the following suggestions may not work...

You might try using the -static option or the -static-libgcc option.

Also, might be useful to use the -nodefaultlibs option if you want to have complete control over all libraries that are linked in.

See http://gcc.gnu.org/onlinedocs/gcc/Link-Options.htmlfor more help on GCC options.

Hello Guys,

I have been trying to build Opencv 3.0 with its IPP_ICV inbuilt package and TBB using Mingw 4.8.2 x64 in windows. Whenever, I set this option in Cmake WITH_IPP=ON that time I got following error.

Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/umatrix.cpp.obj [ 32%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/opencl_kernels_core.cpp.obj Linking CXX shared library ....\bin\libopencv_core300.dll c:/mingw/bin/../lib/gcc/mingw64/4.8.1/../../../../mingw64/bin/ld.exe: cannot find -lRunTmChk collect2.exe: error: ld returned 1 exit status modules\core\CMakeFiles\opencv_core.dir\build.make:1260: recipe for target 'bin/libopencv_core300.dll' failed mingw32-make[2]: * [bin/libopencv_core300.dll] Error 1 CMakeFiles\Makefile2:1334: recipe for target 'modules/core/CMakeFiles/opencv_core.dir/all' failed mingw32-make[1]: * [modules/core/CMakeFiles/opencv_core.dir/all] Error 2

If anybody have any idea regarding this issue then share it with me. Any help would be appreciated.


Tushar Kachhadiya

Leave a Comment

Please sign in to add a comment. Not a member? Join today