Results 1 to 5 of 5

Thread: Building on OSX

  1. #1
    Join Date
    Sep 2009
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Building on OSX

    I've been developing my QT-based application on Windows without issues for a while now. This evening, I broke out the MacBook Pro to try and get it running on OSX. The project itself builds. However, when launching the app bundle, it fails to load my dyn library.

    My project consists of one app project and one shared library project. The app project depends on the library.

    I've looking up information online and noticed there are several articles related to otool, and several other utilities. What's the best way to include my custom dyn lib in my app bundle?

    Thanks.

  2. #2
    Join Date
    Mar 2007
    Location
    Germany
    Posts
    229
    Thanks
    2
    Thanked 29 Times in 28 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Building on OSX

    I am not familiar with MacOS X, but the easiest way is to place the shared library in the same directory as the executable.

  3. #3
    Join Date
    Sep 2009
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Building on OSX

    Quote Originally Posted by Boron View Post
    I am not familiar with MacOS X, but the easiest way is to place the shared library in the same directory as the executable.
    That's what I'm doing on Windows and it's working fine. However, doing the same thing under OSX with an app bundle doesn't work. It appears that you have to place the lib in the app bundle under frameworks. You then have to adjust it so that the app looks for the lib in the app bundle, and not in a system directory somewhere. I'm just wondering how others are doing this. Do they have a custom step in their build? I'm using Qt Creator at the moment.

  4. #4
    Join Date
    Jun 2009
    Posts
    7
    Thanked 1 Time in 1 Post
    Qt products
    Qt4

    Default Re: Building on OSX

    http://labs.trolltech.com/blogs/2007...ut-the-hassle/

    use deployqt it will copy the libs to the app bundle ...

    you can also do by hand , you can open the application bundle with finder can't remember the right name now of the menu. and copy the libs to the bundle.

  5. #5
    Join Date
    Jan 2009
    Posts
    31
    Thanks
    8
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Building on OSX

    It's the 'View Package Contents.." menu option, but it's probably better to use the deployqt tool really.

Similar Threads

  1. Building VTK with QTCreator
    By floyd.pepper in forum Newbie
    Replies: 1
    Last Post: 17th August 2009, 09:42
  2. Building qt out of source
    By elizabeth.h1 in forum Installation and Deployment
    Replies: 4
    Last Post: 8th August 2009, 17:56
  3. Which Linux distribution is best for building compatible apps?
    By Oxidative in forum Installation and Deployment
    Replies: 8
    Last Post: 9th July 2009, 17:13
  4. Building debug version under VS2008
    By KenW in forum Installation and Deployment
    Replies: 1
    Last Post: 2nd May 2008, 20:09
  5. Building Qt 4.3.4 on Win Vista & MinGW
    By Sirow in forum Installation and Deployment
    Replies: 2
    Last Post: 28th April 2008, 19:27

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.