CMake build: Add unittest CMake build files

On MinGW 8.1 I get the following after running ctest -j 40

99% tests passed, 35 tests failed out of 2631

Change-Id: I2c3ce7940b036e52ef393feab5837886355e7b5a
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
Cristian Adam
2019-05-29 14:55:17 +02:00
committed by Cristian Adam
parent 0bbc5ef574
commit f50859e856
17 changed files with 841 additions and 108 deletions

View File

@@ -1,18 +1,9 @@
add_subdirectory(source)
add_qtc_executable(clangrefactoringbackend
DEPENDS clangbackendipc
INCLUDES source
DEPENDS
clangrefactoringbackend_lib Sqlite ClangSupport
libclang clangTooling clangIndex clangQuery clangToolingRefactor
SOURCES
clangrefactoringbackendmain.cpp
source/clangquery.cpp source/clangquery.h
source/clangrefactoringbackend_global.h
source/clangtool.cpp source/clangtool.h
source/findcursorusr.h
source/findlocationsofusrs.h
source/findusrforcursoraction.cpp source/findusrforcursoraction.h
source/macropreprocessorcallbacks.cpp source/macropreprocessorcallbacks.h
source/refactoringcompilationdatabase.cpp source/refactoringcompilationdatabase.h
source/refactoringserver.cpp source/refactoringserver.h
source/sourcelocationsutils.h
source/symbolfinder.cpp source/symbolfinder.h
source/symbollocationfinderaction.cpp source/symbollocationfinderaction.h
)

View File

@@ -0,0 +1,47 @@
add_qtc_library(clangrefactoringbackend_lib STATIC
DEPENDS libclang clangTooling clangIndex clangQuery ClangSupport
DEFINES CLANGSUPPORT_BUILD_LIB
PUBLIC_INCLUDES
${CLANG_INCLUDE_DIRS}
"../../clangpchmanagerbackend/source"
SOURCES
clangquery.cpp clangquery.h
clangquerygatherer.cpp clangquerygatherer.h
clangrefactoringbackend_global.h
clangtool.cpp clangtool.h
collectmacrospreprocessorcallbacks.h
collectmacrossourcefilecallbacks.cpp collectmacrossourcefilecallbacks.h
collectsymbolsaction.cpp collectsymbolsaction.h
filestatus.h
filestatuscache.cpp filestatuscache.h
findcursorusr.h
findlocationsofusrs.h
findusrforcursoraction.cpp findusrforcursoraction.h
indexdataconsumer.cpp indexdataconsumer.h
locationsourcefilecallbacks.cpp locationsourcefilecallbacks.h
macropreprocessorcallbacks.cpp macropreprocessorcallbacks.h
projectpartentry.h
refactoringcompilationdatabase.cpp refactoringcompilationdatabase.h
refactoringserver.cpp refactoringserver.h
sourcedependency.h
sourcelocationentry.h
sourcelocationsutils.h
sourcerangeextractor.cpp sourcerangeextractor.h
sourcerangefilter.cpp sourcerangefilter.h
sourcesmanager.h
symbolentry.h
symbolfinder.cpp symbolfinder.h
symbolindexer.cpp symbolindexer.h
symbolindexertask.h
symbolindexertaskqueue.h
symbolindexertaskqueueinterface.h
symbolindexing.cpp symbolindexing.h
symbolindexinginterface.h
symbollocationfinderaction.cpp symbollocationfinderaction.h
symbolscollector.cpp symbolscollector.h
symbolscollectorinterface.h
symbolstorage.h
symbolstorageinterface.h
symbolsvisitorbase.h
usedmacro.h
)