Generate initialisers for shape functions/derivatives only as needed

I'll trigger a test on buildbot for that branch. Wait for that to pass before merge.