我收到了一个gradle同步错误,其详细信息如下

时间:2015-12-22 12:52:31

标签: android android-studio gradle version-control

我从VCS更新了项目。我清理,重建,成功同步项目但是当我运行它时会给出下面的错误。 昨天也发生了同样的情况,我刚刚清理过重建我的项目&错误发生了,但今天仍然没有工作。 我在stackoverflow&上找到了很多答案。其他网站,但没有一个解决方案解决了我的问题。

关注此行是我开始运行项目的错误:

Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Execution failed for task ':mySNL:dexDebug'.> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.7.0_15\bin\java.exe'' finished with non-zero exit value 1

以下是我正在处理的模块的build.gradle:

apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'

android {
compileSdkVersion 23
buildToolsVersion '23.0.1'

defaultConfig {
    applicationId "com.mysnl"
    minSdkVersion 15
    targetSdkVersion 23
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_7
        targetCompatibility JavaVersion.VERSION_1_7
    }
    multiDexEnabled true
}

buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
    }
}

android {
    packagingOptions {
        exclude 'META-INF/DEPENDENCIES'
        exclude 'META-INF/NOTICE'
        exclude 'META-INF/LICENSE'
        exclude 'META-INF/LICENSE.txt'
        exclude 'META-INF/NOTICE.txt'
    }
    dexOptions {
        incremental true
        javaMaxHeapSize "2g"
    }
}

useLibrary  'org.apache.http.legacy'
}

dependencies {



compile 'com.android.support:multidex:1.0.1'
compile project(':library')
compile project(':resideMenu')
compile project(':wheel')
compile 'com.google.code.gson:gson:2.2.1'
compile files('libs/AF-Android-SDK-v2.3.1.17.jar')
compile files('libs/FlurryAnalytics-5.5.0.jar')
compile files('libs/YouTubeAndroidPlayerApi.jar')

compile 'com.android.support:support-v13:22.2.0'
compile files('libs/android-support-v7-recyclerview.jar')
compile files('libs/bitlyj-2.0.0.jar')
compile files('libs/json_simple-1.1.jar')
compile files('libs/tokenautocomplete-1.1.1.jar')
compile files('libs/twitter4j-core-4.0.2.jar')
compile files('libs/twitter_api_me-1.8.3.jar')

compile 'org.apache.httpcomponents:httpcore:4.3.2'
compile 'com.google.zxing:core:3.2.1'
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.4'
compile ('com.google.android.gms:play-services-gcm:8.3.0'){
    exclude module: 'support-v4'
}

compile 'org.apache.httpcomponents:httpmime:4.2.6'
compile 'se.emilsjolander:StickyScrollViewItems:1.1.0'
compile 'se.emilsjolander:stickylistheaders:2.7.0';
compile 'com.github.siyamed:android-shape-imageview:0.9.+@aar'


/* 5) Use 21 or 22 */
compile ('com.android.support:appcompat-v7:22.2.0'){
    exclude module: 'support-v4'
    exclude module: 'annotation'
}
compile ('com.android.support:design:22.2.0'){
    exclude module: 'support-v4'
    exclude module: 'annotation'
}

/* 6) Add the CSDK framework dependencies (Make sure these version numbers are correct) */
compile ('com.adobe.creativesdk.foundation:auth:0.7.329'){
    exclude module: 'support-v4'
    exclude module: 'annotation'
}
compile ('com.adobe.creativesdk:image:4.0.0'){
    exclude module: 'support-v4'
    exclude module: 'annotation'
}
compile ('com.google.android.gms:play-services-appindexing:8.3.0'){
    exclude module: 'support-v4'
    exclude module: 'annotation'
    exclude module: 'internal'
}

compile ('com.facebook.android:facebook-android-sdk:4.7.0'){
    exclude module: 'support-v4'
}
}

0 个答案:

没有答案