I don't use linux so I can't give you a precise guidance but the procedure should be similar on linux. To make gifs I make images for every frames using potplayer (most video players can do that, just look at the options) and then I convert all the frames to a gif using gimp (I think you can install it on linux). If software on linux is unsatisfactory you can always install windows software in wine or virtualbox. I personnaly don't use gifs. I extract small parts of videos and convert them to videos that are playable in the browser (html5) using command line with ffmpeg. It's like gifs but better in every way, quality and sound.