Add compile hooks.