Did you use the proper MAMEUI Source Code? If you are trying to compile MAMEUI using the MAME 123u3 source code and the MAMEUI 123 source code, you'll get those errors you are mentioning due to the video changes. You MUST use the same MAMEUI source code version as the MAME version you are trying to compile.