Include frameworks in my .app

mrknark
Unregistered
 
Post: #1
Hello.
I'm learning C++ and SDL, and I'm coding in Linux. I'm trying to port my program to Mac, and it works fine.. on my computer. When I try to run it on another computer, it needs SDL.framework, SDL_ttf.framework and SDL_image.framework in /Library/Frameworks. But nobody wants to download them and put them there to run my program. I've seen that some .app's have frameworks inside them, so I tried to do this by adding a "copy files build phase", and it did put them in a Frameworks directory inside the .app. But still it needs them to be in /Library/Frameworks, so how do I fix this?

Thanks in advance.
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #2
http://onesadcookie.com/~keith/DynamicLinking.html explains the issue.

It's not usually a problem for SDL though -- it generally has the correct install name by default. Did you build it yourself from the Makefile or something wacky like that?
Quote this message in a reply
mrknark
Unregistered
 
Post: #3
OneSadCookie Wrote:http://onesadcookie.com/~keith/DynamicLinking.html explains the issue.

It's not usually a problem for SDL though -- it generally has the correct install name by default. Did you build it yourself from the Makefile or something wacky like that?
I don't remember how I installed SDL. I _think_ I downloaded it from libsdl.org, but maybe I installed it with darwinports. I'll try to download it from their libsdl.org and re-install it and see if it works.

edit: I tried it now, and it tells me "Undefined symbols: _SDL_Error referenced from @executable_path/../Frameworks/SDL_image.framework/Versions/A/SDL_image expected to be defined in SDL".

edit: It works after I installed the cvs version of SDL. But, it doesn't start when I doubleclick my .app, but it works if I run my.app/Contents/MacOS/my in the terminal.. Sad
Quote this message in a reply
mrknark
Unregistered
 
Post: #4
I fixed this error by using the cvs version of SDL and SDL_image. But now my program doesn't start when I doubleclick on it. It works when I run my.app/Contents/MacOS/my in the terminal.. Mad
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #5
Are there any messages to the Console (/Applications/Utilitites/Console.app) from a Finder launch?
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  problems with ogg/vorbis frameworks johnMG 5 4,757 Mar 11, 2005 07:22 PM
Last Post: johnMG
  Added SDL_ttf framework to project - can't include headers matticus 3 4,307 Oct 15, 2004 01:14 PM
Last Post: OneSadCookie
  Frameworks which call SDL et al sealfin 6 3,853 Dec 31, 2003 05:42 PM
Last Post: Steven
  How do I include the OpenGL in PB? vossile 2 2,593 Sep 9, 2003 05:48 AM
Last Post: vossile
  Finding an include Josh 1 3,013 Nov 9, 2002 06:39 PM
Last Post: OneSadCookie