Problem with Proguard and XmlPullParser

后端 未结 4 1587
北恋
北恋 2021-01-18 17:03

I\'m having a bit of trouble on an Android project using Proguard with some libraries. Specifically, i\'m having an XmlPullParser collision, and no matter what i seem to do,

4条回答
  •  南方客
    南方客 (楼主)
    2021-01-18 17:18

    To let library classes take precedence and shut up Proguard, put this in main-rules.xml (but copy a part to build.xml first):

                -libraryjars ${android.libraryjars}(!org/xmlpull/v1/XmlPullParser.class,!org/xmlpull/v1/XmlPullParserException.class)
    

    You'll run into other problems with XStream as well, see: Proguard and XStream with omitField() on Android

    For the whole story: https://plus.google.com/112617873637231221858/posts/YxWrEJRMSo4

提交回复
热议问题