gpt4 book ai didi

Android studio 2.3生成aar而不是apk

转载 作者:行者123 更新时间:2023-11-30 00:39:23 25 4
gpt4 key购买 nike

Build > Build APK 生成 aar 而不是 apk。

Success window

outputs 文件夹中我只有 aar 文件夹:

explorer

我的 build.gradle android 部分:

android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
defaultConfig {
applicationId "my.cool.app"
minSdkVersion 21
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true;
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
}

有什么问题?

最佳答案

问题是您的 Build APK 调用了错误的 gradle 函数。检查您的编译选项:

Android Studio/首选项/构建、执行和部署/编译器

Android Studio / Preferences / Build, Executions and Deployment / Compiler

同时检查您的项目配置:

enter image description here

enter image description here

关于Android studio 2.3生成aar而不是apk,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42787961/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com