红鱼儿

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

统计

Delphi 编译的app无法在android 14安装

今天用delphi 12.1升级旧项目,编译正常,但安装时出下面的提示:

08:48:26 E/SplitApkInstaller: Failed to finalize session : INSTALL_PARSE_FAILED_MANIFEST_MALFORMED: Failed parse during installPackageLI: /data/app/vmdl1849586780.tmp/base.apk (at Binary XML file line #67): com.embarcadero.firemonkey.CCFMXNativeActivity: Targeting S+ (version 31 and above) requires that an explicit value for android:exported be defined when intent filters are present
[BT:1.5.0] Error: Installation of the app failed.
com.android.tools.build.bundletool.model.exceptions.CommandExecutionException: Installation of the app failed.
    at com.android.tools.build.bundletool.model.exceptions.InternalExceptionBuilder.build(InternalExceptionBuilder.java:57)
    at com.android.tools.build.bundletool.device.DdmlibDevice.installApks(DdmlibDevice.java:145)

解决方法,在AndriodManifest.template.xml文件中增加一句:android:exported="true":

复制代码
        <activity android:name="com.embarcadero.firemonkey.CCFMXNativeActivity"
                android:label="%activityLabel%"
                android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
                android:launchMode="singleTask"
                android:exported="true">
            <!-- Tell NativeActivity the name of our .so -->
            <meta-data android:name="android.app.lib_name"
                android:value="%libNameValue%" />
            <intent-filter>  
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter> 
        </activity>
复制代码

 正常情况下,你用D12建的项目不存在这个问题,升级旧的项目才可能遇到,因为D12自动加了android:exported="true"。

 

posted on   红鱼儿  阅读(718)  评论(0编辑  收藏  举报

相关博文:
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· 开源Multi-agent AI智能体框架aevatar.ai,欢迎大家贡献代码
· Manus重磅发布:全球首款通用AI代理技术深度解析与实战指南
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
· AI技术革命,工作效率10个最佳AI工具
历史上的今天:
2020-04-10 ChinaCock界面控件介绍-TCCStatusBar,TCCTitleBar,TCCNavigatorBar
点击右上角即可分享
微信分享提示