3 Replies Latest reply on Feb 7, 2011 2:20 PM by krheinlander

    Mac OS X PackageMaker can't deal with FM runtime



      Mac OS X PackageMaker can't deal with FM runtime


      Hi. I'm developing a runtime application with FM Pro 11 Advanced on Max OS X. After building the runtime, some files, in particular all the *.dls files in the language folders in myFMRuntime.app/Contents/Resources, are locked (you know, the one ancient-type lock that prevents you from rm'ing the file even as root ("operation not permitted")). This causes the PackageMaker to fail to pack my runtime application into the install package. That's weird, but can be solved by the SetFile command, i.e. unlocking all *.dls. After that, PackageMaker builds the package. But it still doesn't install. I still get an "operation not permitted" when the package installer tries to move the temporarily created copy of the runtime to its final destination. Unfortunately, no info about what file in my app exactly causes the problem.


      The problem lies in the runtime app only. Haven't the FM devs ever used PackageMaker to ship a FM runtime? What do I need to do to make PackageMaker work with my FM runtime? Any clue is highly appreciated!

        • 1. Re: Mac OS X PackageMaker can't deal with FM runtime

          Perhaps message 5 of 7 in this thread may help: PackageMaker

          • 2. Re: Mac OS X PackageMaker can't deal with FM runtime

            It doesn't seem to be a chmod privileges issue. It just turned out that performing "SetFile -a l" on each of the files in the runtime app bundle solved the problem. However, this still seem odd to me. Why would FM want to lock some of its runtime files? I can't make perfect sense of that. Is that just a (bug-ish) leftover from the old days?

            • 3. Re: Mac OS X PackageMaker can't deal with FM runtime

              I've not run into this issue, requiring a SetFile command. What I did was first create a POSIX compliant .app file - your description appears to have already accomplished that. 

              -- Applescript

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

              sethiddenscriptpathto (((path tome) astext) & "Contents:Resources:First_Tasks_First:First_Tasks_First.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


              set command to "open " & qtdhiddenscriptpath

              -- display dialog qtdhiddenscriptpath

              do shell script command



              Kinda cool to have a double-clickable, single .app file of your runtime. !!!


              You apparently have copied your runtime into the PACKAGE CONTENTS > RESOURCES folder?

              Running Packagemaker against that, should bring up a number of warnings, but no errors. In the build output window. clicking the magnifying glass icon on the right, highlights the error condition, and explains the repair. Once done, the build completes. 

              The issue I have is that PackageMaker is not compatible with the Apple App Store; apparently Packagemaker created the .pkg file, but is missing the archive step. Attempting to create the build using the compatible command line tool, productbuild, gives me an error that I am, as yet, unable to resolve. 

              sudo productbuild --component /Users/kirkr/Desktop/First_Tasks_First.app /Applications --sign "3rd Party Mac Developer Application: developernamehere" FirstTasksFirst.pkgproductbuild: Adding component at /Users/kirkr/Desktop/First_Tasks_First.appproductbuild: error: Can't write temporary package to "/var/folders/zz/zzzivhrRnAmviuee+++++++++++/-Tmp-/productbuild.HA0fKC/First_Tasks_First.app.pkg" (Path "/Users/kirkr/Desktop/First_Tasks_First.app" is not a valid bundle component (using destination path "/Users/kirkr/Desktop")).