本文介绍了我不知道如何将下载器库和许可库添加到Android Studio的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 Google的下载器库和,因为我的应用程序将使用APK扩展.但是问题是我不知道如何将这两个库添加到Android Studio中.我总是通过File-> Import Module将库导入Android Studio,然后选择它.

I'm trying to use Google's Downloader Library and Application Licensing Service since my app is going to use APK Expansion. But the problem is I don't know how to add those 2 libraries to Android Studio. I always import libraries to Android Studio by File -> Import Module and then I select it.

但是这次我说的是:

即使我已经选择了Downloader Library或Licensing Library.

Even after I've already selected the Downloader Library or Licensing Library.

我还尝试通过将目录复制到我的应用程序目录中,然后将它们包含在gradle依赖项中来导入它们,但这也不起作用.

I also tried importing them by copying the directories to my app directory and then including them in gradle dependencies but that doesn't work either.

有人会引导我将这两个库添加到我的Android Studio中,因为我似乎无法弄清楚.

Could someone walk me through adding these 2 libraries to my Android Studio because I can't seem to figure it out.

推荐答案

我以非常奇怪的方式解决了这个问题.

I solved the problem in a very weird way.

我注意到我无法将这两个库直接导入Android Studio,因为它们缺少很多项目文件,因此Android Studio无法将它们识别为库.

I noticed that I can't import those 2 libraries directly to Android Studio because they are missing a lot of project files and therefore Android Studio doesn't recognize them as libraries.

然后我将两个库都导入到Eclipse中,以便生成所有必需的内容,然后将它们直接导出到Android Studio.

I then imported both libraries to Eclipse so that everything neccessary was generated and then exported them directly to Android Studio.

那就像一种魅力.

也许是导入库的一种怪异方法,但至少可以正常工作.

Maybe a weird way to import a library but at least it worked.

这篇关于我不知道如何将下载器库和许可库添加到Android Studio的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-01 14:03