Invalid Binary after Mac App store submission. Probably architecture mismatch - macos

After i tried to submit my OSX App (directly with Xcode organizer) i get the famous "Invalid Binary" error in iTunes Connect.
I wonder if the cause of this error would be the architecture defined as default in Xcode 4.2.
Here a screen:
In my opinion it's strange to have i386 for a 64-bit Intel Architectures.
What do you think ? should i try to remove i386 from valid architectures ?

The only architectures that will actually be built are the ones in BOTH the Architectures and Valid Architectures lists. So, there is no harm in having i386 in Valid Architectures, and you should look elsewhere for the problem.

You are likely missing your signing settings.
http://dl.dropbox.com/u/2978664/appcert.png is a Project Info Panel. Double click the Project and make sure the values are correct there. Then in the target if any of the signing options are bold click them and press delete. This way your project settings are used rather than overridden by the target.

Related

XCode on Apple M1 shows "linking in object file built for iOS" or "ld: warning: directory not found for option" or "'Framework not found"

I am trying to compile a "WebViewGold" ios app on an M1 processor MacBook Pro, using XCode latest (13.4.1) version.
I have greatly struggled to find a solution to those XCode error codes.
I have browsed related answers in threads like: building for iOS Simulator, but linking in object file built for iOS, https://stackoverflow.com/questions/32687105/framework-not-found-in-xcode,https://stackoverflow.com/questions/9458739/ld-warning-directory-not-found-for-option.
Nothing mentioned in the above answers worked!
Any idea about what I should do?
There is a possible, very simple solution provided by this answer.
Basically, freshly upgraded versions of XCode (for example, 13.4.1) running on Apple Silicon-powered Macs (like my M1 MacBook Pro), have components that cannot properly use/output the appropriate object files in all the output platform combinations you need.
This leads to some "interesting" issues and error message cross-overs that find "almost correct" answers on StackOverflow. Hence the many suggestions to exclude "arm64" platform and similar from the build options.
The simple answer to all of that is... to just run XCode with Rosetta enabled. Rosetta will engage with the components that miss the needed cross-platform capabilities.
Here is an example of how to enable an application to use Rosetta.
You select the app icon, then go to the File menu and select "Get Info".
Then click the "Open using Rosetta" checkbox.
It does seem that Build Active Architectures Only = NO is the issue, at least in Debug mode. I can successfully produce a Release archive, so I'd suggest just leaving it alone unless you're trying to debug the Intel version. Try a library, as you can ship the binary that way.

Submitting App with Xcode 7: ERROR ITMS- 90533 Missing Architecture. Extension Bundle requires a UIRequiredDeviceCapabilities value of "arm64"

I'm frantically trying to submit my app for the iOS 9 launch but I'm confronting a weird problem.
When I try to submit my application binary through Xcode 7, I get the following error:
What scares me is googling ERROR ITMS-90533 returned no results.
The architecture Build Settings seems to check out as per this stackoverflow question. In both the Project target and Extension target:
Architectures is set to Standard Architectures (armv7, arm64) in both the Project target and Extension target
Build Active Architecture is set to NO for RELEASE
Valid Architectures is set to arm64, armv7, armv7s
I'm not really sure what to do at this point. I've tried playing around with the settings and nothing seems to be working. Any help would be really awesome.
I managed to upload a similar app (which contains a content blocker extension just as yours) with the following two changes.
First, both Architectures and Valid Architectures only contain arm64.
Second, Info.plist for both the extension and the main app contains the following, restricting this app/extension to 64 bit architectures:
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>arm64</string>
</array>
Content blocker extensions are supposed to be 64-bit only. Not sure if a mixed 32/64 bit app can also contain a 64-bit-only extension. To be on the safe side, and since the content blocking is anyway the main/only functionality of my app, I made both the app and extension 64bit only.
Update, March 2016. With Xcode 7.2.1, you no longer need to set architecture as one comment below notes. You only need to set required device capabilities and valid architectures. (You can see this being the default setting when you create a new Content Blocker extension with the standard Xcode templates.)

Error invalid binary from itunes connect?

I have submitter my universal application .app file to iTunes connect and it shows 'Invalid Binary' status and i got a mail from apple. The mail content is
"Invalid Binary Architecture - iOS 3.0 introduced support for multiple binary architectures. If your binary is built for multiple architectures, your Info.plist must have a MinimumOSVersion key with a value of at least 3.0. Additionally, if your app is intended to support earlier iPhone and iPod touch models, your app must contain at least an armv6 binary; "thin" armv7-only binaries will not be accepted unless the armv7 required device capability is also present in the Info.plist UIRequiredDeviceCapabilities key or the MinimumOSVersion key has a value of 4.3 or higher.".
This is first time for me to submitting app to app store. How help me to solve this problem? What can i to do this? I can't understand the actual meaning of the mail content. Please help me.
You need to either add armv6 to your Target Build Settings Architectures, or set the minimum OS Deployment Target to 4.3
In your Xcode project, what architectures and iOS version are you building for? It sounds like you have the supported iOS setting set to 3.x, but the architecture set to armv7.
The simplest way to fix this, I'm imagining, is to set the supported SDK to something later than 4.x. I target 4.2, which seems to be generally safe.

Cocoa App Won't Launch on 32-bit Intel?

My Cocoa application, built in Xcode 3.2, runs perfectly on 64-bit machines but does not launch on a 32-bit Intel Mac. The Architecture is set to Standard(32/64-bit), Valid Architectures include "i386, ppc, ppc64, ppc7400, ppc970, x86_64" and Build Active Architecture Only is turned off.
Any suggestions as to why this might not launch? There is no error message, the app simply does not open.
Are you sure there's no error message? Did you check the console log using /Applications/Utilities/Console.app?
Are you the build settings are correct at the target level (ie, target-level settings don't override project-level settings with incorrect values)?

Xcode Only Gives Me Desktop Architectures for iOS App

I have an iOS project that I've put in Dropbox to work with a few friends. The issue is that it seems to get "corrupted", so that after some time (after someone else has accessed the Xcode project file), when I try to go and open it again I get a Base SDK Missing error. In the Project Settings, I discover that I'm missing the valid ARM6/ARM7 architecture for iOS apps—I can only choose from 32-bit or 64-bit Intel. My only other options are i386, various forms of PPC, and x86_64. I simply can't build for iOS anymore.
No one else that I'm working with seems to have this problem. It exists in both Xcode 3 and 4, so it's not an Xcode 4 issue either.
Is anyone else having this problem? Is there a fix?
In these cases it's often a good idea to 'Clean All Targets'. I have found that particularly after upgrades to XCode where platforms or architectures have changed, that XCode can become confused about the state of previous builds. Cleaning, then re-specifying your desired targets/architectures/etc and then rebuilding will work well.
Also don't forget that if you hold Alt (or Option) down when you click on the Active build settings drop down will give you additional options.
Can you reinstall XCode? Also, it might be wiser to host the project under source control.
Hehe...turns out that the project had been used under the 4.2 SDK and at the time I only had 4.0, which explained the missing SDK part...Updated to 4.2 and it's all fixed now.
Source control would've been nice, but there aren't that many good ones that support the features we need (for free); if anyone's got a guide to installing Subversion on OS X and using it (without being too technical read Terminal), I'd appreciate that. Or how to set up Git with Xcode 4 (although I know that's under NDA, so that's probably not going to happen).

Resources