- Replacement for getpagesize() for systems which lack it
This commit is contained in:
parent
68e45de53b
commit
13bc0be2b6
|
@ -1,3 +1,6 @@
|
|||
19991228
|
||||
- Replacement for getpagesize() for systems which lack it
|
||||
|
||||
19991227
|
||||
- Automatically correct paths in manpages and configuration files. Patch
|
||||
and script from Andre Lucas <andre.lucas@dial.pipex.com>
|
||||
|
|
|
@ -54,6 +54,25 @@ static sigjmp_buf bail;
|
|||
|
||||
#define EXTRABYTES 2 /* XXX: why 2? you don't want to know */
|
||||
|
||||
#ifndef HAVE_GETPAGESIZE
|
||||
int
|
||||
getpagesize()
|
||||
{
|
||||
#ifdef EXEC_PAGESIZE
|
||||
return EXEC_PAGESIZE;
|
||||
#else /* !EXEC_PAGESIZE */
|
||||
# ifdef NBPG
|
||||
# ifndef CLSIZE
|
||||
# define CLSIZE 1
|
||||
# endif /* No CLSIZE */
|
||||
return NBPG * CLSIZE;
|
||||
# else /* !NBPG */
|
||||
return NBPC;
|
||||
# endif /* NBPG */
|
||||
#endif /* EXEC_PAGESIZE */
|
||||
}
|
||||
#endif /* HAVE_GETPAGESIZE */
|
||||
|
||||
static char *
|
||||
msetup(str, n)
|
||||
char *str;
|
||||
|
|
|
@ -114,10 +114,10 @@ if test -z "$no_pam" ; then
|
|||
fi
|
||||
|
||||
dnl Checks for header files.
|
||||
AC_CHECK_HEADERS(endian.h lastlog.h login.h maillock.h netgroup.h paths.h poll.h pty.h shadow.h util.h utmp.h utmpx.h sys/bsdtty.h sys/poll.h sys/select.h sys/stropts.h sys/time.h sys/ttcompat.h)
|
||||
AC_CHECK_HEADERS(endian.h lastlog.h login.h maillock.h netgroup.h paths.h poll.h pty.h shadow.h sys/bsdtty.h sys/poll.h sys/select.h sys/stropts.h sys/time.h sys/ttcompat.h util.h utmp.h utmpx.h)
|
||||
|
||||
dnl Checks for library functions.
|
||||
AC_CHECK_FUNCS(arc4random updwtmpx mkdtemp openpty _getpty innetgr setenv seteuid setlogin setproctitle setreuid snprintf strlcat strlcpy vsnprintf)
|
||||
AC_CHECK_FUNCS(arc4random getpagesize _getpty innetgr mkdtemp openpty setenv seteuid setlogin setproctitle setreuid snprintf strlcat strlcpy updwtmpx vsnprintf)
|
||||
|
||||
AC_CHECK_FUNC(login,
|
||||
[AC_DEFINE(HAVE_LOGIN)],
|
||||
|
|
Loading…
Reference in New Issue