0

在 Android Studio 1.0 RC 4 中,我试图导入一个 eclipse 库项目而不导出库以从 eclipse 创建 gradle 文件。 在此处输入图像描述

将库作为模块导入后,在编译我的项目时,它会抛出一个配置错误“错误:模块不能是 android 库”

我想这与 mylibrar.gradle 文件有关,但我检查并没有错误。关于这个错误的任何想法guyz。

mylibrary.gradle

apply plugin: 'com.android.library'

android {
    compileSdkVersion 21
    buildToolsVersion "21.1.1"

    defaultConfig {
        /*applicationId "xxxx"*/ // Library project doesnot have application id
        minSdkVersion 9
        targetSdkVersion 21
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
        }
    }
}

dependencies {
    compile files('libs/yyy.jar')
}
4

0 回答 0