I could imagine someone with a meter stick measuring off the 100 meters. You can measure line-of-sight distances extremely precisely using light, etc. But how do they ensure the required precision over such a long distance through an irregular course?
Welcome to the Rhetorical Question section of today’s question: Is the Boston Marathon really exactly the same distance as the Olympic Marathon?
88-page PDF on official road race measuring. They can use a carefully-calibrated bicycle with a counter. Apparently the real problem is making sure it’s not possible for runners to cut corners and whatnot, while not overcorrecting and making the course significantly longer than advertised.
I know that such devices exist, though I’m wondering what they actually use. The ad you linked does not provide specs for the precision of the device. However, it does say that it has a “calibrated, wide rubber tire” and includes a “Certificate of calibration,” but does not say what the error is. It has a “Wheel circumference [of] 3 ft.” That means that an error of 0.01" on the wheel circumference, not unthinkable on a rubber wheel subject to arbitrary wear, would accumulate an error of 485 feet over a marathon course, larger than rounding error.
One especially difficult bit is that usually the streets are closed for the race, but not when they’re measuring. Racers run the shortest route while you are on a bike and following the curb.