3

I created multiple android projects in android studio and noticed that none of them contain the uses-sdk tag in the manifest file. As far as i can tell from google developers tutorials manifest file needs to have it. i didnt find any explanation of its absence anywhere on the net. Im sure the min sdk that i chose during project creation is being used without error as otherwise i would have to use support library for a number of things like the action bar. i know this is also defined in the build.gradle file but how is there no explanation to be found anywhere on the net?

Shreyans
  • 984
  • 1
  • 11
  • 24
  • not a duplicate as i want to know why it is NOT in the manifest as opposed to being BOTH in manifest and gradle. I thought stackoverflow people were smart enough to figure it out. i even mentioned it in my question that i know its present in the build.gradle file. – Shreyans Oct 07 '15 at 01:25

1 Answers1

7

As far as i can tell from google developers tutorials manifest file needs to have it.

Not when you are using Gradle for Android as your build system, such as when you are using Android Studio. The <uses-sdk> information is held in your app's build.gradle file instead. Your app's actual manifest is generated via a manifest merger process that combines the manifest you wrote, manifests from libraries, and Gradle project settings.

how is there no explanation to be found anywhere on the net?

A search on "uses-sdk" "build.gradle" on a major search engine turns up lots of information.

CommonsWare
  • 910,778
  • 176
  • 2,215
  • 2,253
  • 1
    it would be helpful if you gave me some links to these search results? all i could find was the function of uses-sdk and where it is located. Anyways thx for clearing it up. – Shreyans Oct 07 '15 at 00:00