Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

3.0-pre6 on Alpha/Linux 2.0.x



When compiling zsh on said Alpha, I was hit by the
#error there are some unknown limits...
in builtin.c.  Limits 0-5 are the same as under Intel-based Linux, but 6-9
are as follows...

from <asm/resource.h>:
#define RLIMIT_NOFILE   6	/* max number of open files */
#define RLIMIT_AS       7	/* address space limit(?) */
#define RLIMIT_NPROC    8	/* max number of processes */
#define RLIMIT_MEMLOCK  9	/* max locked-in-memory address space */

The patch below is how I got around the problem, but I don't know enough
about this section of code to say whether this is the correct solution.
All comments and corrections are welcome.

Jeff


*** Src/builtin.c.orig	Fri Aug  2 22:43:24 1996
--- Src/builtin.c	Sun Aug 11 00:55:15 1996
***************
*** 3607,3612 ****
--- 3607,3622 ----
  #  define NEXT_RLIM (RLIMIT_AS + 1)
      "addressspace",
  # endif /* RLIMIT_AS */
+ # if defined RLIMIT_NPROC && RLIMIT_NPROC == NEXT_RLIM
+ #  undef NEXT_RLIM
+ #  define NEXT_RLIM (RLIMIT_NPROC + 1)
+     "maxproc",
+ # endif /* RLIMIT_NPROC */
+ # if defined RLIMIT_MEMLOCK && RLIMIT_MEMLOCK == NEXT_RLIM
+ #  undef NEXT_RLIM
+ #  define NEXT_RLIM (RLIMIT_MEMLOCK + 1)
+     "memorylocked",
+ # endif /* RLIMIT_MEMLOCK */
  # if defined RLIMIT_NOFILE && RLIMIT_NOFILE == NEXT_RLIM
  #  undef NEXT_RLIM
  #  define NEXT_RLIM (RLIMIT_NOFILE + 1)



Messages sorted by: Reverse Date, Date, Thread, Author