What is 'No mapping for .ogg'? (SOLVED)


I can build and debug my game without any problem, but when I tried to create bundle for any platform, with Editor 2 or BOB.jar, there is an error as following…

I checked game.project file, did not found any configuration about this. Could anyone help me on this problem?


Are you using a custom appmanifest?


No, I did not use any app manifest or plist file


Could you paste the text of your game.project file here?


Do you have any .ogg files in your project? If so, where? I took a look at the code and the error is generated when the build pipeline tries to make a lookup of compiled file extension (ie *.collectionc, *.scriptc etc) and doesn’t find a mapping of it. Could it be that a .ogg file has ended up inside the build folder somehow?


@Pkeod Here is my game.project file, it is very simple…

title = Mahjong
version = 0.1
dependencies = https://github.com/britzl/defold-clipboard/archive/master.zip,https://www.github.com/britzl/defold-luasocket/archive/master.zip,https://github.com/britzl/defnet/archive/master.zip

main_collection = /game/main/main.collectionc

game_binding = /input/game.input_bindingc
use_accelerometer = 0

width = 1136
height = 852

scale = 0.02

shared_state = 1

bundle_identifier = com.xsjplm.plm

package = com.xsjplm.plm

bundle_identifier = com.xsjplm.plm

track_cpu = 1


@britzl Yes, I have a background music file lobby_bgm.ogg in my project. It can be played correctly when I run or debug my game with Editor 2, but once I tried to bundle the game for any platform, this error message occurs and the bundle process failed.


If you replace it with any other ogg does bundling work?


My bad… I added this sound component by “Add component file” directly. After added it with “Add component->Sound”, the bundle process works smoothly. Thanks for the kindly help.


I resolved this problem same way.

Is It a bug or documented feature?

HTML5 Build error. No mapping for .ogg

It sounds like a bug.

Maybe related to this bug? https://github.com/defold/editor2-issues/issues/2115