klippa-app / react-native-klippa-scanner-sdk

A React Native plugin to use the Klippa Scanner SDK
MIT License
2 stars 0 forks source link

iOS build error: Multiple commands produce PrivacyInfo.xcprivacy #74

Open squio opened 3 months ago

squio commented 3 months ago

Platform:

The upgrade to RN 0.74 added the local resource ios/Bizcuit/PrivacyInfo.xcprivacy

After upgrading the Klippa Scanner SDK version to 0.4.2, the embedded PrivacyInfo.xcprivacy conflicts with the local version.

screen 2024-07-03 om 14 57 04

This line in the Pod spec triggers the issue:

Pod::Spec.new do |spec|
  spec.name             = 'Klippa-Scanner'
  spec.version          = '1.2.1'
  spec.summary          = 'Klippa OCR SDK'
  spec.description      = 'SDK to do document scanning for iOS.'
  spec.homepage         = 'https://www.klippa.com/en/ocr/ocr-sdk/'
  spec.license          = 'PRIVATE'
// ...
  spec.resources = "KlippaScanner.xcframework/*/KlippaScanner.framework/**/*.{strings,png,xcprivacy}"

Work around

Revert back to Klippa Scanner SDK version to 0.4.1, re-install Pods and clean workspace

This SO comment may point in the direction of a proper fix for this issue: https://stackoverflow.com/a/78344724/885397

This is how Sentry fixed the same issue: https://github.com/getsentry/sentry-cocoa/pull/3651