Fixes to build libmono with disabled JIT. (#4421)