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

Build release not working on RN 0.58.3 #406

Open
tominou opened this issue Feb 5, 2019 · 3 comments
Open

Build release not working on RN 0.58.3 #406

tominou opened this issue Feb 5, 2019 · 3 comments

Comments

@tominou
Copy link

tominou commented Feb 5, 2019

It is working fine using react-native run-android but it can not build using ./gradlew assembleRelease. Here are the errors i get:

Execution failed for task ':react-native-material-kit:verifyReleaseResources'.
java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
Output: /xxx/react-native/node_modules/react-native-material-kit/android/build/intermediates/res/merged/release/values-v28/values-v28.xml:7: error: resource android:attr/dialogCornerRadius not found.
/xxx/react-native/node_modules/react-native-material-kit/android/build/intermediates/res/merged/release/values-v28/values-v28.xml:11: error: resource android:attr/dialogCornerRadius not found.
/xxx/react-native/node_modules/react-native-material-kit/android/build/intermediates/res/merged/release/values/values.xml:968: error: resource android:attr/fontVariationSettings not found.
/xxx/react-native/node_modules/react-native-material-kit/android/build/intermediates/res/merged/release/values/values.xml:969: error: resource android:attr/ttcIndex not found.
error: failed linking references.

I use gralde 4.7 and this config:

buildToolsVersion = 28.0.3
minSdkVersion = 16
compileSdkVersion = 28
targetSdkVersion = 27
supportLibVersion = 28.0.0

Thank you in advance for your help

@Edison4mobile
Copy link

Same here.

@cereme
Copy link

cereme commented Feb 20, 2019

Same here too

@dakenf
Copy link

dakenf commented Mar 7, 2019

add this to your root build.gradle file

subprojects { subproject ->
    afterEvaluate{
        if((subproject.plugins.hasPlugin('android') || subproject.plugins.hasPlugin('android-library'))) {
            android {
                compileSdkVersion rootProject.ext.compileSdkVersion
                buildToolsVersion rootProject.ext.buildToolsVersion
            }
        }
    }
}

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