AAkira / Napier

Logging library for Kotlin Multiplatform
Apache License 2.0
820 stars 36 forks source link

Android minSdk version #11

Closed mikedawson closed 5 years ago

mikedawson commented 5 years ago

Hi,

This library is exactly what we were looking for for our Kotlin Multiplatform project. One small issue: why is the minSdk set to 21? I tried checking at the source and changing it to 18 (in dependencies.gradle) and it still compiled. It would be great if minSdk can be lowered so it can be readily used in Android apps that support lower versions. The Android support library default is Android 4 (Sdk 14). Can the minSdk be lowered to 14?

Thanks!

-Mike

AAkira commented 5 years ago

Hi @mikedawson,

Yes, it works. I think the Kotlin Multiplatform project is the latest project. So, I think that I will use it in a new project, rather than in an existing project.

I don't want to downgrade minSdk version because I have to check something of Gradle or have to use multidex etc.

This is my opinion. I may change the minSdk version if there are many requests.

mikedawson commented 5 years ago

Hi @AAkira ,

Thanks for your answer here. The Kotlin multiplatform plugin will generate an Android library (AAR). Multidex is only applicable to the final APK itself, not the AAR libraries. Only those users who have more than 64K methods, and target minSdk lower than 21, would need to enable Multidex (which they have to do anyway, whether or not they are using Napier). I don't think you need to make any changes on your side to accommodate that.

We could double check this for you, and send a pull request and test results. Would that work?

Thanks!

-Mike

AAkira commented 5 years ago

@mikedawson

Yes, I know.

I published v0.0.5 that minSDK is downgraded. Please check it. I'll update the minSDK version if a problem occurs.