I'm trying to build an android app with ionic and Angular
but I have some problems that I can't find a solution
command : ionic cordova build android
BUILD SUCCESSFUL in 7s 1 actionable task: 1 executed Subproject Path: CordovaLib Subproject Path: app Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01 Warning: Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/03 to old ns http://schemas.android.com/sdk/android/repo/addon2/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/03 to old ns http://schemas.android.com/sdk/android/repo/repository2/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/03 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Task :CordovaLib:compileDebugJavaWithJavac Note: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details.
Task :app:stripDebugDebugSymbols Unable to strip the following libraries, packaging them as they are: libsqlc-native-driver.so.
Task :app:compileDebugJavaWithJavac FAILED /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/camera/CameraLauncher.java:40: error: package android.support.v4.content does not exist import android.support.v4.content.FileProvider; ^ /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/camera/CordovaUri.java:25: error: package android.support.v4.content does not exist import android.support.v4.content.FileProvider; ^ /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/camera/FileProvider.java:21: error: package android.support.v4.content does not exist public class FileProvider extends android.support.v4.content.FileProvider {} ^ /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/com/ionicframework/cordova/webview/IonicWebViewEngine.java:11: error: package android.support.annotation does not exist import android.support.annotation.RequiresApi; ^ /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/com/ionicframework/cordova/webview/IonicWebViewEngine.java:122: error: cannot find symbol @RequiresApi(Build.VERSION_CODES.LOLLIPOP) ^ symbol: class RequiresApi location: class com.ionicframework.cordova.webview.IonicWebViewEngine.ServerClient /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/camera/CameraLauncher.java:303: error: cannot find symbol this.imageUri = new CordovaUri(FileProvider.getUriForFile(cordova.getActivity(), ^ symbol: method getUriForFile(androidx.appcompat.app.AppCompatActivity,java.lang.String,java.io.File) location: class org.apache.cordova.camera.FileProvider /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/camera/CameraLauncher.java:801: error: cannot find symbol Uri tmpFile = FileProvider.getUriForFile(cordova.getActivity(), ^ symbol: method getUriForFile(androidx.appcompat.app.AppCompatActivity,java.lang.String,java.io.File) location: class org.apache.cordova.camera.FileProvider Note: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details. Note: /Users/user/Desktop/nosrb-front-end/platforms/android/app/src/main/java/org/apache/cordova/file/AssetFilesystem.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 7 errors
FAILURE: Build failed with an exception.
- What went wrong: Execution failed for task ':app:compileDebugJavaWithJavac'.
Compilation failed; see the compiler error output for details.
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.1.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD FAILED in 22s 45 actionable tasks: 45 executed Command failed with exit code 1: /Users/user/Desktop/nosrb-front-end/platforms/android/gradlew cdvBuildDebug -b /Users/user/Desktop/nosrb-front-end/platforms/android/build.gradle [ERROR] An error occurred while running subprocess cordova.