Problem with linking IPP libraries

Problem with linking IPP libraries

I am trying to compile a program which uses functionippsMalloc_8u. I believe this function is from ipps library. But I am getting following error:

gcc ipp0.c -L/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64/ -lippcore -lipps
/usr/bin/ld: warning: libiomp5.so, needed by /opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64//libippcore.so, not found (try using -rpath or -rpath-link)

/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64//libippcore.so: undefined reference to `omp_get_max_threads@VERSION'

.

.

.
undefined reference to `kmp_create_affinity_mask@VERSION'/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64//libippcore.so: undefined reference to `kmp_get_affinity@VERSION'

collect2: ld returned 1 exit status

The filelibiomp5.so is present in the same directory (/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64/)But how should I link it while compiling the code?

3 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.

Quoting Lincoln GreenhillI am trying to compile a program which uses functionippsMalloc_8u. I believe this function is from ipps library.

[SergeyK] Yes, that's correct. That function is from a Signal Processing domain.

But I am getting following error:
- collapse sourceview plaincopy to clipboardprint?

  1. gccipp0.c-L/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64/-lippcore-lipps
  2. /usr/bin/ld:warning:libiomp5.so,neededby/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64//libippcore.so,
    notfound(tryusing-rpathor-rpath-link)
  3. /opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64//libippcore.so:undefinedreferenceto`omp_get_max_threads@VERSION'

    [SergeyK] Have you seen that warning?

Best regards,
Sergey

Hi Lincoln

In general, a common command to build ipp program like :

gcc main.cpp -I/opt/intel/composer_xe_2011_sp1.10.319/ipp/include -L/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64/ -L/opt/intel/composer_xe_2011_sp1.10.319/compiler/lib/intel64-lipps -lippcore -liomp5

The OpenMP library libiomp5is from Intel Compiler, located in Compilerlib directory. But if you haveitpresented inIPP directory, the command can be
gcc main.cpp -I/opt/intel/composer_xe_2011_sp1.10.319/ipp/include -L/opt/intel/composer_xe_2011_sp1.10.319/ipp/lib/intel64/ -lipps -lippcore -liomp5

Thelibiomp5.soshould be linked explicitly.

Best Regards,
Ying

Laisser un commentaire

Veuillez ouvrir une session pour ajouter un commentaire. Pas encore membre ? Rejoignez-nous dès aujourd’hui