I have an kivy app and i compile it via Buildozer.
My settings are:
# (int) Target Android API, should be as high as possible.
android.api = 34
# (int) Minimum API your APK / AAB will support.
android.minapi = 21
# (int) Android SDK version to use
android.sdk = 34
# (str) Android NDK version to use
android.ndk = 25b
Should i change only android.api = 34 to android.api = 35
or
Should i change both android.api = 34 and android.sdk = 34 to android.api = 35 and android.sdk = 35
Thanks for your replies.
For anyone who comes across this and is looking for a solution for an expo React Native App you need to either
Update your expo SDK to v53 (see here: https://expo.dev/changelog/sdk-53) or
(in case you are looking for a quick fix without updating expo AGAIN): set expo-build-properties in app.json or app.config.js (thanks to @Drazar and @HabiburRaman for pointing this out in the comments)
expo-build-properties in app.json:// app.json
{
"expo": {
...
"plugins": [
[
"expo-build-properties",
{
"android": {
"compileSdkVersion": 35,
"targetSdkVersion": 35,
"buildToolsVersion": "35.0.0"
},
}
]
]
}
}
Original Answer:
Create a file named withTargetSdk35.js (or similar) in your project root:
// withTargetSdk35.js
const { withAppBuildGradle } = require('@expo/config-plugins');
module.exports = function withTargetSdk35(config) {
return withAppBuildGradle(config, (config) => {
if (config.modResults.language === 'groovy') {
config.modResults.contents = config.modResults.contents.replace(
/targetSdkVersion\s*\d+/,
'targetSdkVersion 35'
);
} else {
throw new Error('Cannot modify build.gradle: unexpected language');
}
return config;
});
};
Register the Plugin in app.json or app.config.js
If you're using app.json :
{
"expo": {
...
"plugins": ["./withTargetSdk35"]
}
}
If you're using app.config.js
import withTargetSdk35 from './withTargetSdk35';
export default {
expo: {
...
plugins: [withTargetSdk35],
},
};
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