"One other thing. a straight line is easy to make with a beam of light. And a simple beam of light can be made from the reflection of a mirror. So it's not all the big a deal that the walls were straight."
My back yard wood deck, built by me (another amazing feat of civil engineering which will be studied for generationsor maybe not), I found a miraculous method for marking a straight line: tightly strung string! Yes, I do not mean to brag, but I was (am) centuries ahead of my time.
1. Level the area roughly to slightly below the natural rock surface.
2. Have your workers each carry a goatskin of water from the Nile.
3. Empty into the shallow hole
4. Note which areas stick out.
5. Have your workers push a large flatish piece of rock over the sticking out area and wear it down
6. As the water evaporates/soaks away, other areas will stck out.
7. goto 4.