Putting OpenAL in Framework Folder

Mac desktop question:
Hi there… I’m trying to implement the OpenAL framework in my software. Right now I have to get the user to install it before they can run it.
What I want to do is copy the folder OpenAL.framework in the framework folder
the directory to copy to is here
Mac OSX/Library/Frameworks/

How do I do this… I cannot seem to find a way of accessing this folder. So how would I do this?
Do I use a terminal command?
The OpenAl.Framework is in my resource folder

If the OpenAL.framework folder contains only files, use a Copy Files build step (Insert menu) to copy the files it contains into the OpenAL.framework subfolder of the framework folder.

If the OpenAL.framework folder contains a whole directory structure, you may want to use instead a bash script you call from a script using DoShelCommand. Or simply copy the folder manually into the bundle.

I used this

f=SpecialFolder.System.child("Library").Child("Frameworks").child("OpenAL.framework") if f.exists<>true then dim ff as FolderItem=app.ExecutableFile.Parent.Parent.Child("Resources").Child("OpenAL").Child("OpenAL.framework") ff.CopyFileTo(f) end if

it didn’t work… could I use a shell.execute command - what would be the syntax for that?

I also tried this to no avail:

[code] f=SpecialFolder.System.child(“Library”).Child(“Frameworks”).child(“OpenAL.framework”)
if f.exists<>true then

  dim ff as FolderItem=app.ExecutableFile.Parent.Parent.Child("Resources").Child("OpenAL").Child("OpenAL.framework")
  f=SpecialFolder.System.child("Library").Child("Frameworks")
  msgbox f.NativePath+"     "+ff.NativePath
  dim s as shell
  s.Execute "cp -r "+ff.NativePath+" "+f.NativePath+"/"
end if[/code]

Under the Build Settings header in the sidebar, open the OS X item
From the Insert > Build Step menu, select Copy Files
Drop the framework bundle to the listbox that appears
Select the proper destination for it in the Inspector (Destination popup menu)

[quote=188168:@Sean Clancy]I also tried this to no avail:

[code] f=SpecialFolder.System.child(“Library”).Child(“Frameworks”).child(“OpenAL.framework”)
if f.exists<>true then

  dim ff as FolderItem=app.ExecutableFile.Parent.Parent.Child("Resources").Child("OpenAL").Child("OpenAL.framework")
  f=SpecialFolder.System.child("Library").Child("Frameworks")
  msgbox f.NativePath+"     "+ff.NativePath
  dim s as shell
  s.Execute "cp -r "+ff.NativePath+" "+f.NativePath+"/"
end if[/code][/quote]

You have not read my reply, right after your original post, two hours ago :frowning:

[quote=188161:@Michel Bujardet]If the OpenAL.framework folder contains only files, use a Copy Files build step (Insert menu) to copy the files it contains into the OpenAL.framework subfolder of the framework folder.

If the OpenAL.framework folder contains a whole directory structure, you may want to use instead a bash script you call from a script using DoShelCommand. Or simply copy the folder manually into the bundle.[/quote]

Maybe it’s because of the second paragraph where you recommend to use a bash script if the framework contains folders… Just let the built-in tools do the work (your first paragraph) as they seem to work regardless of just files or whole directory structures…

I did not know it was able to copy entire structures. Thank you for mentioning it.

Maybe I confused with the dragging into the project, which does take files only.

Yes, in the project you can only drag files, but in the Copy Files build step, you can drop folders/bundles…

OpenAL framework
Is it not already integrated in os x?

Axel, good question. Per this link:
https://developer.apple.com/library/mac/documentation/MacOSX/Conceptual/OSX_Technology_Overview/SystemFrameworks/SystemFrameworks.html
the OpenAL framework has been available in OS X since 10.4.
Sean, are you working with the Apple supplied framework, or a different one (possibly the Cross-Platform one (by Roger Meier and Thomas Cunningham))?

I must ask what is your intention of including this within the Application Bundle? Are you intending to release this application on the Mac App Store, you’ll get rejected for including an Apple frameworks within your application bundle, trust me, I’ve tried.