UE4&

Unreal Engine 4 ・プログラミング

Android studio 初回起動時のバグ回避方法 備忘録

Android studio 起動時のバグ回避方法 2021年7月現在 July 2021

Installed Build Tools revision 31.0.0 is corrupted.

エラーコード

Installed Build Tools revision 31.0.0 is corrupted. Remove and install again using the SDK Manager.

 

Project structure -> Building tools version を 30.0.3 に変更する。とにかく 31.0.0 を使わなければ大丈夫。30.0.3 のインストール方法は以下のビデオ参照。

 

www.youtube.com

エミュレータに作っているアプリケーションが表示されない  Manifest merger failed : Apps targeting Android 12 and higher are required

エラーコード

Manifest merger failed : Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.

<activity
android:name=".MainActivity"
android:exported="true"
android:label="@string/app_name"
android:theme="@style/Theme.MyApplication.NoActionBar">

AndroidManifest.xml をこのように記述すると解決できた。

android:exported="true" を追記する。

 android:exported="failed" でもいいが、failed にすると今 Android Studio で開発しているアプリがエミュレータに表示されなくなる。アプリがインストールされていない状態になる。

 

Add this in your AndroidManifest.xml

android:exported="true"

参考サイト

stackoverflow.com

いきなりエラーが出るので開発の敷居は高いな。