android开发中显示Installation failed with message INSTALL_FAILED_OLDER_SDK.

本文记录了一次在Android Studio创建项目并尝试运行时遇到的安装失败问题,错误提示为“INSTALL_FAILED_OLDER_SDK”。通过调整项目的minSdkVersion值从23降低到15解决了该问题。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

在android studio 新创建项目,居然在运行时显示“Installation failed with message INSTALL_FAILED_OLDER_SDK.,It is possible that this issue is resolved by uninstalling an existing version of the apk if it is present, and then re-installing.”,先贴出我的build.gradle :
apply plugin: 'com.android.application'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.2"

    defaultConfig {
        applicationId "com.example.demo.rong_demo2"
        minSdkVersion 23
        targetSdkVersion 23
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
}


这是创建项目时,自动创建的gradle 文件 ,没弄明白怎么回事, 之后 将
minSdkVersion 的23改为15,就能正常运行了,具体什么原因还不明白,先mark起来,路过的大神帮解答一下吧!
-- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy -- mav_state_machine_msgs: 1 messages, 1 services -- +++ processing catkin package: 'mav_system_msgs' -- ==> add_subdirectory(mav_comm/mav_system_msgs) CMake Deprecation Warning at mav_comm/mav_system_msgs/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 2.8.12 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. -- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy -- mav_system_msgs: 2 messages, 0 services -- +++ processing catkin package: 'rotors_comm' -- ==> add_subdirectory(rotors_simulator/rotors_comm) CMake Deprecation Warning at rotors_simulator/rotors_comm/CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 2.8.12 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. -- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy -- Could NOT find octomap_msgs (missing: octomap_msgs_DIR) -- Could not find the required component 'octomap_msgs'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found. CMake Error at /home/zk/ros_catkin_ws/install_isolated/share/catkin/cmake/catkinConfig.cmake:83 (find_package): Could not find a package configuration file provided by "octomap_msgs" with any of the following names: octomap_msgsConfig.cmake octomap_msgs-config.cmake Add the installation prefix of "octomap_msgs" to CMAKE_PREFIX_PATH or set "octomap_msgs_DIR" to a directory containing one of the above files. If "octomap_msgs" provides a separate development package or SDK, be sure it has been installed. Call Stack (most recent call first): rotors_simulator/rotors_comm/CMakeLists.txt:3 (find_package) -- Configuring incomplete, errors occurred! See also "/home/zk/catkin_ws/build/CMakeFiles/CMakeOutput.log". make: *** [Makefile:282:cmake_check_build_system] 错误 1 Invoking "make cmake_check_build_system" failed
最新发布
07-22
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值