mirror of
https://github.com/opencv/opencv.git
synced 2024-11-29 22:00:25 +08:00
Merge pull request #7391 from alalek:24_fix_7388
This commit is contained in:
commit
a34b8d4abf
@ -14,12 +14,7 @@
|
|||||||
|
|
||||||
IF(CMAKE_COMPILER_IS_GNUCXX)
|
IF(CMAKE_COMPILER_IS_GNUCXX)
|
||||||
|
|
||||||
EXEC_PROGRAM(
|
IF(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.2.0")
|
||||||
${CMAKE_CXX_COMPILER}
|
|
||||||
ARGS ${CMAKE_CXX_COMPILER_ARG1} -dumpversion
|
|
||||||
OUTPUT_VARIABLE gcc_compiler_version)
|
|
||||||
#MESSAGE("GCC Version: ${gcc_compiler_version}")
|
|
||||||
IF(gcc_compiler_version VERSION_GREATER "4.2.-1" AND gcc_compiler_version VERSION_LESS "6.0.0")
|
|
||||||
SET(PCHSupport_FOUND TRUE)
|
SET(PCHSupport_FOUND TRUE)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
@ -41,6 +41,9 @@ function(ocv_include_directories)
|
|||||||
get_filename_component(__abs_dir "${dir}" ABSOLUTE)
|
get_filename_component(__abs_dir "${dir}" ABSOLUTE)
|
||||||
if("${__abs_dir}" MATCHES "^${OpenCV_SOURCE_DIR}" OR "${__abs_dir}" MATCHES "^${OpenCV_BINARY_DIR}")
|
if("${__abs_dir}" MATCHES "^${OpenCV_SOURCE_DIR}" OR "${__abs_dir}" MATCHES "^${OpenCV_BINARY_DIR}")
|
||||||
list(APPEND __add_before "${dir}")
|
list(APPEND __add_before "${dir}")
|
||||||
|
elseif(CMAKE_COMPILER_IS_GNUCXX AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "6.0" AND
|
||||||
|
dir MATCHES "/usr/include$")
|
||||||
|
# workaround for GCC 6.x bug
|
||||||
else()
|
else()
|
||||||
include_directories(AFTER SYSTEM "${dir}")
|
include_directories(AFTER SYSTEM "${dir}")
|
||||||
endif()
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user