Jar mismatch! Fix your dependencies

后端 未结 10 1893
借酒劲吻你
借酒劲吻你 2020-11-27 11:32

Steps to reproduce:

  1. create a android project \"MyApp\"
  2. import ActionBarSherlock(ABS),Directional ViewPager(DVP), or any other open source library wh
10条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-11-27 12:26

    Use a Library Project just for the Support Library

    As of ADT 22, using Eclipse Juno

    I don't think any of the above are really the best answers. I also don't think it is recommended to use the external jar function in Eclipse anymore (AFAIK).

    Rather, what worked for me is to create a separate empty library project.

    Then use Android tools > Add Support Library to get the latest version you need or want.

    Then remove the support lib jar from all other projects.

    Finally, for every project that requires it, add a reference to your new Library project

    (project properties) > Android > (Library box) > Add...

    Then all your projects will have a single source to use and update the support library. This also makes javadocs easier to get working.

    For info on how to setup the javadocs see:

    How to attach javadoc or sources to jars in libs folder?

提交回复
热议问题