-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: Duplicate interface definition for class 'RCTEventDispatcher' #3774
Comments
@simoes-agroleague but you need to remove: |
Yes I tested on my side and it was the same for me. |
I am not really confident in adding include which is unused ... (moreover I don't really understand what it do with linking). I applied following patch in the sample which allows to use dynamic framework. @@ -16,19 +16,30 @@ if linkage != nil
end
target 'videoplayer' do
config = use_native_modules!
- use_frameworks! :linkage => :static
+ use_frameworks! :linkage => :dynamic
if ENV['RNV_SAMPLE_ENABLE_ADS']
$RNVideoUseGoogleIMA = true
end
if ENV['RNV_SAMPLE_VIDEO_CACHING']
$RNVideoUseVideoCaching = true
end
+ pre_install do |installer|
+ installer.pod_targets.each do |pod|
+ if pod.name.eql?('react-native-video')
+ def pod.build_type
+ Pod::BuildType.static_library
+ end
+ end
+ end
+ end
+
# Flags change depending on the env values.
flags = get_default_flags()
use_react_native!(
:path => config[:reactNativePath], I first update Can you please try to add the pre_install section in your app to se if it fixes the issue. If correct, I will update documentation. |
@simoes-agroleague Did you test my proposal ? |
Thanks for the proposition @freeboub. |
@simoes-agroleague OK, thanks for the update. |
Exactly @freeboub |
@simoes-agroleague I just try to remove the use_frameworks in the sample app, It builds without issue 🙄 |
@freeboub so how should the rest of us do it :) To make pod install run smoothly, i do the below:
my linkage is the standard react-native new app
and i override any modular headers like this
I'm not sure if I should include the react-native-video to the modular_headers or not, but when i tried pods wouldn't install. |
@Roshdy you should try, but the issue described here is not a pod install issue, but a build issue ... |
@freeboub yes i'm pod installing successfully now, but i'm getting |
Version
6.0.0
What platforms are you having the problem on?
iOS
Architecture
Old architecture
What happened?
I am experiencing the same issue than
Or in other words, changing node_modules/react-native-video/ios/Video/RCTVideo-Bridging-Header.h to:
The issue started on version
6.0.0-rc0
and I use react-native 0.73.6I cannot modify the framework linkage static in the Podfile as it conflict with other libraries (Firebase for ex).
The only working fix is patching
react-native-video/ios/Video/RCTVideo-Bridging-Header.h
by adding the following import :#import "RCTEventDispatcher.h"
Can you please integrate this import to the next version of
react-native-video
?Thanks !
Reproduction
repository link
Reproduction
Step to reproduce this bug are:
Install react-native-video v6.0.0 with react-native v0.73.6 and keep the same config has previously in the Podfile :
The text was updated successfully, but these errors were encountered: