android libs studio
2015-04-02 10:12:00 weixin_33709609 阅读数 40

Android studio libs目录:

 

关于Android studio libs目录,Android studio 已经为我们自动生成了,如果默认

 

 

是看不到默认Libs目录的,点击红色按钮地方,选择project 切换,就可以看到libs目录了》。。详细截图如下:

 

*Click the left side dropdown of android studio and choose project to see libs folders

enter image description here

*after choosing project you will see the libs directory

shareedit

 

2015-04-02 10:12:00 weixin_33815613 阅读数 13

Android studio libs目录:

 

关于Android studio libs目录,Android studio 已经为我们自动生成了,如果默认

 

 

是看不到默认Libs目录的,点击红色按钮地方,选择project 切换,就可以看到libs目录了》。。详细截图如下:

 

*Click the left side dropdown of android studio and choose project to see libs folders

enter image description here

*after choosing project you will see the libs directory

shareedit

 

2018-09-05 13:22:14 niubichen16 阅读数 19

1.add libs directory.step:
a. select module in project view
这里写图片描述
b. right key of mouse new->Directory and give name “libs”
then,it looks like this
这里写图片描述
2.copy .jar to this directory
for example:use linux cmd :cd xxx/app//libs;cp xx.jar ./libs
then,it looks like this
这里写图片描述
3.modify the build.gradle of the module

android {
...
sourceSets {
        main {
            jniLibs.srcDirs = ['libs']
        }
    }
    repositories {
        flatDir {
            dirs 'libs'
        }
    }
 }
dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')
    ...
    implementation files('libs/achartengine-1.0.0.jar')
}
...
2016-09-24 09:48:38 zzldm 阅读数 717

Step to add external library in Android Studio

  1. If you are in Android View in project explorer, change it to Project view as below

enter image description here

  1. Right click the desired module where you would like to add the external library, then selectNew > Directroy and name it as 'libs'
  2. Now copy the blah_blah.jar into the 'libs' folder
  3. Right click the blah_blah.jar, Then select 'Add as Library..'. This will automatically add and entry in build.gradle as compile files('libs/blah_blah.jar') and sync the gradle. And you are done

Please Note : If you are using 3rd party libraries then it is better to use transitive dependencies where Gradle script automatically downloads the JAR and the dependency JAR when gradle script run.

Ex : compile 'com.google.android.gms:play-services-ads:9.4.0'

Read more about Gradle Dependency Mangement


原文

2019-01-08 11:28:28 Mr__dingding 阅读数 177

1.切换到项目的Project目录下

 2.在app目录下如果没有则创建创建libs
 3.将jar文件直接拷贝到libs文件夹下
没有更多推荐了,返回首页