How to build a .dol file

So, long story short

I want to build a .dol of a emulator for MSX2 games which recognizes different rom mapper types saved in a romdb.xml.

After building the .dol I want to make a 00000001.app of it and include it in a existing VC .wad

Alternative to building a new .dol from a emulator like openMSX for example, I could edit the existing .dol I extracted from a VC.wad file but I dunno how to do this.

BTW, anyone knows a way to edit .bin files? I want to edit the msx2config.bin, maybe I can change the rom mapper type in there also.

Any insight or hints would be a blast.
Thx

Original thread: https://assemblergames.com/threads/how-to-build-a-dol-file.29552/