[英]Eclipse ADT removes permissions when signing APK
I am using Eclipse ADT to sign my app for submission to the Play Store. 我正在使用Eclipse ADT对我的应用进行签名,以提交给Play商店。 I right click on the project and choose Android Tools -> Export Signed Application Package.
我右键单击该项目,然后选择“ Android工具->导出签名的应用程序包”。 However when I do this it removes permissions from the Manifest file that is required for the application to run.
但是,当我这样做时,它会从运行该应用程序所需的清单文件中删除权限。 Below is my Manifest file.
以下是我的清单文件。
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="18" />
<uses-permission
android:name="android.permission.INTERNET" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.myou.MyApp"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
After exporting the uses-permission is removed: 导出后,使用许可被删除:
<uses-permission android:name="android.permission.INTERNET" />
I have tried fixing the properties in the Android Tools before exporting, but it still removes the permission. 我曾尝试在导出前修复Android Tools中的属性,但仍会删除该权限。
If anyone comes across this problem the simple answer is: 如果有人遇到此问题,简单的答案是:
Do not attempt to edit AndroidManifest.xml
file found in the bin
directory. 不要尝试编辑在
bin
目录中找到的AndroidManifest.xml
文件。 You need to change the file in the root of your project. 您需要在项目的根目录中更改文件。
尝试重新启动Eclipse,然后导出您的应用程序。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.