To use all Xlib routines, an application program should include the header files: X11/Xlib.h X11/Xutil.h X11/keysym.h X11/Xresource.h
Compiling and linking can be achieved by the command, cc -o executable_file_name source_file_name -lX11
cc -o executable_file_name source_file_name -lX11