Android locale_config.xml 未绑定(bind)前缀错误

标签 android react-native

我目前正在对 Android 应用程序进行渗透测试。我反编译了应用程序,没有任何问题,每当我尝试重新编译它时,apktool.jar 从 locale_config.xml 文件中抛出 Unbound Prefix Error。检查了语法,它们都没有问题。我对发生的事情一无所知。

W: C:\platform-tools\patch-apk\swifty\base_SAP\res\xml\locales_config.xml:3: error: unbound prefix.
W: C:\platform-tools\patch-apk\swifty\base_SAP\res\xml\locales_config.xml: error: file failed to compile.
Failed!!!

文件内容如下:

<?xml version="1.0" encoding="utf-8"?>
<locale-config>
...
    <locale android:name="en-CA" />
    <locale android:name="en-GB" />
    <locale android:name="en-XC" />
    <locale android:name="en-IN" />
    <locale android:name="en-AU" />
    <locale android:name="zh-HK" />
...
</locale-config>

最佳答案

更新build.gradle文件中的compileSdktargetSdk版本到33或更高版本修复问题

android {
    compileSdk = 33
    defaultConfig {
        applicationId = "com.example.app"
        minSdk = 23
        targetSdk = 33
        ...
    }
    ...
}

关于Android locale_config.xml 未绑定(bind)前缀错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71267862/

相关文章:

android - 在 Ubuntu 上安装 Calabash Android 时无法构建 gem native 扩展

java - Fitness.API 在 Google Play Services 7.0 中被移除了吗?

ios - 执行 expo build :ios 时,Apple Developer Portal 中的身份验证失败

reactjs - 如何打开 react-devtools?

react-native - 有没有办法使用 React Native 的打包程序为 "require"路径设置别名?

java - 如何在android中正确实现C2DM?

Android: ScrollView 问题

javascript - React Native NavigationContainer 不显示任何内容

javascript - 带有异步和等待 react native 的箭头功能

适用于 Windows 的 Android Studio 未安装和更新包