King Ghadsi of Jaisalmer got the lake made 650 years ago with the help of the people(when will I use "got it made")
He got the machine made
He caused the machine to be made without personally doing the work
In the US at least, it is idiomatic but very informal. You can say the same thing without a hint of informality by saying
He had the machine made
He caused the machine to be made
With respect to "make", it has a very broad field of meaning, but it would not normally be used to mean "construct a building". The natural verb to use would be "build"
So to be natural without sounding too informal, try
King Ghadsi of Jaisalmer had it built ...