forked from qt-creator/qt-creator
UnitTest: Fix compilation for different configurations
Change-Id: I20d4217d1c33002f7e1ac084af4b0982b2f04971 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io> Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -1,9 +1,7 @@
|
|||||||
INCLUDEPATH += $$PWD
|
INCLUDEPATH += $$PWD
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
$$PWD/includecollector.cpp \
|
|
||||||
$$PWD/pchmanagerserver.cpp \
|
$$PWD/pchmanagerserver.cpp \
|
||||||
$$PWD/pchcreator.cpp \
|
|
||||||
$$PWD/clangpathwatcher.cpp \
|
$$PWD/clangpathwatcher.cpp \
|
||||||
$$PWD/projectparts.cpp \
|
$$PWD/projectparts.cpp \
|
||||||
$$PWD/idpaths.cpp \
|
$$PWD/idpaths.cpp \
|
||||||
@@ -16,12 +14,6 @@ SOURCES += \
|
|||||||
|
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
$$PWD/clangpchmanagerbackend_global.h \
|
$$PWD/clangpchmanagerbackend_global.h \
|
||||||
$$PWD/includecollector.h \
|
|
||||||
$$PWD/collectincludestoolaction.h \
|
|
||||||
$$PWD/collectincludesaction.h \
|
|
||||||
$$PWD/collectincludespreprocessorcallbacks.h \
|
|
||||||
$$PWD/pchmanagerserver.h \
|
|
||||||
$$PWD/pchcreator.h \
|
|
||||||
$$PWD/pchnotcreatederror.h \
|
$$PWD/pchnotcreatederror.h \
|
||||||
$$PWD/environment.h \
|
$$PWD/environment.h \
|
||||||
$$PWD/clangpathwatcher.h \
|
$$PWD/clangpathwatcher.h \
|
||||||
@@ -36,3 +28,16 @@ HEADERS += \
|
|||||||
$$PWD/pchgenerator.h \
|
$$PWD/pchgenerator.h \
|
||||||
$$PWD/pchgeneratornotifierinterface.h \
|
$$PWD/pchgeneratornotifierinterface.h \
|
||||||
$$PWD/pchgeneratorinterface.h
|
$$PWD/pchgeneratorinterface.h
|
||||||
|
|
||||||
|
!isEmpty(LIBTOOLING_LIBS) {
|
||||||
|
SOURCES += \
|
||||||
|
$$PWD/includecollector.cpp \
|
||||||
|
$$PWD/pchcreator.cpp
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$PWD/includecollector.h \
|
||||||
|
$$PWD/collectincludestoolaction.h \
|
||||||
|
$$PWD/collectincludesaction.h \
|
||||||
|
$$PWD/collectincludespreprocessorcallbacks.h \
|
||||||
|
$$PWD/pchcreator.h
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,5 +1,9 @@
|
|||||||
INCLUDEPATH += $$PWD
|
INCLUDEPATH += $$PWD
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$PWD/clangrefactoringbackend_global.h \
|
||||||
|
|
||||||
|
!isEmpty(LIBTOOLING_LIBS) {
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
$$PWD/refactoringcompilationdatabase.cpp \
|
$$PWD/refactoringcompilationdatabase.cpp \
|
||||||
$$PWD/symbolfinder.cpp \
|
$$PWD/symbolfinder.cpp \
|
||||||
@@ -14,7 +18,6 @@ SOURCES += \
|
|||||||
|
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
$$PWD/refactoringcompilationdatabase.h \
|
$$PWD/refactoringcompilationdatabase.h \
|
||||||
$$PWD/clangrefactoringbackend_global.h \
|
|
||||||
$$PWD/symbolfinder.h \
|
$$PWD/symbolfinder.h \
|
||||||
$$PWD/symbollocationfinderaction.h \
|
$$PWD/symbollocationfinderaction.h \
|
||||||
$$PWD/refactoringserver.h \
|
$$PWD/refactoringserver.h \
|
||||||
@@ -27,3 +30,4 @@ HEADERS += \
|
|||||||
$$PWD/clangtool.h \
|
$$PWD/clangtool.h \
|
||||||
$$PWD/sourcerangeextractor.h \
|
$$PWD/sourcerangeextractor.h \
|
||||||
$$PWD/locationsourcefilecallbacks.h
|
$$PWD/locationsourcefilecallbacks.h
|
||||||
|
}
|
||||||
|
|||||||
@@ -7,18 +7,20 @@ include($$PWD/../../../src/libs/utils/utils-lib.pri)
|
|||||||
include($$PWD/../../../src/libs/sqlite/sqlite-lib.pri)
|
include($$PWD/../../../src/libs/sqlite/sqlite-lib.pri)
|
||||||
include($$PWD/../../../src/libs/clangbackendipc/clangbackendipc-lib.pri)
|
include($$PWD/../../../src/libs/clangbackendipc/clangbackendipc-lib.pri)
|
||||||
include($$PWD/../../../src/plugins/coreplugin/corepluginunittestfiles.pri)
|
include($$PWD/../../../src/plugins/coreplugin/corepluginunittestfiles.pri)
|
||||||
|
include($$PWD/../../../src/tools/clangrefactoringbackend/source/clangrefactoringbackend-source.pri)
|
||||||
|
include($$PWD/../../../src/tools/clangpchmanagerbackend/source/clangpchmanagerbackend-source.pri)
|
||||||
|
include($$PWD/../../../src/plugins/clangrefactoring/clangrefactoring-source.pri)
|
||||||
|
include($$PWD/../../../src/plugins/clangpchmanager/clangpchmanager-source.pri)
|
||||||
|
include($$PWD/../../../src/plugins/cpptools/cpptoolsunittestfiles.pri)
|
||||||
|
include(cplusplus.pri)
|
||||||
|
|
||||||
!isEmpty(LLVM_INSTALL_DIR) {
|
!isEmpty(LLVM_INSTALL_DIR) {
|
||||||
include($$PWD/../../../src/shared/clang/clang_defines.pri)
|
include($$PWD/../../../src/shared/clang/clang_defines.pri)
|
||||||
|
|
||||||
include($$PWD/../../../src/tools/clangbackend/ipcsource/clangbackendclangipc-source.pri)
|
include($$PWD/../../../src/tools/clangbackend/ipcsource/clangbackendclangipc-source.pri)
|
||||||
!isEmpty(LIBTOOLING_LIBS):include($$PWD/../../../src/tools/clangrefactoringbackend/source/clangrefactoringbackend-source.pri)
|
|
||||||
include($$PWD/../../../src/tools/clangpchmanagerbackend/source/clangpchmanagerbackend-source.pri)
|
|
||||||
include($$PWD/../../../src/plugins/clangcodemodel/clangcodemodelunittestfiles.pri)
|
include($$PWD/../../../src/plugins/clangcodemodel/clangcodemodelunittestfiles.pri)
|
||||||
include($$PWD/../../../src/plugins/cpptools/cpptoolsunittestfiles.pri)
|
} else {
|
||||||
!isEmpty(LIBTOOLING_LIBS):include($$PWD/../../../src/plugins/clangrefactoring/clangrefactoring-source.pri)
|
DEFINES += CLANG_VERSION=\\\"3.9.1\\\"
|
||||||
include($$PWD/../../../src/plugins/clangpchmanager/clangpchmanager-source.pri)
|
DEFINES += "\"CLANG_RESOURCE_DIR=\\\"/usr/include\\\"\""
|
||||||
include(cplusplus.pri)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
INCLUDEPATH += \
|
INCLUDEPATH += \
|
||||||
|
|||||||
@@ -40,10 +40,6 @@ SOURCES += \
|
|||||||
utf8-test.cpp \
|
utf8-test.cpp \
|
||||||
gtest-qt-printing.cpp \
|
gtest-qt-printing.cpp \
|
||||||
gtest-creator-printing.cpp \
|
gtest-creator-printing.cpp \
|
||||||
clangparsesupportivetranslationunitjob-test.cpp \
|
|
||||||
clangreparsesupportivetranslationunitjob-test.cpp \
|
|
||||||
clangsupportivetranslationunitinitializer-test.cpp \
|
|
||||||
codecompleter-test.cpp \
|
|
||||||
clientserveroutsideprocess-test.cpp \
|
clientserveroutsideprocess-test.cpp \
|
||||||
clangpathwatcher-test.cpp \
|
clangpathwatcher-test.cpp \
|
||||||
projectparts-test.cpp \
|
projectparts-test.cpp \
|
||||||
@@ -51,7 +47,11 @@ SOURCES += \
|
|||||||
changedfilepathcompressor-test.cpp \
|
changedfilepathcompressor-test.cpp \
|
||||||
faketimer.cpp \
|
faketimer.cpp \
|
||||||
pchgenerator-test.cpp \
|
pchgenerator-test.cpp \
|
||||||
fakeprocess.cpp
|
fakeprocess.cpp \
|
||||||
|
pchmanagerclient-test.cpp \
|
||||||
|
projectupdater-test.cpp \
|
||||||
|
pchmanagerserver-test.cpp \
|
||||||
|
pchmanagerclientserverinprocess-test.cpp \
|
||||||
|
|
||||||
!isEmpty(LIBCLANG_LIBS) {
|
!isEmpty(LIBCLANG_LIBS) {
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
@@ -101,7 +101,11 @@ SOURCES += \
|
|||||||
translationunitupdater-test.cpp \
|
translationunitupdater-test.cpp \
|
||||||
unsavedfiles-test.cpp \
|
unsavedfiles-test.cpp \
|
||||||
unsavedfile-test.cpp \
|
unsavedfile-test.cpp \
|
||||||
utf8positionfromlinecolumn-test.cpp
|
utf8positionfromlinecolumn-test.cpp \
|
||||||
|
clangparsesupportivetranslationunitjob-test.cpp \
|
||||||
|
clangreparsesupportivetranslationunitjob-test.cpp \
|
||||||
|
clangsupportivetranslationunitinitializer-test.cpp \
|
||||||
|
codecompleter-test.cpp
|
||||||
}
|
}
|
||||||
|
|
||||||
!isEmpty(LIBTOOLING_LIBS) {
|
!isEmpty(LIBTOOLING_LIBS) {
|
||||||
@@ -117,12 +121,8 @@ SOURCES += \
|
|||||||
sourcerangeextractor-test.cpp \
|
sourcerangeextractor-test.cpp \
|
||||||
gtest-clang-printing.cpp \
|
gtest-clang-printing.cpp \
|
||||||
testclangtool.cpp \
|
testclangtool.cpp \
|
||||||
pchmanagerclientserverinprocess-test.cpp \
|
|
||||||
includecollector-test.cpp \
|
includecollector-test.cpp \
|
||||||
pchmanagerserver-test.cpp \
|
pchcreator-test.cpp
|
||||||
pchcreator-test.cpp \
|
|
||||||
pchmanagerclient-test.cpp \
|
|
||||||
projectupdater-test.cpp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
exists($$GOOGLEBENCHMARK_DIR) {
|
exists($$GOOGLEBENCHMARK_DIR) {
|
||||||
@@ -152,17 +152,22 @@ HEADERS += \
|
|||||||
mockchangedfilepathcompressor.h \
|
mockchangedfilepathcompressor.h \
|
||||||
faketimer.h \
|
faketimer.h \
|
||||||
mockpchgeneratornotifier.h \
|
mockpchgeneratornotifier.h \
|
||||||
fakeprocess.h
|
fakeprocess.h \
|
||||||
|
mockpchmanagerserver.h \
|
||||||
|
mockpchmanagerclient.h \
|
||||||
|
testenvironment.h \
|
||||||
|
mockpchmanagernotifier.h \
|
||||||
|
mockpchcreator.h \
|
||||||
|
dummyclangipcclient.h \
|
||||||
|
mockclangcodemodelclient.h \
|
||||||
|
mockclangcodemodelserver.h
|
||||||
|
|
||||||
!isEmpty(LIBCLANG_LIBS) {
|
!isEmpty(LIBCLANG_LIBS) {
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
chunksreportedmonitor.h \
|
chunksreportedmonitor.h \
|
||||||
clangasyncjob-base.h \
|
clangasyncjob-base.h \
|
||||||
diagnosticcontainer-matcher.h \
|
diagnosticcontainer-matcher.h \
|
||||||
clangcompareoperators.h \
|
clangcompareoperators.h
|
||||||
dummyclangipcclient.h \
|
|
||||||
mockclangcodemodelclient.h \
|
|
||||||
mockclangcodemodelserver.h
|
|
||||||
}
|
}
|
||||||
|
|
||||||
!isEmpty(LIBTOOLING_LIBS) {
|
!isEmpty(LIBTOOLING_LIBS) {
|
||||||
@@ -171,12 +176,7 @@ HEADERS += \
|
|||||||
mockrefactoringclient.h \
|
mockrefactoringclient.h \
|
||||||
mockrefactoringserver.h \
|
mockrefactoringserver.h \
|
||||||
gtest-clang-printing.h \
|
gtest-clang-printing.h \
|
||||||
testclangtool.h \
|
testclangtool.h
|
||||||
mockpchmanagerserver.h \
|
|
||||||
mockpchmanagerclient.h \
|
|
||||||
testenvironment.h \
|
|
||||||
mockpchmanagernotifier.h \
|
|
||||||
mockpchcreator.h
|
|
||||||
}
|
}
|
||||||
|
|
||||||
OTHER_FILES += $$files(data/*)
|
OTHER_FILES += $$files(data/*)
|
||||||
|
|||||||
Reference in New Issue
Block a user