Add a preliminary version of mpm_compile_rules.