OpenAl Framework added to project

Sage
Posts: 1,199
Joined: 2004.10
Post: #16
OneSadCookie Wrote:OpenAL is LGPLed, so an application linking statically to it must still meet the LGPL's conditions on relinking -- either by being open-source, or by making all the .o files available, together with a script to re-link the program.

That's fair -- and makes sense. I can't speak for Kodex but I intend to release my game as GPL when it reaches a suitable milestone. I've released a fair amount under the GPL in my time.

akb825:
Are you *sure* you're supposed to include the full app path instead of "@executable_path"? I've never used install_name_tool, I build my frameworks from XCode and take care of it through the build settings. But considering that otool outputs the string literal "@executable_path" implies to me that my understanding is correct. It's a relative path name, having *nothing* to do with where your app is on the filesystem.
Quote this message in a reply
Moderator
Posts: 613
Joined: 2004.09
Post: #17
Getting undefined symbols on all OpenAL calls.

[Image: Picture1.png]
[Image: Picture2.png]
[Image: Picture3.png]

Kyle Richter
DragonForged.com
Twitter: @kylerichter
Quote this message in a reply
Sage
Posts: 1,199
Joined: 2004.10
Post: #18
Did you add libopenal.a to your project?

That said -- OSC's right, you can't use a statically linked OpenAL unless you comply to the LGPL rules. Of course, if this is just for yourself, who cares...
Quote this message in a reply
Moderator
Posts: 613
Joined: 2004.09
Post: #19
Yea it was added to the project, but since this wont be open source I think I will have to go back to trying to get it working the other way. I recall having the same problem about a year ago and having to go with FMOD for the project.

Kyle Richter
DragonForged.com
Twitter: @kylerichter
Quote this message in a reply
Sage
Posts: 1,199
Joined: 2004.10
Post: #20
Just found this ( woo spotlight! ) -- I built it from Apple's CVS, it's got the @executable_path correctly set.

http://zakariya.net/shamyl/etc/OpenAL.framework.zip

Just drop it in, and add it to your copy files build phase.
Quote this message in a reply
Moderator
Posts: 1,140
Joined: 2005.07
Post: #21
TomorrowPlusX Wrote:That's fair -- and makes sense. I can't speak for Kodex but I intend to release my game as GPL when it reaches a suitable milestone. I've released a fair amount under the GPL in my time.

akb825:
Are you *sure* you're supposed to include the full app path instead of "@executable_path"? I've never used install_name_tool, I build my frameworks from XCode and take care of it through the build settings. But considering that otool outputs the string literal "@executable_path" implies to me that my understanding is correct. It's a relative path name, having *nothing* to do with where your app is on the filesystem.
The first path was the part where he was messing up. The second part, if you notice, uses @executable_path. Smile
Quote this message in a reply
Moderator
Posts: 613
Joined: 2004.09
Post: #22
Tomorrow,
That linked one didnt work either. Still no luck with the terminal

Kyle Richter
DragonForged.com
Twitter: @kylerichter
Quote this message in a reply
Moderator
Posts: 1,140
Joined: 2005.07
Post: #23
Show us the printout from otool -L (or -l, both will show you the info you want), and we'll tell you exactly what to put in to the terminal. Also, show us your last attempt at using install_name_tool so we can tell you where you went wrong.

Edit: what I told you before also was assuming you didn't rebuild. If you did rebuild, this is what you need to type in:
install_name_tool -change "/System/Library/Frameworks/OpenAL.framework/Versions/A/OpenAL" "@executable_path/../Frameworks/OpenAL.framework/Versions/A/OpenAL" "openGLBase.app/Contents/MacOS/openGLBase"

if the current directory is the directory with the application bundle.
Quote this message in a reply
Member
Posts: 116
Joined: 2002.04
Post: #24
If you're getting undefined symbols, then you didn't actually add it to the project. Generally, you'd put it under "External Frameworks and Libraries"

If you post the line that does the actual linking, we can see if it did try to link it.

Wade
Quote this message in a reply
Moderator
Posts: 613
Joined: 2004.09
Post: #25
akb

odexs-Computer:~ kodex$ install_name_tool -change "/System/Library/Frameworks/OpenAL.framework/Versions/A/OpenAL" "@/user/openGLBase.app/Contents/MacOS/openGLBase/../Frameworks/OpenAL.framework/Versions/A/OpenAL" "/Users/openGLBase.app/Contents/MacOS/openGLBase"
Kodexs-Computer:~ kodex$ otool -L /Users/openGLBase.app/Contents/MacOS/openGLBase
/Users/openGLBase.app/Contents/MacOS/openGLBase:
/System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa (compatibility version 1.0.0, current version 11.0.0)
/System/Library/Frameworks/Carbon.framework/Versions/A/Carbon (compatibility version 2.0.0, current version 128.0.0)
/System/Library/Frameworks/AGL.framework/Versions/A/AGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/QuickTime.framework/Versions/A/QuickTime (compatibility version 1.0.0, current version 6.0.0)
@/executable_path/openGLBase.app/Contents/MacOS/openGLBase/../Frameworks/OpenAL.framework/Versions/A/OpenAL (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libmx.A.dylib (compatibility version 1.0.0, current version 92.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 88.1.2)
Kodexs-Computer:~ kodex$

Kyle Richter
DragonForged.com
Twitter: @kylerichter
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #26
no slash after the @
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #27
anyway, should be exactly

Code:
install_name_tool -change "/System/Library/Frameworks/OpenAL.framework/Versions/A/OpenAL" "@executable_path/../Frameworks/OpenAL.framework/Versions/A/OpenAL" "/Users/openGLBase.app/Contents/MacOS/openGLBase"
Quote this message in a reply
Moderator
Posts: 613
Joined: 2004.09
Post: #28
Thanks guys that seemed to have gotten it working, sorry it took me so long.

Kyle Richter
DragonForged.com
Twitter: @kylerichter
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Added SDL_ttf framework to project - can't include headers matticus 3 4,299 Oct 15, 2004 01:14 PM
Last Post: OneSadCookie