Add support for display setup script

It is done the same way as KDM does it.

With autologin, it will be ran right after the display server starts.
Without autologin, it will be ran right after the greeter has
connected to the daemon. This is needed, otherwise it'll just
show a black screen on an Optimus laptop.
Detect if X is ready with the SIGUSR1 signal

Don't retry the connection, rather detect when X is ready with SIGUSR1.

From Xserver man page:

  "When the server starts, it checks to see if it has inherited SIGUSR1
   as SIG_IGN instead of the usual SIG_DFL. In this case, the server
   sends a SIGUSR1 to its parent process after it has set up the various
   connection schemes. Xdm uses this feature to recognize when
   connecting to the server is possible."
Merge branch 'AnAkIn1-displaysetupscript'