Jump to content
Server Maintenance This Week. ×

Runtime as Mac OS X App Bundle?


rrr

This topic is 4702 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Anyone have any tips or methods in regards to packing an FMP runtime solution into a single Mac OS X app bundle (for the purposes of easy launching, distribution, etc?)

ie: packing the .usr solution file, the runtime application the Extensions folder, and even the FMP Acknowledgements pdf, I guess, into a single double-clickable bundle?

Is this possible? Unadvisable? Any insight?

Thanks,

rrr

Link to comment
Share on other sites

Yes, it's possible, I've done it myself. Even created a runtime as a background process! Busy, can't supply more details at the moment.

Bruce

Link to comment
Share on other sites

Yeah, ideally, I would be able to embed the .usr file(s) and the Extensions folder right inside of the existing runtime app bundle, but I don't know how to get the runtime app bundle to look for those resources inside of itself, instead of its parent directory. It may not be possible to go that route, but surely there is a decent way to bundle all of those resources together into a single double-clickable entity.

Rusty

Link to comment
Share on other sites

Hi Rusty,

This is actually much easier to do on a Mac than on Windows. I currently use Iceberg with XCode Developer tools. You can download XCode from Apple's Developer tools website and you can get Iceberg from this link, http://www.versiontracker.com/dyn/moreinfo/macosx/22849.

Once you get comfortable with the options available it is a straight forward process of configuring your Install, everything from Install Scripts to the individual files you need to package. All completely free!

Best Regards,

FMBiz.net

Link to comment
Share on other sites

Thanks, although I believe Iceberg is used to create an installer package, and this is not really what I am trying to do.

Rather, I am simply trying to wrap the solution file (.usr) and Extensions folder into the runtime's application bundle, so that the whole shebang can be treated by the user as a single, double-clickable entity.

Link to comment
Share on other sites

  • Newbies

It's not elegant, but I created an second application bundle using applescript editor that can open an application placed inside of it.

Below is the code for the applescript. Just change the one line in the script, then save it as an application, and lastly open the new application bundle and drag your runtime solution folder in to the top level of the new bundle. I can't take credit for this--I found the script here

http://macosx.com/forums/mac-os-x-system-mac-software/303487-using-applescript-open-file.html

NOTE: Make sure to separate the folder and file name of your runtime solution with a colon and not a slash.

--Applescript

-- Mac path to a hidden script file in the bundle. CHANGE THE NEXT LINE TO MATCH YOUR RUNTIME FOLDER AND APP NAME

set hiddenscriptpath to (((path to me) as text) & "Folder Name:filemaker runtime app name.app")

-- Converting the Mac path to a Posix path

set hiddenscriptpath to POSIX path of hiddenscriptpath

-- Quoting the Posix path

set qtdhiddenscriptpath to quoted form of hiddenscriptpath

-- executing the script file

try

set command to "open " & qtdhiddenscriptpath

display dialog qtdhiddenscriptpath

do shell script command

end try

Link to comment
Share on other sites

Thanks so much, MickMc. This is exactly what I was looking for. I was beginning to consider approaching this problem with AppleScript, and your contribution does exactly what I need. Very helpful.

Link to comment
Share on other sites

Alternately, you can create the simple applescript app bundle as previously mentioned, but view package contents and set it up like this. Double click the info.plist file and set the application executable reference as shown. In my case:

ToDo.app/Contents/MacOS/Runtime

package_setup.png

Link to comment
Share on other sites

  • 1 year later...

It's not elegant, but I created an second application bundle using applescript editor that can open an application placed inside of it.

Below is the code for the applescript. Just change the one line in the script, then save it as an application, and lastly open the new application bundle and drag your runtime solution folder in to the top level of the new bundle. I can't take credit for this--I found the script here

http://macosx.com/forums/mac-os-x-system-mac-software/303487-using-applescript-open-file.html

NOTE: Make sure to separate the folder and file name of your runtime solution with a colon and not a slash.

--Applescript

-- Mac path to a hidden script file in the bundle. CHANGE THE NEXT LINE TO MATCH YOUR RUNTIME FOLDER AND APP NAME

set hiddenscriptpath to (((path to me) as text) & "Folder Name:filemaker runtime app name.app")

-- Converting the Mac path to a Posix path

set hiddenscriptpath to POSIX path of hiddenscriptpath

-- Quoting the Posix path

set qtdhiddenscriptpath to quoted form of hiddenscriptpath

-- executing the script file

try

set command to "open " & qtdhiddenscriptpath

display dialog qtdhiddenscriptpath

do shell script command

end try

I was hoping that you can answer a question.

I used your script and it works perfectly - but I am having one small issue. When trying to open, I always get a dialog box (see below) and when I click OK everything works. I just don't know

what is causing this dialog to appear, and how to stop it.

I am having errors in trying to create a package (with Packages) and I am guessing that the dialog is causing the issue.

Thanks a bunch!!

Hugh

apptext.jpg

Link to comment
Share on other sites

THat looks like a FileMaker custom dialog: IOW, something the developer has put there for debugging, probably in the startup script.

Link to comment
Share on other sites

THat looks like a FileMaker custom dialog: IOW, something the developer has put there for debugging, probably in the startup script.

Ah, that's interesting - more so since I am the developer. :) This is a database that I built for my business, but now people are asking me for it.

Anyway, I completely disabled the start up script, and still the dialog appears. It just seems to be verifying it's location. It's driving me crazy. Any other thoughts?

Thanks.

Hugh

Link to comment
Share on other sites

still the dialog appears. It just seems to be verifying it's location. It's driving me crazy. Any other thoughts?

I am not sue what exactly you did, but perhaps this has something to do with it:

display dialog qtdhiddenscriptpath

Link to comment
Share on other sites

I am not sue what exactly you did, but perhaps this has something to do with it:

Well, this is my absolute first look at Applescript, and I am not proficient in ANY scripting environment, but a closer look probably would have thrown up that "display dialog" box. Worked perfectly when I removed that line.

I want to thank you very much, you have saved my sanity and I will sleep better tonight! Thank you!!! Vaughan, thank you too.

Hugh

Link to comment
Share on other sites

Long live voodoo programming... :P

This thread being over a year old, perhaps it's time to point to the official version:

http://developer.apple.com/library/mac/#documentation/CoreFoundation/Conceptual/CFBundles/Introduction/Introduction.html

Link to comment
Share on other sites

  • 3 weeks later...

This topic is 4702 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.