Repository: godot
Issue: Android Export Gives Zero Indication Why It Failed
Labels: bug,platform:android,topic:export

### Godot version

3.4.5.stable

### System information

Windows 7 64 bit

### Issue description

When exporting for Android, following the build guide, it simply says `'apisigner' returned with error #2`, with no information on what went wrong or how to fix the problem. Godot console outputs this:

```
0 param: --xr_mode_regular
1 param: --use_depth_32
2 param: --use_immersive
ADDING: classes.dex
ADDING: lib/arm64-v8a/libc++_shared.so
ADDING: lib/arm64-v8a/libgodot_android.so
ADDING: lib/armeabi-v7a/libc++_shared.so
ADDING: lib/armeabi-v7a/libgodot_android.so
ADDING: kotlin/annotation/annotation.kotlin_builtins
ADDING: kotlin/collections/collections.kotlin_builtins
ADDING: kotlin/coroutines/coroutines.kotlin_builtins
ADDING: kotlin/internal/internal.kotlin_builtins
ADDING: kotlin/kotlin.kotlin_builtins
ADDING: kotlin/ranges/ranges.kotlin_builtins
ADDING: kotlin/reflect/reflect.kotlin_builtins
ADDING: AndroidManifest.xml
ADDING: res/anim-v21/fragment_fast_out_extra_slow_in.xml
ADDING: res/anim/fragment_fast_out_extra_slow_in.xml
ADDING: res/animator/fragment_close_enter.xml
ADDING: res/animator/fragment_close_exit.xml
ADDING: res/animator/fragment_fade_enter.xml
ADDING: res/animator/fragment_fade_exit.xml
ADDING: res/animator/fragment_open_enter.xml
ADDING: res/animator/fragment_open_exit.xml
ADDING: res/drawable-hdpi-v4/notification_bg_low_normal.9.png
ADDING: res/drawable-hdpi-v4/notification_bg_low_pressed.9.png
ADDING: res/drawable-hdpi-v4/notification_bg_normal.9.png
ADDING: res/drawable-hdpi-v4/notification_bg_normal_pressed.9.png
ADDING: res/drawable-hdpi-v4/notify_panel_notification_icon_bg.png
ADDING: res/drawable-mdpi-v4/notification_bg_low_normal.9.png
ADDING: res/drawable-mdpi-v4/notification_bg_low_pressed.9.png
ADDING: res/drawable-mdpi-v4/notification_bg_normal.9.png
ADDING: res/drawable-mdpi-v4/notification_bg_normal_pressed.9.png
ADDING: res/drawable-mdpi-v4/notify_panel_notification_icon_bg.png
ADDING: res/drawable-nodpi-v4/splash.png
ADDING: res/drawable-nodpi-v4/splash_bg_color.png
ADDING: res/drawable-v21/notification_action_background.xml
ADDING: res/drawable-xhdpi-v4/notification_bg_low_normal.9.png
ADDING: res/drawable-xhdpi-v4/notification_bg_low_pressed.9.png
ADDING: res/drawable-xhdpi-v4/notification_bg_normal.9.png
ADDING: res/drawable-xhdpi-v4/notification_bg_normal_pressed.9.png
ADDING: res/drawable-xhdpi-v4/notify_panel_notification_icon_bg.png
ADDING: res/drawable/notification_bg.xml
ADDING: res/drawable/notification_bg_low.xml
ADDING: res/drawable/notification_icon_background.xml
ADDING: res/drawable/notification_tile_bg.xml
ADDING: res/drawable/splash_drawable.xml
ADDING: res/layout-v16/notification_template_custom_big.xml
ADDING: res/layout-v21/notification_action.xml
ADDING: res/layout-v21/notification_action_tombstone.xml
ADDING: res/layout-v21/notification_template_custom_big.xml
ADDING: res/layout-v21/notification_template_icon_group.xml
ADDING: res/layout/custom_dialog.xml
ADDING: res/layout/downloading_expansion.xml
ADDING: res/layout/godot_app_layout.xml
ADDING: res/layout/notification_action.xml
ADDING: res/layout/notification_action_tombstone.xml
ADDING: res/layout/notification_template_icon_group.xml
ADDING: res/layout/notification_template_part_chronometer.xml
ADDING: res/layout/notification_template_part_time.xml
ADDING: res/layout/status_bar_ongoing_event_progress_bar.xml
ADDING: res/mipmap-anydpi-v26/icon.xml
ADDING: res/mipmap-hdpi-v4/icon.png
ADDING: res/mipmap-hdpi-v4/icon_background.png
ADDING: res/mipmap-hdpi-v4/icon_foreground.png
ADDING: res/mipmap-mdpi-v4/icon.png
ADDING: res/mipmap-mdpi-v4/icon_background.png
ADDING: res/mipmap-mdpi-v4/icon_foreground.png
ADDING: res/mipmap-xhdpi-v4/icon.png
ADDING: res/mipmap-xhdpi-v4/icon_background.png
ADDING: res/mipmap-xhdpi-v4/icon_foreground.png
ADDING: res/mipmap-xxhdpi-v4/icon.png
ADDING: res/mipmap-xxhdpi-v4/icon_background.png
ADDING: res/mipmap-xxhdpi-v4/icon_foreground.png
ADDING: res/mipmap-xxxhdpi-v4/icon.png
ADDING: res/mipmap-xxxhdpi-v4/icon_background.png
ADDING: res/mipmap-xxxhdpi-v4/icon_foreground.png
ADDING: res/mipmap/icon.png
ADDING: res/mipmap/icon_background.png
ADDING: res/mipmap/icon_foreground.png
ADDING: resources.arsc
ERROR: Failed to export the project for platform 'Android'.
   at: _export_project_to_path (editor/project_export.cpp:877)
```

### Steps to reproduce

I followed the guide https://docs.godotengine.org/en/3.4/tutorials/export/exporting_for_android.html, except for Android SDK platform installed version 31 because that's what the built template references for target SDK.

Generated a fresh `debug.keystore` with that command as well. `keytool -keyalg RSA -genkeypair -alias androiddebugkey -keypass android -keystore debug.keystore -storepass android -dname "CN=Android Debug,O=Android,C=US" -validity 9999 -deststoretype pkcs12`.

### Minimal reproduction project

_No response_