0

Well, I am trying to develop an APP for my Smartphone Samsung Galaxy Ace, which contains android 2.3.6 (Gingerbread). The problem is that I can't select a lower API to develop, as shown in the picture:

I also tried downloading the API I needed from SDK Manager

I've also seen some people changing SDK version from activity_main.xml, in the design menu, but as the picture shows, there aren't any other options available:

I tried editing build.gradle(Module:app) But it keeps giving me errors, I used tools:overrideLibrary, but it gives me more errors with more libraries to override

Please, let me know if there's a way to choose API level 9 (in my case) instead of choosing a higher API

Bhargav Rao
  • 50,140
  • 28
  • 121
  • 140
julio
  • 23
  • 1
  • 6
  • What are min sdk, target sdk and building tools versions. These 4 items are related to each others. – Ali Sheikhpour Jan 21 '18 at 20:58
  • What do you mean by "building tools versions"? Are you talking about downloadable sdk tools? My minSdkVersion was set to 9 as iTadreik suggested. Target Sdk is set to 26 as well as compileSdkVersion – julio Jan 22 '18 at 23:52

1 Answers1

0

Create your app with the android 4.0 SDK. Once you have done that, go to your build.gradle(Module: app) and change the minSdkVersion to whatever you want. But be sure not to use api features that are not supported in android 2.3.6, refer to this image.build.gradle(Module: app) You also need to install the Sdk for android 2.3.

Tad
  • 889
  • 9
  • 23
  • Hello, thanks for your reply. That's the problem I talked about, when I try to change minSdkVersion to 9 the program asks to sync project but the build fail and it returns a message error " > Manifest merger failed : uses-sdk:minSdkVersion 9 cannot be smaller than version 14 declared in library as the library might be using APIs not available in 9 Suggestion: use a compatible library with a minSdk of at most 9, or increase this project's minSdk version to at least 14, or use tools:overrideLibrary="android.support.graphics.drawable" to force usage (may lead to runtime failures)" – julio Jan 22 '18 at 21:30
  • From the error details I guess you have used an external library or an Android plugin relating to drawing which requires min sdk 14 – Ali Sheikhpour Jan 23 '18 at 04:55
  • It seems SDK version 13 and lower is no longer supported by the latest Android Studio updates. This article https://9to5google.com/2016/11/21/google-play-services-gingerbread-support-end/ says that Google dropped support for API 9 and raised support up to API 14 in early 2017. So I think if you want to build an app that runs on android 2.3, you will have to use a different IDE. – Tad Jan 24 '18 at 15:55
  • 1
    Thank you iTadreik, downloading an older Android Studio IDE and installing its SDK worked like a charm, now I can make the application for my old smartphone. – julio Jan 24 '18 at 23:04