aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2008-12-23 10:05:36 -0200
committerMike Frysinger <vapier@gentoo.org>2008-12-23 10:05:36 -0200
commit406edf1ed12fe843a2c4c028b1bb2d9db405db60 (patch)
tree6fab08d23b93dba966884940f79f3f2ee139ac5f /localdecls.h
parenthandle MAP_ANON on *BSD systems (diff)
downloadsandbox-406edf1ed12fe843a2c4c028b1bb2d9db405db60.tar.gz
sandbox-406edf1ed12fe843a2c4c028b1bb2d9db405db60.tar.bz2
sandbox-406edf1ed12fe843a2c4c028b1bb2d9db405db60.zip
define AT_FDCWD for older systems
If the system is not up-to-date with latest POSIX, then setup AT_FDCWD ourself so that things build. Considering how we actually use the value, this shouldn't cause any problems ... Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'localdecls.h')
-rw-r--r--localdecls.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/localdecls.h b/localdecls.h
index 38939e9..d061e5b 100644
--- a/localdecls.h
+++ b/localdecls.h
@@ -51,6 +51,13 @@
# define MAP_ANONYMOUS MAP_ANON
#endif
+/* If the system is old and does not support *at funcs, then define
+ * it ourself. Shouldn't matter based on how we use it.
+ */
+#ifndef AT_FDCWD
+# define AT_FDCWD -100
+#endif
+
#if !HAVE_DLVSYM
# define dlvsym(_lib, _sym, _ver) dlsym(_lib, _sym)
#endif