qt-interest@trolltech.com
[Top] [All Lists]

Re: OS X Deployment - Frameworks

Subject: Re: OS X Deployment - Frameworks
From: Kamil Klimek
Date: Thu, 9 Aug 2007 23:00:30 +0200
Please run your application from terminal like this:

cd ~/myApp
./myApp.app/Contents/MacOS/myApp

There "should" be some usefull output.


On Aug 9, 2007, at 10:25 AM, Willy P wrote:

Hey,
I am trying to deploy a dynamically linked app on OS X.  I have read
the docs < http://doc.trolltech.com/4.2/deployment-mac.html > multiple
times and have created the simplest possible case and it doesn't work.
 I am going to be extra explicit b/c I have followed the directions
multiple times and I must be misinterpreting them or not making some
assumption that they are making.

Here goes:

cd ~
mkdir myApp
cd myApp
touch main.cpp

main.cpp looks like this:

#include <QApplication>
#include <QtGui>

int main( int argc, char** argv )
{
        QApplication app( argc, argv );
        QLabel label( "Hello Qt" );
        label.show();
        return app.exec();
}

qmake -project
qmake -spec macx-g++ -config release
make

## my app works fine ##

mkdir myApp.app/Contents/Frameworks
cp -R /Library/Frameworks/QtCore.framework myApp.app/Contents/ Frameworks cp -R /Library/Frameworks/QtGui.framework myApp.app/Contents/ Frameworks

#install_name_tool fun

install_name_tool -id
@executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
myApp.app/Contents/Frameworks/QtCore.framework/Versions/4.0/QtCore

install_name_tool -id
@executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
myApp.app/Contents/Frameworks/QtCore.framework/Versions/4.0/QtGui

install_name_tool -change
/Library/Frameworks/QtCore.framework/Versions/4.0/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
myApp.app/Contents/MacOS/myApp

install_name_tool -change
/Library/Frameworks/QtGui.framework/Versions/4.0/QtGui
@executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
myApp.app/Contents/MacOS/myApp

install_name_tool -change
/Library/Frameworks/QtCore.framework/Versions/4.0/QtCore
@executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
myApp.app/Contents/Frameworks/QtGui.framework/Versions/4.0/QtGui

cd /Library/Frameworks
mkdir hide
copy all the Qt frameworks into the "hide" directory so myApp.app has

Run myApp.app.

It opens and closes quickly.

I don't know what's going wrong and I don't even know how to tell
what's going wrong.

Help me qt user list.  You're my only hope.

Thanks in advance...

-Willy

--
To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
List archive and information: http://lists.trolltech.com/qt-interest/


--
To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with 
"unsubscribe" in the subject or the body.
List archive and information: http://lists.trolltech.com/qt-interest/

<Prev in Thread] Current Thread [Next in Thread>