Hi, Welcome to LQ
We are missing a few details here:
-What is your distribution?
-Why are you trying to install recordmydesktop from source, why not using your package manager (app store)? ReceordMyDesktop is quite common, most distributions have it.
As for your problem, you are probably missing some xlib references, but this is irrelevant, use your package manager, don't install package using the source code unless you have good reasons to do so. You may have, I am not sating otherwise, but I fail to see any.