mplayer -gif89a yourvideo.avi

You can use mplayer like so to create gif animations from video.