react-native-pdf-lib icon indicating copy to clipboard operation
react-native-pdf-lib copied to clipboard

Could not determine the dependencies of task ':react-native-pdf-lib:compileDebugAidl'.

Open thechaudharysab opened this issue 2 years ago • 15 comments

After installing the library and adding

      dexOptions {
      jumboMode = true
  }

In the app/build.gradle then cleaning gradle and building the app again gives me:

* What went wrong:
Could not determine the dependencies of task ':react-native-pdf-lib:compileDebugAidl'.
> Could not resolve all task dependencies for configuration ':react-native-pdf-lib:debugCompileClasspath'.
   > Could not find com.tom_roush:pdfbox-android:1.8.9.1.
     Required by:
         project :react-native-pdf-lib

I have only tested this on Android and not on iOS.

thechaudharysab avatar Mar 26 '23 06:03 thechaudharysab

same problem here

ThushalMadu avatar Apr 01 '23 19:04 ThushalMadu

I also have the same problem which prohibits me from building and running the app..

efstasia avatar Apr 03 '23 12:04 efstasia

+1

MuriloBarranco avatar Apr 14 '23 01:04 MuriloBarranco

+1

BogdanRad avatar May 15 '23 08:05 BogdanRad

Hi @Hopding , please tell the solution for this problem.

abhishekv-gloify avatar May 24 '23 07:05 abhishekv-gloify

i have also the same problem

BrainTech-Code avatar Jun 12 '23 13:06 BrainTech-Code

i have also the same problem

hashimalikhan-123 avatar Jun 13 '23 07:06 hashimalikhan-123

@Hopding can you please look out for the issue.

rajivchaulagain avatar Jul 05 '23 10:07 rajivchaulagain

Hi guys, i also have the same issue.

developerekene avatar Oct 05 '23 15:10 developerekene

Hey, the error you mentioned regarding the PDF library dependency can be resolved with a few adjustments. I've successfully resolved a similar issue, and here's a step-by-step guide to help you out:

  1. Open the android/app/build.gradle file and add the following line within the dependencies block:
implementation 'com.tom-roush:pdfbox-android:1.8.10.3'

OBS: Make sure to replace the version with one available in the Maven repository. You can check the available versions here

  1. Navigate to node_modules/react-native-pdf-lib/android/build.gradle and repeat the same modification in dependencies block.

  2. In the file node_modules/react-native-pdf-lib/android/src/main/java/com/hopding/pdflib/PDFLibModule.java, locate the line:

import android.support.v4.content.FileProvider;

Replace it with:

import androidx.core.content.FileProvider;

After making these changes, clean and rebuild your project. This should resolve the issue you encountered. I've tested these adjustments on Android, but I recommend verifying the iOS side as well.

Let me know if you face any further issues 😁

vinikrummenauer avatar Oct 17 '23 19:10 vinikrummenauer

@vinikrummenauer i have tried but it does'nt work for me

HuzaifaMurtaza01 avatar Feb 20 '24 05:02 HuzaifaMurtaza01

nothing working same problem.

Awais-Qadir3595 avatar May 30 '24 10:05 Awais-Qadir3595

I'm still having the same issue, any another fix @vinikrummenauer

iamblackdev avatar Jun 18 '24 18:06 iamblackdev