[C API] Some makefile features don't work for simulator source files

I added the UDEFS defines to the command line for the simulator. This was missing in the current common.mk too and is described in [C API] Missing UDEFS for simulator code in common.mk