Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Src/rlimits.awk does not work on old NeXTs
- X-seq: zsh-workers 3661
- From: koenig@xxxxxxxxxxxx (Andreas J. Koenig)
- To: zsh-workers@xxxxxxxxxxxxxxx
- Subject: Src/rlimits.awk does not work on old NeXTs
- Date: 26 Dec 1997 13:58:46 +0100
- In-reply-to: Tuomo Pyhala's message of "Fri, 26 Dec 1997 01:00:15 +0200 (EET)"
- Sender: k@xxxxxxxxxxxxxxxxx
The awk that came with NeXTs was pretty dumb. It didn't even have a
useful manpage, so all I can do is to show you the error produced...
  awk -f ./rlimits.awk /usr/include/bsd/sys/resource.h > rlimits.h
  awk: syntax error near line 21
  awk: illegal statement near line 21
and a workaround that in fact does produce a fine rlimits.h on the
NeXT. This all happens on a NeXT 3.3.
*** /tmp/rlimits.awk.~1.1~	Fri Dec 26 13:41:36 1997
--- /tmp/rlimits.awk	Fri Dec 26 13:41:36 1997
***************
*** 18,24 ****
      # in this case I assume GNU libc resourcebits.h
      if (limnum == "") {
  	limnum = limidx++
! 	sub (",", "", limnam)
      }
      limrev[limnam] = limnum
      if (lim[limnum] == "") {
--- 18,26 ----
      # in this case I assume GNU libc resourcebits.h
      if (limnum == "") {
  	limnum = limidx++
! 	# sub (",", "", limnam)   # sub not known on NeXT
! 	split(limnam,limnamarr,",")
! 	limnam = limnamarr[1] limnamarr[2]
      }
      limrev[limnam] = limnum
      if (lim[limnum] == "") {
Hope this helps some, enjoy,
-- 
andreas
Messages sorted by:
Reverse Date,
Date,
Thread,
Author