Skip to content
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

2 files found with path 'lib/arm64-v8a/libc++_shared.so' from inputs...-react native #228

Open
huydosgtech opened this issue May 17, 2022 · 6 comments

Comments

@huydosgtech
Copy link

I think missing in config file for android.
please add following to your android/app/build.gradle**

android {

packagingOptions {
pickFirst 'lib/x86/libc++_shared.so'
pickFirst 'lib/x86_64/libjsc.so'
pickFirst 'lib/arm64-v8a/libjsc.so'
pickFirst 'lib/arm64-v8a/libc++_shared.so'
pickFirst 'lib/x86_64/libc++_shared.so'
pickFirst 'lib/armeabi-v7a/libc++_shared.so'
}

}

@JoniVR
Copy link

JoniVR commented May 31, 2022

I can confirm this is an issue @rumax I had to add these lines inside my own /android/app/build.gradle file, but it would be better to add them to the library. I think these are conflicting with another popular lib (not sure iirc but could have been reanimated or gesture-handler)

@stale
Copy link

stale bot commented Jul 10, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix This will not be worked on label Jul 10, 2022
@rumax rumax removed the wontfix This will not be worked on label Jul 10, 2022
@stale
Copy link

stale bot commented Aug 13, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix This will not be worked on label Aug 13, 2022
@rumax rumax removed the wontfix This will not be worked on label Aug 15, 2022
@stale
Copy link

stale bot commented Nov 2, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix This will not be worked on label Nov 2, 2022
@quocb
Copy link

quocb commented Apr 19, 2023

Getting this same issue but only when trying to do a release build with detox. Runs fine in debug on emulator.

Adding the packagingOptions as suggested by @huydosgtech to my own android/app/build.gradle doesn't do anything, but if I add it to node_modules/react-native-view-pdf/android/build.gradle then it works.

I'd be fine if adding it to my own android/app/build.gradle. Wondering if there's anything else I can do besides using patch-package? Thanks for any help!

Execution failed for task ':react-native-view-pdf:mergeDebugAndroidTestNativeLibs'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.MergeNativeLibsTask$MergeNativeLibsTaskWorkAction
   > 2 files found with path 'lib/arm64-v8a/libc++_shared.so' from inputs:
      - /Users/quocbui/.gradle/caches/transforms-3/dc830d8b3ffa0d5eb10573e829277b87/transformed/jetified-react-android-0.71.7-debug/jni/arm64-v8a/libc++_shared.so
      - /Users/quocbui/.gradle/caches/transforms-3/6bfde66eb9d103e7d37bb4b458eeea88/transformed/jetified-pdfium-android-1.9.2/jni/arm64-v8a/libc++_shared.so
     If you are using jniLibs and CMake IMPORTED targets, see
     https://developer.android.com/r/tools/jniLibs-vs-imported-targets

@stale stale bot removed the wontfix This will not be worked on label Apr 19, 2023
@rumax
Copy link
Owner

rumax commented Apr 20, 2023

And solution used in demo project is not working for you? Any chance that you can reproduce it in demo project at least and create a branch with the change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants