darrarski / arm64-to-sim

A simple command-line tool for hacking native ARM64 binaries to run on the Apple Silicon iOS Simulator.
https://bogo.wtf/arm64-to-sim.html
MIT License
12 stars 3 forks source link

Does not work with LoginWithAmazon iOS framework #1

Open darrarski opened 3 years ago

darrarski commented 3 years ago

As reported by @anfriis in an issue to xcframework-maker, the arm64-to-sim does not work with LoginWithAmazon iOS framework.

I checked the origin implementation of this fork, but it can't "hack" the LoginWithAmazon binary as well.

The problem occurs when reading the header data of the binary. None of the following checks passes, and the error is thrown:

let header: mach_header_64 = headerData.asStruct()
if header.magic != MH_MAGIC_64 || header.cputype != CPU_TYPE_ARM64 {
  throw IncorrectBinaryError()
}

I am not sure how to address the issue at the moment.

ryanbooker commented 3 years ago

The same issue occurs on the SurveyMonkey iOS SDK.

davidpasztor commented 2 years ago

@ryanbooker have you managed to find a solution for making the SurveyMonkey iOS SDK work on M1? I've ran into the exact same issue and other than conditionally linking the SDK for only device archs, I've ran out of ideas.

ryanbooker commented 2 years ago

have you managed to find a solution for making the SurveyMonkey iOS SDK work on M1? I've ran into the exact same issue and other than conditionally linking the SDK for only device archs, I've ran out of ideas.

@davidpasztor I have to run Xcode under Rosetta. SurveyMonkey have abandoned their SDK. In the last response I got from them they said they have no plans to update it.

davidpasztor commented 2 years ago

Was afraid you'd say that :( I was hoping someone actually managed to get the device SDK working on the M1 simulator for SurveyMonkey as well, but it seems to be a lost cause. Thanks for the info though!