se-linux-h: remove ENOTSUPP-defining code; instead, use errno
authorJim Meyering <meyering@redhat.com>
Tue, 21 Oct 2008 15:18:53 +0000 (17:18 +0200)
committerJim Meyering <meyering@redhat.com>
Tue, 21 Oct 2008 16:08:16 +0000 (18:08 +0200)
* modules/selinux-h (Depends-on): Add errno.
(configure.ac): Add AC_REQUIRE([AC_C_INLINE]).
* lib/se-context.in.h: Remove code to define ENOTSUPP.
* lib/se-selinux.in.h: Likewise.

lib/se-context.in.h
lib/se-selinux.in.h
modules/selinux-h

index ec88a03..f9fe923 100644 (file)
@@ -2,15 +2,6 @@
 # define SELINUX_CONTEXT_H
 
 # include <errno.h>
-/* Some systems don't have ENOTSUP.  */
-# ifndef ENOTSUP
-#  ifdef ENOSYS
-#   define ENOTSUP ENOSYS
-#  else
-/* Some systems don't have ENOSYS either.  */
-#   define ENOTSUP EINVAL
-#  endif
-# endif
 
 typedef int context_t;
 static inline context_t context_new (char const *s)
index aeaf950..ce64487 100644 (file)
@@ -3,15 +3,6 @@
 
 # include <sys/types.h>
 # include <errno.h>
-/* Some systems don't have ENOTSUP.  */
-# ifndef ENOTSUP
-#  ifdef ENOSYS
-#   define ENOTSUP ENOSYS
-#  else
-/* Some systems don't have ENOSYS either.  */
-#   define ENOTSUP EINVAL
-#  endif
-# endif
 
 typedef unsigned short security_class_t;
 # define security_context_t char*
index 603e057..05cdd71 100644 (file)
@@ -8,10 +8,12 @@ m4/selinux-context-h.m4
 m4/selinux-selinux-h.m4
 
 Depends-on:
+errno
 
 configure.ac:
 gl_HEADERS_SELINUX_SELINUX_H
 gl_HEADERS_SELINUX_CONTEXT_H
+AC_REQUIRE([AC_C_INLINE])
 
 Makefile.am:
 lib_SOURCES += se-context.in.h se-selinux.in.h