I'm trying to build android 12. I was using Ubuntu 22.04.2 where it worked successfully. Now I've installed a fresh Ubuntu 22.04.3 which is using a new kernel and I started getting this error:
ERROR: Dex2oat failed to compile a boot image.It is likely that the boot classpath is inconsistent.Rebuild with ART_BOOT_IMAGE_EXTRA_ARGS="--runtime-arg -verbose:verifier" to see verification errors.
I've seen this similar issue Android dex2oat build:ERROR: Dex2oat failed to compile a boot image - Nothing worked for me from this thread
- Tried running build with additional flags:
ALLOW_MISSING_DEPENDENCIES=true WITH_DEXPREOPT=false ART_BOOT_IMAGE_EXTRA_ARGS="--runtime-arg -verbose:verifier" m -j4
- Tried remove flags ("-msse4.2" and "-mpopcnt") in art/build/Android.bp (https://i.stack.imgur.com/39O63.png)