we brought two cats [ mother & son] back with us from Dubai, when they came out of quarantine and into our new home the boy kept spraying and he could reach about 5ft up the curtains, we got him done but it made no difference for the rest of his life he sprayed , he lived till he was 12 yrs old and when he died we changed all the carpets & curtains in the house and believe me there was evidence he had sprayed everywhere.
I have written this before dont want to bore you, for similar we bought a small size kennel from the pet store, put it 6ft off the ground away from foxes hopefully, on a pupose built ledge near our back window, put tarpaulin over the top to keep him dry and a made a small cat ladder for access, put small cat blanket and some cat nip inside.