react-native-bluetooth-escpos-printer icon indicating copy to clipboard operation
react-native-bluetooth-escpos-printer copied to clipboard

Any Idea why my app failing to build in assebleRelease,In error logs I see react-native-bluetooth-escpos-printer error logs

Open shubhamdeol opened this issue 5 years ago • 4 comments

Screen Shot 1940-12-25 at 5 32 16 PM

I got these error logs while building app with cli: export ENVFILE=.env && cd android && ./gradlew assembleRelease --debug;

also, I can see Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0 , In error logs

shubhamdeol avatar Mar 16 '19 12:03 shubhamdeol

I'm facing the same problem here...

igorassis avatar Mar 18 '19 04:03 igorassis

I solved my problem changing the compileSdkVersion to 28 and buildToolsVersion to "28.0.3" , and compile to implementation in build.gradle YOUR_PROJECT/node_modules/react-native-bluetooth-escpos-printer/android/build.gradle:

android {
    compileSdkVersion 28
    buildToolsVersion "28.0.3"

    defaultConfig {...}
    ...
}
dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.facebook.react:react-native:+'  // From node_modules
    implementation ...
}

I hope that works to you!

igorassis avatar Mar 18 '19 13:03 igorassis

same thing I did

shubhamdeol avatar Mar 26 '19 11:03 shubhamdeol

I just change buildToolVesion and compileSdkVersion

Go to the dependency build.gradle folder YOUR_PROJECT/node_modules/react-native-bluetooth-escpos-printer/android/build.gradle

android {
    compileSdkVersion 28
     buildToolsVersion "28.0.3"

    defaultConfig {
        minSdkVersion = 21
        targetSdkVersion = 31
        versionCode 1
        versionName "1.0"
    }

Deepak9811 avatar Jun 01 '22 04:06 Deepak9811