Reorganisation to simplify build, each implementation can be compiled