Community
cancel
Showing results for 
Search instead for 
Did you mean: 
frenet
Beginner
77 Views

Linking problems with IPP 7 in Ubuntu 11.10

Jump to solution

I'm moving from IPP6 to IPP7 and am having issues when linking an application to my shared object (which links to the ipp libraries). I had similar problems with IPP6 (http://software.intel.com/en-us/forums/showthread.php?t=82491) but now am having issues on both 32 and 64-bit linux and I cannot seem to resolve this the same way.

I am statically linking to the ipp, umc & uic libraries. I am using IPP 7.0.4.191 and have downloaded the 7.05.059 sample code. I am using g++.

I can build my own shared object that statically links to ipp and umc, but when I try to build an application that links to my shared object, I get link errors.

Originally I was getting the following errors when building the application (first few errors):

/usr/bin/ld: warning: libiomp5.so, needed by ../../lib/libfrenet.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libintlc.so.5, needed by ../../lib/libfrenet.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libimf.so, needed by ../../lib/libfrenet.so, not found (try using -rpath or -rpath-link)
../../lib/libfrenet.so: undefined reference to `omp_get_max_threads@VERSION'
../../lib/libfrenet.so: undefined reference to `GOMP_parallel_sections_start@VERSION'
../../lib/libfrenet.so: undefined reference to `omp_init_lock@VERSION'
../../lib/libfrenet.so: undefined reference to `__kmpc_barrier@VERSION'

I then set my LD_LIBRARY_PATH to point to the directory containing libiomp,libintlc andlibimf and now get the following error when building my app:

/opt/intel/ipp/7.0.4.191/compiler/lib/ia32/libiomp5.so: undefined reference to `pthread_atfork'

I do have -lpthread specified for both the shared object and the application, but the error still occurs. Below is the link info for my shared object:

UIC_LIBS = "${UIC_IMAGE_DIR}/_bin/$(UIC_LIB_ARCH)/lib/uic_core_l.a" \\

"${UIC_IMAGE_DIR}/_bin/$(UIC_LIB_ARCH)/lib/uic_io_l.a" \\
"${UIC_IMAGE_DIR}/_bin/$(UIC_LIB_ARCH)/lib/uic_jpeg_enc_l.a" \\
"${UIC_IMAGE_DIR}/_bin/$(UIC_LIB_ARCH)/lib/uic_jpeg_dec_l.a" \\
"${UIC_IMAGE_DIR}/_bin/$(UIC_LIB_ARCH)/lib/uic_jpeg_common_l.a"

UMC_LIBS = "${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libmpeg4_mux.a" \\

"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libscene_analyzer.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libh264_enc.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libcolor_space_converter.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libumc_io.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libmedia_buffers.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libcommon.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libumc.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libvm_plus.a" \\
"${UMC_AVCODEC_DIR}/_bin/$(UMC_LIB_ARCH)/lib/libvm.a"

IPP_STATIC_LIBS = -L/work/netcdrom/Intel/IPP/7.0.4.191/lib/$(IPP_LIB_ARCH) \\

-lippch_t \\
-lippdc_t \\
-lippcc_t \\
-lippcv_t \\
-lippj_t \\
-lippvc_t \\
-lippi_t \\
-lipps_t \\
-lippcore_t

IPP_SHARED_LIBS = -L /opt/intel/ipp/7.0.4.191/compiler/lib/$(IPP_LIB_ARCH) -liomp5 -lintlc -limf

LIBS = -lraw1394 -lrt ${UIC_LIBS} ${UMC_LIBS} ${IPP_STATIC_LIBS} ${IPP_SHARED_LIBS} ${BOOST_LIB} -lpthread
Thanks for any help on this.

0 Kudos
1 Solution
Chao_Y_Intel
Employee
77 Views

Hello,

It looks that the code is threaded with GNU OpenMP libraries, and the JPEG sample code is threaded at the high level sample. So I suggest you linking with non threaded Intel IPP library.

Change:
-lippch_t \
-lippdc_t \
-lippcc_t \
-lippcv_t \
-lippj_t \
-lippvc_t \
-lippi_t \
-lipps_t \
-lippcore_t

to:
-lippch_l \
-lippdc_l \
-lippcc_l \
-lippcv_l \
-lippj_l \
-lippvc_l \
-lippi_l \
-lipps_l \
-lippcore_l

It does not need to add the -liomp5, but added the -lgomp -lpthread at the linkage frag.

Thanks,
Chao

View solution in original post

1 Reply
Chao_Y_Intel
Employee
78 Views

Hello,

It looks that the code is threaded with GNU OpenMP libraries, and the JPEG sample code is threaded at the high level sample. So I suggest you linking with non threaded Intel IPP library.

Change:
-lippch_t \
-lippdc_t \
-lippcc_t \
-lippcv_t \
-lippj_t \
-lippvc_t \
-lippi_t \
-lipps_t \
-lippcore_t

to:
-lippch_l \
-lippdc_l \
-lippcc_l \
-lippcv_l \
-lippj_l \
-lippvc_l \
-lippi_l \
-lipps_l \
-lippcore_l

It does not need to add the -liomp5, but added the -lgomp -lpthread at the linkage frag.

Thanks,
Chao

View solution in original post

Reply