Skip to main content

Issue

Building and debugging work correctly, but TestFlight uploads fail with “Asset validation failed” due to frameworks containing bitcode.

Cause

Apple deprecated bitcode in Xcode 16. Some DARO SDK dependencies still contain bitcode and must be removed manually until vendors update their frameworks.

Solution

Add this code to the bottom of your Podfile, then rebuild and deploy. This removes bitcode using bitcode_strip during the build process.
post_install do |installer|

  installer.pods_project.targets.each do |target|

    if target.name == 'OpenWrapSDK'
      `xcrun -sdk iphoneos bitcode_strip -r Pods/OpenWrapSDK/OpenWrapSDK/OMSDK_Pubmatic.xcframework/ios-arm64/OMSDK_Pubmatic.framework/OMSDK_Pubmatic -o Pods/OpenWrapSDK/OpenWrapSDK/OMSDK_Pubmatic.xcframework/ios-arm64/OMSDK_Pubmatic.framework/OMSDK_Pubmatic`
    end

    if target.name == 'HyBid'
      `xcrun -sdk iphoneos bitcode_strip -r Pods/HyBid/PubnativeLite/PubnativeLite/OMSDK-1.4.10/OMSDK_Pubnativenet.xcframework/ios-arm64/OMSDK_Pubnativenet.framework/OMSDK_Pubnativenet -o Pods/HyBid/PubnativeLite/PubnativeLite/OMSDK-1.4.10/OMSDK_Pubnativenet.xcframework/ios-arm64/OMSDK_Pubnativenet.framework/OMSDK_Pubnativenet`
    end

    if target.name == 'smaato-ios-sdk'
      `xcrun -sdk iphoneos bitcode_strip -r Pods/smaato-ios-sdk/vendor/OMSDK_Smaato.xcframework/ios-arm64_armv7/OMSDK_Smaato.framework/OMSDK_Smaato -o Pods/smaato-ios-sdk/vendor/OMSDK_Smaato.xcframework/ios-arm64_armv7/OMSDK_Smaato.framework/OMSDK_Smaato`
    end
  end
end