Note that GIF is a paletted format.
A complication arises if you try to combine multiple gifs with different palettes. What colors should you choose then? You could, of course, combine using a generic palette (for example, "web 216"), but the quality is likely to suffer a lot as a consequence if the sources used custom palettes.
Aside from the palette issue, Frob's link is useful in your task.