On Wed, Mar 17, 2010 at 12:50:04 +0100, Cyril Brulebois wrote:
> --- /dev/null
> +++ b/src/lib/debian-installer.d/S62Xorg
> @@ -0,0 +1,2 @@
> +Xorg -retro -noreset -nolisten tcp &
> +export DISPLAY=:0
This is racy, we probably should do something better here. Might need a
bit of code to do something like:
static void sighandler(int signo) {
}
int main() {
signal(SIGUSR1, sighandler);
pid = fork();
if (pid < 0)
fail();
if (pid) {
pause();
return 0;
} else {
signal(SIGUSR1, SIG_IGN);
exec(Xorg);
}
}
to be sure not to start clients before X is ready to accept connections.
Or just a sleep in the shell script, but that's still racy…
Not sure we need to keep -retro there (at least for the release images),
and we should probably not start X if DEBIAN_FRONTEND is not gtk.
Cheers,
Julien
Attachment:
signature.asc
Description: Digital signature