forked from qt-creator/qt-creator
Fix library and plugin paths
OSX: Move libraries from PlugIns/ to Frameworks/ other: move QmlDesigner plugins to plugins directory Change-Id: Ia266a3514ce6a496061daa044b3781daae0bc272 Reviewed-by: Christian Stenger <christian.stenger@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
@@ -19,7 +19,7 @@ QtcProduct {
|
|||||||
flags.push("/INCREMENTAL:NO"); // Speed up startup time when debugging with cdb
|
flags.push("/INCREMENTAL:NO"); // Speed up startup time when debugging with cdb
|
||||||
return flags;
|
return flags;
|
||||||
}
|
}
|
||||||
cpp.installNamePrefix: "@rpath/PlugIns/"
|
cpp.installNamePrefix: "@rpath/Frameworks/"
|
||||||
cpp.rpaths: qbs.targetOS.contains("osx")
|
cpp.rpaths: qbs.targetOS.contains("osx")
|
||||||
? ["@loader_path/..", "@executable_path/.."]
|
? ["@loader_path/..", "@executable_path/.."]
|
||||||
: ["$ORIGIN", "$ORIGIN/.."]
|
: ["$ORIGIN", "$ORIGIN/.."]
|
||||||
|
|||||||
@@ -84,8 +84,8 @@ isEmpty(IDE_BUILD_TREE) {
|
|||||||
IDE_APP_PATH = $$IDE_BUILD_TREE/bin
|
IDE_APP_PATH = $$IDE_BUILD_TREE/bin
|
||||||
macx {
|
macx {
|
||||||
IDE_APP_TARGET = "Qt Creator"
|
IDE_APP_TARGET = "Qt Creator"
|
||||||
IDE_LIBRARY_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/PlugIns
|
IDE_LIBRARY_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/Frameworks
|
||||||
IDE_PLUGIN_PATH = $$IDE_LIBRARY_PATH
|
IDE_PLUGIN_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/PlugIns
|
||||||
IDE_LIBEXEC_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/Resources
|
IDE_LIBEXEC_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/Resources
|
||||||
IDE_DATA_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/Resources
|
IDE_DATA_PATH = $$IDE_APP_PATH/$${IDE_APP_TARGET}.app/Contents/Resources
|
||||||
IDE_DOC_PATH = $$IDE_DATA_PATH/doc
|
IDE_DOC_PATH = $$IDE_DATA_PATH/doc
|
||||||
|
|||||||
@@ -45,15 +45,15 @@ exists(src/shared/qbs/qbs.pro) {
|
|||||||
QBS_RESOURCES_INSTALL_DIR = $${QTC_PREFIX}/share/qtcreator/qbs
|
QBS_RESOURCES_INSTALL_DIR = $${QTC_PREFIX}/share/qtcreator/qbs
|
||||||
cache(QBS_RESOURCES_INSTALL_DIR)
|
cache(QBS_RESOURCES_INSTALL_DIR)
|
||||||
macx {
|
macx {
|
||||||
QBS_PLUGINS_BUILD_DIR = $${IDE_LIBRARY_PATH}
|
QBS_PLUGINS_BUILD_DIR = $${IDE_PLUGIN_PATH}
|
||||||
QBS_APPS_RPATH_DIR = @loader_path/../PlugIns
|
QBS_APPS_RPATH_DIR = @loader_path/../Frameworks
|
||||||
} else {
|
} else {
|
||||||
QBS_PLUGINS_BUILD_DIR = $${IDE_BUILD_TREE}/$${IDE_LIBRARY_BASENAME}/qtcreator
|
QBS_PLUGINS_BUILD_DIR = $${IDE_BUILD_TREE}/$${IDE_LIBRARY_BASENAME}/qtcreator/plugins
|
||||||
QBS_APPS_RPATH_DIR = \$\$ORIGIN/../$$IDE_LIBRARY_BASENAME/qtcreator
|
QBS_APPS_RPATH_DIR = \$\$ORIGIN/../$$IDE_LIBRARY_BASENAME/qtcreator
|
||||||
}
|
}
|
||||||
cache(QBS_PLUGINS_BUILD_DIR)
|
cache(QBS_PLUGINS_BUILD_DIR)
|
||||||
cache(QBS_APPS_RPATH_DIR)
|
cache(QBS_APPS_RPATH_DIR)
|
||||||
QBS_PLUGINS_INSTALL_DIR = $${QTC_PREFIX}/$${IDE_LIBRARY_BASENAME}/qtcreator
|
QBS_PLUGINS_INSTALL_DIR = $${QTC_PREFIX}/$${IDE_LIBRARY_BASENAME}/qtcreator/plugins
|
||||||
cache(QBS_PLUGINS_INSTALL_DIR)
|
cache(QBS_PLUGINS_INSTALL_DIR)
|
||||||
QBS_LIBRARY_DIRNAME = $${IDE_LIBRARY_BASENAME}
|
QBS_LIBRARY_DIRNAME = $${IDE_LIBRARY_BASENAME}
|
||||||
cache(QBS_LIBRARY_DIRNAME)
|
cache(QBS_LIBRARY_DIRNAME)
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ Project {
|
|||||||
property string libDirName: "lib"
|
property string libDirName: "lib"
|
||||||
property string ide_library_path: {
|
property string ide_library_path: {
|
||||||
if (qbs.targetOS.contains("osx"))
|
if (qbs.targetOS.contains("osx"))
|
||||||
return ide_app_target + ".app/Contents/PlugIns"
|
return ide_app_target + ".app/Contents/Frameworks"
|
||||||
else if (qbs.targetOS.contains("windows"))
|
else if (qbs.targetOS.contains("windows"))
|
||||||
return ide_app_path
|
return ide_app_path
|
||||||
else
|
else
|
||||||
@@ -28,7 +28,7 @@ Project {
|
|||||||
}
|
}
|
||||||
property string ide_plugin_path: {
|
property string ide_plugin_path: {
|
||||||
if (qbs.targetOS.contains("osx"))
|
if (qbs.targetOS.contains("osx"))
|
||||||
return ide_library_path
|
return ide_app_target + ".app/Contents/PlugIns"
|
||||||
else if (qbs.targetOS.contains("windows"))
|
else if (qbs.targetOS.contains("windows"))
|
||||||
return libDirName + "/qtcreator/plugins"
|
return libDirName + "/qtcreator/plugins"
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ isEmpty(QBS_INSTALL_DIR) {
|
|||||||
QBS_SOURCE_DIR = $$PWD/../../shared/qbs
|
QBS_SOURCE_DIR = $$PWD/../../shared/qbs
|
||||||
include($$QBS_SOURCE_DIR/src/lib/corelib/use_corelib.pri)
|
include($$QBS_SOURCE_DIR/src/lib/corelib/use_corelib.pri)
|
||||||
include($$QBS_SOURCE_DIR/src/lib/qtprofilesetup/use_qtprofilesetup.pri)
|
include($$QBS_SOURCE_DIR/src/lib/qtprofilesetup/use_qtprofilesetup.pri)
|
||||||
macx:QMAKE_LFLAGS += -Wl,-rpath,@loader_path/ # Mac: fix rpath for qbscore soname
|
osx:QMAKE_LFLAGS += -Wl,-rpath,@loader_path/../Frameworks # OS X: fix rpath for qbscore soname
|
||||||
} else {
|
} else {
|
||||||
include($${QBS_INSTALL_DIR}/include/qbs/use_installed_corelib.pri)
|
include($${QBS_INSTALL_DIR}/include/qbs/use_installed_corelib.pri)
|
||||||
include($${QBS_INSTALL_DIR}/include/qbs/use_installed_qtprofilesetup.pri)
|
include($${QBS_INSTALL_DIR}/include/qbs/use_installed_qtprofilesetup.pri)
|
||||||
|
|||||||
@@ -172,7 +172,7 @@ QString QbsProjectParser::pluginsBaseDirectory() const
|
|||||||
+ QLatin1String("/../PlugIns"));
|
+ QLatin1String("/../PlugIns"));
|
||||||
else
|
else
|
||||||
return QDir::cleanPath(QCoreApplication::applicationDirPath()
|
return QDir::cleanPath(QCoreApplication::applicationDirPath()
|
||||||
+ QLatin1String("/../" IDE_LIBRARY_BASENAME "/qtcreator"));
|
+ QLatin1String("/../" IDE_LIBRARY_BASENAME "/qtcreator/plugins"));
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
macx {
|
macx {
|
||||||
DESTDIR = $$IDE_LIBRARY_PATH/QmlDesigner
|
DESTDIR = $$IDE_PLUGIN_PATH/QmlDesigner
|
||||||
} else {
|
} else {
|
||||||
DESTDIR = $$IDE_LIBRARY_PATH/qmldesigner
|
DESTDIR = $$IDE_PLUGIN_PATH/qmldesigner
|
||||||
target.path = $$QTC_PREFIX/$$IDE_LIBRARY_BASENAME/qtcreator/qmldesigner
|
target.path = $$QTC_PREFIX/$$IDE_LIBRARY_BASENAME/qtcreator/plugins/qmldesigner
|
||||||
INSTALLS += target
|
INSTALLS += target
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -139,7 +139,7 @@ bool QmlDesignerPlugin::initialize(const QStringList & /*arguments*/, QString *e
|
|||||||
const QString pluginPath = Utils::HostOsInfo::isMacHost()
|
const QString pluginPath = Utils::HostOsInfo::isMacHost()
|
||||||
? QString(QCoreApplication::applicationDirPath() + "/../PlugIns/QmlDesigner")
|
? QString(QCoreApplication::applicationDirPath() + "/../PlugIns/QmlDesigner")
|
||||||
: QString(QCoreApplication::applicationDirPath() + "/../"
|
: QString(QCoreApplication::applicationDirPath() + "/../"
|
||||||
+ QLatin1String(IDE_LIBRARY_BASENAME) + "/qtcreator/qmldesigner");
|
+ QLatin1String(IDE_LIBRARY_BASENAME) + "/qtcreator/plugins/qmldesigner");
|
||||||
data->pluginManager.setPluginPaths(QStringList() << pluginPath);
|
data->pluginManager.setPluginPaths(QStringList() << pluginPath);
|
||||||
|
|
||||||
createDesignModeWidget();
|
createDesignModeWidget();
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ win32 {
|
|||||||
|
|
||||||
DESTDIR = $$IDE_LIBRARY_PATH
|
DESTDIR = $$IDE_LIBRARY_PATH
|
||||||
|
|
||||||
|
osx: QMAKE_LFLAGS_SONAME = -Wl,-install_name,@rpath/Frameworks/
|
||||||
include(rpath.pri)
|
include(rpath.pri)
|
||||||
|
|
||||||
TARGET = $$qtLibraryName($$TARGET)
|
TARGET = $$qtLibraryName($$TARGET)
|
||||||
|
|||||||
@@ -110,17 +110,8 @@ pluginspec2json.CONFIG += no_link
|
|||||||
moc_header.depends += $$pluginspec2json.output
|
moc_header.depends += $$pluginspec2json.output
|
||||||
QMAKE_EXTRA_COMPILERS += pluginspec2json
|
QMAKE_EXTRA_COMPILERS += pluginspec2json
|
||||||
|
|
||||||
macx {
|
osx: QMAKE_LFLAGS_SONAME = -Wl,-install_name,@rpath/PlugIns/
|
||||||
QMAKE_LFLAGS_SONAME = -Wl,-install_name,@rpath/PlugIns/
|
include(rpath.pri)
|
||||||
QMAKE_LFLAGS += -Wl,-rpath,@loader_path/../,-rpath,@executable_path/../
|
|
||||||
} else:linux-* {
|
|
||||||
#do the rpath by hand since it's not possible to use ORIGIN in QMAKE_RPATHDIR
|
|
||||||
QMAKE_RPATHDIR += \$\$ORIGIN
|
|
||||||
QMAKE_RPATHDIR += \$\$ORIGIN/..
|
|
||||||
IDE_PLUGIN_RPATH = $$join(QMAKE_RPATHDIR, ":")
|
|
||||||
QMAKE_LFLAGS += -Wl,-z,origin \'-Wl,-rpath,$${IDE_PLUGIN_RPATH}\'
|
|
||||||
QMAKE_RPATHDIR =
|
|
||||||
}
|
|
||||||
|
|
||||||
contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
|
contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
macx {
|
macx {
|
||||||
QMAKE_LFLAGS_SONAME = -Wl,-install_name,@rpath/PlugIns/
|
|
||||||
QMAKE_LFLAGS += -Wl,-rpath,@loader_path/../,-rpath,@executable_path/../
|
QMAKE_LFLAGS += -Wl,-rpath,@loader_path/../,-rpath,@executable_path/../
|
||||||
} else:linux-* {
|
} else:linux-* {
|
||||||
#do the rpath by hand since it's not possible to use ORIGIN in QMAKE_RPATHDIR
|
#do the rpath by hand since it's not possible to use ORIGIN in QMAKE_RPATHDIR
|
||||||
|
|||||||
@@ -30,9 +30,7 @@ Project {
|
|||||||
? ["@loader_path/" + FileInfo.relativePath(appInstallDir, libInstallDir)]
|
? ["@loader_path/" + FileInfo.relativePath(appInstallDir, libInstallDir)]
|
||||||
: ["$ORIGIN/..", "$ORIGIN/../" + project.ide_library_path]
|
: ["$ORIGIN/..", "$ORIGIN/../" + project.ide_library_path]
|
||||||
property string resourcesInstallDir: project.ide_data_path + "/qbs"
|
property string resourcesInstallDir: project.ide_data_path + "/qbs"
|
||||||
property string pluginsInstallDir: qbs.targetOS.contains("windows")
|
property string pluginsInstallDir: project.ide_plugin_path
|
||||||
? project.libDirName + "/qtcreator"
|
|
||||||
: project.ide_library_path
|
|
||||||
property string appInstallDir: project.ide_bin_path
|
property string appInstallDir: project.ide_bin_path
|
||||||
property string relativePluginsPath: FileInfo.relativePath(appInstallDir, pluginsInstallDir)
|
property string relativePluginsPath: FileInfo.relativePath(appInstallDir, pluginsInstallDir)
|
||||||
property string relativeSearchPath: FileInfo.relativePath(appInstallDir,
|
property string relativeSearchPath: FileInfo.relativePath(appInstallDir,
|
||||||
|
|||||||
Reference in New Issue
Block a user