mangstadt / ez-vcard

A vCard parser library for Java
Other
399 stars 92 forks source link

How to solve proguard time inner class issue? #74

Closed krishna-mk88 closed 7 years ago

krishna-mk88 commented 7 years ago

Information:Gradle tasks [:assembleRelease] Error:warning: Ignoring InnerClasses attribute for an anonymous inner class Error:(org.apache.commons.httpclient.HttpMethodBase$1) that doesn't come with an Error:associated EnclosingMethod attribute. This class was probably produced by a Error:compiler that did not target the modern .class file format. The recommended Error:solution is to recompile the class from source, using an up-to-date compiler Error:and without specifying any "-target" type options. The consequence of ignoring Error:this warning is that reflective operations on this class will incorrectly Error:indicate that it is not an inner class. Error:warning: Ignoring InnerClasses attribute for an anonymous inner class Error:(org.apache.commons.httpclient.protocol.ControllerThreadSocketFactory$1) that doesn't come with an Error:associated EnclosingMethod attribute. This class was probably produced by a Error:compiler that did not target the modern .class file format. The recommended Error:solution is to recompile the class from source, using an up-to-date compiler Error:and without specifying any "-target" type options. The consequence of ignoring Error:this warning is that reflective operations on this class will incorrectly Error:indicate that it is not an inner class. Error:UNEXPECTED TOP-LEVEL ERROR: Error:java.lang.OutOfMemoryError: GC overhead limit exceeded Error:Execution failed for task ':transformClassesWithDexForRelease'.

com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: java.lang.UnsupportedOperationException Information:BUILD FAILED

here above me added error details. eclipse project convert to android studio project. after proguard time above issue displayed but it run debug apk. proguard time this issue displayed. please help me. how to solve this issue

Gradle file:

apply plugin: 'com.android.application'

dependencies { compile fileTree(include: '*.jar', dir: 'libs') // compile 'com.android.support:appcompat-v7:+' compile group: 'org.codehaus.jackson', name: 'jackson-core-asl', version: '1.9.13' compile group: 'org.codehaus.jackson', name: 'jackson-mapper-asl', version: '1.9.13' compile 'com.google.android.gms:play-services:8.4.0'

// compile 'com.fasterxml.jackson.core:jackson-core-asl:1.9.13' // compile 'com.fasterxml.jackson.core:jackson-mapper-asl:1.9.13'

} buildscript { repositories { jcenter() }

dependencies {
    classpath 'com.android.tools.build:gradle:2.2.2'
   // classpath 'com.android.tools.build:gradle:1.3.0'

}

}

android { //compileSdkVersion 19 // buildToolsVersion "19.0.3" compileSdkVersion 23 buildToolsVersion "23.0.0" defaultConfig {

    minSdkVersion 14
    targetSdkVersion 21

    // Enabling multidex support.
    multiDexEnabled true
}
useLibrary  'org.apache.http.legacy'
compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_7
    targetCompatibility JavaVersion.VERSION_1_7
}
android {
  packagingOptions {
        exclude 'META-INF/DEPENDENCIES.txt'
        exclude 'META-INF/LICENSE.txt'
        exclude 'META-INF/NOTICE.txt'
       exclude 'META-INF/NOTICE'
        exclude 'META-INF/LICENSE'
        exclude 'META-INF/DEPENDENCIES'
        exclude 'META-INF/notice.txt'
        exclude 'META-INF/license.txt'
        exclude 'META-INF/dependencies.txt'
        exclude 'META-INF/LGPL2.1'
      exclude 'META-INF/ASL2.0'

    }

}
defaultConfig {
    multiDexEnabled true
}
sourceSets {
    main {
        manifest.srcFile 'AndroidManifest.xml'
        java.srcDirs = ['src']
        resources.srcDirs = ['src']
        aidl.srcDirs = ['src']
        renderscript.srcDirs = ['src']
        res.srcDirs = ['res']
        assets.srcDirs = ['assets']
    }

    // Move the tests to tests/java, tests/res, etc...
    instrumentTest.setRoot('tests')

    // Move the build types to build-types/<type>
    // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
    // This moves them out of them default location under src/<type>/... which would
    // conflict with src/ being used by the main source set.
    // Adding new build types or product flavors should be accompanied
    // by a similar customization.
    debug.setRoot('build-types/debug')
    release.setRoot('build-types/release')
}
allprojects {
    repositories {
        mavenCentral()
    }
}

}

mangstadt commented 7 years ago

Don't know