While your at it install the checkinstall package so you can use it in place of the make install step to build a .deb file you can install with
dpkg -i file.deb depending on the options set in the /etc/checkinstallrc it will be automatically installed. To build the .deb use a command line like this replacing the obvious parts with the correct package name, version number and your name.
Code:
checkinstall -D --pkgname=name --pkgversion==1.2.3 --maintainer="Your Name your@email.com"
You want to install the apt-file package as well this allows you to search to find which package contains the file you need when getting a compile error "not found". You need to run
apt-file update as root (good to do every once in a while) to update its cache then you can search with in your case above
apt-file search X11/Xlib.h to get a result like below.
Code:
apt-file search X11/Xlib.h
ghc-cvs-libsrc: usr/share/doc/ghc-cvs-libsrc/X11/Graphics/X11/Xlib.hs
ghc6: usr/lib/ghc-6.4.1/imports/Graphics/X11/Xlib.hi
ghc6: usr/lib/ghc-6.4.2/imports/Graphics/X11/Xlib.hi
ghc6-libsrc: usr/share/doc/ghc6-libsrc/X11/Graphics/X11/Xlib.hs
ghc6-libsrc: usr/share/doc/ghc6-libsrc/X11/Graphics/X11/Xlib.hs
hugs: usr/lib/hugs/packages/X11/Graphics/X11/Xlib.hs
hugs: usr/lib/hugs/packages/X11/Graphics/X11/Xlib.hs
ivtools-dev: usr/include/IV-X11/Xlib.h
libx11-dev: usr/include/X11/Xlib.h
libx11-dev: usr/include/X11/Xlib.h
Which as the post above tells you shows the needed libx11-dev in the results.