forked from qt-creator/qt-creator
CMake: Make sure there is a "clean" target
Change-Id: I9e3eb49b7f5a2d7d5c89a53969c4703b3ce99330 Reviewed-by: Cristian Adam <cristian.adam@gmail.com> Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
This commit is contained in:
@@ -177,6 +177,16 @@ bool CMakeCbpParser::parseCbpFile(Kit *kit, const QString &fileName, const QStri
|
||||
sortFiles();
|
||||
|
||||
fi.close();
|
||||
|
||||
// There is always a clean target:
|
||||
CMakeBuildTarget cleanTarget;
|
||||
cleanTarget.title = QLatin1String("clean");
|
||||
cleanTarget.targetType = UtilityType;
|
||||
cleanTarget.workingDirectory = m_buildDirectory;
|
||||
cleanTarget.sourceDirectory = m_sourceDirectory;
|
||||
|
||||
m_buildTargets.append(cleanTarget);
|
||||
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@@ -65,7 +65,8 @@ class CMakeManager;
|
||||
enum TargetType {
|
||||
ExecutableType = 0,
|
||||
StaticLibraryType = 2,
|
||||
DynamicLibraryType = 3
|
||||
DynamicLibraryType = 3,
|
||||
UtilityType = 64
|
||||
};
|
||||
|
||||
struct CMAKE_EXPORT CMakeBuildTarget
|
||||
|
Reference in New Issue
Block a user