aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/CMakeLists.txt5
-rw-r--r--src/app/CMakeLists.txt8
-rw-r--r--src/app/config-ui/CMakeLists.txt19
-rw-r--r--src/app/config/CMakeLists.txt13
-rw-r--r--src/app/qbs-create-project/CMakeLists.txt10
-rw-r--r--src/app/qbs-setup-android/CMakeLists.txt12
-rw-r--r--src/app/qbs-setup-qt/CMakeLists.txt12
-rw-r--r--src/app/qbs-setup-toolchains/CMakeLists.txt26
-rw-r--r--src/app/qbs/CMakeLists.txt50
-rw-r--r--src/app/shared/CMakeLists.txt1
-rw-r--r--src/app/shared/logging/CMakeLists.txt13
-rw-r--r--src/lib/CMakeLists.txt2
-rw-r--r--src/lib/corelib/CMakeLists.txt460
-rw-r--r--src/lib/corelib/corelib.qbs5
-rw-r--r--src/lib/corelib/jsextensions/jsextensions.pri4
-rw-r--r--src/lib/corelib/jsextensions/propertylist_darwin.h (renamed from src/lib/corelib/jsextensions/propertylist.h)30
-rw-r--r--src/lib/corelib/jsextensions/propertylist_darwin.mm (renamed from src/lib/corelib/jsextensions/propertylist.mm)31
-rw-r--r--src/lib/corelib/tools/preferences.cpp1
-rw-r--r--src/lib/corelib/tools/preferences.h1
-rw-r--r--src/lib/msbuild/CMakeLists.txt72
-rw-r--r--src/libexec/CMakeLists.txt1
-rw-r--r--src/libexec/qbs_processlauncher/CMakeLists.txt25
-rw-r--r--src/plugins/CMakeLists.txt2
-rw-r--r--src/plugins/generator/CMakeLists.txt5
-rw-r--r--src/plugins/generator/clangcompilationdb/CMakeLists.txt10
-rw-r--r--src/plugins/generator/iarew/CMakeLists.txt119
-rw-r--r--src/plugins/generator/keiluv/CMakeLists.txt80
-rw-r--r--src/plugins/generator/makefilegenerator/CMakeLists.txt10
-rw-r--r--src/plugins/generator/visualstudio/CMakeLists.txt25
-rw-r--r--src/plugins/scanner/CMakeLists.txt2
-rw-r--r--src/plugins/scanner/cpp/CMakeLists.txt16
-rw-r--r--src/plugins/scanner/qt/CMakeLists.txt4
-rw-r--r--src/shared/CMakeLists.txt1
-rw-r--r--src/shared/json/CMakeLists.txt4
34 files changed, 1019 insertions, 60 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
new file mode 100644
index 000000000..278b86ad1
--- /dev/null
+++ b/src/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_subdirectory(app)
+add_subdirectory(lib)
+add_subdirectory(libexec)
+add_subdirectory(plugins)
+add_subdirectory(shared)
diff --git a/src/app/CMakeLists.txt b/src/app/CMakeLists.txt
new file mode 100644
index 000000000..3a4ab38e0
--- /dev/null
+++ b/src/app/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_subdirectory(config)
+add_subdirectory(config-ui)
+add_subdirectory(qbs)
+add_subdirectory(qbs-create-project)
+add_subdirectory(qbs-setup-android)
+add_subdirectory(qbs-setup-qt)
+add_subdirectory(qbs-setup-toolchains)
+add_subdirectory(shared)
diff --git a/src/app/config-ui/CMakeLists.txt b/src/app/config-ui/CMakeLists.txt
new file mode 100644
index 000000000..bced804c2
--- /dev/null
+++ b/src/app/config-ui/CMakeLists.txt
@@ -0,0 +1,19 @@
+set(SOURCES
+ commandlineparser.cpp
+ commandlineparser.h
+ main.cpp
+ mainwindow.cpp
+ mainwindow.h
+ mainwindow.ui
+ )
+
+# TODO: support Info.plist
+if(APPLE)
+ set(MACOS_SOURCES fgapp.mm)
+ set(MACOS_FRAMEWORKS "-framework ApplicationServices" "-framework Cocoa")
+endif()
+
+add_qbs_app(qbs-config-ui
+ DEPENDS corelib logginglib Qt5::Widgets ${MACOS_FRAMEWORKS}
+ SOURCES ${SOURCES} ${MACOS_SOURCES}
+ )
diff --git a/src/app/config/CMakeLists.txt b/src/app/config/CMakeLists.txt
new file mode 100644
index 000000000..67dd78483
--- /dev/null
+++ b/src/app/config/CMakeLists.txt
@@ -0,0 +1,13 @@
+set(SOURCES
+ configcommand.h
+ configcommandexecutor.cpp
+ configcommandexecutor.h
+ configcommandlineparser.cpp
+ configcommandlineparser.h
+ configmain.cpp
+ )
+
+add_qbs_app(qbs-config
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/app/qbs-create-project/CMakeLists.txt b/src/app/qbs-create-project/CMakeLists.txt
new file mode 100644
index 000000000..b3c1f75f5
--- /dev/null
+++ b/src/app/qbs-create-project/CMakeLists.txt
@@ -0,0 +1,10 @@
+set(SOURCES
+ createproject.cpp
+ createproject.h
+ create-project-main.cpp
+ )
+
+add_qbs_app(qbs-create-project
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/app/qbs-setup-android/CMakeLists.txt b/src/app/qbs-setup-android/CMakeLists.txt
new file mode 100644
index 000000000..97d0c8a60
--- /dev/null
+++ b/src/app/qbs-setup-android/CMakeLists.txt
@@ -0,0 +1,12 @@
+set(SOURCES
+ android-setup.cpp
+ android-setup.h
+ commandlineparser.cpp
+ commandlineparser.h
+ main.cpp
+ )
+
+add_qbs_app(qbs-setup-android
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/app/qbs-setup-qt/CMakeLists.txt b/src/app/qbs-setup-qt/CMakeLists.txt
new file mode 100644
index 000000000..55b86e3a2
--- /dev/null
+++ b/src/app/qbs-setup-qt/CMakeLists.txt
@@ -0,0 +1,12 @@
+set(SOURCES
+ commandlineparser.cpp
+ commandlineparser.h
+ main.cpp
+ setupqt.cpp
+ setupqt.h
+ )
+
+add_qbs_app(qbs-setup-qt
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/app/qbs-setup-toolchains/CMakeLists.txt b/src/app/qbs-setup-toolchains/CMakeLists.txt
new file mode 100644
index 000000000..9dc610bd3
--- /dev/null
+++ b/src/app/qbs-setup-toolchains/CMakeLists.txt
@@ -0,0 +1,26 @@
+set(SOURCES
+ clangclprobe.cpp
+ clangclprobe.h
+ commandlineparser.cpp
+ commandlineparser.h
+ gccprobe.cpp
+ gccprobe.h
+ iarewprobe.cpp
+ iarewprobe.h
+ keilprobe.cpp
+ keilprobe.h
+ main.cpp
+ msvcprobe.cpp
+ msvcprobe.h
+ probe.cpp
+ probe.h
+ sdccprobe.cpp
+ sdccprobe.h
+ xcodeprobe.cpp
+ xcodeprobe.h
+ )
+
+add_qbs_app(qbs-setup-toolchains
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/app/qbs/CMakeLists.txt b/src/app/qbs/CMakeLists.txt
new file mode 100644
index 000000000..009130426
--- /dev/null
+++ b/src/app/qbs/CMakeLists.txt
@@ -0,0 +1,50 @@
+set(SOURCES
+ application.cpp
+ application.h
+ commandlinefrontend.cpp
+ commandlinefrontend.h
+ consoleprogressobserver.cpp
+ consoleprogressobserver.h
+ ctrlchandler.cpp
+ ctrlchandler.h
+ main.cpp
+ qbstool.cpp
+ qbstool.h
+ session.cpp
+ session.h
+ sessionpacket.cpp
+ sessionpacket.h
+ sessionpacketreader.cpp
+ sessionpacketreader.h
+ status.cpp
+ status.h
+ stdinreader.cpp
+ stdinreader.h
+ )
+
+set(PARSER_SOURCES
+ commandlineoption.cpp
+ commandlineoption.h
+ commandlineoptionpool.cpp
+ commandlineoptionpool.h
+ commandlineparser.cpp
+ commandlineparser.h
+ commandpool.cpp
+ commandpool.h
+ commandtype.h
+ parsercommand.cpp
+ parsercommand.h
+ )
+list_transform_prepend(PARSER_SOURCES parser/)
+
+add_qbs_app(qbs
+ DEFINES
+ "QBS_VERSION=\"${QBS_VERSION}\""
+ "QBS_RELATIVE_LIBEXEC_PATH=\"${QBS_RELATIVE_LIBEXEC_PATH}\""
+ "QBS_RELATIVE_SEARCH_PATH=\"${QBS_RELATIVE_SEARCH_PATH}\""
+ "QBS_RELATIVE_PLUGINS_PATH=\"${QBS_RELATIVE_PLUGINS_PATH}\""
+ DEPENDS corelib logginglib
+ SOURCES ${SOURCES} ${PARSER_SOURCES}
+ )
+
+add_dependencies(qbs qbs_cpp_scanner qbs_qt_scanner)
diff --git a/src/app/shared/CMakeLists.txt b/src/app/shared/CMakeLists.txt
new file mode 100644
index 000000000..504db2b5b
--- /dev/null
+++ b/src/app/shared/CMakeLists.txt
@@ -0,0 +1 @@
+add_subdirectory(logging)
diff --git a/src/app/shared/logging/CMakeLists.txt b/src/app/shared/logging/CMakeLists.txt
new file mode 100644
index 000000000..8fbeed184
--- /dev/null
+++ b/src/app/shared/logging/CMakeLists.txt
@@ -0,0 +1,13 @@
+set(SOURCES
+ coloredoutput.cpp
+ coloredoutput.h
+ consolelogger.cpp
+ consolelogger.h
+ )
+
+add_qbs_library(logginglib
+ STATIC
+ DEPENDS corelib
+ PUBLIC_INCLUDES $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/../>
+ SOURCES ${SOURCES}
+ )
diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt
new file mode 100644
index 000000000..f029edd1f
--- /dev/null
+++ b/src/lib/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(corelib)
+add_subdirectory(msbuild)
diff --git a/src/lib/corelib/CMakeLists.txt b/src/lib/corelib/CMakeLists.txt
new file mode 100644
index 000000000..2dfaf225c
--- /dev/null
+++ b/src/lib/corelib/CMakeLists.txt
@@ -0,0 +1,460 @@
+set(QBS_HEADERS qbs.h)
+
+set(FILE_UPDATE_SOURCES
+ changeset.cpp
+ changeset.h
+ projectfileupdater.cpp
+ projectfileupdater.h
+ qmljsrewriter.cpp
+ qmljsrewriter.h
+ )
+list_transform_prepend(FILE_UPDATE_SOURCES api/)
+
+set(API_SOURCES
+ internaljobs.cpp
+ internaljobs.h
+ jobs.cpp
+ languageinfo.cpp
+ project.cpp
+ project_p.h
+ projectdata.cpp
+ projectdata_p.h
+ propertymap_p.h
+ rulecommand.cpp
+ rulecommand_p.h
+ runenvironment.cpp
+ transformerdata.cpp
+ transformerdata_p.h
+ )
+list_transform_prepend(API_SOURCES api/)
+
+set(API_HEADERS
+ jobs.h
+ languageinfo.h
+ project.h
+ projectdata.h
+ rulecommand.h
+ runenvironment.h
+ transformerdata.h
+ )
+list_transform_prepend(API_HEADERS api/)
+
+set(BUILD_GRAPH_SOURCES
+ abstractcommandexecutor.cpp
+ abstractcommandexecutor.h
+ artifact.cpp
+ artifact.h
+ artifactcleaner.cpp
+ artifactcleaner.h
+ artifactsscriptvalue.cpp
+ artifactsscriptvalue.h
+ artifactvisitor.cpp
+ artifactvisitor.h
+ buildgraph.cpp
+ buildgraph.h
+ buildgraphnode.cpp
+ buildgraphnode.h
+ buildgraphloader.cpp
+ buildgraphloader.h
+ buildgraphvisitor.h
+ cycledetector.cpp
+ cycledetector.h
+ dependencyparametersscriptvalue.cpp
+ dependencyparametersscriptvalue.h
+ depscanner.cpp
+ depscanner.h
+ emptydirectoriesremover.cpp
+ emptydirectoriesremover.h
+ environmentscriptrunner.cpp
+ environmentscriptrunner.h
+ executor.cpp
+ executor.h
+ executorjob.cpp
+ executorjob.h
+ filedependency.cpp
+ filedependency.h
+ inputartifactscanner.cpp
+ inputartifactscanner.h
+ jscommandexecutor.cpp
+ jscommandexecutor.h
+ nodeset.cpp
+ nodeset.h
+ nodetreedumper.cpp
+ nodetreedumper.h
+ processcommandexecutor.cpp
+ processcommandexecutor.h
+ productbuilddata.cpp
+ productbuilddata.h
+ productinstaller.cpp
+ productinstaller.h
+ projectbuilddata.cpp
+ projectbuilddata.h
+ qtmocscanner.cpp
+ qtmocscanner.h
+ rawscanneddependency.cpp
+ rawscanneddependency.h
+ rawscanresults.cpp
+ rawscanresults.h
+ requestedartifacts.cpp
+ requestedartifacts.h
+ requesteddependencies.cpp
+ requesteddependencies.h
+ rescuableartifactdata.h
+ rulecommands.cpp
+ rulecommands.h
+ rulegraph.cpp
+ rulegraph.h
+ rulenode.cpp
+ rulenode.h
+ rulesapplicator.cpp
+ rulesapplicator.h
+ rulesevaluationcontext.cpp
+ rulesevaluationcontext.h
+ scriptclasspropertyiterator.h
+ timestampsupdater.cpp
+ timestampsupdater.h
+ transformer.cpp
+ transformer.h
+ transformerchangetracking.cpp
+ transformerchangetracking.h
+ )
+list_transform_prepend(BUILD_GRAPH_SOURCES buildgraph/)
+
+set(BUILD_GRAPH_HEADERS buildgraph/forward_decls.h)
+
+set(GENERATORS_SOURCES
+ generatableprojectiterator.cpp
+ generatableprojectiterator.h
+ generator.cpp
+ generatordata.cpp
+ generatorutils.cpp
+ generatorutils.h
+ generatorversioninfo.cpp
+ generatorversioninfo.h
+ igeneratableprojectvisitor.h
+ ixmlnodevisitor.h
+ xmlproject.cpp
+ xmlproject.h
+ xmlprojectwriter.cpp
+ xmlprojectwriter.h
+ xmlproperty.cpp
+ xmlproperty.h
+ xmlpropertygroup.cpp
+ xmlpropertygroup.h
+ xmlworkspace.cpp
+ xmlworkspace.h
+ xmlworkspacewriter.cpp
+ xmlworkspacewriter.h
+ )
+list_transform_prepend(GENERATORS_SOURCES generators/)
+
+set(GENERATORS_HEADERS generators/generator.h generators/generatordata.h)
+
+set(JS_EXTENSIONS_SOURCES
+ environmentextension.cpp
+ file.cpp
+ fileinfoextension.cpp
+ jsextensions.cpp
+ jsextensions.h
+ moduleproperties.cpp
+ moduleproperties.h
+ process.cpp
+ temporarydir.cpp
+ textfile.cpp
+ binaryfile.cpp
+ utilitiesextension.cpp
+ domxml.cpp
+ )
+list_transform_prepend(JS_EXTENSIONS_SOURCES jsextensions/)
+
+if(APPLE)
+ set(JS_EXTENSIONS_MACOS_SOURCES
+ propertylist_darwin.h
+ propertylist_darwin.mm
+ propertylistutils.h
+ propertylistutils.mm
+ )
+else()
+ set(JS_EXTENSIONS_MACOS_SOURCES propertylist.cpp)
+endif()
+list_transform_prepend(JS_EXTENSIONS_MACOS_SOURCES jsextensions/)
+
+set(LANGUAGE_SOURCES
+ artifactproperties.cpp
+ artifactproperties.h
+ astimportshandler.cpp
+ astimportshandler.h
+ astpropertiesitemhandler.cpp
+ astpropertiesitemhandler.h
+ asttools.cpp
+ asttools.h
+ builtindeclarations.cpp
+ builtindeclarations.h
+ deprecationinfo.h
+ evaluationdata.h
+ evaluator.cpp
+ evaluator.h
+ evaluatorscriptclass.cpp
+ evaluatorscriptclass.h
+ filecontext.cpp
+ filecontext.h
+ filecontextbase.cpp
+ filecontextbase.h
+ filetags.cpp
+ filetags.h
+ identifiersearch.cpp
+ identifiersearch.h
+ item.cpp
+ item.h
+ itemdeclaration.cpp
+ itemdeclaration.h
+ itemobserver.h
+ itempool.cpp
+ itempool.h
+ itemreader.cpp
+ itemreader.h
+ itemreaderastvisitor.cpp
+ itemreaderastvisitor.h
+ itemreadervisitorstate.cpp
+ itemreadervisitorstate.h
+ itemtype.h
+ jsimports.h
+ language.cpp
+ language.h
+ loader.cpp
+ loader.h
+ moduleloader.cpp
+ moduleloader.h
+ modulemerger.cpp
+ modulemerger.h
+ moduleproviderinfo.h
+ preparescriptobserver.cpp
+ preparescriptobserver.h
+ projectresolver.cpp
+ projectresolver.h
+ property.cpp
+ property.h
+ propertydeclaration.cpp
+ propertydeclaration.h
+ propertymapinternal.cpp
+ propertymapinternal.h
+ qualifiedid.cpp
+ qualifiedid.h
+ resolvedfilecontext.cpp
+ resolvedfilecontext.h
+ scriptengine.cpp
+ scriptengine.h
+ scriptimporter.cpp
+ scriptimporter.h
+ scriptpropertyobserver.cpp
+ scriptpropertyobserver.h
+ value.cpp
+ value.h
+ )
+list_transform_prepend(LANGUAGE_SOURCES language/)
+
+set(LANGUAGE_HEADERS language/forward_decls.h)
+
+set(LOGGING_SOURCES
+ categories.cpp
+ categories.h
+ ilogsink.cpp
+ logger.cpp
+ logger.h
+ translator.h
+ )
+list_transform_prepend(LOGGING_SOURCES logging/)
+
+set(LOGGING_HEADERS logging/ilogsink.h)
+
+set(PARSER_SOURCES
+ qmlerror.cpp
+ qmlerror.h
+ qmljsast.cpp
+ qmljsast_p.h
+ qmljsastfwd_p.h
+ qmljsastvisitor.cpp
+ qmljsastvisitor_p.h
+ qmljsengine_p.cpp
+ qmljsengine_p.h
+ qmljsglobal_p.h
+ qmljsgrammar.cpp
+ qmljsgrammar_p.h
+ qmljskeywords_p.h
+ qmljslexer.cpp
+ qmljslexer_p.h
+ qmljsmemorypool_p.h
+ qmljsparser.cpp
+ qmljsparser_p.h
+ )
+list_transform_prepend(PARSER_SOURCES parser/)
+
+set(TOOLS_SOURCES
+ architectures.cpp
+ buildgraphlocker.cpp
+ buildgraphlocker.h
+ buildoptions.cpp
+ clangclinfo.cpp
+ clangclinfo.h
+ cleanoptions.cpp
+ codelocation.cpp
+ commandechomode.cpp
+ dynamictypecheck.h
+ error.cpp
+ executablefinder.cpp
+ executablefinder.h
+ fileinfo.cpp
+ fileinfo.h
+ filesaver.cpp
+ filesaver.h
+ filetime.cpp
+ filetime.h
+ generateoptions.cpp
+ hostosinfo.h
+ id.cpp
+ id.h
+ iosutils.h
+ joblimits.cpp
+ jsliterals.cpp
+ jsliterals.h
+ jsonhelper.h
+ installoptions.cpp
+ launcherinterface.cpp
+ launcherinterface.h
+ launcherpackets.cpp
+ launcherpackets.h
+ launchersocket.cpp
+ launchersocket.h
+ msvcinfo.cpp
+ msvcinfo.h
+ pathutils.h
+ persistence.cpp
+ persistence.h
+ preferences.cpp
+ processresult.cpp
+ processresult_p.h
+ processutils.cpp
+ processutils.h
+ profile.cpp
+ profiling.cpp
+ profiling.h
+ progressobserver.cpp
+ progressobserver.h
+ projectgeneratormanager.cpp
+ qbsassert.cpp
+ qbsassert.h
+ qbspluginmanager.cpp
+ qbspluginmanager.h
+ qbsprocess.cpp
+ qbsprocess.h
+ qttools.cpp
+ qttools.h
+ scannerpluginmanager.cpp
+ scannerpluginmanager.h
+ scripttools.cpp
+ scripttools.h
+ set.h
+ settings.cpp
+ settingscreator.cpp
+ settingscreator.h
+ settingsmodel.cpp
+ settingsrepresentation.cpp
+ setupprojectparameters.cpp
+ shellutils.cpp
+ shellutils.h
+ stlutils.h
+ stringconstants.h
+ stringutils.h
+ toolchains.cpp
+ version.cpp
+ visualstudioversioninfo.cpp
+ visualstudioversioninfo.h
+ vsenvironmentdetector.cpp
+ vsenvironmentdetector.h
+ weakpointer.h
+ )
+list_transform_prepend(TOOLS_SOURCES tools/)
+
+set(TOOLS_HEADERS
+ architectures.h
+ buildoptions.h
+ cleanoptions.h
+ codelocation.h
+ commandechomode.h
+ error.h
+ generateoptions.h
+ installoptions.h
+ joblimits.h
+ preferences.h
+ processresult.h
+ profile.h
+ projectgeneratormanager.h
+ qbs_export.h
+ settings.h
+ settingsmodel.h
+ settingsrepresentation.h
+ setupprojectparameters.h
+ toolchains.h
+ version.h
+ )
+list_transform_prepend(TOOLS_HEADERS tools/)
+
+set(EXTERNAL_DEPENDS "")
+if(APPLE)
+ set(TOOLS_MACOS_SOURCES
+ applecodesignutils.cpp
+ applecodesignutils.h
+ )
+ list_transform_prepend(TOOLS_MACOS_SOURCES tools/)
+ set(EXTERNAL_DEPENDS "-framework Foundation" "-framework Security")
+endif()
+
+if(WIN32)
+ set(EXTERNAL_DEPENDS "psapi" "shell32")
+endif()
+
+add_qbs_library(corelib
+ DEFINES
+ "QBS_VERSION=\"${QBS_VERSION}\""
+ "QBS_RELATIVE_LIBEXEC_PATH=\"${QBS_RELATIVE_LIBEXEC_PATH}\""
+ ${QBS_UNIT_TESTS_DEFINES}
+ ${QBS_PROJECT_FILE_UPDATES_DEFINES}
+ DEPENDS
+ Qt5::CorePrivate Qt5::Gui Qt5::Network Qt5::Script Qt5::Xml ${EXTERNAL_DEPENDS}
+ PUBLIC_DEPENDS
+ Qt5::Core
+ INCLUDES
+ "${CMAKE_CURRENT_SOURCE_DIR}/../.."
+ SOURCES
+ ${QBS_HEADERS}
+ ${FILE_UPDATE_SOURCES}
+ ${API_SOURCES}
+ ${API_HEADERS}
+ ${BUILD_GRAPH_SOURCES}
+ ${BUILD_GRAPH_HEADERS}
+ ${GENERATORS_SOURCES}
+ ${GENERATORS_HEADERS}
+ ${JS_EXTENSIONS_SOURCES}
+ ${JS_EXTENSIONS_MACOS_SOURCES}
+ ${LANGUAGE_SOURCES}
+ ${LANGUAGE_HEADERS}
+ ${LOGGING_SOURCES}
+ ${LOGGING_HEADERS}
+ ${PARSER_SOURCES}
+ ${TOOLS_SOURCES}
+ ${TOOLS_HEADERS}
+ ${TOOLS_MACOS_SOURCES}
+ )
+
+# not sure if there's a better way to do this
+if(INSTALL_PUBLIC_HEADERS)
+ install(FILES ${QBS_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR})
+ install(FILES ${API_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/api)
+ install(FILES ${BUILD_GRAPH_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/buildgraph)
+ install(FILES ${GENERATORS_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/generators)
+ install(FILES ${LOGGING_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/logging)
+ install(FILES ${LANGUAGE_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/language)
+ install(FILES ${TOOLS_HEADERS} DESTINATION ${QBS_HEADERS_INSTALL_DIR}/tools)
+ set(QMAKE_PRI_FILES use_installed_corelib.pri ../../../qbs_version.pri)
+ install(FILES ${QMAKE_PRI_FILES} DESTINATION ${QBS_HEADERS_INSTALL_DIR})
+endif()
diff --git a/src/lib/corelib/corelib.qbs b/src/lib/corelib/corelib.qbs
index 619c0f0e3..9f95f417f 100644
--- a/src/lib/corelib/corelib.qbs
+++ b/src/lib/corelib/corelib.qbs
@@ -258,7 +258,10 @@ QbsLibrary {
prefix: "jsextensions/"
condition: qbs.targetOS.contains("darwin")
files: [
- "propertylist.mm",
+ // This is ugly, but because of QBS-1592 we cannot check the platform in the header
+ // using Q_OS_DARWIN
+ "propertylist_darwin.h",
+ "propertylist_darwin.mm",
"propertylistutils.h",
"propertylistutils.mm",
]
diff --git a/src/lib/corelib/jsextensions/jsextensions.pri b/src/lib/corelib/jsextensions/jsextensions.pri
index 2bffc9914..004a3e42a 100644
--- a/src/lib/corelib/jsextensions/jsextensions.pri
+++ b/src/lib/corelib/jsextensions/jsextensions.pri
@@ -18,8 +18,8 @@ SOURCES += \
$$PWD/utilitiesextension.cpp
darwin {
- HEADERS += $$PWD/propertylistutils.h
- SOURCES += $$PWD/propertylist.mm $$PWD/propertylistutils.mm
+ HEADERS += $$PWD/propertylistutils.h $$PWD/propertylist_darwin.h
+ SOURCES += $$PWD/propertylist_darwin.mm $$PWD/propertylistutils.mm
LIBS += -framework Foundation
} else {
SOURCES += $$PWD/propertylist.cpp
diff --git a/src/lib/corelib/jsextensions/propertylist.h b/src/lib/corelib/jsextensions/propertylist_darwin.h
index adb90f786..75900b144 100644
--- a/src/lib/corelib/jsextensions/propertylist.h
+++ b/src/lib/corelib/jsextensions/propertylist_darwin.h
@@ -43,31 +43,6 @@
#include <QtCore/qglobal.h>
-// ### remove when qbs requires qbs 1.6 to build itself
-#if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0) && defined(__APPLE__) && !defined(Q_OS_MAC)
-#define Q_OS_MAC
-#endif
-
-#ifndef Q_OS_MAC
-
-#include <QtScript/qscriptengine.h>
-
-namespace qbs {
-namespace Internal {
-
-// provide a fake initializer for other platforms
-void initializeJsExtensionPropertyList(QScriptValue extensionObject)
-{
- // provide a fake object
- QScriptEngine *engine = extensionObject.engine();
- extensionObject.setProperty(QLatin1String("PropertyList"), engine->newObject());
-}
-
-} // namespace Internal
-} // namespace qbs
-
-#else // Q_OS_MAC
-
#include <QtCore/qobject.h>
#include <QtCore/qstring.h>
#include <QtCore/qvariant.h>
@@ -82,13 +57,14 @@ void initializeJsExtensionPropertyList(QScriptValue extensionObject);
class PropertyListPrivate;
+// We need to have this class in the header since CMake's automoc doesn't handle .mm files
class PropertyList : public QObject, public QScriptable
{
Q_OBJECT
public:
static QScriptValue ctor(QScriptContext *context, QScriptEngine *engine);
PropertyList(QScriptContext *context);
- ~PropertyList();
+ ~PropertyList() override;
Q_INVOKABLE bool isEmpty() const;
Q_INVOKABLE void clear();
Q_INVOKABLE void readFromObject(const QScriptValue &value);
@@ -110,6 +86,4 @@ private:
Q_DECLARE_METATYPE(qbs::Internal::PropertyList *)
-#endif // Q_OS_MAC
-
#endif // QBS_PROPERTYLIST_H
diff --git a/src/lib/corelib/jsextensions/propertylist.mm b/src/lib/corelib/jsextensions/propertylist_darwin.mm
index 2ae422c41..7a08b5e9f 100644
--- a/src/lib/corelib/jsextensions/propertylist.mm
+++ b/src/lib/corelib/jsextensions/propertylist_darwin.mm
@@ -38,6 +38,8 @@
**
****************************************************************************/
+#include "propertylist_darwin.h"
+
#include <language/scriptengine.h>
#include <tools/hostosinfo.h>
@@ -62,31 +64,6 @@ enum {
namespace qbs {
namespace Internal {
-class PropertyListPrivate;
-
-class PropertyList : public QObject, public QScriptable
-{
- Q_OBJECT
-public:
- static QScriptValue ctor(QScriptContext *context, QScriptEngine *engine);
- PropertyList(QScriptContext *context);
- ~PropertyList() override;
- Q_INVOKABLE bool isEmpty() const;
- Q_INVOKABLE void clear();
- Q_INVOKABLE void readFromObject(const QScriptValue &value);
- Q_INVOKABLE void readFromString(const QString &input);
- Q_INVOKABLE void readFromFile(const QString &filePath);
- Q_INVOKABLE void readFromData(const QByteArray &data);
- Q_INVOKABLE void writeToFile(const QString &filePath, const QString &plistFormat);
- Q_INVOKABLE QScriptValue format() const;
- Q_INVOKABLE QScriptValue toObject() const;
- Q_INVOKABLE QString toString(const QString &plistFormat) const;
- Q_INVOKABLE QString toXMLString() const;
- Q_INVOKABLE QString toJSON(const QString &style = QString()) const;
-private:
- PropertyListPrivate *d;
-};
-
class PropertyListPrivate
{
public:
@@ -367,7 +344,3 @@ void initializeJsExtensionPropertyList(QScriptValue extensionObject)
engine->newFunction(&PropertyList::ctor));
extensionObject.setProperty(QStringLiteral("PropertyList"), obj);
}
-
-Q_DECLARE_METATYPE(qbs::Internal::PropertyList *)
-
-#include "propertylist.moc"
diff --git a/src/lib/corelib/tools/preferences.cpp b/src/lib/corelib/tools/preferences.cpp
index 4db271758..42fb5002a 100644
--- a/src/lib/corelib/tools/preferences.cpp
+++ b/src/lib/corelib/tools/preferences.cpp
@@ -63,6 +63,7 @@ Preferences::Preferences(Settings *settings, QVariantMap profileContents)
{
}
+Preferences::~Preferences() = default;
/*!
* \brief Returns true <=> colored output should be used for printing messages.
diff --git a/src/lib/corelib/tools/preferences.h b/src/lib/corelib/tools/preferences.h
index 2824ebf2c..517bd442b 100644
--- a/src/lib/corelib/tools/preferences.h
+++ b/src/lib/corelib/tools/preferences.h
@@ -56,6 +56,7 @@ class QBS_EXPORT Preferences
public:
explicit Preferences(Settings *settings, QString profileName = QString());
Preferences(Settings *settings, QVariantMap profileContents);
+ ~Preferences();
bool useColoredOutput() const;
int jobs() const;
diff --git a/src/lib/msbuild/CMakeLists.txt b/src/lib/msbuild/CMakeLists.txt
new file mode 100644
index 000000000..bce7a1dcf
--- /dev/null
+++ b/src/lib/msbuild/CMakeLists.txt
@@ -0,0 +1,72 @@
+set(SOLUTION_SOURCES
+ ivisualstudiosolutionproject.cpp
+ ivisualstudiosolutionproject.h
+ visualstudiosolutionfileproject.cpp
+ visualstudiosolutionfileproject.h
+ visualstudiosolutionfolderproject.cpp
+ visualstudiosolutionfolderproject.h
+ visualstudiosolution.cpp
+ visualstudiosolution.h
+ visualstudiosolutionglobalsection.cpp
+ visualstudiosolutionglobalsection.h
+ )
+list_transform_prepend(SOLUTION_SOURCES solution/)
+
+set(MSBUILD_SOURCES
+ imsbuildgroup.cpp
+ imsbuildgroup.h
+ imsbuildnode.cpp
+ imsbuildnode.h
+ imsbuildnodevisitor.h
+ msbuildimport.cpp
+ msbuildimport.h
+ msbuildimportgroup.cpp
+ msbuildimportgroup.h
+ msbuilditem.cpp
+ msbuilditem.h
+ msbuilditemdefinitiongroup.cpp
+ msbuilditemdefinitiongroup.h
+ msbuilditemgroup.cpp
+ msbuilditemgroup.h
+ msbuilditemmetadata.cpp
+ msbuilditemmetadata.h
+ msbuildproject.cpp
+ msbuildproject.h
+ msbuildproperty.cpp
+ msbuildproperty.h
+ msbuildpropertybase.cpp
+ msbuildpropertybase.h
+ msbuildpropertygroup.cpp
+ msbuildpropertygroup.h
+ )
+list_transform_prepend(MSBUILD_SOURCES msbuild/)
+
+set(MSBUILD_ITEMS_SOURCES
+ msbuildclcompile.cpp
+ msbuildclcompile.h
+ msbuildclinclude.cpp
+ msbuildclinclude.h
+ msbuildfileitem.cpp
+ msbuildfileitem.h
+ msbuildfilter.cpp
+ msbuildfilter.h
+ msbuildlink.cpp
+ msbuildlink.h
+ msbuildnone.cpp
+ msbuildnone.h
+ )
+list_transform_prepend(MSBUILD_ITEMS_SOURCES msbuild/items/)
+
+set(IO_SOURCES
+ msbuildprojectwriter.cpp
+ msbuildprojectwriter.h
+ visualstudiosolutionwriter.cpp
+ visualstudiosolutionwriter.h
+ )
+list_transform_prepend(IO_SOURCES io/)
+
+add_qbs_library(qbsmsbuild
+ STATIC
+ DEPENDS corelib
+ SOURCES ${SOLUTION_SOURCES} ${MSBUILD_SOURCES} ${MSBUILD_ITEMS_SOURCES} ${IO_SOURCES}
+ )
diff --git a/src/libexec/CMakeLists.txt b/src/libexec/CMakeLists.txt
new file mode 100644
index 000000000..dcf87ae88
--- /dev/null
+++ b/src/libexec/CMakeLists.txt
@@ -0,0 +1 @@
+add_subdirectory(qbs_processlauncher)
diff --git a/src/libexec/qbs_processlauncher/CMakeLists.txt b/src/libexec/qbs_processlauncher/CMakeLists.txt
new file mode 100644
index 000000000..f9a8c1b4c
--- /dev/null
+++ b/src/libexec/qbs_processlauncher/CMakeLists.txt
@@ -0,0 +1,25 @@
+set(SOURCES
+ launcherlogging.cpp
+ launcherlogging.h
+ launchersockethandler.cpp
+ launchersockethandler.h
+ processlauncher-main.cpp
+ )
+
+set(PATH_TO_PROTOCOL_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/../../lib/corelib/tools")
+set(PROTOCOL_SOURCES
+ launcherpackets.cpp
+ launcherpackets.h
+ )
+list_transform_prepend(PROTOCOL_SOURCES ${PATH_TO_PROTOCOL_SOURCES}/)
+
+add_qbs_app(qbs_processlauncher
+ DESTINATION ${QBS_LIBEXEC_PATH}
+ DEPENDS Qt5::Core Qt5::Network
+ INCLUDES ${PATH_TO_PROTOCOL_SOURCES}
+ SOURCES ${SOURCES} ${PROTOCOL_SOURCES}
+ )
+set_target_properties(qbs_processlauncher PROPERTIES
+ BUILD_RPATH "${QBS_LIBEXEC_RPATH}"
+ INSTALL_RPATH "${QBS_LIBEXEC_RPATH}"
+ )
diff --git a/src/plugins/CMakeLists.txt b/src/plugins/CMakeLists.txt
new file mode 100644
index 000000000..659468aa4
--- /dev/null
+++ b/src/plugins/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(generator)
+add_subdirectory(scanner)
diff --git a/src/plugins/generator/CMakeLists.txt b/src/plugins/generator/CMakeLists.txt
new file mode 100644
index 000000000..738e428bc
--- /dev/null
+++ b/src/plugins/generator/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_subdirectory(clangcompilationdb)
+add_subdirectory(iarew)
+add_subdirectory(keiluv)
+add_subdirectory(makefilegenerator)
+add_subdirectory(visualstudio)
diff --git a/src/plugins/generator/clangcompilationdb/CMakeLists.txt b/src/plugins/generator/clangcompilationdb/CMakeLists.txt
new file mode 100644
index 000000000..b7c50b746
--- /dev/null
+++ b/src/plugins/generator/clangcompilationdb/CMakeLists.txt
@@ -0,0 +1,10 @@
+set(SOURCES
+ clangcompilationdbgenerator.cpp
+ clangcompilationdbgenerator.h
+ clangcompilationdbgeneratorplugin.cpp
+ )
+
+add_qbs_plugin(clangcompilationdbgenerator
+ DEPENDS corelib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/plugins/generator/iarew/CMakeLists.txt b/src/plugins/generator/iarew/CMakeLists.txt
new file mode 100644
index 000000000..e08f3ff9d
--- /dev/null
+++ b/src/plugins/generator/iarew/CMakeLists.txt
@@ -0,0 +1,119 @@
+set(COMMON_SOURCES
+ iarewfileversionproperty.cpp
+ iarewfileversionproperty.h
+ iarewgenerator.cpp
+ iarewgenerator.h
+ iarewgeneratorplugin.cpp
+ iarewoptionpropertygroup.cpp
+ iarewoptionpropertygroup.h
+ iarewproject.cpp
+ iarewproject.h
+ iarewprojectwriter.cpp
+ iarewprojectwriter.h
+ iarewsettingspropertygroup.cpp
+ iarewsettingspropertygroup.h
+ iarewsourcefilepropertygroup.cpp
+ iarewsourcefilepropertygroup.h
+ iarewsourcefilespropertygroup.cpp
+ iarewsourcefilespropertygroup.h
+ iarewtoolchainpropertygroup.cpp
+ iarewtoolchainpropertygroup.h
+ iarewutils.cpp
+ iarewutils.h
+ iarewversioninfo.h
+ iarewworkspace.cpp
+ iarewworkspace.h
+ iarewworkspacewriter.cpp
+ iarewworkspacewriter.h
+ )
+
+set(ARCHS_ARM_SOURCES
+ armarchiversettingsgroup_v8.cpp
+ armarchiversettingsgroup_v8.h
+ armassemblersettingsgroup_v8.cpp
+ armassemblersettingsgroup_v8.h
+ armbuildconfigurationgroup_v8.cpp
+ armbuildconfigurationgroup_v8.h
+ armcompilersettingsgroup_v8.cpp
+ armcompilersettingsgroup_v8.h
+ armgeneralsettingsgroup_v8.cpp
+ armgeneralsettingsgroup_v8.h
+ armlinkersettingsgroup_v8.cpp
+ armlinkersettingsgroup_v8.h
+ )
+list_transform_prepend(ARCHS_ARM_SOURCES archs/arm/)
+
+set(ARCHS_AVR_SOURCES
+ avrarchiversettingsgroup_v7.cpp
+ avrarchiversettingsgroup_v7.h
+ avrassemblersettingsgroup_v7.cpp
+ avrassemblersettingsgroup_v7.h
+ avrbuildconfigurationgroup_v7.cpp
+ avrbuildconfigurationgroup_v7.h
+ avrcompilersettingsgroup_v7.cpp
+ avrcompilersettingsgroup_v7.h
+ avrgeneralsettingsgroup_v7.cpp
+ avrgeneralsettingsgroup_v7.h
+ avrlinkersettingsgroup_v7.cpp
+ avrlinkersettingsgroup_v7.h
+ )
+list_transform_prepend(ARCHS_AVR_SOURCES archs/avr/)
+
+set(ARCHS_MCS51_SOURCES
+ mcs51archiversettingsgroup_v10.cpp
+ mcs51archiversettingsgroup_v10.h
+ mcs51assemblersettingsgroup_v10.cpp
+ mcs51assemblersettingsgroup_v10.h
+ mcs51buildconfigurationgroup_v10.cpp
+ mcs51buildconfigurationgroup_v10.h
+ mcs51compilersettingsgroup_v10.cpp
+ mcs51compilersettingsgroup_v10.h
+ mcs51generalsettingsgroup_v10.cpp
+ mcs51generalsettingsgroup_v10.h
+ mcs51linkersettingsgroup_v10.cpp
+ mcs51linkersettingsgroup_v10.h
+ )
+list_transform_prepend(ARCHS_MCS51_SOURCES archs/mcs51/)
+
+set(ARCHS_STM8_SOURCES
+ stm8archiversettingsgroup_v3.cpp
+ stm8archiversettingsgroup_v3.h
+ stm8assemblersettingsgroup_v3.cpp
+ stm8assemblersettingsgroup_v3.h
+ stm8buildconfigurationgroup_v3.cpp
+ stm8buildconfigurationgroup_v3.h
+ stm8compilersettingsgroup_v3.cpp
+ stm8compilersettingsgroup_v3.h
+ stm8generalsettingsgroup_v3.cpp
+ stm8generalsettingsgroup_v3.h
+ stm8linkersettingsgroup_v3.cpp
+ stm8linkersettingsgroup_v3.h
+ )
+list_transform_prepend(ARCHS_STM8_SOURCES archs/stm8/)
+
+set(ARCHS_MSP430_SOURCES
+ msp430archiversettingsgroup_v7.cpp
+ msp430archiversettingsgroup_v7.h
+ msp430assemblersettingsgroup_v7.cpp
+ msp430assemblersettingsgroup_v7.h
+ msp430buildconfigurationgroup_v7.cpp
+ msp430buildconfigurationgroup_v7.h
+ msp430compilersettingsgroup_v7.cpp
+ msp430compilersettingsgroup_v7.h
+ msp430generalsettingsgroup_v7.cpp
+ msp430generalsettingsgroup_v7.h
+ msp430linkersettingsgroup_v7.cpp
+ msp430linkersettingsgroup_v7.h
+ )
+list_transform_prepend(ARCHS_MSP430_SOURCES archs/msp430/)
+
+add_qbs_plugin(iarewgenerator
+ DEPENDS corelib qbsjson
+ SOURCES
+ ${COMMON_SOURCES}
+ ${ARCHS_ARM_SOURCES}
+ ${ARCHS_AVR_SOURCES}
+ ${ARCHS_MCS51_SOURCES}
+ ${ARCHS_STM8_SOURCES}
+ ${ARCHS_MSP430_SOURCES}
+ )
diff --git a/src/plugins/generator/keiluv/CMakeLists.txt b/src/plugins/generator/keiluv/CMakeLists.txt
new file mode 100644
index 000000000..68229a2bc
--- /dev/null
+++ b/src/plugins/generator/keiluv/CMakeLists.txt
@@ -0,0 +1,80 @@
+set(COMMON_SOURCES
+ keiluvfilesgroupspropertygroup.cpp
+ keiluvfilesgroupspropertygroup.h
+ keiluvgenerator.cpp
+ keiluvgenerator.h
+ keiluvgeneratorplugin.cpp
+ keiluvproject.cpp
+ keiluvproject.h
+ keiluvprojectwriter.cpp
+ keiluvprojectwriter.h
+ keiluvutils.cpp
+ keiluvutils.h
+ keiluvversioninfo.h
+ keiluvworkspace.cpp
+ keiluvworkspace.h
+ keiluvworkspacewriter.cpp
+ keiluvworkspacewriter.h
+ )
+
+set(ARCHS_ARM_SOURCES
+ armbuildtargetgroup_v5.cpp
+ armbuildtargetgroup_v5.h
+ armcommonpropertygroup_v5.cpp
+ armcommonpropertygroup_v5.h
+ armdebugoptiongroup_v5.cpp
+ armdebugoptiongroup_v5.h
+ armdlloptiongroup_v5.cpp
+ armdlloptiongroup_v5.h
+ armtargetassemblergroup_v5.cpp
+ armtargetassemblergroup_v5.h
+ armtargetcommonoptionsgroup_v5.cpp
+ armtargetcommonoptionsgroup_v5.h
+ armtargetcompilergroup_v5.cpp
+ armtargetcompilergroup_v5.h
+ armtargetgroup_v5.cpp
+ armtargetgroup_v5.h
+ armtargetlinkergroup_v5.cpp
+ armtargetlinkergroup_v5.h
+ armtargetmiscgroup_v5.cpp
+ armtargetmiscgroup_v5.h
+ armutilitiesgroup_v5.cpp
+ armutilitiesgroup_v5.h
+ )
+list_transform_prepend(ARCHS_ARM_SOURCES archs/arm/)
+
+set(ARCHS_MCS51_SOURCES
+ mcs51buildtargetgroup_v5.cpp
+ mcs51buildtargetgroup_v5.h
+ mcs51commonpropertygroup_v5.cpp
+ mcs51commonpropertygroup_v5.h
+ mcs51debugoptiongroup_v5.cpp
+ mcs51debugoptiongroup_v5.h
+ mcs51dlloptiongroup_v5.cpp
+ mcs51dlloptiongroup_v5.h
+ mcs51targetassemblergroup_v5.cpp
+ mcs51targetassemblergroup_v5.h
+ mcs51targetcommonoptionsgroup_v5.cpp
+ mcs51targetcommonoptionsgroup_v5.h
+ mcs51targetcompilergroup_v5.cpp
+ mcs51targetcompilergroup_v5.h
+ mcs51targetgroup_v5.cpp
+ mcs51targetgroup_v5.h
+ mcs51targetlinkergroup_v5.cpp
+ mcs51targetlinkergroup_v5.h
+ mcs51targetmiscgroup_v5.cpp
+ mcs51targetmiscgroup_v5.h
+ mcs51utilitiesgroup_v5.cpp
+ mcs51utilitiesgroup_v5.h
+ mcs51utils.cpp
+ mcs51utils.h
+ )
+list_transform_prepend(ARCHS_MCS51_SOURCES archs/mcs51/)
+
+add_qbs_plugin(keiluvgenerator
+ DEPENDS corelib qbsjson
+ SOURCES
+ ${COMMON_SOURCES}
+ ${ARCHS_ARM_SOURCES}
+ ${ARCHS_MCS51_SOURCES}
+ )
diff --git a/src/plugins/generator/makefilegenerator/CMakeLists.txt b/src/plugins/generator/makefilegenerator/CMakeLists.txt
new file mode 100644
index 000000000..bf6abae73
--- /dev/null
+++ b/src/plugins/generator/makefilegenerator/CMakeLists.txt
@@ -0,0 +1,10 @@
+set(SOURCES
+ makefilegenerator.cpp
+ makefilegenerator.h
+ makefilegeneratorplugin.cpp
+ )
+
+add_qbs_plugin(makefilegenerator
+ DEPENDS corelib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/plugins/generator/visualstudio/CMakeLists.txt b/src/plugins/generator/visualstudio/CMakeLists.txt
new file mode 100644
index 000000000..cd83e0b66
--- /dev/null
+++ b/src/plugins/generator/visualstudio/CMakeLists.txt
@@ -0,0 +1,25 @@
+set(SOURCES
+ msbuildfiltersproject.cpp
+ msbuildfiltersproject.h
+ msbuildqbsgenerateproject.cpp
+ msbuildqbsgenerateproject.h
+ msbuildqbsproductproject.cpp
+ msbuildqbsproductproject.h
+ msbuildsharedsolutionpropertiesproject.cpp
+ msbuildsharedsolutionpropertiesproject.h
+ msbuildsolutionpropertiesproject.cpp
+ msbuildsolutionpropertiesproject.h
+ msbuildtargetproject.cpp
+ msbuildtargetproject.h
+ msbuildutils.h
+ visualstudiogenerator.cpp
+ visualstudiogenerator.h
+ visualstudioguidpool.cpp
+ visualstudioguidpool.h
+ visualstudiogeneratorplugin.cpp
+ )
+
+add_qbs_plugin(visualstudiogenerator
+ DEPENDS corelib qbsmsbuild qbsjson
+ SOURCES ${SOURCES}
+ )
diff --git a/src/plugins/scanner/CMakeLists.txt b/src/plugins/scanner/CMakeLists.txt
new file mode 100644
index 000000000..e4cbfb9e7
--- /dev/null
+++ b/src/plugins/scanner/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(cpp)
+add_subdirectory(qt)
diff --git a/src/plugins/scanner/cpp/CMakeLists.txt b/src/plugins/scanner/cpp/CMakeLists.txt
new file mode 100644
index 000000000..b394dd74d
--- /dev/null
+++ b/src/plugins/scanner/cpp/CMakeLists.txt
@@ -0,0 +1,16 @@
+set(SOURCES
+ ../scanner.h
+ CPlusPlusForwardDeclarations.h
+ Lexer.cpp
+ Lexer.h
+ Token.cpp
+ Token.h
+ cpp_global.h
+ cppscanner.cpp
+ )
+
+add_qbs_plugin(qbs_cpp_scanner
+ DEFINES "CPLUSPLUS_NO_PARSER"
+ DEPENDS corelib
+ SOURCES ${SOURCES}
+ )
diff --git a/src/plugins/scanner/qt/CMakeLists.txt b/src/plugins/scanner/qt/CMakeLists.txt
new file mode 100644
index 000000000..69771fa3a
--- /dev/null
+++ b/src/plugins/scanner/qt/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_qbs_plugin(qbs_qt_scanner
+ DEPENDS corelib
+ SOURCES ../scanner.h qtscanner.cpp
+ )
diff --git a/src/shared/CMakeLists.txt b/src/shared/CMakeLists.txt
new file mode 100644
index 000000000..7a340d53d
--- /dev/null
+++ b/src/shared/CMakeLists.txt
@@ -0,0 +1 @@
+add_subdirectory(json)
diff --git a/src/shared/json/CMakeLists.txt b/src/shared/json/CMakeLists.txt
new file mode 100644
index 000000000..a25124cd9
--- /dev/null
+++ b/src/shared/json/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_qbs_library(qbsjson
+ STATIC
+ SOURCES json.cpp json.h
+ )