Commit 17e1bcb0 authored by Anatoly Baksheev's avatar Anatoly Baksheev

fixed pch for non-windows

parent c49dc377
......@@ -41,9 +41,12 @@ macro(define_opencv_module name)
set_target_properties(${the_target} PROPERTIES FOLDER "modules")
endif()
if (OPENCV_BUILD_SHARED_LIB)
#add_definitions(-DCVAPI_EXPORTS)
set_target_properties(${the_target} PROPERTIES DEFINE_SYMBOL CVAPI_EXPORTS)
if (OPENCV_BUILD_SHARED_LIB)
if(MSVC)
set_target_properties(${the_target} PROPERTIES DEFINE_SYMBOL CVAPI_EXPORTS)
else()
add_definitions(-DCVAPI_EXPORTS)
endif()
endif()
# Additional target properties
......
......@@ -109,8 +109,11 @@ if(SOLUTION_FOLDERS_ENABLED)
endif()
if (OPENCV_BUILD_SHARED_LIB)
#add_definitions(-DCVAPI_EXPORTS)
set_target_properties(${the_target} PROPERTIES DEFINE_SYMBOL CVAPI_EXPORTS)
if (MSVC)
set_target_properties(${the_target} PROPERTIES DEFINE_SYMBOL CVAPI_EXPORTS)
else()
add_definitions(-DCVAPI_EXPORTS)
endif()
endif()
# Additional target properties
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment