bogo / arm64-to-sim

Transmogrify native iOS frameworks to run in iOS Simulator on Apple silicon.
https://bogo.wtf/arm64-to-sim.html
MIT License
540 stars 87 forks source link

Yandex maps mobile modifying problem #15

Open c-villain opened 2 years ago

c-villain commented 2 years ago

Hi, I am currently using ur tools to modify binary framework Yandex maps mobile... Link to framework is taken from here... Every time am getting zerofill error...

ld: in /Users/c-villain/Library/Developer/Xcode/DerivedData/Utkonos-flitswrpfdrvoncmykfarjwnxqce/Build/Products/Debug-iphonesimulator/YandexMapsMobile.framework/YandexMapsMobile(YMKSearchMasstransit2xObjectMetadata_Binding.mm.o), section __DATA/__bss has type zero-fill but non-zero file offset file '/Users/c-villain/Library/Developer/Xcode/DerivedData/Utkonos-flitswrpfdrvoncmykfarjwnxqce/Build/Products/Debug-iphonesimulator/YandexMapsMobile.framework/YandexMapsMobile' for architecture arm64

build on Xcode 13.3.1

any ideas what's going wrong?...

igor-makarov commented 2 years ago

@bogo I've checked this out very thoroughly. It appears that the Yandex SDK has non-zero offsets in S_ZEROFILL sections before the modification. So the iPhone version also doesn't build. This is not a problem with the Transmogrifier.

I've additionally discovered some Unix horrors in the Yandex SDK:

I've made a hacked build of xcframework_converter that handles all of this, plus the zero-fill patch: https://github.com/igor-makarov/XCFrameworkConverter/releases/tag/0.4.0-hack-zerofill

mixdesign commented 2 years ago

@igor-makarov Hey, Igor. Thanks for your work on converter. I tried the patched version to fix an issue for YandexMapsMobile, but still have same error on device build (arm64). I tried 0.7.0 version and 0.4.0-hack-zerofill separately. Same error!

I'm using converter from Podfile. I'm in Xcode 14.0.1 right now.

igor-makarov commented 2 years ago

Hey @mixdesign! I haven't looked at the new versions of the Yandex SDK because I don't actually use it.

It appears that the Yandex company isn't maintaining it very well, and I'm not sure how sustainable it is to constantly work around its quirks. I haven't got bandwidth right now to check it again.

Sorry about the late reply, but I don't have an answer.

igor-makarov commented 2 years ago

@mixdesign Although now that I recall it, the newest SDK versions are supposed to have XCFramework packaging and not require the converter.

mixdesign commented 2 years ago

@igor-makarov yeah, thanks for your time and thoughts. I just found that there are fresh libs based on xcframeworks :) Link: https://github.com/CocoaPods/Specs/tree/master/Specs/d/d/0/YandexMapsMobile