fixed compile problems when Makefiles are used
This commit is contained in:
parent
d2c2c07ad2
commit
be4251c143
@ -106,10 +106,10 @@ macro(define_opencv_module name)
|
||||
add_executable(${the_target} ${test_srcs} ${test_hdrs})
|
||||
|
||||
if(PCHSupport_FOUND)
|
||||
set(pch_header ${CMAKE_CURRENT_SOURCE_DIR}/test/precomp.hpp)
|
||||
set(pch_header ${CMAKE_CURRENT_SOURCE_DIR}/test/test_precomp.hpp)
|
||||
if(${CMAKE_GENERATOR} MATCHES "Visual*" OR ${CMAKE_GENERATOR} MATCHES "Xcode*")
|
||||
if(${CMAKE_GENERATOR} MATCHES "Visual*")
|
||||
set(${the_target}_pch "test/precomp.cpp")
|
||||
set(${the_target}_pch "test/test_precomp.cpp")
|
||||
endif()
|
||||
add_native_precompiled_header(${the_target} ${pch_header})
|
||||
elseif(CMAKE_COMPILER_IS_GNUCXX AND ${CMAKE_GENERATOR} MATCHES ".*Makefiles")
|
||||
|
@ -1 +0,0 @@
|
||||
#include "precomp.hpp"
|
@ -1,4 +1,4 @@
|
||||
#include "precomp.hpp"
|
||||
#include "test_precomp.hpp"
|
||||
#include <iostream>
|
||||
|
||||
using namespace cv;
|
||||
|
@ -1,2 +1,2 @@
|
||||
#include "precomp.hpp"
|
||||
#include "test_precomp.hpp"
|
||||
#include "opencv2/gtest/gtest_main.hpp"
|
||||
|
1
modules/core/test/test_precomp.cpp
Normal file
1
modules/core/test/test_precomp.cpp
Normal file
@ -0,0 +1 @@
|
||||
#include "test_precomp.hpp"
|
Loading…
x
Reference in New Issue
Block a user