I will do everything in my power to keep from having to pull a barrel to work on it. That said, what lathe do you have? What's the hole dia. through the spindle? How much room do you have compared to how long the barrel is? Can you hold the muzzle in a four jaw and support the breech of the barrel with a spider on the outboard end of the tailstock? I had one job where the spider extended too much, and I made a plug for the spindle out of Delrin, turned to be a snug fit in the spindle, and bored to fit closely around the barrel ahead of the receiver. This gave me just enough room to turn and thread the muzzle. Generally, you'll want about .500" to .625" of thread for most muzzle brakes.
Another way to do the job...do you have a Bridgeport? Make up a clamp for the barrel to hold it vertically on the side of the table, and indicate the bore to true vertical. Swivel the mill's head and extend it so that you can use a boring head to cut straight down onto the barrel at the muzzle, cutting to the major diameter of the muzzle brake threads. (Practice this on a piece of bar stock first!) Choose a brake that uses "standard" threads, like 1/2-28 (M-16 flash hider thread size) or something else readily available in a split die. Cut a relief with your boring head to the minor diameter of the threads for about 1/8" at the muzzle. Thread with the die in several steps until the brake will start on with hard hand pressure. Clean up the threads and fit the brake. If you've been careful, there will be little or no cleanup or bluing damage. Practice this again before doing it!
“You can have peace. Or you can have freedom. Don't ever count on having both at once.”
― Robert A. Heinlein