I am away from TC now, but from memory the files were
/usr/local/lib/libXtst*
/usr/local/lib/pkgconfig/xtst.pc
I can't remember if there are files in /usr/local/include, but if there were libXtst at this point would not be detected and used. This is kind of a kludge, but I remember reading that ratpoison works fine without being built against libXtst. Doing this same thing with Xinerama results in a failed build, and as Xinerama is available in the Xlibs_support extension it does not add much overhead to using ratpoison. Installing Xorg-7.4-dev, Xlibs_support and removing the above files should build ratpoison fine, resulting in a dependency of Xlibs_support during runtime.