Open Nirmal-cod opened 11 months ago
Task :hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars FAILED
FAILURE: Build failed with an exception.
What went wrong: A problem was found with the configuration of task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' (type 'LibraryJniLibsTask').
Reason: Task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' uses this output of task ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.
Possible solutions:
@hariks789
Task :hariks789_react-native-background-geolocation:packageDebugResources FAILED
same, @Nirmal-cod you fixed??
@Nirmal-cod @lahed Sorry, I am no longer maintaining the package. We started using the paid package for the app.
This fork from @mak12 might help you guys https://github.com/mak12/react-native-background-geolocation
Task :hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars FAILED
FAILURE: Build failed with an exception.
What went wrong: A problem was found with the configuration of task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' (type 'LibraryJniLibsTask').
- Gradle detected a problem with the following location: '/Users/nirmal/rioapp/node_modules/@hariks789/react-native-background-geolocation/android/lib/build/intermediates/stripped_native_libs/release/out'. Reason: Task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' uses this output of task ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Possible solutions:
- Declare task ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' as an input of ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars'.
- Declare an explicit dependency on ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' from ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' using Task#dependsOn.
- Declare an explicit dependency on ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' from ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' using Task#mustRunAfter
I think your settings.gradle file like this.
include ':@hariks789_react-native-background-geolocation-common' project(':@hariks789_react-native-background-geolocation-common').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/common') include ':@hariks789_react-native-background-geolocation' project(':@hariks789_react-native-background-geolocation').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/lib')
Remove the two lines .
include ':@hariks789_react-native-background-geolocation' project(':@hariks789_react-native-background-geolocation').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/lib')
Use this line only. It is working
include ':@hariks789_react-native-background-geolocation-common' project(':@hariks789_react-native-background-geolocation-common').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/common')
But we using alternate package. That package also I got same error. After remove the lines working fine.
https://www.npmjs.com/package/@drewaker/react-native-background-geolocation
Task :hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars FAILED
FAILURE: Build failed with an exception.
What went wrong: A problem was found with the configuration of task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' (type 'LibraryJniLibsTask').
- Gradle detected a problem with the following location: '/Users/nirmal/rioapp/node_modules/@hariks789/react-native-background-geolocation/android/lib/build/intermediates/stripped_native_libs/release/out'. Reason: Task ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' uses this output of task ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Possible solutions:
- Declare task ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' as an input of ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars'.
- Declare an explicit dependency on ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' from ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' using Task#dependsOn.
- Declare an explicit dependency on ':@hariks789_react-native-background-geolocation:stripReleaseDebugSymbols' from ':hariks789_react-native-background-geolocation:copyReleaseJniLibsProjectAndLocalJars' using Task#mustRunAfter
I think your settings.gradle file like this.
include ':@hariks789_react-native-background-geolocation-common' project(':@hariks789_react-native-background-geolocation-common').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/common') include ':@hariks789_react-native-background-geolocation' project(':@hariks789_react-native-background-geolocation').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/lib')
Remove the two lines .
include ':@hariks789_react-native-background-geolocation' project(':@hariks789_react-native-background-geolocation').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/lib')
Use this line only. It is working
include ':@hariks789_react-native-background-geolocation-common' project(':@hariks789_react-native-background-geolocation-common').projectDir = new File(rootProject.projectDir, '../node_modules/@hariks789/react-native-background-geolocation/android/common')
But we using alternate package. That package also I got same error. After remove the lines working fine.
https://www.npmjs.com/package/@drewaker/react-native-background-geolocation
Thanks
You saved my time
include ':@mauron85_react-native-background-geolocation-common'
project(':@mauron85_react-native-background-geolocation-common').projectDir = new File(rootProject.projectDir, '../node_modules/@mauron85/react-native-background-geolocation/android/common')
worked for me
Your Environment
buildToolsVersion = "33.0.0" minSdkVersion = 21 compileSdkVersion = 33 targetSdkVersion = 33
Context
:@hariks789_react-native-background-geolocation-common:compileReleaseJavaWithJavac'. > Compilation failed; see the compiler error output for details. got this error..
Expected Behavior
wanted to build app
Actual Behavior
problem in build
Possible Fix
Steps to Reproduce
1. 2. 3. 4.
Context
Debug logs