Skip to content

Commit 2d28bb4

Browse files
committed
ipp: disable compilation with IPP 9+
1 parent 3d8395c commit 2d28bb4

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

cmake/OpenCVFindIPP.cmake

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,6 @@ function(get_ipp_version _ROOT_DIR)
8585
message(STATUS "found IPP: ${_MAJOR}.${_MINOR}.${_BUILD} [${_VERSION_STR}]")
8686
message(STATUS "at: ${_ROOT_DIR}")
8787

88-
return()
89-
9088
endfunction()
9189

9290

@@ -129,8 +127,6 @@ function(set_ipp_old_libraries)
129127
${IPP_LIB_PREFIX}${IPP_PREFIX}${IPPCORE}${IPP_ARCH}${IPP_SUFFIX}${IPP_LIB_SUFFIX}
130128
PARENT_SCOPE)
131129

132-
return()
133-
134130
endfunction()
135131

136132

@@ -173,7 +169,6 @@ function(set_ipp_new_libraries _LATEST_VERSION)
173169
${IPP_LIB_PREFIX}svml${CMAKE_SHARED_LIBRARY_SUFFIX})
174170
endif()
175171
set(IPP_LIBRARIES ${IPP_LIBRARIES} PARENT_SCOPE)
176-
return()
177172

178173
endfunction()
179174

@@ -208,7 +203,7 @@ function(set_ipp_variables _LATEST_VERSION)
208203
set(IPP_LIBRARIES ${IPP_LIBRARIES} PARENT_SCOPE)
209204
message(STATUS "IPP libs: ${IPP_LIBRARIES}")
210205

211-
else()
206+
elseif(${_LATEST_VERSION} VERSION_LESS "9.0")
212207
# message(STATUS "new")
213208

214209
# set INCLUDE and LIB folders
@@ -229,7 +224,10 @@ function(set_ipp_variables _LATEST_VERSION)
229224
endif()
230225

231226
if (UNIX)
232-
get_filename_component(INTEL_COMPILER_LIBRARY_DIR ${IPP_ROOT_DIR}/../lib REALPATH)
227+
get_filename_component(INTEL_COMPILER_LIBRARY_DIR ${IPP_ROOT_DIR}/../compiler/lib REALPATH)
228+
if(NOT EXISTS "${INTEL_COMPILER_LIBRARY_DIR}")
229+
get_filename_component(INTEL_COMPILER_LIBRARY_DIR ${IPP_ROOT_DIR}/../lib REALPATH)
230+
endif()
233231
if (IPP_X64)
234232
if(NOT EXISTS ${INTEL_COMPILER_LIBRARY_DIR}/intel64)
235233
message(SEND_ERROR "Intel compiler EM64T libraries not found")
@@ -253,10 +251,11 @@ function(set_ipp_variables _LATEST_VERSION)
253251
set(IPP_LIBRARIES ${IPP_LIBRARIES} PARENT_SCOPE)
254252
message(STATUS "IPP libs: ${IPP_LIBRARIES}")
255253

254+
else()
255+
message(STATUS "IPP: version ${_LATEST_VERSION} is not supported (${IPP_ROOT_DIR})")
256+
set(IPP_FOUND 0 PARENT_SCOPE)
256257
endif()
257258

258-
return()
259-
260259
endfunction()
261260

262261

modules/core/include/opencv2/core/internal.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,10 @@ CV_INLINE IppiSize ippiSize(const cv::Size & _size)
104104
return size;
105105
}
106106

107+
#if IPP_VERSION_MAJOR >= 9 // IPP 9+ is not supported
108+
#undef HAVE_IPP
109+
#undef IPP_VERSION_MAJOR
110+
#endif
107111
#endif
108112

109113
#ifndef IPPI_CALL

0 commit comments

Comments
 (0)