Qt4 was still required for gtests
This commit is contained in:
@@ -4,9 +4,6 @@ set(GTEST_SRCDIR /usr/src/gtest)
|
||||
if(EXISTS "${GTEST_SRCDIR}/src/gtest-all.cc")
|
||||
add_library(gtests-lib STATIC EXCLUDE_FROM_ALL ${GTEST_SRCDIR}/src/gtest-all.cc )
|
||||
target_include_directories(gtests-lib PUBLIC ${GTEST_INCDIR} PUBLIC ${GTEST_SRCDIR})
|
||||
|
||||
find_package(Qt4 4.8.1 REQUIRED)
|
||||
include(${QT_USE_FILE})
|
||||
add_definitions(-DSIMU)
|
||||
set(TESTS_PATH ${RADIO_SRC_DIRECTORY})
|
||||
configure_file(${RADIO_SRC_DIRECTORY}/tests/location.h.in ${CMAKE_CURRENT_BINARY_DIR}/location.h @ONLY)
|
||||
@@ -19,8 +16,9 @@ if(EXISTS "${GTEST_SRCDIR}/src/gtest-all.cc")
|
||||
file(GLOB TEST_SRC_FILES ${RADIO_SRC_DIRECTORY}/tests/*.cpp)
|
||||
|
||||
add_executable(gtests EXCLUDE_FROM_ALL ${TEST_SRC_FILES} ${CMAKE_CURRENT_SOURCE_DIR}/location.h ${RADIO_SRC} ../targets/simu/simpgmspace.cpp)
|
||||
qt5_use_modules(gtests Core Widgets)
|
||||
add_dependencies(gtests ${FIRMWARE_DEPENDENCIES} gtests-lib)
|
||||
target_link_libraries(gtests gtests-lib ${QT_LIBRARIES} pthread)
|
||||
target_link_libraries(gtests gtests-lib pthread)
|
||||
message("Added optional gtests target")
|
||||
else()
|
||||
message("WARNING: can't find gtests source, gtest target will not be available!")
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include <QtGui/QApplication>
|
||||
#include <QApplication>
|
||||
#include "gtests.h"
|
||||
|
||||
int32_t lastAct = 0;
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
|
||||
#include <QtCore/QDir>
|
||||
#include <QtCore/QDebug>
|
||||
#include <QtGui/QApplication>
|
||||
#include <QtGui/QPainter>
|
||||
#include <QApplication>
|
||||
#include <QPainter>
|
||||
#include <math.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user