Can the name of the bundle application be different of the name of the executable file?

198 views Asked by At

I have a sandboxed login item whose executable file name is something like X174423.MyApp because it is prefixed with my developer ID. I'd like to set the bundle name for this helper application to MyApp.

In Xcode 5, I've tried to change the bundle display name but the name of the bundle does'nt change.

I've created a CFBundleDisplayName entry in the InfoPlist.strings but the name of the bundle reminds the same.

It seems that I've missed something but what ?

1

There are 1 answers

1
mahal tertin On

If I understand correctly, you'd like to have the bundle to be shown in Finder as MyApp. I don't know why exactly it has to be like this, but it's working for us the following way. In your Apps Info.plist:

  <key>CFBundleDisplayName</key>
  <string>X174423.MyApp</string>
  <key>CFBundleName</key>
  <string>X174423.MyApp</string>

and following in the InfoPlist.strings:

  /* Localized versions of Info.plist keys */
   CFBundleDisplayName = "MyApp";
   CFBundleName = "MyApp";

Alternatively you could try this in Info.plist and don't use InfoPlist.strings:

  <key>CFBundleExecutable</key>
  <string>X174423.MyApp</string>
  <key>CFBundleDisplayName</key>
  <string>MyApp</string>
  <key>CFBundleName</key>
  <string>MyApp</string>