Changes to make this branch compatible with the current Firedrake changes.