From e7a477b3a01b54a78b753f48398fec63fbd6316f Mon Sep 17 00:00:00 2001
From: Daniel Molkentin <daniel.molkentin@nokia.com>
Date: Fri, 25 Sep 2009 12:28:44 +0200
Subject: [PATCH] Build system: make 'install' target work on Windows.

Reviewed-By: Oswald Buddenhagen
---
 share/qtcreator/static.pro |  2 +-
 src/app/app.pro            |  2 ++
 src/qtcreatorlibrary.pri   | 13 +++++++++----
 src/qtcreatorplugin.pri    |  2 +-
 4 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/share/qtcreator/static.pro b/share/qtcreator/static.pro
index 1a43be02405..0256c8ad73d 100644
--- a/share/qtcreator/static.pro
+++ b/share/qtcreator/static.pro
@@ -57,7 +57,7 @@ DATA_DIRS = \
     }
 }
 
-unix:!macx {
+!macx {
     for(data_dir, DATA_DIRS) {
         eval($${data_dir}.files = $$quote($$PWD/$$data_dir))
         eval($${data_dir}.path = /share/qtcreator)
diff --git a/src/app/app.pro b/src/app/app.pro
index b1830edff2f..932048f298f 100644
--- a/src/app/app.pro
+++ b/src/app/app.pro
@@ -14,6 +14,8 @@ win32 {
     else:LIBS *= -lExtensionSystem -lAggregation
 
     RC_FILE = qtcreator.rc
+    target.path = /bin
+    INSTALLS += target
 } else:macx {
     CONFIG(debug, debug|release):LIBS *= -lExtensionSystem_debug -lAggregation_debug
     else:LIBS *= -lExtensionSystem -lAggregation
diff --git a/src/qtcreatorlibrary.pri b/src/qtcreatorlibrary.pri
index ecfee84d112..a1663e5b4c9 100644
--- a/src/qtcreatorlibrary.pri
+++ b/src/qtcreatorlibrary.pri
@@ -1,7 +1,7 @@
 include(../qtcreator.pri)
 
 win32 {
-	DLLDESTDIR = $$IDE_APP_PATH
+    DLLDESTDIR = $$IDE_APP_PATH
 }
 
 DESTDIR = $$IDE_LIBRARY_PATH
@@ -12,7 +12,12 @@ TARGET = $$qtLibraryTarget($$TARGET)
 
 contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
 
-unix:!macx {
-	target.path = /$$IDE_LIBRARY_BASENAME/qtcreator
-	INSTALLS += target
+!macx {
+    win32 {
+        target.path = /bin
+        target.files = $$DESTDIR/$${TARGET}.dll
+    } else {
+        target.path = /$$IDE_LIBRARY_BASENAME/qtcreator
+    }
+    INSTALLS += target
 }
diff --git a/src/qtcreatorplugin.pri b/src/qtcreatorplugin.pri
index 15c3f6019ec..7dbe5a87113 100644
--- a/src/qtcreatorplugin.pri
+++ b/src/qtcreatorplugin.pri
@@ -42,7 +42,7 @@ contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
 
 CONFIG += plugin plugin_with_soname
 
-unix:!macx {
+!macx {
     target.path = /$$IDE_LIBRARY_BASENAME/qtcreator/plugins/$$PROVIDER
     pluginspec.files += $${TARGET}.pluginspec
     pluginspec.path = /$$IDE_LIBRARY_BASENAME/qtcreator/plugins/$$PROVIDER
-- 
GitLab