diff --git a/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.cpp b/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..3ea888b3bd721b4fa28f8b1d25efcb82609d5e32
--- /dev/null
+++ b/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.cpp
@@ -0,0 +1,42 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#include "cmakebuildconfiguration.h"
+
+CMakeBuildConfiguration::CMakeBuildConfiguration(const QString &name)
+    : BuildConfiguration(name)
+{
+
+}
+
+CMakeBuildConfiguration::CMakeBuildConfiguration(const QString &name, BuildConfiguration *source)
+    : BuildConfiguration(name, source)
+{
+
+}
diff --git a/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.h b/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.h
new file mode 100644
index 0000000000000000000000000000000000000000..be98eecda15da7990bf26413e75d318055873c15
--- /dev/null
+++ b/src/plugins/cmakeprojectmanager/cmakebuildconfiguration.h
@@ -0,0 +1,42 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#ifndef CMAKEBUILDCONFIGURATION_H
+#define CMAKEBUILDCONFIGURATION_H
+
+#include <projectexplorer/buildconfiguration.h>
+
+class CMakeBuildConfiguration : public ProjectExplorer::BuildConfiguration
+{
+public:
+    CMakeBuildConfiguration(const QString &name);
+    CMakeBuildConfiguration(const QString &name, BuildConfiguration *source);
+};
+
+#endif // CMAKEBUILDCONFIGURATION_H
diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.cpp b/src/plugins/cmakeprojectmanager/cmakeproject.cpp
index 8363b7491b5ef183cc3f85638aac3376abde8d7b..34262e966a4db21320574185d8216558a63b82ca 100644
--- a/src/plugins/cmakeprojectmanager/cmakeproject.cpp
+++ b/src/plugins/cmakeprojectmanager/cmakeproject.cpp
@@ -34,6 +34,7 @@
 #include "makestep.h"
 #include "cmakeopenprojectwizard.h"
 #include "cmakebuildenvironmentwidget.h"
+#include "cmakebuildconfiguration.h"
 
 #include <projectexplorer/projectexplorerconstants.h>
 #include <cpptools/cppmodelmanagerinterface.h>
@@ -103,7 +104,7 @@ bool CMakeBuildConfigurationFactory::create(const QString &type) const
                           &ok);
     if (!ok || buildConfigurationName.isEmpty())
         return false;
-    BuildConfiguration *bc = new BuildConfiguration(buildConfigurationName);
+    BuildConfiguration *bc = new CMakeBuildConfiguration(buildConfigurationName);
 
     MakeStep *makeStep = new MakeStep(m_project, bc);
     bc->insertBuildStep(0, makeStep);
@@ -132,6 +133,14 @@ bool CMakeBuildConfigurationFactory::create(const QString &type) const
     return true;
 }
 
+bool CMakeBuildConfigurationFactory::clone(const QString &name, ProjectExplorer::BuildConfiguration *source) const
+{
+    CMakeBuildConfiguration *old = static_cast<CMakeBuildConfiguration *>(source);
+    CMakeBuildConfiguration *bc = new CMakeBuildConfiguration(name, old);
+    m_project->addBuildConfiguration(bc);
+    return true;
+}
+
 /*!
   \class CMakeProject
 */
@@ -649,7 +658,7 @@ bool CMakeProject::restoreSettingsImpl(ProjectExplorer::PersistentSettingsReader
         if (copw.exec() != QDialog::Accepted)
             return false;
 
-        ProjectExplorer::BuildConfiguration *bc = new ProjectExplorer::BuildConfiguration("all");
+        CMakeBuildConfiguration *bc = new CMakeBuildConfiguration("all");
         addBuildConfiguration(bc);
         bc->setValue("msvcVersion", copw.msvcVersion());
         if (!copw.buildDirectory().isEmpty())
diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.h b/src/plugins/cmakeprojectmanager/cmakeproject.h
index 126061c61bebc4f92a0b3553d38d485457b13dd7..38595b525cdbf93604342c9dfaed5583cff86f6b 100644
--- a/src/plugins/cmakeprojectmanager/cmakeproject.h
+++ b/src/plugins/cmakeprojectmanager/cmakeproject.h
@@ -74,6 +74,7 @@ public:
     QString displayNameForType(const QString &type) const;
 
     bool create(const QString &type) const;
+    bool clone(const QString &name, ProjectExplorer::BuildConfiguration *source) const;
 
 private:
     CMakeProject *m_project;
diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.pro b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.pro
index fe516111f6e24d37be03b3d5b24de5ab9cbacfa9..fd898b76754f7ec2126d248a57ac3e5a982061ae 100644
--- a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.pro
+++ b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.pro
@@ -10,7 +10,8 @@ HEADERS = cmakeproject.h \
     makestep.h \
     cmakerunconfiguration.h \
     cmakeopenprojectwizard.h \
-    cmakebuildenvironmentwidget.h
+    cmakebuildenvironmentwidget.h \
+    cmakebuildconfiguration.h
 SOURCES = cmakeproject.cpp \
     cmakeprojectplugin.cpp \
     cmakeprojectmanager.cpp \
@@ -18,7 +19,8 @@ SOURCES = cmakeproject.cpp \
     makestep.cpp \
     cmakerunconfiguration.cpp \
     cmakeopenprojectwizard.cpp \
-    cmakebuildenvironmentwidget.cpp
+    cmakebuildenvironmentwidget.cpp \
+    cmakebuildconfiguration.cpp
 RESOURCES += cmakeproject.qrc
 FORMS += 
 
diff --git a/src/plugins/genericprojectmanager/genericbuildconfiguration.cpp b/src/plugins/genericprojectmanager/genericbuildconfiguration.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..04385f821215479d8163a946747626b44f98362a
--- /dev/null
+++ b/src/plugins/genericprojectmanager/genericbuildconfiguration.cpp
@@ -0,0 +1,46 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#include "genericbuildconfiguration.h"
+
+using namespace GenericProjectManager;
+using namespace GenericProjectManager::Internal;
+using ProjectExplorer::BuildConfiguration;
+
+GenericBuildConfiguration::GenericBuildConfiguration(const QString &name)
+    : BuildConfiguration(name)
+{
+
+}
+
+GenericBuildConfiguration::GenericBuildConfiguration(const QString &name, GenericBuildConfiguration *source)
+    : BuildConfiguration(name, source)
+{
+
+}
diff --git a/src/plugins/genericprojectmanager/genericbuildconfiguration.h b/src/plugins/genericprojectmanager/genericbuildconfiguration.h
new file mode 100644
index 0000000000000000000000000000000000000000..58f05dc447890ca85869afe6d4c22ca2ff45cd90
--- /dev/null
+++ b/src/plugins/genericprojectmanager/genericbuildconfiguration.h
@@ -0,0 +1,48 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#ifndef GENERICBUILDCONFIGURATION_H
+#define GENERICBUILDCONFIGURATION_H
+
+#include <projectexplorer/buildconfiguration.h>
+
+namespace GenericProjectManager {
+    namespace Internal {
+
+
+class GenericBuildConfiguration : public ProjectExplorer::BuildConfiguration
+{
+public:
+    GenericBuildConfiguration(const QString &name);
+    GenericBuildConfiguration(const QString &name, GenericBuildConfiguration *source);
+};
+
+} // namespace GenericProjectManager
+} // namespace Internal
+#endif // GENERICBUILDCONFIGURATION_H
diff --git a/src/plugins/genericprojectmanager/genericproject.cpp b/src/plugins/genericprojectmanager/genericproject.cpp
index 7775582cc4add8d5a44914c8208bd645b4b8454d..25e914a9fb805cf4930e51cd43824f2c4a0358a4 100644
--- a/src/plugins/genericprojectmanager/genericproject.cpp
+++ b/src/plugins/genericprojectmanager/genericproject.cpp
@@ -30,6 +30,7 @@
 #include "genericproject.h"
 #include "genericprojectconstants.h"
 #include "genericmakestep.h"
+#include "genericbuildconfiguration.h"
 
 #include <projectexplorer/toolchain.h>
 #include <projectexplorer/projectexplorerconstants.h>
@@ -145,7 +146,7 @@ bool GenericBuildConfigurationFactory::create(const QString &type) const
                           &ok);
     if (!ok || buildConfigurationName.isEmpty())
         return false;
-    BuildConfiguration *bc = new BuildConfiguration(buildConfigurationName);
+    GenericBuildConfiguration *bc = new GenericBuildConfiguration(buildConfigurationName);
     m_project->addBuildConfiguration(bc); // also makes the name unique...
 
     GenericMakeStep *makeStep = new GenericMakeStep(m_project, bc);
@@ -154,6 +155,14 @@ bool GenericBuildConfigurationFactory::create(const QString &type) const
     return true;
 }
 
+bool GenericBuildConfigurationFactory::clone(const QString &name, BuildConfiguration *source) const
+{
+    // TODO
+    GenericBuildConfiguration *bc = new GenericBuildConfiguration(name, static_cast<GenericBuildConfiguration *>(source));
+    m_project->addBuildConfiguration(bc);
+    return true;
+}
+
 ////////////////////////////////////////////////////////////////////////////////////
 // GenericProject
 ////////////////////////////////////////////////////////////////////////////////////
@@ -518,7 +527,7 @@ bool GenericProject::restoreSettingsImpl(ProjectExplorer::PersistentSettingsRead
     Project::restoreSettingsImpl(reader);
 
     if (buildConfigurations().isEmpty()) {
-        ProjectExplorer::BuildConfiguration *bc = new BuildConfiguration("all");
+        GenericBuildConfiguration *bc = new GenericBuildConfiguration("all");
         addBuildConfiguration(bc);
 
         GenericMakeStep *makeStep = new GenericMakeStep(this, bc);
diff --git a/src/plugins/genericprojectmanager/genericproject.h b/src/plugins/genericprojectmanager/genericproject.h
index 784951aa23a224cd798d7ea93a8db79c6957dbed..c0a3c042036cd20c073c9a4126f4f39e2d220b7f 100644
--- a/src/plugins/genericprojectmanager/genericproject.h
+++ b/src/plugins/genericprojectmanager/genericproject.h
@@ -67,6 +67,7 @@ public:
     QString displayNameForType(const QString &type) const;
 
     bool create(const QString &type) const;
+    bool clone(const QString &name, ProjectExplorer::BuildConfiguration *source) const;
 
 private:
     GenericProject *m_project;
diff --git a/src/plugins/genericprojectmanager/genericprojectmanager.pro b/src/plugins/genericprojectmanager/genericprojectmanager.pro
index a58404176a9c2a66c2eac82bf657cb0ec5001fa5..cc7f6164242d5edc22f55f6c33b375cc7a8a4647 100644
--- a/src/plugins/genericprojectmanager/genericprojectmanager.pro
+++ b/src/plugins/genericprojectmanager/genericprojectmanager.pro
@@ -10,7 +10,8 @@ HEADERS = genericproject.h \
     genericprojectwizard.h \
     genericprojectfileseditor.h \
     pkgconfigtool.h \
-    genericmakestep.h
+    genericmakestep.h \
+    genericbuildconfiguration.h
 SOURCES = genericproject.cpp \
     genericprojectplugin.cpp \
     genericprojectmanager.cpp \
@@ -18,8 +19,8 @@ SOURCES = genericproject.cpp \
     genericprojectwizard.cpp \
     genericprojectfileseditor.cpp \
     pkgconfigtool.cpp \
-    genericmakestep.cpp
+    genericmakestep.cpp \
+    genericbuildconfiguration.cpp
 RESOURCES += genericproject.qrc
 FORMS += genericmakestep.ui
-
 OTHER_FILES += GenericProjectManager.pluginspec
diff --git a/src/plugins/projectexplorer/buildconfiguration.h b/src/plugins/projectexplorer/buildconfiguration.h
index 54ec4a690133b491fe63f565dea393fcf7ebe9cd..a6acb4c1c305ee3b8a06e60a3b30fedd596557d4 100644
--- a/src/plugins/projectexplorer/buildconfiguration.h
+++ b/src/plugins/projectexplorer/buildconfiguration.h
@@ -50,13 +50,14 @@ class PROJECTEXPLORER_EXPORT BuildConfiguration : public QObject
     Q_OBJECT
 
 public:
-    BuildConfiguration(const QString &name);
-    BuildConfiguration(const QString &name, BuildConfiguration *source);
-    ~BuildConfiguration();
+    // ctors are protected
+    virtual ~BuildConfiguration();
+
     QString name() const;
     QString displayName() const;
     void setDisplayName(const QString &name);
 
+    // TODO remove those
     QVariant value(const QString &key) const;
     void setValue(const QString &key, QVariant value);
 
@@ -73,6 +74,10 @@ public:
     void removeCleanStep(int position);
     void moveCleanStepUp(int position);
 
+protected:
+    BuildConfiguration(const QString &name);
+    BuildConfiguration(const QString &name, BuildConfiguration *source);
+
 private:
     void setName(const QString &name);
 
@@ -101,6 +106,14 @@ public:
     // returns true if build configuration(s) actually have been added
     virtual bool create(const QString &type) const = 0;
 
+    // clones a given BuildConfiguration
+    virtual bool clone(const QString &name, BuildConfiguration *source) const = 0;
+
+    // TODO All those methods make the internal name (and display name) unique,
+    // but in different ways
+
+    //virtual bool restore(const QString &name);
+
 // to come:
 // restore
 // clone
diff --git a/src/plugins/projectexplorer/buildsettingspropertiespage.cpp b/src/plugins/projectexplorer/buildsettingspropertiespage.cpp
index fac04077b61ddcce688139013e7fcc1d114740f8..bf2fcf13fd0ee3535849dd950b89b4d9f5decb03 100644
--- a/src/plugins/projectexplorer/buildsettingspropertiespage.cpp
+++ b/src/plugins/projectexplorer/buildsettingspropertiespage.cpp
@@ -356,7 +356,10 @@ void BuildSettingsWidget::cloneConfiguration(const QString &sourceConfiguration)
 
     newBuildConfiguration = Project::makeUnique(newBuildConfiguration, buildConfigurationNames);
 
-    m_project->copyBuildConfiguration(sourceConfiguration, newBuildConfiguration);
+    BuildConfiguration *sourceBc = m_project->buildConfiguration(sourceConfiguration);
+
+    m_project->buildConfigurationFactory()->clone(newBuildConfiguration, sourceBc);
+
     m_project->setDisplayNameFor(m_project->buildConfiguration(newBuildConfiguration), newDisplayName);
 
     m_buildConfiguration = newBuildConfiguration;
diff --git a/src/plugins/projectexplorer/project.cpp b/src/plugins/projectexplorer/project.cpp
index e8c0b31c8443c6de3057cb51731d72d2fe216213..37bd4d3fa0c71be5f48ac2d942caf54b2a1713ce 100644
--- a/src/plugins/projectexplorer/project.cpp
+++ b/src/plugins/projectexplorer/project.cpp
@@ -109,17 +109,6 @@ void Project::removeBuildConfiguration(BuildConfiguration *configuration)
     delete configuration;
 }
 
-void Project::copyBuildConfiguration(const QString &source, const QString &dest)
-{
-    BuildConfiguration *sourceConfiguration = buildConfiguration(source);
-    if (!sourceConfiguration)
-        return;
-
-    m_buildConfigurationValues.push_back(new BuildConfiguration(dest, sourceConfiguration));
-
-    emit addedBuildConfiguration(this, dest);
-}
-
 QList<BuildConfiguration *> Project::buildConfigurations() const
 {
     return m_buildConfigurationValues;
diff --git a/src/plugins/projectexplorer/project.h b/src/plugins/projectexplorer/project.h
index 6ad90351f4f51be2e0527fd01eaa13d8947bcedd..2e7e43a6972806a66a38fedeb7cb4475c0e36554 100644
--- a/src/plugins/projectexplorer/project.h
+++ b/src/plugins/projectexplorer/project.h
@@ -86,7 +86,7 @@ public:
     // Build configuration
     void addBuildConfiguration(BuildConfiguration *configuration);
     void removeBuildConfiguration(BuildConfiguration *configuration);
-    void copyBuildConfiguration(const QString &source, const QString &dest);
+
     BuildConfiguration *buildConfiguration(const QString & name) const;
     QList<BuildConfiguration *> buildConfigurations() const;
     // remove and add "QString uniqueConfigurationDisplayName(const QString &proposedName) const" instead
diff --git a/src/plugins/projectexplorer/session.cpp b/src/plugins/projectexplorer/session.cpp
index 8dcb7c238d2131c1c8583d552e5a577975c82577..8fb3b897d51be1a58c996a363cdab581ac550fa0 100644
--- a/src/plugins/projectexplorer/session.cpp
+++ b/src/plugins/projectexplorer/session.cpp
@@ -853,7 +853,6 @@ Project *SessionManager::projectForFile(const QString &fileName) const
     foreach (Project *p, projectList)
         if (p != currentProject && projectContainsFile(p, fileName))
             return p;
-
     return 0;
 }
 
diff --git a/src/plugins/qt4projectmanager/qt4buildconfiguration.cpp b/src/plugins/qt4projectmanager/qt4buildconfiguration.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..cc62dbe4484d1e851ff77ef020c59252d5e59b57
--- /dev/null
+++ b/src/plugins/qt4projectmanager/qt4buildconfiguration.cpp
@@ -0,0 +1,51 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#include "qt4buildconfiguration.h"
+
+using namespace Qt4ProjectManager;
+using namespace Qt4ProjectManager::Internal;
+using ProjectExplorer::BuildConfiguration;
+
+Qt4BuildConfiguration::Qt4BuildConfiguration(const QString &name)
+    : BuildConfiguration(name)
+{
+
+}
+
+Qt4BuildConfiguration::Qt4BuildConfiguration(const QString &name, Qt4BuildConfiguration *source)
+    : BuildConfiguration(name, source)
+{
+
+}
+
+Qt4BuildConfiguration::~Qt4BuildConfiguration()
+{
+
+}
diff --git a/src/plugins/qt4projectmanager/qt4buildconfiguration.h b/src/plugins/qt4projectmanager/qt4buildconfiguration.h
new file mode 100644
index 0000000000000000000000000000000000000000..d359a7810ae40dd9396698e7bded219b6d6f2771
--- /dev/null
+++ b/src/plugins/qt4projectmanager/qt4buildconfiguration.h
@@ -0,0 +1,50 @@
+/**************************************************************************
+**
+** This file is part of Qt Creator
+**
+** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+**
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** Commercial Usage
+**
+** Licensees holding valid Qt Commercial licenses may use this file in
+** accordance with the Qt Commercial License Agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Nokia.
+**
+** GNU Lesser General Public License Usage
+**
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file.  Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at http://qt.nokia.com/contact.
+**
+**************************************************************************/
+
+#ifndef QT4BUILDCONFIGURATION_H
+#define QT4BUILDCONFIGURATION_H
+
+#include <projectexplorer/buildconfiguration.h>
+
+namespace Qt4ProjectManager {
+namespace Internal {
+
+class Qt4BuildConfiguration : public ProjectExplorer::BuildConfiguration
+{
+public:
+    Qt4BuildConfiguration(const QString &name);
+    // copy ctor
+    Qt4BuildConfiguration(const QString &name, Qt4BuildConfiguration *source);
+    ~Qt4BuildConfiguration();
+};
+
+} // namespace Qt4ProjectManager
+} // namespace Internal
+
+#endif // QT4BUILDCONFIGURATION_H
diff --git a/src/plugins/qt4projectmanager/qt4project.cpp b/src/plugins/qt4projectmanager/qt4project.cpp
index 4f23d4bbbab8f96554890ddb4cb4e813d47de563..7c127bba26301b2d42bd6749700ab3c1f0478070 100644
--- a/src/plugins/qt4projectmanager/qt4project.cpp
+++ b/src/plugins/qt4projectmanager/qt4project.cpp
@@ -41,6 +41,7 @@
 #include "qt4projectmanagerconstants.h"
 #include "projectloadwizard.h"
 #include "qtversionmanager.h"
+#include "qt4buildconfiguration.h"
 
 #ifdef QTCREATOR_WITH_S60
 #include "qt-s60/gccetoolchain.h"
@@ -295,6 +296,14 @@ bool Qt4BuildConfigurationFactory::create(const QString &type) const
     return true;
 }
 
+bool Qt4BuildConfigurationFactory::clone(const QString &name, BuildConfiguration *source) const
+{
+    Qt4BuildConfiguration *oldbc = static_cast<Qt4BuildConfiguration *>(source);
+    Qt4BuildConfiguration *newbc = new Qt4BuildConfiguration(name, oldbc);
+    m_project->addBuildConfiguration(newbc);
+    return true;
+}
+
 /*!
   \class Qt4Project
 
@@ -443,7 +452,7 @@ void Qt4Project::addQt4BuildConfiguration(QString buildConfigurationName, QtVers
     bool debug = qmakeBuildConfiguration & QtVersion::DebugBuild;
 
     // Add the buildconfiguration
-    ProjectExplorer::BuildConfiguration *bc = new ProjectExplorer::BuildConfiguration(buildConfigurationName);
+    Qt4BuildConfiguration *bc = new Qt4BuildConfiguration(buildConfigurationName);
     addBuildConfiguration(bc);
 
     QMakeStep *qmakeStep = new QMakeStep(this, bc);
diff --git a/src/plugins/qt4projectmanager/qt4project.h b/src/plugins/qt4projectmanager/qt4project.h
index d5529125b7648615e7e32a4f28ffa51c548e9c79..84ae43db6138fa78e5a60d0f70ba171a72c98e2a 100644
--- a/src/plugins/qt4projectmanager/qt4project.h
+++ b/src/plugins/qt4projectmanager/qt4project.h
@@ -131,6 +131,7 @@ public:
     QString displayNameForType(const QString &type) const;
 
     bool create(const QString &type) const;
+    bool clone(const QString &name, ProjectExplorer::BuildConfiguration *source) const;
 
     void update();
 
diff --git a/src/plugins/qt4projectmanager/qt4projectconfigwidget.cpp b/src/plugins/qt4projectmanager/qt4projectconfigwidget.cpp
index a309cc7e628d156c3cfcb80446877637a1bae1d1..fdafc76416fe21493073626984e069aa4c972471 100644
--- a/src/plugins/qt4projectmanager/qt4projectconfigwidget.cpp
+++ b/src/plugins/qt4projectmanager/qt4projectconfigwidget.cpp
@@ -165,8 +165,7 @@ void Qt4ProjectConfigWidget::init(const QString &buildConfiguration)
 
 void Qt4ProjectConfigWidget::changeConfigName(const QString &newName)
 {
-    m_pro->setDisplayNameFor(
-            m_pro->buildConfiguration(m_buildConfiguration), newName);
+    m_pro->setDisplayNameFor(m_pro->buildConfiguration(m_buildConfiguration), newName);
 }
 
 void Qt4ProjectConfigWidget::setupQtVersionsComboBox()
diff --git a/src/plugins/qt4projectmanager/qt4projectmanager.pro b/src/plugins/qt4projectmanager/qt4projectmanager.pro
index b30e3fe8c05e614aaaaeb15fa082751a13607ca0..556deeb6a1438f8dd4465665bb1a6f6f79b5cc8d 100644
--- a/src/plugins/qt4projectmanager/qt4projectmanager.pro
+++ b/src/plugins/qt4projectmanager/qt4projectmanager.pro
@@ -39,7 +39,8 @@ HEADERS += qt4projectmanagerplugin.h \
     qtuicodemodelsupport.h \
     externaleditors.h \
     gettingstartedwelcomepagewidget.h \
-    gettingstartedwelcomepage.h
+    gettingstartedwelcomepage.h \
+    qt4buildconfiguration.h
 SOURCES += qt4projectmanagerplugin.cpp \
     qt4projectmanager.cpp \
     qt4project.cpp \
@@ -74,7 +75,8 @@ SOURCES += qt4projectmanagerplugin.cpp \
     qtuicodemodelsupport.cpp \
     externaleditors.cpp \
     gettingstartedwelcomepagewidget.cpp \
-    gettingstartedwelcomepage.cpp
+    gettingstartedwelcomepage.cpp \
+    qt4buildconfiguration.cpp
 FORMS += makestep.ui \
     qmakestep.ui \
     qt4projectconfigwidget.ui \