ios 意外的 CFBundleExecutable 键

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/32096130/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-31 07:20:11  来源:igfitidea点击:

Unexpected CFBundleExecutable key

iosapp-store-connectcocoapodsios9xcode7-beta5

提问by Dumoko

After spending some time googling, something tells me that the issue is new.

花了一些时间谷歌搜索后,有些东西告诉我这个问题是新的。

We had a fully functional project supporting iOS7-8. Of course it was multiple times successfully submitted to AppStore.

我们有一个支持 iOS7-8 的全功能项目。当然是多次成功提交到AppStore。

We use pods, lots of tracking and monitoring, like GA and Instabug.

我们使用 pod,进行大量跟踪和监控,例如 GA 和 Instabug。

Now we decided to submit a version of the app built on Xcode 7 on iOS 9 to TestFlight.

现在我们决定向 TestFlight 提交一个基于 iOS 9 上的 Xcode 7 构建的应用程序版本。

We disabled bitcode, since many pods, like Flurry and other prebuilt libraries does not include it.

我们禁用了 bitcode,因为许多 pod,如 Flurry 和其他预建库都不包含它。

The build was successful, after the submission to iTunesConnect we get this: enter image description here

构建成功,提交到 iTunesConnect 后,我​​们得到: 在此处输入图片说明

We had same for GoogleAppIndexing library (in pods too), but we removed it, just to make it work. Now - Instabug. It is going too far, so I am trying to understand what is going on in iOS 9 and what are the changes that made a fully working project to start throwing such errors.

我们有同样的 GoogleAppIndexing 库(也在 pod 中),但我们删除了它,只是为了让它工作。现在 - Instabug。它走得太远了,所以我试图了解 iOS 9 中发生的事情,以及使一个完全正常工作的项目开始抛出此类错误的更改是什么。

Any thoughts and ideas are welcomed! Please share your experience, and if I missed something, I will gladly share my steps.

欢迎任何想法和想法!请分享您的经验,如果我错过了什么,我很乐意分享我的步骤。

回答by Sleiman

I encountered the same problem today with the same exact error message when trying to submit our app (using Xcode 7 beta 5) but instead of the instabug.bundlebit, it was for me TencentOpenApi_IOS_Bundle.bundle.

我今天在尝试提交我们的应用程序(使用 Xcode 7 beta 5)时遇到了同样的问题,并出现了相同的错误消息,但不是一instabug.bundle点点,而是给我的TencentOpenApi_IOS_Bundle.bundle

I solved the problem by finding the named bundle in the project then - just as the error message suggests - edited the Info.plistthat is in the bundle by removing the CFBundleExecutablekey. The CFBundlePackageTypekey was already set to BNDLso I didn't touch it.

我通过在项目中找到命名包解决了这个问题 - 正如错误消息所暗示的那样 -Info.plist通过删除CFBundleExecutable密钥来编辑包中的那个。该CFBundlePackageType键已经被设置为BNDL,所以我不碰它。

After these changes I did Product > Clean and then had no problem submitting the app to the App store.

在这些更改之后,我做了 Product > Clean,然后将应用程序提交到 App Store 没有问题。

I hope this helps.

我希望这有帮助。

回答by Adam S

Encountered this with AviarySDKon Xcode 7 GM, while submitting to the App Store.

AviarySDK在 Xcode 7 GM 上遇到这个问题,同时提交到 App Store。

First I'd check to see whether you're on the latest version of your library - the vendor may have fixed this already. If you are still facing this problem however, as Sleiman describes you need to remove the CFBundleExecutablekey from the plist file for the offending library.

首先,我会检查您是否使用的是最新版本的库——供应商可能已经修复了这个问题。但是,如果您仍然面临这个问题,正如 Sleiman 所描述的,您需要CFBundleExecutable从有问题的库的 plist 文件中删除密钥。

Cmd + Shift + O and type "Info.plist", you can then find the appropriate file:

Cmd + Shift + O 并输入“Info.plist”,然后就可以找到相应的文件:

enter image description here

在此处输入图片说明

Once editing the plist, you may be seeing descriptive names (instead of the CFBundleExecutableand other keys. I couldn't edit this file in an external editor, so I had to switch to view raw keys/values by right-clicking on the list:

编辑 plist 后,您可能会看到描述性名称(而不是CFBundleExecutable和其他键。我无法在外部编辑器中编辑此文件,因此我必须通过右键单击列表来切换以查看原始键/值:

enter image description here

在此处输入图片说明

You can now see the CFBundleExecutablekey (which has a description of "Executable file") which you can delete.

您现在可以看到CFBundleExecutable可以删除的密钥(其中有“可执行文件”的描述)。

For AviarySDK I did this twice, once for each Info.plistseen in the above image, and was then able to successfully submit.

对于 AviarySDK,我做了两次,Info.plist上图中看到的每个都做了一次,然后能够成功提交。

回答by Jonathan Nolasco Barrientos

I solve this problem as follows: We have to remove all the "Executable files" of the following packages:

我解决这个问题如下:我们必须删除以下包的所有“可执行文件”:

  • GooglePlus.bundle
  • GPPCommonSharedResources.bundle
  • GPPShareboxSharedResources.bundle
  • GooglePlus.bundle
  • GPPCommonSharedResources.bundle
  • GPPShareboxSharedResources.bundle

Be sure that "Bundle type code" is equal BNDL

确保“捆绑类型代码”等于 BNDL

Important: Do not edit anything in the info.plist the main project.

重要提示:不要在主项目的 info.plist 中编辑任何内容。

Attached screens as they should be his "info.plist" listed above each package.

附加的屏幕应该是他在每个包上方列出的“info.plist”。

enter image description here

在此处输入图片说明

enter image description here

在此处输入图片说明

enter image description here

在此处输入图片说明

回答by William Entriken

Here's what worked for me

这对我有用

  1. Apple-Shift-F, search for CFBundleExecutable
  2. Click each one except "PODS" or your main target
  3. Delete it (delete key)
  1. Apple-Shift-F,搜索 CFBundleExecutable
  2. 单击除“PODS”或您的主要目标之外的每一个
  3. 删除它(删除键)

enter image description here

在此处输入图片说明

回答by Manab Kumar Mal

If the build is submitted through Less than(<) Xcode 7.0then it will be submitted and also I have solved it by following way for Xcode 7:

如果构建是通过Less than(<) Xcode 7.0提交的,那么它将被提交,并且我已经通过以下方式为Xcode 7解决了这个问题:

Searched for info.plistin the projects Project Navigator as like following image:

info.plist在项目 Project Navigator 中搜索如下图:

enter image description here

在此处输入图片说明

Now opened these info.plistfiles one by one and deleted the BundleExecutablekey EXCEPT the target's info.plist

现在将这些info.plist文件一一打开并删除除目标的BundleExecutable密钥之外的密钥info.plist

Now cleaned the project and achieved and It is submitted with No issue.

现在清理了项目并实现了,并且没有问题提交。

回答by Umar Farooq

I had the same issue in Google Maps Library i removed CFBundleExecutablekey inside GMSCoreResources.bundle(Info.plist) which is SDK's info.plist clean project and upload to appstore.

我在 Google Maps Library 中遇到了同样的问题,我删除了( ) 里面的CFBundleExecutable键,这是 SDK 的 info.plist 清理项目并上传到应用商店。GMSCoreResources.bundleInfo.plist

Happy Programming.

快乐编程。

enter image description here

在此处输入图片说明

回答by InitialC

Just check your Build Settings => Enable Bitcode, and set it NO

只需检查您的构建设置 => 启用位码,并将其设置为 NO

回答by Oleksiy Dudarev

I just added word "BNDL" to appropriate place in plist"Bundle creator OS Type code".

我刚刚在plist“Bundle creator OS Type code”中的适当位置添加了“BNDL”一词。

That was the issue

那是问题

回答by Krunal Nagvadia

In my case I just Drag and Drop The SDKIn folder include info.plistfile which is not in use. That's create the issue for me. So find the unused info.plistfile and delete it from the Source code.

在我的情况下,我只是拖放未使用的SDKIn 文件夹包含info.plist文件。这就是为我创造的问题。因此找到未使用的info.plist文件并将其从源代码中删除。

回答by jimejim

One additional note: sometimes if you have additional targets there will be target properties that may also include the key (in the "Info" section), so make sure to check those and remove it from there also. I discovered this with one of the bundles I was trying to include. I deleted the info from the plist, but kept getting the error.

附加说明:有时,如果您有其他目标,则目标属性可能也包含密钥(在“信息”部分),因此请务必检查这些并将其从那里删除。我在尝试包含的其中一个包中发现了这一点。我从 plist 中删除了信息,但一直收到错误消息。