gcc gcc-3.3 g++ g++-3.3 libstdc++5-3.3-dev xlibs-dev libice-dev libsm-dev libx11-dev libxau-dev libxext-dev libxi-dev libxkbfile-dev libxmu-dev libxmuu-dev libxp-dev libxpm-dev libxrandr-dev libxrender-dev libxt-dev libxtrap-dev libxtst-dev libxv-dev pm-dev render-dev x-dev xlibs-static-dev zliblg-dev xlibmesa-gl-dev xlibmesa-glu-dev libxxf86vm-dev
Many of the ones that come with xlibs-dev are not required, however I suggested xlibs-dev because it includes several of the packages you do require in just one selection. The other reason of course is that this guide should still work after new versions of GCC and X become standard. You'll most likely need at least xlibs-static-dev and libx11-dev. You may also need x-dev and libxext-dev.