There are two different puzzles. (Well, maybe more, I've seen two puzzles so far.) One has three statues, the other ten.
For each, mine stone blocks from a spot in the room. (Note: Once solo dungeoneering I've had a wall that required a mining level far enough beyond mine that I couldn't reach it with potions - I had to skip this bonus room.) You *can* take damage from the mining. Use a chisel (found on the floor) to shape the blocks into the needed weapon (sword, staff or bow).
The ten-statue puzzle is based on the combat triangle. Equip each statue with the weapon style that "dominates" that of the statue it faces. (Example: If a statue on one end has a sword, make a staff for the statue that faces it.)
For the three-statue puzzle, just make the weapon that matches the stance of the statue. There should be one of each type when you are done.