Warning:Project app: 只支持Jar类型的本地依赖

Warning:Project app: Only Jar-type local dependencies are supported

我正在尝试通过 youtubeAPI 获取电影视频预告片,但是当我在依赖项中添加 YouTubeAndroidPlayerApi-1.2.2.zip 时,它显示错误:

Warning:Project app: Only Jar-type local dependencies are supported. Cannot handle: MyMovies/app\libs\YouTubeAndroidPlayerApi-1.2.2.zip.

那么我该如何解决呢。或者如何在 android studio 中添加 zip 文件。

提取 YouTubeAndroidPlayerApi-1.2.2.zip 文件 > 进入 libs 目录。你会发现 YouTubeAndroidPlayerApi.jar。尝试将其包含在您的项目中。