diff options
author | Brian Cameron <Brian.Cameron@sun.com> | 2008-02-25 15:05:44 -0500 |
---|---|---|
committer | William Jon McCann <jmccann@redhat.com> | 2008-02-25 15:05:44 -0500 |
commit | f39d3756e1d9da62de923ba470d3312b89bea6be (patch) | |
tree | 81c7fc1067edd9d1386b9b041b6a5c3e7e85860e | |
parent | f551717e1830e86a8ccf5312f79ce8882af9f352 (diff) |
fix solaris vt handling to work when no vt available
This fixes the patch that
Simon Zhang sent you earlier so that it builds on machines
without VT.
-rw-r--r-- | src/ck-vt-monitor.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/ck-vt-monitor.c b/src/ck-vt-monitor.c index 414abf6..d21026b 100644 --- a/src/ck-vt-monitor.c +++ b/src/ck-vt-monitor.c @@ -40,7 +40,7 @@ #include "ck-sysdeps.h" #include "ck-marshal.h" -#ifdef __sun +#if defined (__sun) && defined (HAVE_SYS_VT_H) #include <sys/vt.h> #include <signal.h> #include <stropts.h> @@ -163,7 +163,7 @@ ck_vt_monitor_get_active (CkVtMonitor *vt_monitor, return TRUE; } -#ifdef __sun +#if defined (__sun) && defined (HAVE_SYS_VT_H) static void handle_vt_active (void) { @@ -382,7 +382,9 @@ vt_add_watches (CkVtMonitor *vt_monitor) int i; gint32 current_num; -#ifdef __sun +#if defined (__sun) && !defined (HAVE_SYS_VT_H) + /* Best to do nothing if VT is not supported */ +#elif defined (__sun) && defined (HAVE_SYS_VT_H) /* * Solaris supports synchronous event notification in STREAMS. * Applications that open the virtual console device can |