任务: react-native-image-filter-kit:编译Debug Renderscript失败

3
当我运行这个命令 npx react-native run-android,我得到了以下结果: Task :react-native-image-filter-kit:compileDebugRenderscript FAILED 我按照此链接的安装说明进行了操作 https://github.com/iyegoroff/react-native-image-filter-kit
配置如下:
操作系统:Ubuntu 18.04.5 LTS- 64bit
yarn版本:1.22.5
node版本:v14.16.0
npm版本:6.14.11
react-native版本:0.63.4
react-native-image-filter-kit版本:^0.7.3
如果需要,我可以提供更多的配置细节。
我尝试在Android Studio的虚拟设备Pixel 4 XL API 29 Android 10上以及我的设备Samsung Galaxy S7上运行,但都无法运行。
尝试在我的项目中重新安装软件包。
尝试使用#31的解决方案,通过更改android/app/build.gradle && android/build.gradle && gradle.wrapper.properties
我是React-Native和Android应用程序的新手。 任何提示或帮助对我来说都将非常感激。

android/build.gradle



// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    ext {
         buildToolsVersion = "29.0.3"
        minSdkVersion = 17
        compileSdkVersion = 29
        targetSdkVersion = 29
        renderscriptVersion = 21
        supportLibVersion = '1.0.2'
        mediaCompatVersion = '1.0.1'
        supportV4Version = '1.0.0'
    }
    repositories {
        google()
        jcenter()
    }
     dependencies {
        classpath("com.android.tools.build:gradle:3.6.0")
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }

}

allprojects {
    repositories {
        mavenLocal()
        maven {
            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url("$rootDir/../node_modules/react-native/android")
        }
        maven {
            // Android JSC is installed from npm
            url("$rootDir/../node_modules/jsc-android/dist")
        }

        google()
        jcenter()

        maven { url 'https://maven.google.com' } // ADD THIS

        maven { url 'https://www.jitpack.io' }
    }
}

android/app/build.gradle

android {
    compileSdkVersion rootProject.ext.compileSdkVersion
    buildToolsVersion rootProject.ext.buildToolsVersion

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }

.
.
.
 defaultConfig {
        applicationId "com.shakendate.shakendate"
        minSdkVersion rootProject.ext.minSdkVersion
        targetSdkVersion rootProject.ext.targetSdkVersion
        versionCode 17
        versionName "1.0"
        renderscriptTargetApi rootProject.ext.renderscriptVersion
        renderscriptSupportModeEnabled true
        vectorDrawables.useSupportLibrary = true
        multiDexEnabled true
    }
.
.
.
dependencies {
    implementation fileTree(dir: "libs", include: ["*.jar"])
    //noinspection GradleDynamicVersion
    implementation "com.facebook.react:react-native:+"  // From node_modules

    implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"

    implementation 'com.android.support:multidex:1.0.3'

    implementation project(':react-native-linear-gradient')

    implementation project(':react-native-splash-screen')

    implementation project(':react-native-svg')

    debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
        exclude group:'com.facebook.fbjni'
    }

    debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
        exclude group:'com.facebook.flipper'
        exclude group:'com.squareup.okhttp3', module:'okhttp'
    }

    debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}") {
        exclude group:'com.facebook.flipper'
    }

package.json

"dependencies": {
        "@react-native-async-storage/async-storage": "^1.13.2",
        "@react-native-community/cameraroll": "^4.0.1",
        "@react-native-community/masked-view": "^0.1.10",
        "@react-native-community/slider": "^3.0.3",
        "@react-native-picker/picker": "^1.9.4",
        "@react-navigation/bottom-tabs": "^5.11.2",
        "@react-navigation/native": "^5.8.10",
        "@react-navigation/stack": "^5.12.8",
        "axios": "^0.21.0",
        "moment": "^2.29.1",
        "react": "16.13.1",
        "react-native": "0.63.4",
        "react-native-actions-sheet": "^0.3.5",
        "react-native-actionsheet": "^2.4.2",
        "react-native-calendars": "^1.846.0",
        "react-native-countdown-circle-timer": "^2.3.10",
        "react-native-device-info": "^7.3.1",
        "react-native-geolocation-service": "^5.1.1",
        "react-native-gesture-handler": "^1.9.0",
        "react-native-iap": "^5.2.3",
        "react-native-image-crop-picker": "^0.35.1",
        "react-native-image-filter-kit": "^0.7.3",
        "react-native-keyboard-aware-scroll-view": "^0.9.3",
        "react-native-linear-gradient": "^2.5.6",
        "react-native-picker-select": "^8.0.4",
        "react-native-reanimated": "^1.13.2",
        "react-native-safe-area-context": "^3.1.9",
        "react-native-screens": "^2.16.1",
        "react-native-shake": "^3.5.0",
        "react-native-share": "^5.1.0",
        "react-native-simple-toast": "^1.1.3",
        "react-native-snap-carousel": "^3.9.1",
        "react-native-splash-screen": "^3.2.0",
        "react-native-svg": "^12.1.0",
        "react-native-view-shot": "^3.1.2",
        "react-native-webview": "^11.0.2",
        "react-navigation": "^4.4.3",
        "react-redux": "^7.2.2",
        "redux": "^4.0.5",
        "redux-thunk": "^2.3.0"
    },
    "devDependencies": {
        "@babel/core": "^7.8.4",
        "@babel/runtime": "^7.8.4",
        "@react-native-community/eslint-config": "^1.1.0",
        "babel-jest": "^25.1.0",
        "eslint": "^6.5.1",
        "husky": "^4.3.5",
        "jest": "^25.1.0",
        "lint-staged": "^10.5.3",
        "metro-react-native-babel-preset": "^0.59.0",
        "prettier": "^2.2.1",
        "react-test-renderer": "16.13.1"
    },


你找到解决办法了吗?我也遇到了完全相同的问题。 - undefined
很遗憾,由于我们有紧急的交付要求,所以我已经转换到另一个套餐了。 - undefined
1个回答

0

我在安装了这个软件包后解决了问题

对于32位二进制文件:sudo apt-get install libncurses5:i386

对于64位二进制文件:sudo apt-get install libncurses5

还需使用以下命令安装库集合:

sudo apt-get install ia32-libs


这个命令在哪里运行? - undefined

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接