In a Hornblower story, the hero is in the Pacific and has a mast shot away. Since he knew he would be operating from home, he had a spare mast ready. He took the ship into an island, set up a shore battery, and Bush, ever resourceful Bush pulled the stub out “Like a rotten tooth*” and popped in the new one.
How could you do such a thing without a dockyard and using only primitive stone astrolabes?
Bonus, for a story I am playing with. My ship is blockaded. The Bad Guys can only see my masts over a low island. On a dark and stormy night, I pop out my masts. Then the Bad Guys assume I snuck out at night. Then they go looking for me.
Pretty neat, huh?
*Why do I remember that line?