how do I fix hinges to sandstone (that is quite soft)
You could drill out larger holes, then fill with epoxy, then mount the hinges through the epoxy. But that seems like a lot of work. 

I'd instead install a post alongside the wall and use the post.