forked from qt-creator/qt-creator
Add additional instructions on how to use designer plugins from within Mac version of Qt Creator
Merge-request: 138 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
This commit is contained in:
committed by
Friedemann Kleint
parent
9135c8ccb1
commit
1ee76d9dfa
@@ -0,0 +1,116 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
|
||||
** All rights reserved.
|
||||
** Contact: Nokia Corporation (qt-info@nokia.com)
|
||||
**
|
||||
** This file is part of the documentation of the Qt Toolkit.
|
||||
**
|
||||
** $QT_BEGIN_LICENSE:LGPL$
|
||||
** No Commercial Usage
|
||||
** This file contains pre-release code and may not be distributed.
|
||||
** You may use this file in accordance with the terms and conditions
|
||||
** contained in the Technology Preview License Agreement accompanying
|
||||
** this package.
|
||||
**
|
||||
** 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.
|
||||
**
|
||||
** In addition, as a special exception, Nokia gives you certain additional
|
||||
** rights. These rights are described in the Nokia Qt LGPL Exception
|
||||
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
|
||||
**
|
||||
** If you have questions regarding the use of this file, please contact
|
||||
** Nokia at qt-info@nokia.com.
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
**
|
||||
** $QT_END_LICENSE$
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
//! [0]
|
||||
otool -L /Developer/Applications/Qt/plugins/designer/libqwt_designer_plugin.dylib
|
||||
//! [0]
|
||||
|
||||
|
||||
//! [1]
|
||||
/Developer/Applications/Qt/plugins/designer/libqwt_designer_plugin.dylib:
|
||||
libqwt_designer_plugin.dylib (compatibility version 0.0.0, current version 0.0.0)
|
||||
libqwt.5.dylib (compatibility version 5.2.0, current version 5.2.1)
|
||||
QtDesigner.framework/Versions/4/QtDesigner (compatibility version 4.6.0, current version 4.6.2)
|
||||
QtScript.framework/Versions/4/QtScript (compatibility version 4.6.0, current version 4.6.2)
|
||||
QtXml.framework/Versions/4/QtXml (compatibility version 4.6.0, current version 4.6.2)
|
||||
QtGui.framework/Versions/4/QtGui (compatibility version 4.6.0, current version 4.6.2)
|
||||
QtCore.framework/Versions/4/QtCore (compatibility version 4.6.0, current version 4.6.2)
|
||||
/usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 7.9.0)
|
||||
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 438.0.0)
|
||||
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.0.1)
|
||||
//! [1]
|
||||
|
||||
//! [2]
|
||||
otool -L /usr/local/qwt-5.2.1/lib/libqwt.5.dylib
|
||||
//! [2]
|
||||
|
||||
|
||||
//! [3]
|
||||
/usr/local/qwt-5.2.1/lib/libqwt.5.dylib:
|
||||
libqwt.5.dylib (compatibility version 5.2.0, current version 5.2.1)
|
||||
QtGui.framework/Versions/4/QtGui (compatibility version 4.6.0, current version 4.6.2)
|
||||
QtCore.framework/Versions/4/QtCore (compatibility version 4.6.0, current version 4.6.2)
|
||||
/usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 7.9.0)
|
||||
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 438.0.0)
|
||||
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.0.1)
|
||||
//! [3]
|
||||
|
||||
|
||||
//! [4]
|
||||
sudo cp /Developer/Applications/Qt/plugins/designer/libqwt_designer_plugin.dylib \
|
||||
/Developer/Applications/Qt/Qt\ Creator.app/Contents/MacOS/designer
|
||||
sudo cp -R /usr/local/qwt-5.2.1/lib/* \
|
||||
/Developer/Applications/Qt/Qt\ Creator.app/Contents/Frameworks/
|
||||
//! [4]
|
||||
|
||||
|
||||
//! [5]
|
||||
cd /Developer/Applications/Qt/Qt\ Creator.app/Contents/MacOS/designer
|
||||
sudo install_name_tool -change
|
||||
QtCore.framework/Versions/4/QtCore \
|
||||
@executable_path/../Frameworks/libQtCore.4.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
sudo install_name_tool -change QtGui.framework/Versions/4/QtGui \
|
||||
@executable_path/../Frameworks/libQtGui.4.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
sudo install_name_tool -change QtXml.framework/Versions/4/QtXml \
|
||||
@executable_path/../Frameworks/libQtXml.4.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
sudo install_name_tool -change QtScript.framework/Versions/4/QtScript \
|
||||
@executable_path/../Frameworks/libQtScript.4.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
sudo install_name_tool -change QtDesigner.framework/Versions/4/QtDesigner \
|
||||
@executable_path/../Frameworks/libQtDesigner.4.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
sudo install_name_tool -change libqwt.5.dylib \
|
||||
@executable_path/../Frameworks/libqwt.5.dylib \
|
||||
libqwt_designer_plugin.dylib
|
||||
|
||||
cd /Developer/Applications/Qt/Qt\ Creator.app/Contents/Frameworks
|
||||
sudo install_name_tool -change \
|
||||
QtCore.framework/Versions/4/QtCore \
|
||||
@executable_path/../Frameworks/libQtCore.4.dylib \
|
||||
libqwt.5.2.1.dylib
|
||||
sudo install_name_tool -change \
|
||||
QtGui.framework/Versions/4/QtGui \
|
||||
@executable_path/../Frameworks/libQtGui.4.dylib \
|
||||
libqwt.5.2.1.dylib
|
||||
//! [5]
|
||||
+57
-1
@@ -6293,7 +6293,7 @@
|
||||
which one you use.
|
||||
|
||||
The integrated \QD fetches plugins from the \c {%SDK%\bin\designer} folder on Windows
|
||||
and Linux and \c {QtCreator.app/Contents/MacOS/designer} folder on Mac. To check which plugins
|
||||
and Linux. See \l{Additional Steps needed on Mac} for how to do it on Mac. To check which plugins
|
||||
were loaded successfully and which failed, choose \gui{Tools > Form Editor >
|
||||
About Qt Designer Plugins}.
|
||||
|
||||
@@ -6301,6 +6301,62 @@
|
||||
located under \c {%SDK%\qt}. Therefore, it fetches plugins from the following folder:
|
||||
\c {%SDK%\qt\plugins\designer}. To check which plugins were loaded successfully and which
|
||||
failed, choose \gui{Help > About Plugins}.
|
||||
|
||||
\section1 Additional Steps needed on Mac
|
||||
|
||||
Due to the fact that Qt Creator uses its own set of Qt Libraries located in the bundle,
|
||||
you need to reconfigure additional designer plugins you want to use with Qt Creator.
|
||||
Read \l{http://doc.qt.nokia.com/4.6/deployment-mac.html}{Deploying an Application on Mac OS X}
|
||||
to get general information on deploying on Mac.
|
||||
|
||||
The necessary steps of this process are shown by taking version 5.2.1 of the
|
||||
\l{http://qwt.sourceforge.net/}{Qwt - Qt Widgets for Technical Applications} library as a sample.
|
||||
|
||||
In order to check the paths used in the Qwt library use the \c otool:
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 0
|
||||
|
||||
Here is what the output looks like for Qwt 5.2.1
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 1
|
||||
|
||||
This tells us two things:
|
||||
|
||||
\list 1
|
||||
|
||||
\o The plugin itself uses the following Qt core libraries:
|
||||
QtDesigner, QtScript, QtXml, QtGui and QtCore
|
||||
|
||||
\o The plugin also uses \c libqwt.5.dylib
|
||||
|
||||
\endlist
|
||||
|
||||
This means that you need to copy the designer plugin \c {libqwt_designer_plugin.dylib}
|
||||
and the Qwt library files \c {libqwt.*.dylib} to the following locations respectively:
|
||||
|
||||
\list
|
||||
\o \c {libqwt_designer_plugin.dylib} needs to be copied to \c {QtCreator.app/Contents/MacOS/designer}
|
||||
\o and the files \c {libqwt.*.dylib} need to be copied to \c {QtCreator.app/Contents/Frameworks}
|
||||
\endlist
|
||||
|
||||
This can be done by the following commands:
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 4
|
||||
|
||||
We also need to check the libraries that are used by the Qwt library itself. We do this
|
||||
again with the \c otool:
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 2
|
||||
|
||||
which returns the following output:
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 3
|
||||
|
||||
Now we have all the information necessary to fix the references of the used libraries
|
||||
using the \c install_name_tool as:
|
||||
|
||||
\snippet examples/doc_src_plugins.qdoc 5
|
||||
|
||||
|
||||
\section1 Matching Build Keys
|
||||
|
||||
|
||||
Reference in New Issue
Block a user