The application cannot be opened because its executable is missing

后端 未结 5 728
半阙折子戏
半阙折子戏 2020-12-15 07:44

I have an application that I have been developing for some time now. Recently launching the application via a double click presents a dialog that says \"You can\'t open the

5条回答
  •  甜味超标
    2020-12-15 07:58

    OK, some (more) shots in the dark.

    1. The docs for LSMinimumSystemVersion say that the value is supposed to be a string with the form n.n.n. You might try adding a “.0” to the end of your value.
    2. When you use ./RepoWatch.app/Contents/MacOS/RepoWatch to run it manually, are you using some sort of completion or filename generation, or are you typing it all in (especially the filename of the executable)?
      • Maybe the executable filename has some odd invisible/combining/look-alike character in it that does not match the value in Info.plist. Try ls -w /path/to/RepoWatch.app/Contents/MacOS/ | xxd to look at the bytes for anything non-ASCII.
    3. Does plutil -lint /path/to/Info.plist give you an “OK”?
    4. The @ after the permissions in the ls -l output indicates some xattrs. These could be harmless, but have you looked at which ones are there with ls -l@?
      • If one of the xattrs looks suspect (or even if not) you could (cd /path/to/RepoWatch.app/Contents/ && mv Info.plist Info.plist.save && cat Info.plist.save > Info.plist) to get a copy without the xattrs and test with it.
      • If using the non-xattr'd file still causes problems, you might try systematically modifying and deleting keys (after making a backup copy, like the .save above) to see if you can cause a different error message that might help indicate the problem.

提交回复
热议问题