I’m engaged on a “system data” app and it reveals the CPU structure. I’ve been utilizing this code which works wonderful.
func getArchitecture() -> String? {
guard
let data = NXGetLocalArchInfo(),
let string = data.pointee.description
else { return nil }
return String(utf8String: string)
}
The NXGetLocalArchInfo
perform has been deprecated in iOS 16, and I do not know what to make use of as a substitute.
Edit: After some analysis, it seems like the brand new API must be macho_arch_name_for_mach_header
: https://github.com/firebase/firebase-ios-sdk/commit/19c1b15f7c012b0633eb74fd2effd961c88d28a3
Nonetheless, I do not know find out how to write it in Swift. Please assist.