2012-10-23 9 views
15

ठीक है लोग तो यह काम करने के लिए अपने प्रोजेक्ट करने की कोशिश कर अत्यंत कष्टप्रद होता जा रहा है जब/Proguard संदर्भित नहीं कर सकते पाते वर्ग com.google.ads.internal.state.AdState

Progaurd रहता निर्यात मुझे इस त्रुटि दे रही है:

Proguard returned with error code 1. See console 

यहाँ पूर्ण त्रुटि मैं कंसोल में मिलता है:

Warning: com.google.ads.m: can't find referenced class com.google.ads.internal.state.AdState 
[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu] Warning: com.google.ads.m: can't find referenced class com.google.ads.internal.state.AdState 

[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]  You should check if you need to specify additional program jars. 

[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu] Warning: there were 2 unresolved references to classes or interfaces. 

[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]   You may need to specify additional library jars (using '-libraryjars'). 

[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu] java.io.IOException: Please correct the above warnings first. 

[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]  at proguard.Initializer.execute(Initializer.java:321) 
[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]  at proguard.ProGuard.initialize(ProGuard.java:211) 
[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]  at proguard.ProGuard.execute(ProGuard.java:86) 
[2012-10-23 18:14:20 - com.fttech.monkey_toss.Menu]  at proguard.ProGuard.main(ProGuard.java:492) 

किसी को भी यह कैसे हल करने के लिए पता है ??

संपादित करें:

यह मेरा नया त्रुटि है::

java.io.IOException: Can't read [C:\Users\a\workspace2\AndEngine\bin\andengine.jar] (Can't process class [org/andengine/ui/activity/SimpleBaseGameActivity.class] (Unexpected end of ZLIB input stream)) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.InputReader.readInput(InputReader.java:230) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.InputReader.readInput(InputReader.java:200) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.InputReader.readInput(InputReader.java:178) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.InputReader.execute(InputReader.java:78) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.ProGuard.readInput(ProGuard.java:196) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.ProGuard.execute(ProGuard.java:78) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.ProGuard.main(ProGuard.java:492) 
[2012-10-23 23:47:02 - Monkey Toss_New] Caused by: java.io.IOException: Can't process class [org/andengine/ui/activity/SimpleBaseGameActivity.class] (Unexpected end of ZLIB input stream) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.ClassReader.read(ClassReader.java:112) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.FilteredDataEntryReader.read(FilteredDataEntryReader.java:87) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.JarReader.read(JarReader.java:65) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.DirectoryPump.readFiles(DirectoryPump.java:65) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.DirectoryPump.pumpDataEntries(DirectoryPump.java:53) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.InputReader.readInput(InputReader.java:226) 
[2012-10-23 23:47:02 - Monkey Toss_New]  ... 6 more 
[2012-10-23 23:47:02 - Monkey Toss_New] Caused by: java.lang.RuntimeException: Unexpected end of ZLIB input stream 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.classfile.io.RuntimeDataInput.readInt(RuntimeDataInput.java:136) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.classfile.io.ProgramClassReader.visitProgramClass(ProgramClassReader.java:77) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.classfile.ProgramClass.accept(ProgramClass.java:346) 
[2012-10-23 23:47:02 - Monkey Toss_New]  at proguard.io.ClassReader.read(ClassReader.java:91) 
[2012-10-23 23:47:02 - Monkey Toss_New]  ... 11 more 
+0

आप पढ़ना चाहिए https://groups.google.com/forum/?fromgroups=#!topic/ google-admob-ads-sdk/JllLSIXWtBk – hrules6872

+0

इसी प्रकार: http://stackoverflow.com/questions/18646899/proguard-cant-find-referenced-class-com-google-android-gms-r/ – trante

उत्तर

28

यह समस्या AdMob SDK के साथ शुरू किया

यहाँ मेरी proguarg-project.txt

# To enable ProGuard in your project, edit project.properties 
# to define the proguard.config property as described in that file. 
    # 
# Add project specific ProGuard rules here. 
# By default, the flags in this file are appended to flags specified 
# in ${sdk.dir}/tools/proguard/proguard-android.txt 
# You can edit the include path and order by changing the ProGuard 
# include property in project.properties. 
# 
# For more details, see 
# http://developer.android.com/guide/deve ... guard.html 

# Add any project specific keep options here: 

# If your project uses WebView with JS, uncomment the following 
# and specify the fully qualified class name to the JavaScript interface 
# class: 
#-keepclassmembers class fqcn.of.javascript.interface.for.webview { 
# public *; 
#} 
#admob, uncomment if using: 
-keep public class com.admob.android.ads.** {*;} 

# google analytics, uncomment if using: 
#-keep class com.google.android.apps.analytics.PipelinedRequester$Callbacks 

# google inapp billing, uncomment if using: 
#-keep class com.android.vending.billing.** 

# Box2D 
-keep public class com.badlogic.** {*;} 

संपादित है 6.1.0 और 6.2.1 (एंड्रॉइड के लिए)। त्रुटि को ठीक करने के लिए, अपने proguard.cfg फ़ाइल से जोड़ें:

-dontwarn com.google.ads.** 

स्रोत: https://groups.google.com/d/msg/google-admob-ads-sdk/JllLSIXWtBk/ioXzTWKoYgMJ

+1

मेरे लिए यह केवल काम करता है जब मैं उस लाइन को proguard-project.txt में डालता हूं। – Anonsage

+0

मेरी प्रोजेक्ट में मेरे पास proguard.cfg नहीं है I have proguard-project.txt है, इसलिए जब मैंने इसे proguard-project.txt में जोड़ा, यह काम करता है !! बहुत बहुत धन्यवाद !!! :) –

संबंधित मुद्दे