adobe / aepsdk-react-native

A wrapper around the iOS and Android AEP mobile SDK to allow for integration with React Native applications.
Apache License 2.0
15 stars 28 forks source link

React Native iOS - Underlying Objective-C module 'AEPRulesEngine' not found #263

Closed snanthagopal closed 1 year ago

snanthagopal commented 1 year ago

The latest version "@adobe/react-native-aepcore": "2.0.0" experiencing this issue in iOS only and it was working 1.0.0

Expected Behaviour

Actual Behaviour

Reproduce Scenario (including but not limited to)

Steps to Reproduce

  1. yarn add @adobe/react-native-aepcore
  2. cd iOS && pod install
  3. Import these on your iOS AppDelegate import AEPCore import AEPSignal import AEPServices import AEPLifecycle
  4. Go to product from the menu --> Archive

Platform and Version

React Native - iOS

Sample Code that illustrates the problem

Logs taken while reproducing problem

AEPCoreEngine

Screenshot 2023-04-05 at 11 04 14
csnvrl commented 1 year ago

We're having the same issue

dsoffiantini commented 1 year ago

Hi @snanthagopal, we are tracking issues with adobe sdks and the latest version of xcode (14.3). We are currently testing some workarounds until we hear back from Apple on how to solve the underlying issue. For now, downgrading xcode will solve the issue. I'll keep this thread up to date with any new updates we get back from Apple.

praveek commented 1 year ago

We are still working on the underlying issue but in the meantime you can use one of these workarounds 1) Linking as static frameworks by addinguse_frameworks! :linkage => :static to your Podfile. Flipper does not work when use_frameworks is enabled, and you should remove it from Podfile.

2) Adding the -no-verify-emitted-module-interface flag to failing targets to avoid verification failure. You can add the following post install hook to your Podfile to automatically add this flag to AEP library targets.

post_install do |installer|
  installer.pods_project.targets.each do |t|
    if t.name.start_with?("AEP")
      t.build_configurations.each do |bc|
          bc.build_settings['OTHER_SWIFT_FLAGS'] = '$(inherited) -no-verify-emitted-module-interface'
      end
    end
  end
end
gevgasparyan commented 1 year ago

Same issue after upgrading to xCode 14.3.

Adding these lines solved the issue

installer.pods_project.targets.each do |t|
    if t.name.start_with?("AEP")
      t.build_configurations.each do |bc|
          bc.build_settings['OTHER_SWIFT_FLAGS'] = '$(inherited) -no-verify-emitted-module-interface'
      end
    end
  end
ram-vilash commented 1 year ago

Nothing seems to be working, I am still getting the same issue.

XCode Version - 14.3.1, RN - 0.69.1, @adobe/react-native-aepcore : 5.0

cacheung commented 1 year ago

@ram-vilash this issue is still open, the workaround is having these lines in the Podfile. Have you tried that?

post_install do |installer|
  installer.pods_project.targets.each do |t|
    if t.name.start_with?("AEP")
      t.build_configurations.each do |bc|
          bc.build_settings['OTHER_SWIFT_FLAGS'] = '$(inherited) -no-verify-emitted-module-interface'
      end
    end
  end
end
cacheung commented 1 year ago

@ram-vilash, have you tried with the workaround and does it work for you? We are planning to close this issue soon since this is not a Adobe SDK issue.