Error - Failed compiling Android resources

When compiling a game for android, I get an Android resource compilation error, help me fix it

What extensions are you using?

640x960
Or something else? Iā€™m still new to this

@Potota was wondering if you have added anything from the Asset Portal to your list of project dependencies in game.project.

Or is this happening with an empty project?

I took textures and files from the ā€œMagic Linkā€ lesson, ran the game to check if everything is fine when compiling on Windows, but an error pops up on Android

Ok. But itā€™s not happening with an empty project? Make sure that icons and any file references in the Android section of the game.project file exists and are valid.

I faced this issue as well and see the cause in my case. If I set project title to ā€œKį»³ HoĆ ngā€, it failed to compile Android bundle, but if I set it to ā€œKy Hoangā€, it compiled successfully.

These lines are in console when it failed:

    2024-01-02 12:30:20 INFO    exec: C:\Users\chung\AppData\Local\Temp\3013256825095741087\aapt2.exe compile -o C:\Users\chung\AppData\Local\Temp\compiled_resources9302001017514913233\com.chungxa.kyhoang --dir D:\Defold\Projects\KyHoang\build\armv7-android\Kį»³ HoĆ ng\res\com.chungxa.kyhoang 

    2024-01-02 12:30:20 INFO    Failed compiling C:\Users\chung\AppData\Local\Temp\compiled_resources9302001017514913233\com.chungxa.kyhoang, code: 1, error: D:\Defold\Projects\KyHoang\build\armv7-android\Kį»³ HoĆ ng\res\com.chungxa.kyhoang: error: failed to open directory: The system cannot find the file specified. (2).
     
    ERROR: unspecified:-1: 'com.dynamo.bob.CompileExceptionError: Failed compiling Android resources'
2 Likes

Thanks, I added a ticket here for the issue with the characters. Should be good first issue if any of our contributors are interested.

1 Like