Open endarova opened 5 years ago
It is expected to fail since latest modules require sdk 28. However we can try to better handle situation with user friendly error message.
We can add warning when you pass --compileSdk
that this will skip CLI's verification and the build may not work.
My project is under the latest Nativescript version (5.3), but my app needs to run on android 5.1.
I'm trying to achieve that by running; tns run android --bundle --compileSdk 22
But I'm asked to install Android SDK 28.
How can I generate a build for the version I need? Couldn't find anything on the docs.
Hi @RosilBelli,
No need to set compileSdk in this case. App you build with default options should work on all Android versions above 4.2.
CLI: 5.0.0-2018-10-16-12488 (RC) Android Runtime: 5.0.0-2018-10-23-165909-01
The new android runtime requires sdk 28. If you build such project with tns build --compileSdk 27 the build will fail with error for missing resources. We need a check in that case and warning that you cannot build project with last android runtime with sdk lower than 28.
Steps:
FAILURE: Build failed with an exception.