Is @mprotect@ POSIX now?
\begin{code}
-
#if STACK_CHECK_BY_PAGE_FAULT
/* #define STK_CHK_DEBUG */
# if defined(HAVE_GETPAGESIZE)
# define GETPAGESIZE() getpagesize()
# else
-# error getpagesize
+# if defined(linux_TARGET_OS) || defined(linuxaout_TARGET_OS)
+# /* it has it, but it is in BSD land; easier to just say so */
+# define GETPAGESIZE() getpagesize()
+# else
+# error getpagesize
+# endif
# endif
# endif
extern int mprotect PROTO((caddr_t, size_t, int));
#endif
+/* Needed for FreeBSD (SDM, 96/03) */
+#ifndef PROT_NONE
+#define PROT_NONE 0
+#endif
+
void
unmapMiddleStackPage(addr_, size)
char * /*caddr_t*/ addr_;
}
#endif /* STACK_CHECK_BY_PAGE_FAULT */
-
\end{code}