Deb -- figure out the area of your roof in square inches. Note that what you really need is the area of the FOOTPRINT of your roof (equals the footprint of your building, enlarged by whatever the roof overhang is). Multiply feet wide by feet long, then by 144 to get area in square inches.
A gallon is about 232 cubic inches. Thus if you divide your "area in square inches" number by 232 it will tell you how many gallons your roof will collect
from a 1" rainfall.
To calculate water collection from other size rainfalls, the easiest thing is to calculate the 1" rainfall version then multiply by half (for a 0.5" rainfall) or whatever else
(example: a 10x10-footprint chicken coop would collect [10x10x144]/232 = 62 gallons from a 1" rainfall)
Pat