내 응용 프로그램은 정상적으로 작동하지만 multidex android와 관련된 문제가 발생했습니다. 나는 문제를 찾고 android.developers 가이드에 따라 필수 업데이 트를 했어. 그러나 몇 시간 동안 나는 같은 문제로 싸우고있다. 다른 솔루션을 적용했지만 여전히 동일한 문제가 있습니다. 하나의 gradle 빌드는 11-12 분 동안 곧바로 걸리며 솔루션을 테스트하기 위해 11-12 분을 기다려야 만 실제로 나를 죽이고 있습니다. 내 Gradle 및 매니페스트 파일을 공유하고 있습니다. 이 문제와 관련하여 도움을주십시오.multidex 동작을 업데이트 할 수 없습니다.
Build.Gradle 파일
apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "24.0.0"
defaultConfig {
applicationId "com.example.mudasir.login"
minSdkVersion 16
targetSdkVersion 24
versionCode 1
versionName "1.0"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions{
exclude'META-INF/NOTICE.txt'
exclude'META-INF/NOTICE'
exclude'META-INF/notice.txt'
exclude'META-INF/LICENSE.txt'
exclude'META-INF/LICENSE'
exclude'META-INF/license.txt'
}
dexOptions{
preDexLibraries = false
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
//compile 'com.android.support:appcompat-v7:24.2.0'
compile 'com.android.support:design:24.2.0'
compile 'com.android.support:support-v4:24.2.0'
compile 'com.google.android.gms:play-services:9.4.0'
}
매니페스트 파일 :
이<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.mudasir.login">
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<!--
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" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme">
android:name="android.support.multidex.MultiDexApplication">
<activity
android:name=".SignUpActivity"
android:label="@string/app_name"
android:theme="@style/AppTheme.NoActionBar" />
<activity
android:name=".MainScreenActivity"
android:label="@string/title_activity_main_screen_activity"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".SignInActivity"
android:label="@string/title_activity_signin_"
android:theme="@style/AppTheme.NoActionBar" />
<activity
android:name=".sidemenu_Activity"
android:theme="@style/AppTheme.NoActionBar">
</activity>
<!--
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=".MapsActivity"
android:label="@string/title_activity_maps">
</activity>
</application>
</manifest>
로 분할 된 V4 지원 라이브러리의 같은 날 ..이 유일한 문제가 .. 확인하자 ?? –
예, 이미 multidexEnabled true 및 업데이트 된 응용 프로그램 태그 – abhishesh
을 지정했습니다. 시도해보십시오 .. 10 miuntes gradle 빌드를 사용하여 하나의 솔루션을 확인합니다. : ( –