hal ChangeLog,1.437,1.438 configure.in,1.70,1.71

David Zeuthen david at freedesktop.org
Thu Feb 24 20:52:25 PST 2005


Update of /cvs/hal/hal
In directory gabe:/tmp/cvs-serv25656

Modified Files:
	ChangeLog configure.in 
Log Message:
2005-02-24  David Zeuthen  <davidz at redhat.com>

	* configure.in: Add back selinux detection; default to auto

	* tools/linux/add_selinux.c: New file, add selinux attributes the
	Right Way(tm) instead of hardcoding the context (RH bug 135765)

	* tools/linux/Makefile.am: If HAVE_SELINUX is set, add build rules
	for hald-add-selinux-mount-option

	* fdi/policy/10osvendor/20-storage-add-selinux.fdi: New file, invoke
	hald-add-selinux-mount-option (only used if HAVE_SELINUX is 1)

	* tools/linux/hal_hotplug_map.c: Removed (forgot to remove it earlier)



Index: ChangeLog
===================================================================
RCS file: /cvs/hal/hal/ChangeLog,v
retrieving revision 1.437
retrieving revision 1.438
diff -u -d -r1.437 -r1.438
--- ChangeLog	25 Feb 2005 03:49:06 -0000	1.437
+++ ChangeLog	25 Feb 2005 04:52:23 -0000	1.438
@@ -1,5 +1,20 @@
 2005-02-24  David Zeuthen  <davidz at redhat.com>
 
+	* configure.in: Add back selinux detection; default to auto
+
+	* tools/linux/add_selinux.c: New file, add selinux attributes the
+	Right Way(tm) instead of hardcoding the context (RH bug 135765)
+
+	* tools/linux/Makefile.am: If HAVE_SELINUX is set, add build rules
+	for hald-add-selinux-mount-option
+
+	* fdi/policy/10osvendor/20-storage-add-selinux.fdi: New file, invoke
+	hald-add-selinux-mount-option (only used if HAVE_SELINUX is 1)
+
+	* tools/linux/hal_hotplug_map.c: Removed (forgot to remove it earlier)
+
+2005-02-24  David Zeuthen  <davidz at redhat.com>
+
 	* hald/hald.c (parent_wait_for_child): Fixup accidental message being
 	printed
 

Index: configure.in
===================================================================
RCS file: /cvs/hal/hal/configure.in,v
retrieving revision 1.70
retrieving revision 1.71
diff -u -d -r1.70 -r1.71
--- configure.in	24 Feb 2005 17:33:03 -0000	1.70
+++ configure.in	25 Feb 2005 04:52:23 -0000	1.71
@@ -74,6 +74,7 @@
 AC_ARG_ENABLE(verbose-mode,     [  --enable-verbose-mode   support verbose debug mode],enable_verbose_mode=$enableval,enable_verbose_mode=$USE_MAINTAINER_MODE)
 AC_ARG_ENABLE(doxygen-docs,     [  --enable-doxygen-docs   build DOXYGEN documentation (requires Doxygen)],enable_doxygen_docs=$enableval,enable_doxygen_docs=auto)
 AC_ARG_ENABLE(docbook-docs,     [  --enable-docbook-docs   build DocBook documentation (requires docbook2html)],enable_docbook_docs=$enableval,enable_docbook_docs=auto)
+AC_ARG_ENABLE(selinux,          [  --enable-selinux        build with SELinux support],enable_selinux=$enableval,enable_selinux=auto)
 
 if test x$enable_verbose_mode = xyes; then
     AC_DEFINE(ENABLE_VERBOSE_MODE,1,[Support a verbose mode])
@@ -375,6 +376,35 @@
 AC_SUBST(HALD_PID_FILE)
 AC_DEFINE_UNQUOTED(HALD_PID_FILE, "$HALD_PID_FILE", [pid file])
 
+# SELinux detection
+if test x$enable_selinux = xno ; then
+    have_selinux=no;
+else
+    # See if we have sufficiently new SELinux library
+    AC_CHECK_LIB(selinux, selinux_removable_context_path, 
+                 have_selinux=yes, have_selinux=no)
+
+    if test x$enable_selinux = xauto ; then
+        if test x$have_selinux = xno ; then
+                AC_MSG_WARN([Sufficiently new SELinux library not found])
+        fi
+    else 
+        if test x$have_selinux = xno ; then
+                AC_MSG_ERROR([SELinux explicitly required, and sufficiently new SELinux library not found])
+        fi
+    fi
+fi
+
+AM_CONDITIONAL(HAVE_SELINUX, test x$have_selinux = xyes)
+
+if test x$have_selinux = xyes ; then
+    SELINUX_LIBS=-lselinux
+    AC_DEFINE(HAVE_SELINUX,1,[SELinux support])
+else
+    SELINUX_LIBS=
+fi
+
+
 ALL_LINGUAS="da fr de nl ru hu pt it"
 AC_SUBST(ALL_LINGUAS)
 
@@ -455,6 +485,7 @@
         Group for HAL:            ${HAL_GROUP}
         hald pidfile:             ${HALD_PID_FILE}
         hald backend:             ${HALD_BACKEND}
+        Building SELinux support: ${have_selinux}
 
         install fstab-sync:       ${enable_fstab_sync}
         Extended PCMCIA support:  ${enable_pcmcia_support}




More information about the hal-commit mailing list