From 219a43d7458886062b30eb1e36d8f2259f388128 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Einar=20Johan=20Tr=C3=B8an=20S=C3=B8ma=CC=8Aen?= Date: Thu, 9 Apr 2015 18:30:03 +0200 Subject: [PATCH] CREATE_PROJECT: Revert idea about createOneProjectPerEngine. --- devtools/create_project/create_project.cpp | 17 +++++------------ devtools/create_project/create_project.h | 7 ------- devtools/create_project/xcode.h | 3 +-- 3 files changed, 6 insertions(+), 21 deletions(-) diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp index 4113d6c83e6..2f784529bd8 100644 --- a/devtools/create_project/create_project.cpp +++ b/devtools/create_project/create_project.cpp @@ -1285,22 +1285,17 @@ void ProjectProvider::createProject(BuildSetup &setup) { if (i->first == setup.projectName) continue; // Retain the files between engines if we're creating a single project - if (createOneProjectPerEngine()) { - in.clear(); ex.clear(); - } + in.clear(); ex.clear(); + const std::string moduleDir = setup.srcDir + targetFolder + i->first; createModuleList(moduleDir, setup.defines, setup.testDirs, in, ex); - if (createOneProjectPerEngine()) { - createProjectFile(i->first, i->second, setup, moduleDir, in, ex); - } + createProjectFile(i->first, i->second, setup, moduleDir, in, ex); } if (setup.tests) { // Create the main project file. - if (createOneProjectPerEngine()) { - in.clear(); ex.clear(); - } + in.clear(); ex.clear(); createModuleList(setup.srcDir + "/backends", setup.defines, setup.testDirs, in, ex); createModuleList(setup.srcDir + "/backends/platform/sdl", setup.defines, setup.testDirs, in, ex); createModuleList(setup.srcDir + "/base", setup.defines, setup.testDirs, in, ex); @@ -1314,9 +1309,7 @@ void ProjectProvider::createProject(BuildSetup &setup) { createProjectFile(setup.projectName, svmUUID, setup, setup.srcDir, in, ex); } else if (!setup.devTools) { // Last but not least create the main project file. - if (createOneProjectPerEngine()) { - in.clear(); ex.clear(); - } + in.clear(); ex.clear(); // File list for the Project file createModuleList(setup.srcDir + "/backends", setup.defines, setup.testDirs, in, ex); createModuleList(setup.srcDir + "/backends/platform/sdl", setup.defines, setup.testDirs, in, ex); diff --git a/devtools/create_project/create_project.h b/devtools/create_project/create_project.h index cea1222b4d0..459342a67d4 100644 --- a/devtools/create_project/create_project.h +++ b/devtools/create_project/create_project.h @@ -458,13 +458,6 @@ protected: */ virtual const char *getProjectExtension() { return ""; } - /** - * Returns whether the provider produces one project per engine - * allowing providers such as the XCode-project provider to disable - * the logic for this in the super-class, thus merging the engine-files - * into the main project instead. - */ - virtual bool createOneProjectPerEngine() const { return true; } /** * Adds files of the specified directory recursively to given project file. * diff --git a/devtools/create_project/xcode.h b/devtools/create_project/xcode.h index f0b0b1e350d..b02cb5b75c4 100644 --- a/devtools/create_project/xcode.h +++ b/devtools/create_project/xcode.h @@ -45,9 +45,8 @@ protected: void writeFileListToProject(const FileNode &dir, std::ofstream &projectFile, const int indentation, const StringList &duplicate, const std::string &objPrefix, const std::string &filePrefix); - // Disable multi-project creation on ProjectProvider - bool createOneProjectPerEngine() const { return false; } private: + std::string _projectRoot; enum { SettingsAsList = 0x01, SettingsSingleItem = 0x02,