2 files found with path ‘lib/arm64-v8a/libc++_shared.so‘ from inputs...-react native

  1. 安装react-native是出现错误:
  2. 先声明一下我的rn是   0.68.2
  3. 编辑一下  android/build.gradle ,一下加上一段话,将全部版本变成统一的。

    
    allprojects {
        
        // ...
    
        def REACT_NATIVE_VERSION = new File(['node', '--print',"JSON.parse(require('fs').readFileSync(require.resolve('react-native/package.json'), 'utf-8')).version"].execute(null, rootDir).text.trim())
    
        configurations.all {
            resolutionStrategy {
                force "com.facebook.react:react-native:" + REACT_NATIVE_VERSION
            }
        }
    }
    

     

你可能感兴趣的:(react,native,react,native)