When shotguns come from the factory with two barrels, both are headspaced properly. Shotguns are also a lot more tolerant of headspace than rifles, since pressures are lower and the shell normally backs up in the chamber. (A rifle cartridge adheres to the chamber walls at the front and backs up at the rear, causing it to stretch; if the headspace is excessive, the case tears apart and releases high pressure gas and/or renders the gun unusable with a broken case in the chamber.) In addition, shotgun shells have a long heavy base wads that pretty well eliminate blowouts from unsupported cases and headspace on the rim, eliminating problems with chamber length.
As for machineguns, that depends on the gun. The Brownings with screw-in barrels have to be gauged when another barrel in put in (the gauge is not a true headspace gauge, only a block to set the bolt-barrel face distance). The M60 type has its extra barrels already headspaced to that bolt.
Jim