New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Found an unexpected Mach-O header code: 1918975009 #52

Closed
carloslozano opened this Issue Nov 19, 2014 · 4 comments

Comments

Projects
None yet
2 participants
@carloslozano
Member

carloslozano commented Nov 19, 2014

Linked frameworks including invalid binaries. Builds work on device and emulator but non iOS binaries are being included in the build, causing the following validation error:

2014-11-19 22:00:57 +0000 [MT] Failed to generate distribution items with error: Error Domain=DVTMachOErrorDomain Code=1 "Found an unexpected Mach-O header code: 1918975009" UserInfo=0x7fb840744350 {NSLocalizedDescription=Found an unexpected Mach-O header code: 1918975009, NSLocalizedRecoverySuggestion=}

This makes it impossible to validate the application for distribution.

@carloslozano carloslozano added the bug label Nov 19, 2014

@carloslozano

This comment has been minimized.

Member

carloslozano commented Nov 19, 2014

Fixed error by:

  • Targeting iOS 8 on all embedded frameworks.
  • Removing "Defines Module" from Build Settings.
  • Realm, removed "phantom" framework (sourced from static lib)

It seems iOS < 8 targets with embedded frameworks are automatically rejected by the validation of the application... so they can't be distributed.

@carloslozano

This comment has been minimized.

Member

carloslozano commented Jan 16, 2015

Targets < 8 no longer an issue 😅

@ainulyaqin

This comment has been minimized.

ainulyaqin commented Apr 20, 2015

Hi Carlos,

i have problem same with u, do you want to help me what the matter with this error ?

2015-04-20 10:15:02 +0000 [MT] Failed to generate distribution items with error: Error Domain=DVTMachOErrorDomain Code=1 "Found an unexpected Mach-O header code: 1918975009" UserInfo=0x7fe751d19ef0 {NSLocalizedDescription=Found an unexpected Mach-O header code: 1918975009, NSLocalizedRecoverySuggestion=}

using xcode 6.
base SDK project: 8.1
ios deployment target : target : 8.0

iam using cocoapod 0.36.x builder in myproject, i set to ios deplyment target 8.0 too,

in "Defines Module" set to "No"

I clean and archieve still show error when, export and save for ad hoc.

@carloslozano

This comment has been minimized.

Member

carloslozano commented Apr 24, 2015

Are you trying to link against a static library from a Swift project?

I'm currently working on Xcode 6.3.1 and Cocoapods 0.36.4 and I'm no longer encountering this issue. However, I do recall that removing "Library Includes Swift Code" from the build settings of the project and this seemed to overcome the problem.

In any event, without looking at your specific use-case, it's a bit hard to determine the source of the problem. Is there any place where you have your code so that I can try to compile it with my current set-up and maybe find the offensive setting?

Regards,

C!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment