src.qbs 1.89 KB
Newer Older
1
import qbs
2
import qbs.File
3
import qbs.FileInfo
4 5 6 7 8 9 10 11 12 13

Project {
    name: "Sources"
    references: [
        "app/app.qbs",
        "app/app_version_header.qbs",
        "libs/libs.qbs",
        "plugins/plugins.qbs",
        "tools/tools.qbs"
    ]
14 15

    property bool qbsSubModuleExists: File.exists(qbsProject.qbsBaseDir + "/qbs.qbs")
16
    property path qbs_install_dir: qbs.getEnv("QBS_INSTALL_DIR")
17
    property bool useExternalQbs: qbs_install_dir
18
    property bool buildQbsProjectManager: useExternalQbs || qbsSubModuleExists
19 20 21 22 23 24 25
    Project {
        name: "qbs"
        id: qbsProject
        property string qbsBaseDir: path + "/shared/qbs"
        condition: qbsSubModuleExists && !useExternalQbs

        property bool enableUnitTests: false
Christian Kandeler's avatar
Christian Kandeler committed
26
        property bool enableProjectFileUpdates: true
27
        property bool installApiHeaders: false
28 29
        property string libInstallDir: project.ide_library_path
        property stringList libRPaths:  qbs.targetOS.contains("osx")
30 31
            ? ["@loader_path/" + FileInfo.relativePath(appInstallDir, libInstallDir)]
            : ["$ORIGIN/..", "$ORIGIN/../" + project.ide_library_path]
32
        property string resourcesInstallDir: project.ide_data_path + "/qbs"
33 34 35
        property string pluginsInstallDir: qbs.targetOS.contains("windows")
            ? project.libDirName + "/qtcreator"
            : project.ide_library_path
36
        property string appInstallDir: project.ide_bin_path
37 38 39
        property string relativePluginsPath: FileInfo.relativePath(appInstallDir, pluginsInstallDir)
        property string relativeSearchPath: FileInfo.relativePath(appInstallDir,
                                                                  resourcesInstallDir)
40 41

        references: [
42
            qbsBaseDir + "/src/lib/libs.qbs",
43
            qbsBaseDir + "/src/plugins/plugins.qbs",
44 45
            qbsBaseDir + "/share/share.qbs",
            qbsBaseDir + "/src/app/apps.qbs",
46 47
        ]
    }
48
}