revert r16317, in preference to changing catkin
This commit is contained in:
parent
0c8ca2eae9
commit
91f6583be5
|
@ -35,11 +35,9 @@ catkin_project(roslib
|
||||||
)
|
)
|
||||||
|
|
||||||
#integration tests
|
#integration tests
|
||||||
find_package(GTest)
|
|
||||||
if(GTEST_FOUND)
|
|
||||||
add_gtest(${PROJECT_NAME}-utest test/utest.cpp)
|
|
||||||
target_link_libraries(${PROJECT_NAME}-utest roslib ${Boost_LIBRARIES} ${ROS_LIBRARIES})
|
|
||||||
|
|
||||||
add_gtest(${PROJECT_NAME}-test_package test/package.cpp)
|
add_gtest(${PROJECT_NAME}-utest test/utest.cpp)
|
||||||
target_link_libraries(${PROJECT_NAME}-test_package roslib ${ROS_LIBRARIES})
|
target_link_libraries(${PROJECT_NAME}-utest roslib ${Boost_LIBRARIES} ${ROS_LIBRARIES})
|
||||||
endif(GTEST_FOUND)
|
|
||||||
|
add_gtest(${PROJECT_NAME}-test_package test/package.cpp)
|
||||||
|
target_link_libraries(${PROJECT_NAME}-test_package roslib ${ROS_LIBRARIES})
|
||||||
|
|
|
@ -104,7 +104,10 @@ function(add_gtest exe)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Create the program, with basic + gtest build flags
|
# Create the program, with basic + gtest build flags
|
||||||
find_package(GTest REQUIRED)
|
find_package(GTest)
|
||||||
|
if(NOT GTEST_FOUND)
|
||||||
|
message("Warning: GTest not found; C++ tests will fail to build.")
|
||||||
|
endif()
|
||||||
include_directories(${GTEST_INCLUDE_DIRS})
|
include_directories(${GTEST_INCLUDE_DIRS})
|
||||||
add_executable(${exe} EXCLUDE_FROM_ALL ${_gtest_DEFAULT_ARGS})
|
add_executable(${exe} EXCLUDE_FROM_ALL ${_gtest_DEFAULT_ARGS})
|
||||||
target_link_libraries(${exe} ${GTEST_LIBRARIES} ${THREADS_LIBRARY})
|
target_link_libraries(${exe} ${GTEST_LIBRARIES} ${THREADS_LIBRARY})
|
||||||
|
|
Loading…
Reference in New Issue