forked from qt-creator/qt-creator
-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
qbs build: Introduce new module "qtc".
The qtc module gathers properties that used to live in the top-level project file. This is the first step towards making it possible to build plugins against an installed Qt Creator ("out of source build"). Change-Id: Ia1514cc9c888e80be01b308e908de48980fcbdb8 Reviewed-by: Joerg Bornemann <[email protected]>
- Loading branch information
Christian Kandeler
committed
Jun 8, 2016
1 parent
db9437c
commit a0f956f
Showing
48 changed files
with
189 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import qbs | ||
import qbs.FileInfo | ||
|
||
Module { | ||
Depends { name: "qtc" } | ||
|
||
property bool enableUnitTests: false | ||
property bool enableProjectFileUpdates: true | ||
property bool installApiHeaders: false | ||
property string libInstallDir: qtc.ide_library_path | ||
property stringList libRPaths: qbs.targetOS.contains("osx") | ||
? ["@loader_path/" + FileInfo.relativePath('/' + appInstallDir, '/' + libInstallDir)] | ||
: ["$ORIGIN/..", "$ORIGIN/../" + qtc.ide_library_path] | ||
property string resourcesInstallDir: qtc.ide_data_path + "/qbs" | ||
property string pluginsInstallDir: qtc.ide_plugin_path | ||
property string appInstallDir: qtc.ide_bin_path | ||
property string libexecInstallDir: qtc.ide_libexec_path | ||
property string relativeLibexecPath: FileInfo.relativePath('/' + appInstallDir, | ||
'/' + libexecInstallDir) | ||
property string relativePluginsPath: FileInfo.relativePath('/' + appInstallDir, | ||
'/' + pluginsInstallDir) | ||
property string relativeSearchPath: FileInfo.relativePath('/' + appInstallDir, | ||
'/' + resourcesInstallDir) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
import qbs | ||
import qbs.Environment | ||
|
||
Module { | ||
property string ide_version_major: '4' | ||
property string ide_version_minor: '0' | ||
property string ide_version_release: '82' | ||
property string qtcreator_version: ide_version_major + '.' + ide_version_minor + '.' | ||
+ ide_version_release | ||
|
||
property string ide_compat_version_major: '4' | ||
property string ide_compat_version_minor: '0' | ||
property string ide_compat_version_release: '82' | ||
property string qtcreator_compat_version: ide_compat_version_major + '.' | ||
+ ide_compat_version_minor + '.' + ide_compat_version_release | ||
|
||
property string libDirName: "lib" | ||
property string ide_app_path: qbs.targetOS.contains("osx") ? "" : "bin" | ||
property string ide_app_target: qbs.targetOS.contains("osx") ? "Qt Creator" : "qtcreator" | ||
property string ide_library_path: { | ||
if (qbs.targetOS.contains("osx")) | ||
return ide_app_target + ".app/Contents/Frameworks" | ||
else if (qbs.targetOS.contains("windows")) | ||
return ide_app_path | ||
else | ||
return libDirName + "/qtcreator" | ||
} | ||
property string ide_plugin_path: { | ||
if (qbs.targetOS.contains("osx")) | ||
return ide_app_target + ".app/Contents/PlugIns" | ||
else if (qbs.targetOS.contains("windows")) | ||
return libDirName + "/qtcreator/plugins" | ||
else | ||
return ide_library_path + "/plugins" | ||
} | ||
property string ide_data_path: qbs.targetOS.contains("osx") | ||
? ide_app_target + ".app/Contents/Resources" | ||
: "share/qtcreator" | ||
property string ide_libexec_path: qbs.targetOS.contains("osx") | ||
? ide_data_path : qbs.targetOS.contains("windows") | ||
? ide_app_path | ||
: "libexec/qtcreator" | ||
property string ide_bin_path: qbs.targetOS.contains("osx") | ||
? ide_app_target + ".app/Contents/MacOS" | ||
: ide_app_path | ||
property string ide_doc_path: qbs.targetOS.contains("osx") | ||
? ide_data_path + "/doc" | ||
: "share/doc/qtcreator" | ||
|
||
property bool testsEnabled: Environment.getEnv("TEST") || qbs.buildVariant === "debug" | ||
property stringList generalDefines: [ | ||
"QT_CREATOR", | ||
'IDE_LIBRARY_BASENAME="' + libDirName + '"', | ||
"QT_NO_CAST_TO_ASCII", | ||
"QT_RESTRICTED_CAST_FROM_ASCII" | ||
].concat(testsEnabled ? ["WITH_TESTS"] : []) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.