proguard

I got this error for first attempt to login facebook.How can solve this?

时光毁灭记忆、已成空白 提交于 2019-12-10 12:09:18
问题 I searched very much but I did not see the real solution. Somebody says use ex facebook sdk , is it the real solution?(I use facebook 3.6 but somebody says on stackoverflow use 3.2) I use proguard, com.facebook.aq: com.facebook.c.f got an unexpected method signature: public abstract java.lang.Object com.facebook.c.c.e() at com.facebook.c.h.a(Unknown Source) at com.facebook.c.f.invoke(Unknown Source) at $Proxy0.e(Native Method) at com.facebook.b.al.a(Unknown Source) at com.facebook.b.al.a

obfuscation with proguard vs. java.lang.reflect.Proxy

随声附和 提交于 2019-12-10 11:57:09
问题 I use for debugging reasons the java.lang.reflect.Proxy stuff to have a generic way to implement all possible interfaces... but this seems to be difficult to get it working with proguard. Any suggestions? THX -Marco public class DebugLogListenerFactory { public static IAirplaneListenerAll createStreamHandle(ICAirplane plane) { DebugLogListenerHandler handler = new DebugLogListenerHandler(plane); IAirplaneListenerAll proxy = (IAirplaneListenerAll) Proxy .newProxyInstance(IAirplaneListenerAll

Jackson Json parser returns nulls on all object members on Android after optimizing with Proguard

梦想的初衷 提交于 2019-12-10 10:12:55
问题 I have an Android app which uses Jackson parser for JSON parsing. After I've ran Proguard on the classes I started to get null values on each and every member of the de-serialized classes. For example, if I have a object: public class Service{ private String name; private String version; ... getters, setters and stuff } and I receive a JSON with list of those objects: [{"name":"service1","version":"1.1"},{"name":"service2","version":"1.0"}] then I do: objectMapper.readValue(jsonString,new

Android性能优化—不建议使用枚举Enum

匆匆过客 提交于 2019-12-10 09:15:34
最近优化App,由于项目中使用了Lib,而Lib代码中包含了大量的枚举类型,导致App占用内存过多。好吧,知道问题点,那就干掉,抛弃之~ 问题是解决了,为啥会这样呢? 先来看看Android官网的说明吧: 看见了吧,Android官网不建议咱们使用enums,说的也很清楚了,占用内存多(Enums often require more than twice as much memory as static constants.)。 Android中当你的App启动后系统会给App单独分配一块内存。App的DEX code、Heap以及运行时的内存分配都会在这块内存中。 举个栗子: 1.使用Int表示状态 public static final int VALUE1 =1; public static final int VALUE1 =2; public static final int VALUE1 =3; 2.使用Enums表示状态 public static enum Value{ VALUE1, VALUE2, VALUE3 } 情形2中的DEX size增加是情形1中的13倍之多。这还只是DEX code的增加,同样,运行时的内存分配,一个enum值的声明会消耗至少20 bytes,这还不算其中的对象数组需要保持对enum值的引用。Why

proguard causes a crash in google play services' ActivityRecognitionResult getMostProbableActivity

前提是你 提交于 2019-12-10 09:02:21
问题 I've recently released an app to the play store, and while it works perfectly fine without proguard, i've got an unexpected crash when i did decide to use it. I've looked here for the recommended proguard rules for google play services, i've also tried adding another line for this case. Here's what I got (the third line is for my app): -keep class * extends java.util.ListResourceBundle { protected Object[][] getContents(); } -keep class * implements com.google.android.gms.internal.ae -keep

Using proguard with espresso/androidTest

依然范特西╮ 提交于 2019-12-10 02:43:23
问题 I'm trying to configure proguard to use it with my espresso UI test flavor. The thing is Proguard tends to ignore my debug proguard config. This is how the config looks: buildTypes { debug { minifyEnabled true proguardFiles 'proguard-debug.pro' testProguardFile 'proguard-debug.pro' signingConfig signingConfigs.release } } I added testProguardFile but it doesn't seem to work on androidTest . I'm running mockDebug flavor variant. When I just run the app it works fine, but when I try to run test

Can't generate signed APK in Android Studio, because proguard-rules.txt is missing

隐身守侯 提交于 2019-12-10 01:10:00
问题 I have a problem with generating signed APK in Android Studio. After fixing all the warnings I am stuck on this one: Error:Execution failed for task ':app:proguardRelease'. java.io.FileNotFoundException: /Users/franek/Documents/Android_Studio_Melange/app/proguard-rules.txt (No such file or directory) I don't want to change minifyEnabled to false, because I want to keep Proguard working. How can I fix this error? A fragment of build.gradle: buildTypes { release { minifyEnabled true

Producing an obfuscated library out of an Android Library Project

烈酒焚心 提交于 2019-12-09 23:53:40
问题 I've written an Android application using an Android Library project, also written by me. I have to release the source code of the app, but I don't want to distribute the sources of the library. This library defines, among other things, custom views, so it includes XML layouts and resources. I was thinking of releasing this library in binary form (a .jar maybe?), to be referenced by the main project. I want this binary library to be obfuscated via Proguard. Is this feasible? How? Thanks. 回答1:

Always running proguard before Android dex'ing in Eclipse

和自甴很熟 提交于 2019-12-09 17:48:20
问题 Is there a way to make Eclipse always run proguard before dex'ing when trying to run an Android Application? e.g. some way of seamlessly inserting it as a build step? By default it will run when exporting, but I need it to always run, even when e.g. just doing a normal "Run" or "Debug" from the menu / keyboard. For context, the reason this is relevant is that I'm running into the "too many opcodes / no expanded opcodes" (http://code.google.com/p/android/issues/detail?id=26203) issues with my

android - proguard error in android studio

空扰寡人 提交于 2019-12-09 16:39:36
问题 I want to use proguard for my application ,I enabled it but when I want to generate apk file ,it gives me this error: Information:Gradle tasks [:app:assembleRelease] :app:preBuild UP-TO-DATE :app:preReleaseBuild UP-TO-DATE :app:checkReleaseManifest :app:preDebugBuild UP-TO-DATE :app:prepareComAndroidSupportAppcompatV72300Library UP-TO-DATE :app:prepareComAndroidSupportCardviewV72300Library UP-TO-DATE :app:prepareComAndroidSupportDesign2300Library UP-TO-DATE :app