From 9f7ded3fb41f7f656895373463e5aa3ca04f86bc Mon Sep 17 00:00:00 2001 From: Halton Huo Date: Thu, 20 May 2010 10:48:09 +0800 Subject: Revert "Enhancement CanActivateSessions for OpenSolaris." This reverts commit b2e65a0ab7f4c417c85433e3e9bf97befbe6da3b. --- configure.ac | 13 ------------- src/Makefile.am | 1 - src/ck-seat.c | 26 +------------------------- 3 files changed, 1 insertion(+), 39 deletions(-) diff --git a/configure.ac b/configure.ac index 8619f31..117d788 100644 --- a/configure.ac +++ b/configure.ac @@ -319,19 +319,6 @@ if test "x$enable_rbac_shutdown" != "xno"; then fi AC_SUBST(RBAC_LIBS) -dnl --------------------------------------------------------------------------- -dnl check for SCF (Only avail on solaris) -dnl --------------------------------------------------------------------------- - -AC_CHECK_LIB(scf, smf_get_state, - [SCF_LIBS=-lscf - AC_DEFINE(HAVE_SCF,1,[Define to 1 if the libscf library is present.])], - [AC_MSG_WARN([[ -*** -*** libscf was not found. -]])]) -AC_SUBST(SCF_LIBS) - dnl --------------------------------------------------------------------------- dnl Finish dnl --------------------------------------------------------------------------- diff --git a/src/Makefile.am b/src/Makefile.am index 4788fe1..6ab05c8 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -139,7 +139,6 @@ console_kit_daemon_LDADD = \ $(CONSOLE_KIT_LIBS) \ $(POLKIT_LIBS) \ $(RBAC_LIBS) \ - $(SCF_LIBS) \ libck.la \ libck-event-log.la \ $(NULL) diff --git a/src/ck-seat.c b/src/ck-seat.c index b2e5628..af7db59 100644 --- a/src/ck-seat.c +++ b/src/ck-seat.c @@ -25,9 +25,6 @@ #include #include #include -#ifdef HAVE_SCF -#include -#endif #include #include @@ -664,26 +661,6 @@ ck_seat_add_session (CkSeat *seat, return TRUE; } -is_VT_enabled () -{ -#ifdef HAVE_SYS_VT_H - char *state = NULL; - gboolean vt_enabled; - - state = smf_get_state ("svc:/system/vtdaemon:default"); - if (state && g_str_equal (state, SCF_STATE_STRING_ONLINE)) { - vt_enabled = TRUE; - } else { - vt_enabled = FALSE; - } - - g_free (state); - return vt_enabled; -#else - return FALSE; -#endif /* HAVE_SYS_VT_H */ -} - gboolean ck_seat_can_activate_sessions (CkSeat *seat, gboolean *can_activate, @@ -692,8 +669,7 @@ ck_seat_can_activate_sessions (CkSeat *seat, g_return_val_if_fail (CK_IS_SEAT (seat), FALSE); if (can_activate != NULL) { - *can_activate = (seat->priv->kind == CK_SEAT_KIND_STATIC) - && is_VT_enabled (); + *can_activate = (seat->priv->kind == CK_SEAT_KIND_STATIC); } return TRUE; -- cgit v1.2.3