The GiGi GUI library (also called GG) is used by FreeOrion to handle most of the basic UI and graphics things (windows, fonts, input, images, and such). It uses (at least in this project) SDL internally for platform-dependant things, and OpenGL for graphics.
Source can be obtained from SVN in Linux using the command:
svn co https://gigi.svn.sourceforge.net/svnroot/gigi/trunk gigi
For Windows, a graphical shell-extention SVN client, such as TortoiseSVN is reccomended, with which the source can be obtained from https://gigi.svn.sourceforge.net/svnroot/gigi/trunk.
For compilation of the most recent version of FreeOrion from SVN, use the most recent version of GiGi from SVN as well.
For compilation of FreeOrion 0.3, 0.3.1 or 0.3.1-RC1, use the official version 0.6.0 release. Tarball (linux) or zipfile (Windows) are available on the sourceforge GiGi 0.6.0 release download page. The 0.6.0 tagged set of files is messed up, so you must use the release files and NOT the CVS 0.6.0 tagged version of the files.