AndroidStudio2023.1.1,我要配置gradle的buildFeatures的AIDL以建立AIDL文件

参照其它博主设置了

buildFeatures {
    aidl true
}

但是输出了报错Unexpected tokens (use ';' to separate expressions on the same line),如下图所示:

经过个人尝试,要更换成aidl=true才行,即:

android {
    buildFeatures {
        aidl=true
    }
}

,重新构建后,已经成功:

可以建立AIDL文件了。

更多推荐