Qt-interest Archive, July 2007
Qt 4.3: Deploying on Mac OS X
Message 1 in thread
Dear all
we are having problems deploying our application after moving from Qt
4.2.3 QT to 4.3 on a Mac OSX Intel based machine.
after compiling we copy the QT Frameworks in our application bundle
with the following commands:
----------
echo ' Copy QTCore 4.3 Frameworks...'
mkdir -p
tab30qt.app/Contents/Frameworks/QtCore.framework/Versions/4
cp /Library/Frameworks/QtCore.framework/Versions/4/QtCore
tab30qt.app/Contents/Frameworks/QtCore.framework/Versions/4/
echo ' Copy QTGui 4.3 Frameworks...'
mkdir -p
tab30qt.app/Contents/Frameworks/QtGui.framework/Versions/4
cp /Library/Frameworks/QtGui.framework/Versions/4/QtGui
tab30qt.app/Contents/Frameworks/QtGui.framework/Versions/4/
echo ' Copy QTOpenGL 4.3 Frameworks...'
mkdir -p
tab30qt.app/Contents/Frameworks/QtOpenGL.framework/Versions/4
cp /Library/Frameworks/QtOpenGL.framework/Versions/4/QtOpenGL
tab30qt.app/Contents/Frameworks/QtOpenGL.framework/Versions/
4/
echo ' Copy QtSvg 4.3 Frameworks...'
mkdir -p
tab30qt.app/Contents/Frameworks/QtSvg.framework/Versions/4
cp /Library/Frameworks/QtSvg.framework/Versions/4/QtSvg
tab30qt.app/Contents/Frameworks/QtSvg.framework/Versions/4/
echo ' Copy QtXml 4.3 Frameworks...'
mkdir -p
tab30qt.app/Contents/Frameworks/QtXml.framework/Versions/4
cp /Library/Frameworks/QtXml.framework/Versions/4/QtXml
tab30qt.app/Contents/Frameworks/QtXml.framework/Versions/4/
----------
after this we run the install_name_tool:
------------
install_name_tool -change QtCore.framework/Versions/4/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4/Qt
Core tab30qt.app
/Contents/Frameworks/QtGui.framework/Versions/4/QtGui
# QtXml dipende da QTCore
install_name_tool -change QtCore.framework/Versions/4/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4/Qt
Core tab30qt.app
/Contents/Frameworks/QtXml.framework/Versions/4/QtXml
# QtSvg dipende da QtCore, QtGui QtXml
install_name_tool -change QtCore.framework/Versions/4/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4/Qt
Core tab30qt.app
/Contents/Frameworks/QtSvg.framework/Versions/4/QtSvg
install_name_tool -change QtGui.framework/Versions/4/QtGui
@executable_path/../Frameworks/QtGui.framework/Versions/4/Qt
Gui tab30qt.app/Con
tents/Frameworks/QtSvg.framework/Versions/4/QtSvg
install_name_tool -change QtXml.framework/Versions/4/QtXml
@executable_path/../Frameworks/QtXml.framework/Versions/4/Qt
Xml tab30qt.app/Con
tents/Frameworks/QtSvg.framework/Versions/4/QtSvg
# QtOpenGL dipende da QtGui e da QtCore ... gli aggiorno le path
(internamente)
install_name_tool -change QtGui.framework/Versions/4/QtGui
@executable_path/../Frameworks/QtGui.framework/Versions/4/Qt
Gui tab30qt.app/Con
tents/Frameworks/QtOpenGL.framework/Versions/4/QtOpenGL
install_name_tool -change QtCore.framework/Versions/4/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4/Qt
Core tab30qt.app
/Contents/Frameworks/QtOpenGL.framework/Versions/4/QtOpen
GL
------------------
This is the output i get after running otool -L:
----------
otool -L tab30qt
tab30qt:
@executable_path/../Frameworks/libtoonzlib.dylib (compatibility
version 0.0.0, current version 0.0.0)
@executable_path/../Frameworks/libtnzbase.dylib (compatibility
version 0.0.0, current version 0.0.0)
@executable_path/../Frameworks/libtnzcore.dylib (compatibility
version 0.0.0, current version 0.0.0)
@executable_path/../Frameworks/libtnzext.dylib (compatibility
version 0.0.0, current version 0.0.0)
/System/Library/Frameworks/GLUT.framework/Versions/A/GLUT
(compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/QuickTime.framework/Versions/A/Q
uickTime (compatibility version 1.0.0, current version 200.0.0)
@executable_path/../Frameworks/QtSvg.framework/Versions/4/QtS
vg (compatibility version 4.3.0, current version 4.3.0)
@executable_path/../Frameworks/QtXml.framework/Versions/4/Qt
Xml (compatibility version 4.3.0, current version 4.3.0)
@executable_path/../Frameworks/QtOpenGL.framework/Versions/
4/QtOpenGL (compatibility version 4.3.0, current version 4.3.0)
@executable_path/../Frameworks/QtGui.framework/Versions/4/Qt
Gui (compatibility version 4.3.0, current version 4.3.0)
/System/Library/Frameworks/Carbon.framework/Versions/A/Carbo
n (compatibility version 2.0.0, current version 128.0.0)
/System/Library/Frameworks/AppKit.framework/Versions/C/AppK
it (compatibility version 45.0.0, current version 824.42.0)
@executable_path/../Frameworks/QtCore.framework/Versions/4/Q
tCore (compatibility version 4.3.0, current version 4.3.0)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version
1.2.3)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 88.3.9)
/usr/lib/libiconv.2.dylib (compatibility version 5.0.0, current
version 5.0.0)
/System/Library/Frameworks/ApplicationServices.framework/Versio
ns/A/ApplicationServices (compatibility version 1.0.0, current vers
ion 22.0.0)
/System/Library/Frameworks/OpenGL.framework/Versions/A/Ope
nGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/AGL.framework/Versions/A/AGL
(compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current
version 7.4.0)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current
version 1.0.0)
--------
but when i try to run the application this is what i get...
----------
QObject::moveToThread: Current thread (0x222bc20) is not the
object's thread (0x220af30).
Cannot move to target thread (0x220af30)
Cannot open file ':Resources/folder_up.svg', because: Unknown error
QObject::moveToThread: Current thread (0x222bc20) is not the
object's thread (0x220af30).
Cannot move to target thread (0x220af30)
Cannot open file ':Resources/folder_new.svg', because: Unknown error
QObject::moveToThread: Current thread (0x222bc20) is not the
object's thread (0x220af30).
Cannot move to target thread (0x220af30)
QObject::moveToThread: Current thread (0x222bc20) is not the
object's thread (0x220af30).
Cannot move to target thread (0x220af30)
QPixmap: Must construct a QApplication before a QPaintDevice
------------------
then the program closes.
As i said we did not had this problem with QT 4.2.3. while after
installing QT 4.3 this problem appear.
Probably something changed and we are missing something?
Best Regards,
Angelo