How do they differ? Or are they the same? As I understand both of these define what SDK version the app should be compiled against.
Please help to clarify. Thanks in advance
Even if the compileSdkVersion and targetSdkVersion have completely different meanings they are obviously not independent. targetSdkVersion cannot be higher than the compileSdkVersion simply because we cannot target things that we know nothing about during compilation.
android:targetSdkVersion — Specifies the API Level on which the application is designed to run. In some cases, this allows the application to use manifest elements or behaviors defined in the target API Level, rather than being restricted to using only those defined for the minimum API Level.
You can create this file manually in project root directory, near other ". properties" files.
The min sdk version is the earliest release of the Android SDK that your application can run on. Usually this is because of a problem with the earlier APIs, lacking functionality, or some other behavioural issue. The target sdk version is the version your application was targeted to run on.
The docs say
android:targetSdkVersion: This attribute informs the system that you have tested against the target version and the system should not enable any compatibility behaviors to maintain your app's forward-compatibility with the target version. The application is still able to run on older versions
If not set, the default value equals that given to minSdkVersion. Which indicates market will filter devices with lower sdk.
target=android-sdk version in project properties file indicates Eclipse will not allow use methods or classes from sdk higher than this one.
ie. One related to the development environment and other related to android devices.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With