summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmmanuel Dreyfus <manu@netbsd.org>2014-06-30 15:06:05 +0200
committerAndreas Gruenbacher <andreas.gruenbacher@gmail.com>2014-06-30 15:09:37 +0200
commit92247401984dd9a80d9d0c8c030692323f980678 (patch)
tree845ee741305f5362e59eb3793ee704141bdb7444
parent50fc862d69984089ce09138b3350ee7762290403 (diff)
downloadattr-92247401984dd9a80d9d0c8c030692323f980678.tar.gz
Portability fixes
- <features.h> is Linux specific - Define __THROW for non glibc based systems
-rw-r--r--include/xattr.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/xattr.h b/include/xattr.h
index 070d7c5..fd1f268 100644
--- a/include/xattr.h
+++ b/include/xattr.h
@@ -20,7 +20,18 @@
#ifndef __XATTR_H__
#define __XATTR_H__
+#if defined(linux)
#include <features.h>
+#endif
+
+/* Portability non glibc c++ build systems */
+#ifndef __THROW
+# if defined __cplusplus
+# define __THROW throw ()
+# else
+# define __THROW
+# endif
+#endif
#include <errno.h>
#ifndef ENOATTR