【发布时间】:2020-04-03 11:45:47
【问题描述】:
我试图寻找解决方案,就像我无处可去。 我已经尝试过这个解决方案:
Manifest merger failed with multiple errors, see logs
但不会帮助我
这是我的清单文件
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:dist="http://schemas.android.com/apk/distribution"
xmlns:tools="http://schemas.android.com/tools"
xmlns:activitytools="http://schemas.android.com/apk/res-auto"
package="technerd.com.iboda">
<!--
The ACCESS_COARSE/FINE_LOCATION permissions are not required to use
Google Maps Android API v2, but you must specify either coarse or fine
location permissions for the 'MyLocation' functionality.
-->
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
<dist:module dist:instant="true"
/>
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<service
android:name=".onAppKilled"
android:stopWithTask="false" />
<activity android:name=".HistorySingle"/>
<activity android:name=".HistoryActivity" />
<activity android:name=".DriverSettings" />
<activity android:name=".SignUp" />
<!--
The API key for Google Maps-based APIs is defined as a string resource.
(See the file "res/values/google_maps_api.xml").
Note that the API key is linked to the encryption key used to sign the APK.
You need a different API key for each encryption key, including the release key that is used to
sign the APK for publishing.
You can define the keys for the debug and release targets in src/debug/ and src/release/.
-->
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="@string/google_maps_key" />
<activity
android:name=".DriverMapsActivity"
android:label="@string/title_activity_driver_maps" />
<activity
android:name=".CustomerMapsActivity"
android:label="@string/title_activity_customer_maps" />
<activity android:name=".DriverLogin" />
<activity android:name=".CustomerLogin" />
<activity android:name=".MainActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
合并清单中的错误日志
合并错误:
错误:属性
AndroidManifest.xml:21:13-66 中的activity#com.google.android.libraries.places.widget.AutocompleteActivity@theme value=(@style/PlacesAutocompleteThemeOverlay) 也出现在 AndroidManifest.xml:18:13- 61 值=(@style/PlacesAutocompleteOverlay)。建议:将 'tools:replace="android:theme"' 添加到 AndroidManifest.xml:16:9-23:20 的元素以覆盖。应用程序主清单(此文件),第 20 行
错误:属性
activity#com.google.android.libraries.places.widget.AutocompleteActivity@windowSoftInputMode value=(stateAlwaysVisible|adjustPan) 来自 AndroidManifest.xml:22:13-71 也出现在 AndroidManifest.xml:19:13-55值=(调整大小)。建议:将 'tools:replace="android:windowSoftInputMode"' 添加到 AndroidManifest.xml:16:9-23:20 的元素以覆盖。应用程序主清单(此文件),第 21 行
【问题讨论】:
-
同时发布你的模块级别
build.gradle -
查看此链接,它将对您有所帮助:developer.android.com/studio/build/manifest-merge 并查看此链接:stackoverflow.com/questions/25981156/…