Closed MrTarantula closed 2 years ago
This issue is an error related to arm64 build failure in xcode12 version.
'ld: symbol(s) not found for architecture arm64'
I solved the error by adding 'arm64, i386' to the debug/profile/release item of excluded architectures as shown in the picture above.
As a result of the test, 'i386' is omitted and only 'arm64' is added to build.
I already have those same values in my build settings.
Did you also proceed with build clean after the setting?
Reference (https://github.com/flutter/flutter/issues/41900#issuecomment-601599410)
I have completely cleaned and rebuilt several times, and those values were already set anyway, so it didn't matter.
One thing that does work is if I change my project configuration to None
:
It will build but the App Store does not accept it:
ERROR ITMS-90057: "The bundle 'Payload/Runner.app/PlugIns/OneSignalNotificationServiceExtension.appex' is missing plist key. The Info.plist file is missing the required key: CFBundleShortVersionString. Please find more information about CFBundleShortVersionString at https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleshortversionstring"
ERROR ITMS-90360: "Missing Info.plist value. A value for the key 'CFBundleShortVersionString' in bundle Runner.app/PlugIns/OneSignalNotificationServiceExtension.appex is required."
Those values are set by Flutter in Info.plist
:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleDisplayName</key>
<string>OneSignalNotificationServiceExtension</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>$(FLUTTER_BUILD_NAME)</string>
<key>CFBundleVersion</key>
<string>$(FLUTTER_BUILD_NUMBER)</string>
<key>NSExtension</key>
<dict>
<key>NSExtensionPointIdentifier</key>
<string>com.apple.usernotifications.service</string>
<key>NSExtensionPrincipalClass</key>
<string>NotificationService</string>
</dict>
</dict>
</plist>
Here is my Debug-dev.xconfig
:
#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug-dev.xcconfig"
#include "Generated.xcconfig"
and my Pods-Runner.debug-dev.xcconfig
:
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = NO
FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/FirebaseAnalytics/Frameworks" "${PODS_ROOT}/GoogleAppMeasurement/Frameworks" "${PODS_ROOT}/OneSignalXCFramework/iOS_SDK/OneSignalSDK/OneSignal_XCFramework" "${PODS_XCFRAMEWORKS_BUILD_DIR}/FirebaseAnalytics" "${PODS_XCFRAMEWORKS_BUILD_DIR}/GoogleAppMeasurement" "${PODS_XCFRAMEWORKS_BUILD_DIR}/OneSignal"
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 $(inherited) PB_FIELD_32BIT=1 PB_NO_PACKED_STRUCTS=1 PB_ENABLE_MALLOC=1
HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/FMDB" "${PODS_ROOT}/Headers/Public/Firebase" "${PODS_ROOT}/Headers/Public/FirebaseABTesting" "${PODS_ROOT}/Headers/Public/FirebaseCore" "${PODS_ROOT}/Headers/Public/FirebaseCoreDiagnostics" "${PODS_ROOT}/Headers/Public/FirebaseCrashlytics" "${PODS_ROOT}/Headers/Public/FirebaseDynamicLinks" "${PODS_ROOT}/Headers/Public/FirebaseInstallations" "${PODS_ROOT}/Headers/Public/FirebaseRemoteConfig" "${PODS_ROOT}/Headers/Public/GoogleDataTransport" "${PODS_ROOT}/Headers/Public/GoogleUtilities" "${PODS_ROOT}/Headers/Public/PromisesObjC" "${PODS_ROOT}/Headers/Public/device_info" "${PODS_ROOT}/Headers/Public/firebase_analytics" "${PODS_ROOT}/Headers/Public/firebase_core" "${PODS_ROOT}/Headers/Public/firebase_crashlytics" "${PODS_ROOT}/Headers/Public/firebase_dynamic_links" "${PODS_ROOT}/Headers/Public/firebase_remote_config" "${PODS_ROOT}/Headers/Public/flutter_statusbarcolor" "${PODS_ROOT}/Headers/Public/fluttertoast" "${PODS_ROOT}/Headers/Public/nanopb" "${PODS_ROOT}/Headers/Public/onesignal_flutter" "${PODS_ROOT}/Headers/Public/package_info" "${PODS_ROOT}/Headers/Public/path_provider" "${PODS_ROOT}/Headers/Public/shared_preferences" "${PODS_ROOT}/Headers/Public/sqflite" "${PODS_ROOT}/Headers/Public/url_launcher" "${PODS_ROOT}/Headers/Public/webview_flutter" $(inherited) ${PODS_ROOT}/Firebase/CoreOnly/Sources "${PODS_TARGET_SRCROOT}/Sources/FBLPromises/include"
LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/FMDB" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseABTesting" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseCore" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseCoreDiagnostics" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseCrashlytics" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseDynamicLinks" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseInstallations" "${PODS_CONFIGURATION_BUILD_DIR}/FirebaseRemoteConfig" "${PODS_CONFIGURATION_BUILD_DIR}/GoogleDataTransport" "${PODS_CONFIGURATION_BUILD_DIR}/GoogleUtilities" "${PODS_CONFIGURATION_BUILD_DIR}/PromisesObjC" "${PODS_CONFIGURATION_BUILD_DIR}/device_info" "${PODS_CONFIGURATION_BUILD_DIR}/firebase_analytics" "${PODS_CONFIGURATION_BUILD_DIR}/firebase_core" "${PODS_CONFIGURATION_BUILD_DIR}/firebase_crashlytics" "${PODS_CONFIGURATION_BUILD_DIR}/firebase_dynamic_links" "${PODS_CONFIGURATION_BUILD_DIR}/firebase_remote_config" "${PODS_CONFIGURATION_BUILD_DIR}/flutter_statusbarcolor" "${PODS_CONFIGURATION_BUILD_DIR}/fluttertoast" "${PODS_CONFIGURATION_BUILD_DIR}/nanopb" "${PODS_CONFIGURATION_BUILD_DIR}/onesignal_flutter" "${PODS_CONFIGURATION_BUILD_DIR}/package_info" "${PODS_CONFIGURATION_BUILD_DIR}/path_provider" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences" "${PODS_CONFIGURATION_BUILD_DIR}/sqflite" "${PODS_CONFIGURATION_BUILD_DIR}/url_launcher" "${PODS_CONFIGURATION_BUILD_DIR}/webview_flutter"
OTHER_CFLAGS = $(inherited) -fmodule-map-file="${PODS_ROOT}/Headers/Public/device_info/device_info.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_analytics/firebase_analytics.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_core/firebase_core.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_crashlytics/firebase_crashlytics.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_dynamic_links/firebase_dynamic_links.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_remote_config/firebase_remote_config.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/package_info/package_info.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/path_provider/path_provider.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/shared_preferences/shared_preferences.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/sqflite/sqflite.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/url_launcher/url_launcher.modulemap" -fmodule-map-file="${PODS_ROOT}/Headers/Public/webview_flutter/webview_flutter.modulemap"
OTHER_LDFLAGS = $(inherited) -ObjC -l"FMDB" -l"FirebaseABTesting" -l"FirebaseCore" -l"FirebaseCoreDiagnostics" -l"FirebaseCrashlytics" -l"FirebaseDynamicLinks" -l"FirebaseInstallations" -l"FirebaseRemoteConfig" -l"GoogleDataTransport" -l"GoogleUtilities" -l"PromisesObjC" -l"c++" -l"device_info" -l"firebase_analytics" -l"firebase_core" -l"firebase_crashlytics" -l"firebase_dynamic_links" -l"firebase_remote_config" -l"flutter_statusbarcolor" -l"fluttertoast" -l"nanopb" -l"onesignal_flutter" -l"package_info" -l"path_provider" -l"shared_preferences" -l"sqflite" -l"sqlite3" -l"url_launcher" -l"webview_flutter" -l"z" -framework "CoreTelephony" -framework "FirebaseAnalytics" -framework "Foundation" -framework "GoogleAppMeasurement" -framework "OneSignal" -framework "QuartzCore" -framework "Security" -framework "StoreKit" -framework "SystemConfiguration" -framework "UIKit" -weak_framework "WebKit"
OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/device_info/device_info.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_analytics/firebase_analytics.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_core/firebase_core.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_crashlytics/firebase_crashlytics.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_dynamic_links/firebase_dynamic_links.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/firebase_remote_config/firebase_remote_config.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/package_info/package_info.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/path_provider/path_provider.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/shared_preferences/shared_preferences.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/sqflite/sqflite.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/url_launcher/url_launcher.modulemap" -Xcc -fmodule-map-file="${PODS_ROOT}/Headers/Public/webview_flutter/webview_flutter.modulemap"
PODS_BUILD_DIR = ${BUILD_DIR}
PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
PODS_PODFILE_DIR_PATH = ${SRCROOT}/.
PODS_ROOT = ${SRCROOT}/Pods
PODS_XCFRAMEWORKS_BUILD_DIR = $(PODS_CONFIGURATION_BUILD_DIR)/XCFrameworkIntermediates
USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES
'ERROR ITMS-90057: "The bundle 'Payload/Runner.app/PlugIns/OneSignalNotificationServiceExtension.appex' is missing plist key.' is located 'ios/OneSignalNotificationServiceExtension/info.plist'
in my value is
<key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleVersion</key>
<string>1</string>
That looks to be a custom build variable set up by you or your team. FLUTTER_BUILD_NUMBER
comes from Flutter, and also appears in my app's Info.plist
..
Hello!
I may be late but this may help someone facing a similar issue.
When you are adding an extension to a Flutter project, please, check the Other Linker Flags under the Build Settings of the extension.
For me, they looked like this:
This is, the extension was trying to link all the libraries but it didn't know how to do it and here it was failing.
To solve the issue, just double click on the libraries, select all of them in the dialog and click remove (- button). In the end, it should look like this:
After this, I could run my extension without any issue
Same here, I its annoying 😢 that I need to exclude the arm64 architecture eveytime I run the app on an iOS simulator.
Thanks for the great work, hope this issue get resolved ASAP.
Description: After going through the upgrade steps, the app fails to build for iOS:
Environment
Steps to Reproduce Issue: