Material colour to textures. Cycles

Hi! Let’s say we have 10 materials with 10 different colours and a mesh where instead of vertex paint or texture paint we just assigned materials. How can I bake the materials into textures? Thanks!

Download a cycles texture baking build
See http://code.blender.org/index.php/2014/02/cycles-baking/

Is there any 2.70 build with CUDA support and baking?