bulubulu_鲸鱼不是鱼 2017-08-29 07:11
浏览 2192

如何使用android studio将指定文件编译到apk中

我现在有一些文件需要编译到apk中,但是不知道如何操作

这个是我需要编译到apk中的文件:
这个是我需要编译到apk中的文件
我希望最终达成的效果:
我希望最终达成的效果
我所使用的android stduio的版本为2.3.3,gradle版本为2.2.3。

我的 build.gradle文件

 apply plugin: 'com.android.application'

android {
    compileSdkVersion 25
    buildToolsVersion "25.0.2"
    defaultConfig {
        applicationId "lnsoft.mobile.xtyth"
        minSdkVersion 21
        targetSdkVersion 25
        versionCode 4
        versionName "1.06"
        //testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
//        multiDexEnabled true
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
//    sourceSets{
//        main{
//            jniLibs.srcDirs=['libs']
//        }
//    }
    aaptOptions.cruncherEnabled = false
    aaptOptions.useNewCruncher = false
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:cardview-v7:25.3.1'
    compile 'com.android.support:design:25.3.1'
    compile 'com.android.support:recyclerview-v7:25.3.1'
    compile 'com.android.support:appcompat-v7:25.3.1'
    compile 'org.litepal.android:core:1.6.0'
    compile 'com.alibaba:fastjson:1.1.62.android'
    compile project(path: ':commondialogutils_green')
    compile project(':Android_Validator_master')
    compile project(':pulltorefreshview')
    compile project(':changeskin')
//    compile 'com.android.support:multidex:1.0.1'
}

我该如何操作?

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 Qt下使用tcp获取数据的详细操作
    • ¥15 idea右下角设置编码是灰色的
    • ¥15 全志H618ROM新增分区
    • ¥20 jupyter保存图像功能的实现
    • ¥15 在grasshopper里DrawViewportWires更改预览后,禁用电池仍然显示
    • ¥15 NAO机器人的录音程序保存问题
    • ¥15 C#读写EXCEL文件,不同编译
    • ¥15 MapReduce结果输出到HBase,一直连接不上MySQL
    • ¥15 扩散模型sd.webui使用时报错“Nonetype”
    • ¥15 stm32流水灯+呼吸灯+外部中断按键