Community
cancel
Showing results for 
Search instead for 
Did you mean: 
ltkeene
Beginner
144 Views

Can't link to IPP 6.1

Hello all,

I'm having difficulty setting up my environment to use the trial version of IPP that I've recently downloaded. I'm using VC2008. So far, the only IPP functionality I've got in my app is the following memory allocation:

Ipp32f* buffer1 = ippsMalloc_32f(bufferLength);
ippSetNumThreads(1);

I've run the ippenv.bat file. I've also run the example application that comes with IPP and that's working as well. I;ve set my environment variable as follows:

Control Panel -> System -> Advanced -> Environment Variables , and in the System variables group box I edit the "lib" variable by appending: "c:\Program Files\Intel\IPP\6.1.1.035\ia32\stublib".

I've also altered the project settings of my app by selecting "Configuration properties -> Linker -> General -> Additional librariy directories" and inserting the same path to the stublib folder.

I've added a couple of includes ("ipps.h" and "ippcore.h") and I'm able to compile, but I'm getting linker errors such as:

error LNK2019: unresolved externel symbol _ippSetNumThreads@4 referenced in function...

What have I failed to do? Thanks in advance.
0 Kudos
9 Replies
fanguts
Beginner
144 Views

Quoting - ltkeene
Hello all,

I'm having difficulty setting up my environment to use the trial version of IPP that I've recently downloaded. I'm using VC2008. So far, the only IPP functionality I've got in my app is the following memory allocation:

Ipp32f* buffer1 = ippsMalloc_32f(bufferLength);
ippSetNumThreads(1);

I've run the ippenv.bat file. I've also run the example application that comes with IPP and that's working as well. I;ve set my environment variable as follows:

Control Panel -> System -> Advanced -> Environment Variables , and in the System variables group box I edit the "lib" variable by appending: "c:Program FilesIntelIPP6.1.1.035ia32stublib".

I've also altered the project settings of my app by selecting "Configuration properties -> Linker -> General -> Additional librariy directories" and inserting the same path to the stublib folder.

I've added a couple of includes ("ipps.h" and "ippcore.h") and I'm able to compile, but I'm getting linker errors such as:

error LNK2019: unresolved externel symbol _ippSetNumThreads@4 referenced in function...

What have I failed to do? Thanks in advance.

Libs path should be set from Tool->Option->solution/project->VC++Dir
ltkeene
Beginner
144 Views

Quoting - fanguts

Libs path should be set from Tool->Option->solution/project->VC++Dir

Thank you for the reply. I've done the following:

"Tools -> Options -> Projects and solutions -> VC++ Directories", selected "Library files" in the drop-down list, and added

"C:Program FilesIntelIPP6.1.1.035ia32stublib" to the list box.

I get the same linker errors. Any other thoughts anyone? Thank you.

-L
ltkeene
Beginner
144 Views

I should also note that I am trying to link dynamically, not statically.
ltkeene
Beginner
144 Views

Quoting - ltkeene
I should also note that I am trying to link dynamically, not statically.

By examining the setup of one of the samples,I added the following to the "Additional dependencies" edit box:

ipps.lib ippcore.lib

I didn't see these listed in the install instructions, but it seems to be linking now. Not sure if this is the correct setup, however.

-L
fanguts
Beginner
144 Views

Quoting - ltkeene

By examining the setup of one of the samples,I added the following to the "Additional dependencies" edit box:

ipps.lib ippcore.lib

I didn't see these listed in the install instructions, but it seems to be linking now. Not sure if this is the correct setup, however.

-L

correct
ltkeene
Beginner
144 Views

Quoting - fanguts

correct

Unfortunately, the problem has arisen again. I've changed my include statements to only:

#include "ipp.h"

and in my code I am calling the sinc kernel function "ippsSinc_32f(...)". I'm getting linker errors again:

"error LNK2019: unresolved external symbol _ippsSinC_32f@12 referenced in function..."

Something is just wrong with what I've done with my project settings. I've followed the instructions on page 2-10 of the Intel IPP User's Guide regarding setting the environment variables. I've added "ipps.lib ippcore.lib" in the Additional Dependencies edit box. What have I missed now? The instal/linking instructions for IPP definately need some streamlining. Any more ideas anyone? As always, thanks.

-L
ltkeene
Beginner
144 Views

Quoting - ltkeene

Unfortunately, the problem has arisen again. I've changed my include statements to only:

#include "ipp.h"

and in my code I am calling the sinc kernel function "ippsSinc_32f(...)". I'm getting linker errors again:

"error LNK2019: unresolved external symbol _ippsSinC_32f@12 referenced in function..."

Something is just wrong with what I've done with my project settings. I've followed the instructions on page 2-10 of the Intel IPP User's Guide regarding setting the environment variables. I've added "ipps.lib ippcore.lib" in the Additional Dependencies edit box. What have I missed now? The instal/linking instructions for IPP definately need some streamlining. Any more ideas anyone? As always, thanks.

-L

Seems I had to add "ippsr.lib" to the Additional Dependencies directive. For anyone who's having similar trouble, this Intel doc was helpful:

http://software.intel.com/en-us/articles/building-a-windows-application-using-intel-ipp/
Sergey_K_Intel
Employee
144 Views

Yes, sometimes it's hard to determine what library to add to the project. I usually simply search for the undefined symbol among IPP library files or among include files. In your case "ippsSinC_32f" is declared in "ippsr.h", so I would add "ippsr.lib" to the project :).
Regards,
Sergey

Vladimir_Dudnik
Employee
144 Views

Whenlook forfunction namein IPP manual you may find that it specifies which header file function is declared. Then we usually have direct correspondence to the library name where this function is defined. For example, if function declared in ippi.h file then you need to link with ippi library.

The only exception from this rule functions from ippg (generated domain) which declared in ipps.h file but defined in ippg library.

Regards,
Vladimir
Reply