home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume26 / pdksh / patch01a next >
Encoding:
Text File  |  1991-11-25  |  39.9 KB  |  1,443 lines

  1. Newsgroups: comp.sources.misc
  2. From: sjg@zen.void.oz.au (Simon J. Gerraty)
  3. Subject:  v26i071:  pdksh - Public Domain Korn Shell, Version 4, Patch01a/2
  4. Message-ID: <csm-v26i071=pdksh.220032@sparky.IMD.Sterling.COM>
  5. X-Md4-Signature: 191efe6659e9fd7fdf93c1a3abb9548f
  6. Date: Tue, 26 Nov 1991 04:01:33 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: sjg@zen.void.oz.au (Simon J. Gerraty)
  10. Posting-number: Volume 26, Issue 71
  11. Archive-name: pdksh/patch01a
  12. Environment: UNIX
  13. Patch-To: pdksh: Volume 25, Issue 47-55
  14.  
  15. This is the first patch release for PD KSH 4
  16. It is in two parts due to its size.  Please apply
  17. this patch and the next together before attempting to rebuild.
  18.  
  19. The main changes are to the build process.
  20. There have been some minor changes to most files in the 
  21. ./sh directory to support building independently of the
  22. ./std tree.
  23.  
  24. start of patch 25-Nov-91
  25. It should be applied by changing directory to the root
  26. of the source tree and using the command:
  27.     patch -p0 < this_file
  28.  
  29. The following is a complete list of patches to date.
  30.  
  31. # PD ksh Version 4
  32. Prereq: 09-Nov-91
  33. Prereq: 10-Nov-91
  34. *** PATCHDATES.old    Mon Nov 25 13:39:59 1991
  35. --- PATCHDATES    Mon Nov 25 13:34:43 1991
  36. ***************
  37. *** 1,3 ****
  38. ! PD ksh Version 4
  39.   09-Nov-91
  40.   10-Nov-91
  41. --- 1,4 ----
  42. ! # PD ksh Version 4
  43.   09-Nov-91
  44.   10-Nov-91
  45. + 25-Nov-91
  46. *** /dev/null    Mon Nov 25 11:15:05 1991
  47. --- ChangeLog    Mon Nov 25 13:18:30 1991
  48. ***************
  49. *** 0 ****
  50. --- 1,17 ----
  51. + Fri Nov 22 22:24:29 1991  Simon J. Gerraty  (sjg at zen)
  52. +     * Cleaned up the build process slightly.  Makefiles in ./std tree
  53. +     now maintain objects within the libraries rather than simply
  54. +     building the .o's and archiving them.  Of course the make(1) used
  55. +     must know how to maintain libraries :-)
  56. +     * Added bug.report as a template for bug reporting.
  57. +     * Source in ./sh can be built independently of ./std tree if
  58. +     desired.  See comments in ./sh/Makefile.
  59. +     * As originally distributed some of libstdc.a was not used and
  60. +     libposix.a was not used at all.  On Sun's this highlighted a bug
  61. +     (incompatibility) in the times() call.  Now the ./std/libs are
  62. +     used fully, and the supplied times() call functions as expected.
  63. *** /dev/null    Mon Nov 25 11:15:05 1991
  64. --- INSTALL    Mon Nov 25 13:58:35 1991
  65. ***************
  66. *** 0 ****
  67. --- 1,141 ----
  68. + BUILDING THE PD KSH
  69. + ===================
  70. + The PD KSH can be built in two ways.  The default method uses
  71. + the POSIX/ANSI compatability libraries in ./std.  The
  72. + alternative method is to build the ksh in ./sh without the ./std
  73. + tree.  The second method should be used only if a) you have a
  74. + real POSIX environemnt or b) you have major difficulties with
  75. + building the ./std tree.
  76. + I have modified the source slightly to make standalone building
  77. + simpler.  Using -DNOSTDHDRS avoids attempts to include ANSI
  78. + headers that may be lacking.  I have built the shell this way on
  79. + all Sun platforms and on a Bull DPX/2 (which has good POSIX
  80. + support) as a test only since it already has a real ksh.
  81. + It is recommended that you try using the ./std tree first.  This
  82. + avoids problems like BSD times() calls that do not return an
  83. + indication of elapsed time and so on.
  84. + Using ./std:
  85. + ------------
  86. + If you are on a Sun building it quite simple:
  87. +     make CONFIG=-D_BSD
  88. + will do it.  If you have a sun386 or sun3 and have gcc, it is
  89. + worth using, just add CC="gcc -pipe" to the above command line.
  90. + If you have SunOS 4.1 or later you probably need to add
  91. + -DHAVE_SYS_STDTYPES
  92. + Building on other systems may well be more difficult.
  93. + Apparently the creating of the ./std/h tree causes problems on
  94. + some systems.  
  95. + Notes on ./std:
  96. + ---------------
  97. + I have updated the Makefiles in ./std/stdc and ./tsd/posix to
  98. + maintain the objects within the libraries.  Ie.
  99. + libstdc.a(strstr.o) If your make(1) doesn't know how to do this
  100. + then you will need to modify the makefiles accordingly.
  101. + In ReadMe.jrm, John MacMillan recommends being cautious of
  102. + std/libstdc.a and using only those routines which your system
  103. + lacks.  Please note that I have tested virtually none of
  104. + ./std/stdc.  The Makefile contains target lines for most modules
  105. + but most are commented out.  I suggest you uncomment _only_
  106. + those that you need.
  107. + On the other hand std/libposix.a seems quite safe, and
  108. + indeed provides a better times() call for BSD systems.
  109. + Read ReadMe.jrm for more...
  110. + Building without ./std:
  111. + -----------------------
  112. + On some systems it might be worth forgetting about ./std/lib*
  113. + either because they proved too difficult to build or they seem
  114. + unnecessary.  As previously indicated I have done this on Sun's
  115. + and on a Bull system.  On Sun's it is perhaps not a great idea
  116. + as you then get the system's times() call which does not behave
  117. + the way the shell wants.
  118. + In anycase to build without ./std, you simply cd to ./sh and
  119. + either edit the Makefile accordingly, or use an appropriate
  120. + command line.  For instance:
  121. + Sun with SunOS 4.0:
  122. +     cd ./sh
  123. +     ln -s ../std/stdc/strstr.c .
  124. +     ln -s ../std/stdc/memmove.c .
  125. +     make CFLAGS="-D_BSD -DNOSTDHDRS" \
  126. +         XOBJS="strstr.o memmove.o" LDLIBS="" LDFLAGS=""
  127. + Note that we still need a couple of functions from ./std/stdc
  128. + On the Bull system which is a POSIX compliant System V machine:
  129. +     cd ./sh
  130. +     make CFLAGS="-D_SYSV" LDLIBS="-lc_s" LDFLAGS=""
  131. + On this system you need to undefine JOBS in config.h, jobs.c
  132. + assumes a lot and may cause problems for System V machines.
  133. + INSTALLING:
  134. + ===========
  135. + This is quite simple.  
  136. +     # cp ./ksh /bin
  137. +     # chmod 555 /bin/ksh
  138. + The above assumes of course that you don't already have a
  139. + /bin/ksh :-)
  140. + The manual page ksh.1 should be copied to an appropriate
  141. + location.
  142. + BSD:
  143. +     # cp ksh.1 /usr/man/man1
  144. + SYSV:
  145. +     # nroff -man ksh.1 > /usr/catman/u_man/man1/ksh.1
  146. +     # pack /usr/catman/u_man/man1/ksh.1
  147. + Or something similar.  For systems such as Sun's that really
  148. + only ship with a C-shell environment, the ./etc directory
  149. + contains a useful /etc/profile and /etc/ksh.kshrc file to
  150. + provide a suitable environemnt for /bin/sh and /bin/ksh users,
  151. + they should work, they are straight of my system and I use them
  152. + on Sun,Bull and even an SCO system.
  153. + PROBLEMS:
  154. + =========
  155. + Clearly building will not be so simple on all systems.
  156. + Apparently some of the enum manipulations border on ilegal and
  157. + cause some compilers problems.  Curiously both gcc -ansi and the
  158. + GreenHills compiler on the Bull system are quite picky and did
  159. + not complain.  Note if you want to use gcc -ansi you may well
  160. + need to add some definitions, for instance the following all
  161. + work on the sun386:
  162. +     CC=cc
  163. +     CC=gcc
  164. +     CC=gcc -ansi -Dsun -Di386 -Dsun386
  165. + The last three items on the last line are normally all defined
  166. + automatically, but this is disabled when -ansi is used.  The
  167. + system headers do not work unless they know what architecture is
  168. + in use.  
  169. + If you find and fix a problem please fill in a copy of
  170. + ./bug-report and e-mail it to pdksh-bug@zen.void.oz.au
  171. *** /dev/null    Mon Nov 25 11:15:05 1991
  172. --- MACHINES    Mon Nov 25 13:01:44 1991
  173. ***************
  174. *** 0 ****
  175. --- 1,25 ----
  176. + This shell has been compiled on the following systems:
  177. + Notes:
  178. + (1)    Built and tested by me (sjg), seems ok :-)
  179. + (2)    Reported ok
  180. + (3)    Reported no good
  181. + (4)    Built with ./std/lib*
  182. + (5)    Built without ./std/lib*
  183. + (6)    No job control
  184. + If you succesfully build this shell on another system please let
  185. + me know. 
  186. + System, OS            Notes    Compiler/Flags
  187. + --------------------------    -----    --------------
  188. + sun386, SunOS 4.0.2        1,4    gcc-1.40 -D_BSD
  189. + sun4c,    SunOS 4.1.1        1,4    cc -D_BSD -DHAVE_SYS_STDTYPES
  190. + sun3,    SunOS 4.0.3        1,4    cc -D_BSD
  191. + sun386, SunOS 4.0.2        1,5    cc -DNOSTDHDRS -D_BSD
  192. + sun4c,    SunOS 4.1.1        1,5    cc -DNOSTDHDRS -D_BSD -DHAVE_SYS_STDTYPES
  193. + sun3,    SunOS 4.0.3        1,5    cc -DNOSTDHDRS -D_BSD
  194. + Bull DPX/2, B.O.S. 2.00.45    1,5,6    cc -D_SYSV
  195. + Bull XPS-100            2,6
  196. *** MANIFEST.old    Mon Nov 25 13:39:02 1991
  197. --- MANIFEST    Mon Nov 25 13:35:14 1991
  198. ***************
  199. *** 1,113 ****
  200.      File Name        Archive #    Description
  201.   -----------------------------------------------------------
  202. !  README                    1    Please read
  203.    Changes.jrm               1    
  204.    Changes.mlj               1    
  205.    MANIFEST                  1    This shipping list
  206.    Makefile                  1    
  207.    PATCHDATES                1    C-News style patch tracking
  208.    ReadMe.jrm                1    General info and Install instructions
  209.    ReadMe.sjg                1    
  210.    ReadMe.vimode             1    
  211.    etc                       1    
  212. !  etc/ksh.kshrc             1    global .kshrc, WARNING contains ESC chars
  213.    etc/profile               1    
  214.    etc/sys_config.sh         1    
  215.    ksh.1                     2    Manual page
  216.    sh                        1    ksh source
  217. !  sh/ChangeLog              1    Current change list
  218.    sh/Changes                1    
  219. !  sh/Makefile               1    
  220.    sh/ReadMe                 1    Original ReadMe (out of date)
  221. !  sh/alloc.c                1    
  222.    sh/alloc.h                1    
  223. !  sh/c_ksh.c                2    
  224. !  sh/c_sh.c                 2    
  225.    sh/c_test.c               3    
  226.    sh/config.h               1    
  227.    sh/edit.c                 3    
  228. !  sh/edit.h                 1    
  229. !  sh/emacs.c                3    
  230.    sh/eval.c                 4    
  231. !  sh/exec.c                 4    
  232. !  sh/expand.h               1    
  233.    sh/expr.c                 3    
  234. !  sh/getopts.c              4    
  235. !  sh/history.c              4    
  236. !  sh/io.c                   4    
  237. !  sh/jobs.c                 5    
  238.    sh/lex.c                  5    
  239. !  sh/lex.h                  4    
  240. !  sh/mail.c                 4    
  241. !  sh/main.c                 5    
  242. !  sh/misc.c                 5    
  243. !  sh/sh.h                   5    
  244. !  sh/syn.c                  6    
  245. !  sh/table.c                6    
  246. !  sh/table.h                6    
  247. !  sh/trace.c                6    Simple trace facilty
  248. !  sh/trace.h                6    
  249. !  sh/trap.c                 6    
  250. !  sh/tree.c                 6    
  251. !  sh/tree.h                 6    
  252. !  sh/tty.h                  2    
  253. !  sh/ulimit.c               6    
  254. !  sh/var.c                  7    
  255. !  sh/version.c              4    
  256. !  sh/vi.c                   7    
  257.    std                       1    libraries
  258. !  std/Makefile              5    
  259.    std/posix                 2    
  260. !  std/posix                 2    posix lib source
  261. !  std/posix/Makefile        6    
  262. !  std/posix/dirent.C        6    
  263. !  std/posix/dirent.H        6    
  264. !  std/posix/dirent.h        2    
  265. !  std/posix/dup2.c          4    
  266. !  std/posix/fcntl.c         6    
  267. !  std/posix/fcntl.h         6    
  268. !  std/posix/fixincludes     6    
  269. !  std/posix/io.h            6    
  270. !  std/posix/time.h          6    
  271. !  std/posix/times.c         6    
  272. !  std/posix/times.h         6    
  273. !  std/posix/unistd.c        6    
  274. !  std/posix/unistd.h        7    
  275. !  std/posix/wait.h          7    
  276. !  std/stdc                  3    stdc lib source
  277. !  std/stdc/Makefile         7    
  278. !  std/stdc/clock.c          7    
  279. !  std/stdc/fprintf.c        7    
  280. !  std/stdc/limits.h         7    
  281. !  std/stdc/memchr.c         6    
  282. !  std/stdc/memcmp.c         7    
  283. !  std/stdc/memcpy.c         7    
  284. !  std/stdc/memmove.c        7    
  285. !  std/stdc/memset.c         7    
  286. !  std/stdc/setvbuf.c        7    
  287. !  std/stdc/sprintf.c        7    
  288. !  std/stdc/stdarg.h         8    
  289. !  std/stdc/stddef.h         8    
  290. !  std/stdc/stdio.c          8    
  291. !  std/stdc/stdio.h_std      8    
  292. !  std/stdc/stdio.sed        8    
  293. !  std/stdc/stdlib.h         8    
  294. !  std/stdc/strcat.c         8    
  295. !  std/stdc/strchr.c         8    
  296. !  std/stdc/strcmp.c         8    
  297. !  std/stdc/strcpy.c         8    
  298. !  std/stdc/strcspn.c        8    
  299. !  std/stdc/strerror.c       8    
  300. !  std/stdc/string.h         8    
  301. !  std/stdc/strlen.c         8    
  302. !  std/stdc/strncat.c        8    
  303. !  std/stdc/strncmp.c        8    
  304. !  std/stdc/strncpy.c        8    
  305. !  std/stdc/strpbrk.c        8    
  306. !  std/stdc/strrchr.c        8    
  307. !  std/stdc/strspn.c         8    
  308. !  std/stdc/strstr.c         8    
  309. !  std/stdc/strtok.c         8    
  310. !  std/stdc/time.h           8    
  311. !  std/stdc/types.h          8    
  312. !  std/stdc/vprintf.c        8    
  313. --- 1,121 ----
  314.      File Name        Archive #    Description
  315.   -----------------------------------------------------------
  316. !  ChangeLog                 1    Current change history
  317.    Changes.jrm               1    
  318.    Changes.mlj               1    
  319. +  INSTALL                   1    Installation notes
  320. +  MACHINES                  1    Systems the shell has been built on
  321.    MANIFEST                  1    This shipping list
  322.    Makefile                  1    
  323.    PATCHDATES                1    C-News style patch tracking
  324. +  README                    1    Please read
  325.    ReadMe.jrm                1    General info and Install instructions
  326.    ReadMe.sjg                1    
  327.    ReadMe.vimode             1    
  328. +  bug-report                1    Bug report template
  329.    etc                       1    
  330. !  etc/ksh.kshrc             1    global .kshrc
  331.    etc/profile               1    
  332.    etc/sys_config.sh         1    
  333.    ksh.1                     2    Manual page
  334.    sh                        1    ksh source
  335. !  sh/ChangeLog              2    Current change list
  336.    sh/Changes                1    
  337. !  sh/Makefile               2    
  338.    sh/ReadMe                 1    Original ReadMe (out of date)
  339. !  sh/alloc.c                2    
  340.    sh/alloc.h                1    
  341. !  sh/c_ksh.c                3    
  342. !  sh/c_sh.c                 3    
  343.    sh/c_test.c               3    
  344.    sh/config.h               1    
  345.    sh/edit.c                 3    
  346. !  sh/edit.h                 3    
  347. !  sh/emacs.c                4    
  348.    sh/eval.c                 4    
  349. !  sh/exec.c                 5    
  350. !  sh/expand.h               3    
  351.    sh/expr.c                 3    
  352. !  sh/getopts.c              5    
  353. !  sh/history.c              5    
  354. !  sh/io.c                   5    
  355. !  sh/jobs.c                 6    
  356.    sh/lex.c                  5    
  357. !  sh/lex.h                  5    
  358. !  sh/mail.c                 6    
  359. !  sh/main.c                 6    
  360. !  sh/misc.c                 6    
  361. !  sh/sh.h                   6    
  362. !  sh/stdh.h                 6    Centralise std header inclusion.
  363. !  sh/syn.c                  7    
  364. !  sh/table.c                7    
  365. !  sh/table.h                7    
  366. !  sh/trace.c                7    Simple trace facilty
  367. !  sh/trace.h                7    
  368. !  sh/trap.c                 7    
  369. !  sh/tree.c                 7    
  370. !  sh/tree.h                 7    
  371. !  sh/tty.h                  1    
  372. !  sh/ulimit.c               7    
  373. !  sh/var.c                  8    
  374. !  sh/version.c              3    
  375. !  sh/vi.c                   8    
  376.    std                       1    libraries
  377. !  std/Makefile              3    
  378. !  std/mklinks               1    make symlinks
  379.    std/posix                 2    
  380. !  std/posix                 4    posix lib source
  381. !  std/posix/ChangeLog       4    change history
  382. !  std/posix/Makefile        5    
  383. !  std/posix/dirent.C        7    
  384. !  std/posix/dirent.H        7    
  385. !  std/posix/dirent.h        7    
  386. !  std/posix/dup2.c          7    
  387. !  std/posix/fcntl.c         7    
  388. !  std/posix/fcntl.h         7    
  389. !  std/posix/fixincludes     8    
  390. !  std/posix/io.h            8    
  391. !  std/posix/time.h          8    
  392. !  std/posix/times.c         8    
  393. !  std/posix/times.h         8    
  394. !  std/posix/unistd.c        9    
  395. !  std/posix/unistd.h        9    
  396. !  std/posix/wait.h          9    
  397. !  std/stdc                  5    stdc lib source
  398. !  std/stdc/ChangeLog        7    change history
  399. !  std/stdc/Makefile         9    
  400. !  std/stdc/clock.c          9    
  401. !  std/stdc/fprintf.c        9    
  402. !  std/stdc/limits.h         9    
  403. !  std/stdc/memchr.c         8    
  404. !  std/stdc/memcmp.c         9    
  405. !  std/stdc/memcpy.c         9    
  406. !  std/stdc/memmove.c        9    
  407. !  std/stdc/memset.c         9    
  408. !  std/stdc/setvbuf.c        9    
  409. !  std/stdc/sprintf.c        9    
  410. !  std/stdc/stdarg.h         9    
  411. !  std/stdc/stddef.h         9    
  412. !  std/stdc/stdio.c          9    
  413. !  std/stdc/stdio.h_std      9    
  414. !  std/stdc/stdio.sed        9    
  415. !  std/stdc/stdlib.h         9    
  416. !  std/stdc/strcat.c         9    
  417. !  std/stdc/strchr.c         9    
  418. !  std/stdc/strcmp.c         9    
  419. !  std/stdc/strcpy.c         9    
  420. !  std/stdc/strcspn.c        9    
  421. !  std/stdc/strerror.c       9    
  422. !  std/stdc/string.h         9    
  423. !  std/stdc/strlen.c         9    
  424. !  std/stdc/strncat.c        9    
  425. !  std/stdc/strncmp.c        9    
  426. !  std/stdc/strncpy.c        9    
  427. !  std/stdc/strpbrk.c        9    
  428. !  std/stdc/strrchr.c        9    
  429. !  std/stdc/strspn.c         9    
  430. !  std/stdc/strstr.c         9    
  431. !  std/stdc/strtok.c         9    
  432. !  std/stdc/time.h           9    
  433. !  std/stdc/types.h          9    
  434. !  std/stdc/vprintf.c        9    
  435. *** Makefile.old    Mon Nov 25 13:39:21 1991
  436. --- Makefile    Mon Nov 25 13:54:22 1991
  437. ***************
  438. *** 1,14 ****
  439.   # PD Bourne/Korn Shell
  440. ! # 
  441.   
  442. ! SHELL=/bin/sh
  443.   
  444.   #CONFIG= -D_SYSV
  445. ! #CONFIG= -D_BSD
  446.   #CONFIG= -D_V7
  447.   #CONFIG= -D_ST        /* Atari ST */
  448.   
  449.   MANPAGES = ksh.1
  450.   #INSTALL=bsdinstall
  451.   INSTALL=install
  452.   
  453. --- 1,21 ----
  454.   # PD Bourne/Korn Shell
  455. ! # @(#)Makefile 1.4 91/11/25 13:54:20
  456.   
  457. ! SHELL = /bin/sh
  458. ! MAKE  = make
  459.   
  460. + LN=ln -s
  461. + #LN=ln
  462.   #CONFIG= -D_SYSV
  463. ! CONFIG= -D_BSD 
  464. ! #CONFIG= -D_BSD -DHAVE_SYS_STDTYPES
  465.   #CONFIG= -D_V7
  466.   #CONFIG= -D_ST        /* Atari ST */
  467.   
  468.   MANPAGES = ksh.1
  469. + #MANDIR=/usr/catman/u_man/man1
  470. + #MANDIR=/usr/man/man1
  471.   #INSTALL=bsdinstall
  472.   INSTALL=install
  473.   
  474. ***************
  475. *** 18,32 ****
  476.       ( cd sh ; $(MAKE) 'CC=$(CC)' 'CONFIG=$(CONFIG)' $@ )
  477.   
  478.   libs:
  479. !     ( cd std ; $(MAKE) 'CC=$(CC)' 'CONFIG=$(CONFIG)' $@ )
  480.   
  481.   install: sh/ksh
  482. !     ( cd sh ; $(INSTALL) -s ksh $(HCRDESTDIR)/bin )
  483.   
  484.   sh/ksh:    ksh
  485.   
  486.   inst-man: $(MANPAGES)
  487. !     $(INSTALL) -c -m 444 $(MANPAGES) $(HCRDESTDIR)/man/u_man/man1
  488.   
  489.   clean clobber:
  490.       ( cd std ; $(MAKE) $@ )
  491. --- 25,39 ----
  492.       ( cd sh ; $(MAKE) 'CC=$(CC)' 'CONFIG=$(CONFIG)' $@ )
  493.   
  494.   libs:
  495. !     ( cd std ; $(MAKE) 'CC=$(CC)' 'CONFIG=$(CONFIG)' 'LN=$(LN)' libs )
  496.   
  497.   install: sh/ksh
  498. !     ( cd sh ; $(INSTALL) -s ksh $(DESTDIR)/bin )
  499.   
  500.   sh/ksh:    ksh
  501.   
  502.   inst-man: $(MANPAGES)
  503. !     $(INSTALL) -c -m 444 $(MANPAGES) $(MANDESTDIR)/man1
  504.   
  505.   clean clobber:
  506.       ( cd std ; $(MAKE) $@ )
  507. *** README.old    Mon Nov 25 13:38:06 1991
  508. --- README    Sat Nov 23 11:55:04 1991
  509. ***************
  510. *** 1,5 ****
  511.           Public Domain Korn Shell
  512. !               Version 4.1
  513.   
  514.   PD KSH:
  515.   
  516. --- 1,5 ----
  517.           Public Domain Korn Shell
  518. !               Version 4.2
  519.   
  520.   PD KSH:
  521.   
  522. ***************
  523. *** 6,26 ****
  524.   This is the latest version of the PD ksh (pdksh).  It is not
  525.   intended to be the ultimate shell but rather a usable ksh work
  526.   alike.  For those of us who have to work on multiple systems it
  527. ! is nice to have the same user interface on all.  Pdksh is not
  528. ! 100% compatible with the ksh.  Having said that, I use it daily
  529.   beside a real ksh88 and find them virtually indistinguishable.
  530.   
  531.   I only run this shell on sun's and only for interactive use.  I
  532. ! use it on sun4c, sun3 and sun386 systems.  The makefiles are
  533. ! probably set up for a sun386 :-).  
  534.   
  535. ! I am releasing this version of the shell (with the kind
  536.   permission of the previous maintainers and major contributors) to
  537.   ensure that it is available from usenet archive sites.  Of
  538.   course it remains in the Public Domain.  Equally obviously
  539.   neither myself nor any other contributors make any claims of
  540. ! suitability etc.  Ie. NO WARRANTY!!!  
  541.   
  542.   HISTORY:
  543.   
  544.   This shell was written by Eric Gisin.  It is based on Charles
  545. --- 6,37 ----
  546.   This is the latest version of the PD ksh (pdksh).  It is not
  547.   intended to be the ultimate shell but rather a usable ksh work
  548.   alike.  For those of us who have to work on multiple systems it
  549. ! is nice to have the same user interface on all.  I resisted
  550. ! moving to the ksh on a Bull system at work for nearly a year due
  551. ! to the lack of a ksh on my Sun systems.  When I first picked up
  552. ! the 3.2 PD KSH a couple of years ago, it took any a few minutes
  553. ! to convert a C-shell fan to a ksh fan :-)  Pdksh is not 100%
  554. ! compatible with the ksh.  Having said that, I use it daily
  555.   beside a real ksh88 and find them virtually indistinguishable.
  556.   
  557.   I only run this shell on sun's and only for interactive use.  I
  558. ! use it on sun4c, sun3 and sun386 systems.  The shell itself has
  559. ! been compiled on each of these both with and without the
  560. ! POSIX/ANSI compatability libraries in ./std.  See the file
  561. ! MACHINES for details of systems that the shell has been built
  562. ! on.
  563.   
  564. ! I have released this version of the shell (with the kind
  565.   permission of the previous maintainers and major contributors) to
  566.   ensure that it is available from usenet archive sites.  Of
  567.   course it remains in the Public Domain.  Equally obviously
  568.   neither myself nor any other contributors make any claims of
  569. ! suitability etc.  Ie. NO WARRANTY!!!  If you make any changes
  570. ! and distribute them, please leave your own finger prints in the
  571. ! source.  Its bad enough being flamed for my own bugs let alone
  572. ! anyone elses :-)
  573.   
  574.   HISTORY:
  575.   
  576.   This shell was written by Eric Gisin.  It is based on Charles
  577. ***************
  578. *** 46,66 ****
  579.   
  580.   INSTALLATION:
  581.   
  582. ! ReadMe.jrm is John R MacMillan's README file and contains
  583. ! information about the current source arrangement.  Please read it.
  584.   
  585. - Eric Gisin's original ReadMe file can be found in ./sh,  it is
  586. - somewhat out of date but retained for history's sake :-)  Use
  587. - the instructions in ReadMe.jrm.
  588.   The original instructions indicated that a POSIX compliant
  589.   environment and possibly an ANSI compiler are required.  I have
  590. ! used both gcc and native Sun compilers without problems.
  591. ! Actually I use gcc on the sun386 and cc on the others.
  592. ! I do know that a friend's SysVr2 NS3210 system required some
  593. ! serious modifications to get the shell running.  If he ever
  594. ! sends me the diffs I'll fix the source :-)
  595.   
  596.   ENVIRONMENT:
  597.   
  598.   My main interest in this shell is for Sun workstations.  Every
  599. --- 57,85 ----
  600.   
  601.   INSTALLATION:
  602.   
  603. ! The file INSTALL contains intructions for building and
  604. ! installing the shell.  
  605.   
  606.   The original instructions indicated that a POSIX compliant
  607.   environment and possibly an ANSI compiler are required.  I have
  608. ! used both gcc and native Sun and the GreenHills ANSI compiler
  609. ! without problems.
  610.   
  611. + The POSIX/STDC compatability stuff in ./std seems to cause lots
  612. + of problems for some systems.  This was at least in part because
  613. + I distributed it with half the librraies disabled :-), in any
  614. + case the shell itself in ./sh can now be compiled without any of
  615. + the ./std stuff which makes things much simpler on systems that
  616. + have a real POSIX environment.
  617. + Porting to new environemnts can be a real pain.  I don't really
  618. + plan to make a huge effort in this area since I expect that this
  619. + shell will be mainly required on exotic or obscure systems (the
  620. + ones that the vendor does not provide a ksh for).  Thus the
  621. + small "market" does not warrant a C-news or X11 style
  622. + portability effort.  Of course if people send patches for
  623. + various systems I'm happy to try and integrate them.
  624.   ENVIRONMENT:
  625.   
  626.   My main interest in this shell is for Sun workstations.  Every
  627. ***************
  628. *** 88,97 ****
  629.   Many folk have contributed to this shell.  There are surely
  630.   still plenty of bugs to be found/fixed.
  631.   
  632. ! Feel free to e-mail fixes to pdksh-bug@zen.void.oz.au
  633. ! Please use context diffs (ie diff -c, get gnudiff if your
  634. ! system's diff doesn't support -c).
  635. ! I will, if need be, release patches following the C-news style.
  636.   
  637.   I hope you find this shell as useful as I do...
  638.   
  639. --- 107,115 ----
  640.   Many folk have contributed to this shell.  There are surely
  641.   still plenty of bugs to be found/fixed.
  642.   
  643. ! There is a template bug report in bug-report [borrowed from the
  644. ! X11R5 mit tree], just fill in the blanks and mail to
  645. ! pdksh-bug@zen.void.oz.au.  
  646.   
  647.   I hope you find this shell as useful as I do...
  648.   
  649. *** /dev/null    Mon Nov 25 11:15:05 1991
  650. --- bug-report    Mon Nov 25 13:02:36 1991
  651. ***************
  652. *** 0 ****
  653. --- 1,32 ----
  654. + To: pdksh-bug@zen.void.oz.au
  655. + Subject: [area]: [synopsis]   [replace with actual area and short description]
  656. + VERSION:
  657. +     PD KSH: 25-Nov-1991
  658. +     [Official patches will edit this line to indicate the patch level]
  659. + MACHINE and OPERATING SYSTEM:
  660. +     [e.g. Sparc/SunOS 4.1.1, DECstation 3100/Ultrix 4.2, ...]
  661. + COMPILER:
  662. +     [e.g. native cc, native ANSI cc, gcc 1.39, ...]
  663. + AREA:
  664. +     [Area of the source tree affected,
  665. +      e.g., std/posix, std/stdc, sh]
  666. + SYNOPSIS:
  667. +     [Brief description of the problem and where it is located]
  668. + DESCRIPTION:
  669. +     [Detailed description of problem.  Please provide as much detail
  670. +      as you can manage.  The more information we have the more likely 
  671. +      a fix]
  672. + SAMPLE FIX:
  673. +     [Preferred, but not necessary.  Please send context diffs (diff -c)]
  674. + [PLEASE make your Subject: line as descriptive as possible.
  675. +  Subjects like "pdksh bug" or "bug report" are not helpful!]
  676. + [Remove all the explanatory text in brackets before mailing.]
  677. + [Send to pdksh-bug@zen.void.oz.au]
  678. *** etc/ksh.kshrc.old    Mon Nov 25 13:39:05 1991
  679. --- etc/ksh.kshrc    Mon Nov 18 19:26:19 1991
  680. ***************
  681. *** 16,28 ****
  682.   #    $HOME/.kshrc
  683.   #
  684.   # AMENDED:
  685. ! #    91/11/12 19:39:44 (sjg)
  686.   #
  687.   # RELEASED:
  688. ! #    91/11/12 19:39:46 v2.4
  689.   #
  690.   # SCCSID:
  691. ! #    @(#)ksh.kshrc 2.4 91/11/12 19:39:44 (sjg)
  692.   #
  693.   #    @(#)Copyright (c) 1991 Simon J. Gerraty
  694.   #
  695. --- 16,28 ----
  696.   #    $HOME/.kshrc
  697.   #
  698.   # AMENDED:
  699. ! #    91/11/18 19:25:39 (sjg)
  700.   #
  701.   # RELEASED:
  702. ! #    91/11/18 19:25:41 v2.5
  703.   #
  704.   # SCCSID:
  705. ! #    @(#)ksh.kshrc 2.5 91/11/18 19:25:39 (sjg)
  706.   #
  707.   #    @(#)Copyright (c) 1991 Simon J. Gerraty
  708.   #
  709. ***************
  710. *** 54,94 ****
  711.       # the PD ksh is not 100% compatible
  712.       case "$KSH_VERSION" in
  713.       *PD*)    # PD ksh
  714. -         builtin=builtin
  715.               bind ^?=delete-char-backward
  716.               bind ^[^?=delete-word-backward
  717.           ;;
  718.       *)    # real ksh ?
  719. -         builtin=""
  720.           ;;
  721.       esac
  722.       case "$TERM" in
  723.       sun*)
  724. -         # these are not as neat as their csh equivalents
  725.           if [ "$tty" != console ]; then
  726. !             ilabel () { print -n "\033]L$*\033\\"; }
  727. !             label () { print -n "\033]l$*\033\\"; }
  728. !             alias stripe='label $USER @ $HOSTNAME \($tty\) - $PWD'
  729. !             cds () { "cd" $*; eval stripe; }
  730. !             alias cd=cds
  731. !             eval stripe
  732. !             eval ilabel "$USER@$HOSTNAME"
  733. !             PS1=$PROMPT
  734.           fi
  735.           ;;
  736.       xterm*)
  737. !         # these are not as neat as their csh equivalents
  738. !         ilabel () { print -n "\033]1;$*\007"; }
  739. !         label () { print -n "\033]2;$*\007"; }
  740. !         alias stripe='label xterm: $USER @ $HOSTNAME \($tty\) - $PWD'
  741. !         cds () { "cd" $*; eval stripe; }
  742. !         alias cd=cds
  743. !         eval stripe
  744. !         eval ilabel "$USER@$HOSTNAME"
  745. !         PS1=$PROMPT
  746.           ;;
  747.       *)    ;;
  748.       esac
  749.       alias quit=exit
  750.       alias cls=clear
  751.       alias logout=exit
  752. --- 54,91 ----
  753.       # the PD ksh is not 100% compatible
  754.       case "$KSH_VERSION" in
  755.       *PD*)    # PD ksh
  756.               bind ^?=delete-char-backward
  757.               bind ^[^?=delete-word-backward
  758.           ;;
  759.       *)    # real ksh ?
  760.           ;;
  761.       esac
  762.       case "$TERM" in
  763.       sun*)
  764.           if [ "$tty" != console ]; then
  765. !             ILS='\033]L'; ILE='\033\\'
  766. !             WLS='\033]l'; WLE='\033\\'
  767.           fi
  768.           ;;
  769.       xterm*)
  770. !         ILS='\033]1;'; ILE='\007'
  771. !         WLS='\033]2;xterm: '; WLE='\007'
  772.           ;;
  773.       *)    ;;
  774.       esac
  775. +     # do we want window decorations?
  776. +     if [ "$ILS" ]; then
  777. +         wftp () { ilabel "ftp $*"; "ftp" $*; ilabel "$USER@$HOSTNAME"; }
  778. +         wcd () { "cd" $*; eval stripe; }
  779. +         ilabel () { print -n "${ILS}$*${ILE}"; }
  780. +         label () { print -n "${WLS}$*${WLE}"; }
  781. +         alias stripe='label $USER @ $HOSTNAME \($tty\) - $PWD'
  782. +         alias cd=wcd
  783. +         alias ftp=wftp
  784. +         eval stripe
  785. +         eval ilabel "$USER@$HOSTNAME"
  786. +         PS1=$PROMPT
  787. +     fi
  788.       alias quit=exit
  789.       alias cls=clear
  790.       alias logout=exit
  791. *** sh/ChangeLog.old    Mon Nov 25 13:38:51 1991
  792. --- sh/ChangeLog    Mon Nov 25 13:41:15 1991
  793. ***************
  794. *** 1,3 ****
  795. --- 1,39 ----
  796. + Mon Nov 25 12:36:42 1991  Simon J. Gerraty  (sjg at zen)
  797. +     * stdh.h:  make sure FD_CLEXEC is defined if we support F_SETFD.
  798. +     
  799. +     * emacs.c: Attempt to make alloc() of x_tab acceptible to more
  800. +     compilers.  Not 100% yet.
  801. +     
  802. + Sat Nov 23 14:31:44 1991  Simon J. Gerraty  (sjg at zen)
  803. +     * Improved fd_clexec handling for systems that don't have
  804. +     an F_SETFD fcntl().  The new arrangement will not blow up if an
  805. +     attempt is made to fd_clexec a fd above MAXFD (64 by default).
  806. +     main.c:main()  and io.c:savefd() now simply call
  807. +     exec.c:fd_clexec(). 
  808. + Fri Nov 22 11:24:57 1991  Simon J. Gerraty  (sjg at zen)
  809. +     * Since many people had problems using the headers and libraries
  810. +     in std/*, modified sh/* so that they can be compiled in the
  811. +     absence of std/*.  This requires putting in some fixes that I had
  812. +     left out from my 3.2 version.  Particularly, catering for systems
  813. +     that do not have F_SETFD.
  814. +     * exec.c:
  815. +     Added fd_clexec array for tracking fd's to close in child after
  816. +     fork().  This is avoid wasting fd's on systems that don't have
  817. +     F_SETFD.
  818. +     * jobs.c:
  819. +     Allow Sun's and perhaps other BSD systems to define WAIT_T to be
  820. +     union wait and thus use their native status handling for children.
  821. +     * The file sh/MACHINES now tracks systems the shell has been
  822. +     compiled on.
  823.   Sat Nov  9 14:57:30 1991  Simon J. Gerraty  (sjg at zen)
  824.   
  825.       * Release version 4.1 as a new base line.
  826. *** sh/Makefile.old    Mon Nov 25 13:39:24 1991
  827. --- sh/Makefile    Mon Nov 25 13:33:17 1991
  828. ***************
  829. *** 1,27 ****
  830.   # PD Bourne/Korn Shell
  831. ! # NOTE: the are no depencies of .c file on .h files yet.
  832.   
  833.   SHELL = /bin/sh
  834.   
  835. ! # This is for the sun386i your mileage may vary :-)
  836. ! #CC=gcc -ansi -Dsun386 -Dsun -Di386
  837.   
  838.   #CONFIG= -D_SYSV
  839.   CONFIG= -D_BSD
  840.   
  841. ! STD=    ../std
  842.   
  843. ! #CC = shcc
  844. ! CCOPTS = $(DBG)
  845. ! CFLAGS = $(CCOPTS) -I$(STD)/h $(CONFIG)
  846.   
  847. ! #LDOPTS = -s
  848. ! LDFLAGS = $(LDOPTS) -L$(STD)
  849.   
  850. ! COMPATLIBS =  -lstdc # -lposix
  851. ! #OTHERLIBS = -lc_s
  852. ! #OTHERLIBS = -ldirent
  853. ! LDLIBS = $(COMPATLIBS) $(OTHERLIBS)
  854.   
  855.   HDRS =    sh.h table.h expand.h lex.h tree.h tty.h trace.h
  856.   SRCS1 =    version.c main.c misc.c trap.c alloc.c io.c \
  857. --- 1,68 ----
  858.   # PD Bourne/Korn Shell
  859. ! # @(#)Makefile 1.3 91/11/25 13:33:10
  860.   
  861.   SHELL = /bin/sh
  862. + MAKE  = make
  863.   
  864. ! LN    = ln
  865.   
  866. + # You _can_ build this shell without the ../std tree if your
  867. + # system provides a sufficiently POSIX environment, or if your
  868. + # BSD system is a Sun or close.  If not try ../std.
  869. + # gcc is good value on most mc68k's and sun386's if nothing else.
  870. + # if you don't have gcc cc should do
  871. + # CC=gcc -pipe
  872. + CC=cc
  873. + # The following are the defintions used (or thereabouts) 
  874. + # to build ksh without ../std
  875. + #
  876. + # sun386 SunOS 4.0.2, sun3 SunOS 4.0.3
  877. + # CONFIG=-D_BSD
  878. + # XOPTS=-DNOSTDHRDS
  879. + # copy these from ../std/stdc or ensure they are in libstdc.a
  880. + # XOBJS = memmove.o strstr.o 
  881. + #
  882. + # sun3  SunOS 4.1.1
  883. + # CONFIG=-D_BSD
  884. + # XOPTS=-DNOSTDHRDS
  885. + # copy these from ../std/stdc or ensure they are in libstdc.a
  886. + # XOBJS = memmove.o
  887. + #
  888. + # sun4c (sparc) SunOS 4.1.1
  889. + # CC=cc -pipe    # don't use gcc
  890. + # CONFIG=-D_BSD
  891. + # XOPTS=-DNOSTDHRDS
  892. + # copy these from ../std/stdc or ensure they are in libstdc.a
  893. + # XOBJS = memmove.o
  894. + #
  895. + # Bull DPX/2 B.O.S. 2.00.45
  896. + # CONFIG=-D_SYSV
  897. + # XOPTS=
  898. + # XOBJS=
  899. + #
  900.   #CONFIG= -D_SYSV
  901. + #CONFIG= -D_BSD -DHAVE_SYS_STDTYPES
  902.   CONFIG= -D_BSD
  903.   
  904. ! STD=../std
  905. ! INCL=$(STD)/h
  906. ! XINCL=-I$(STD)/h
  907. ! LDOPTS=-L$(STD)
  908. ! XOBJS=
  909.   
  910. ! # use -O if you trust it :-)
  911. ! #DBG=-g
  912. ! CFLAGS = $(DBG) $(CONFIG) $(XINCL) $(XOPTS)
  913.   
  914. ! LDFLAGS = $(LDOPTS)
  915.   
  916. ! COMPATLIBS = -lstdc -lposix
  917. ! #XLIBS = -lc_s
  918. ! #XLIBS = -ldirent
  919. ! LDLIBS = $(COMPATLIBS) $(XLIBS)
  920.   
  921.   HDRS =    sh.h table.h expand.h lex.h tree.h tty.h trace.h
  922.   SRCS1 =    version.c main.c misc.c trap.c alloc.c io.c \
  923. ***************
  924. *** 36,42 ****
  925.       exec.o jobs.o trap.o \
  926.       c_sh.o c_ksh.o c_test.o \
  927.       ulimit.o getopts.o expr.o history.o \
  928. !     var.o table.o alloc.o io.o eval.o mail.o trace.o
  929.   
  930.   ksh: $(OBJS) 
  931.       $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LDLIBS)
  932. --- 77,83 ----
  933.       exec.o jobs.o trap.o \
  934.       c_sh.o c_ksh.o c_test.o \
  935.       ulimit.o getopts.o expr.o history.o \
  936. !     var.o table.o alloc.o io.o eval.o mail.o trace.o $(XOBJS)
  937.   
  938.   ksh: $(OBJS) 
  939.       $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LDLIBS)
  940. ***************
  941. *** 47,51 ****
  942.   clobber: clean
  943.       rm -f ksh
  944.   
  945.   
  946. ! edit.o emacs.o:    edit.h
  947. --- 88,282 ----
  948.   clobber: clean
  949.       rm -f ksh
  950.   
  951. + link:
  952. +     ($(SHELL) ../std/mklinks $(INCL) stdh.h)
  953. +     
  954.   
  955. ! depend:
  956. !     makedepend $(CFLAGS) $(SRCS1) $(SRCS2)
  957. ! install:
  958. !     @echo "Try:"
  959. !     @echo "cp ksh /bin"
  960. !     @echo "strip /bin/ksh"
  961. !     @echo "chmod 555 /bin/ksh"
  962. ! # DO NOT DELETE THIS LINE -- make depend depends on it.
  963. ! # If this runs make out of memory, delete /usr/include lines.
  964. ! alloc.o: alloc.c
  965. ! alloc.o: config.h
  966. ! alloc.o: sh.h
  967. ! alloc.o: stdh.h
  968. ! alloc.o: trace.h
  969. ! c_ksh.o: c_ksh.c
  970. ! c_ksh.o: config.h
  971. ! c_ksh.o: sh.h
  972. ! c_ksh.o: stdh.h
  973. ! c_ksh.o: table.h
  974. ! c_ksh.o: trace.h
  975. ! c_sh.o: c_sh.c
  976. ! c_sh.o: config.h
  977. ! c_sh.o: lex.h
  978. ! c_sh.o: sh.h
  979. ! c_sh.o: stdh.h
  980. ! c_sh.o: table.h
  981. ! c_sh.o: trace.h
  982. ! c_sh.o: tree.h
  983. ! c_test.o: c_test.c
  984. ! c_test.o: config.h
  985. ! c_test.o: sh.h
  986. ! c_test.o: stdh.h
  987. ! c_test.o: trace.h
  988. ! edit.o: config.h
  989. ! edit.o: edit.c
  990. ! edit.o: edit.h
  991. ! edit.o: lex.h
  992. ! edit.o: sh.h
  993. ! edit.o: stdh.h
  994. ! edit.o: trace.h
  995. ! edit.o: tty.h
  996. ! emacs.o: config.h
  997. ! emacs.o: edit.h
  998. ! emacs.o: emacs.c
  999. ! emacs.o: expand.h
  1000. ! emacs.o: lex.h
  1001. ! emacs.o: sh.h
  1002. ! emacs.o: stdh.h
  1003. ! emacs.o: table.h
  1004. ! emacs.o: trace.h
  1005. ! emacs.o: tree.h
  1006. ! eval.o: config.h
  1007. ! eval.o: eval.c
  1008. ! eval.o: expand.h
  1009. ! eval.o: lex.h
  1010. ! eval.o: sh.h
  1011. ! eval.o: stdh.h
  1012. ! eval.o: table.h
  1013. ! eval.o: trace.h
  1014. ! eval.o: tree.h
  1015. ! exec.o: config.h
  1016. ! exec.o: exec.c
  1017. ! exec.o: lex.h
  1018. ! exec.o: sh.h
  1019. ! exec.o: stdh.h
  1020. ! exec.o: table.h
  1021. ! exec.o: trace.h
  1022. ! exec.o: tree.h
  1023. ! expr.o: config.h
  1024. ! expr.o: expr.c
  1025. ! expr.o: sh.h
  1026. ! expr.o: stdh.h
  1027. ! expr.o: table.h
  1028. ! expr.o: trace.h
  1029. ! getopts.o: config.h
  1030. ! getopts.o: getopts.c
  1031. ! getopts.o: sh.h
  1032. ! getopts.o: stdh.h
  1033. ! getopts.o: table.h
  1034. ! getopts.o: trace.h
  1035. ! history.o: config.h
  1036. ! history.o: history.c
  1037. ! history.o: lex.h
  1038. ! history.o: sh.h
  1039. ! history.o: stdh.h
  1040. ! history.o: trace.h
  1041. ! io.o: config.h
  1042. ! io.o: io.c
  1043. ! io.o: sh.h
  1044. ! io.o: stdh.h
  1045. ! io.o: trace.h
  1046. ! jobs.o: config.h
  1047. ! jobs.o: jobs.c
  1048. ! jobs.o: sh.h
  1049. ! jobs.o: stdh.h
  1050. ! jobs.o: trace.h
  1051. ! jobs.o: tree.h
  1052. ! lex.o: config.h
  1053. ! lex.o: expand.h
  1054. ! lex.o: lex.c
  1055. ! lex.o: lex.h
  1056. ! lex.o: sh.h
  1057. ! lex.o: stdh.h
  1058. ! lex.o: table.h
  1059. ! lex.o: trace.h
  1060. ! lex.o: tree.h
  1061. ! mail.o: config.h
  1062. ! mail.o: mail.c
  1063. ! mail.o: sh.h
  1064. ! mail.o: stdh.h
  1065. ! mail.o: table.h
  1066. ! mail.o: trace.h
  1067. ! main.o: config.h
  1068. ! main.o: lex.h
  1069. ! main.o: main.c
  1070. ! main.o: sh.h
  1071. ! main.o: stdh.h
  1072. ! main.o: table.h
  1073. ! main.o: trace.h
  1074. ! main.o: tree.h
  1075. ! memmove.o: memmove.c
  1076. ! memmove.o: stdh.h
  1077. ! misc.o: config.h
  1078. ! misc.o: expand.h
  1079. ! misc.o: misc.c
  1080. ! misc.o: sh.h
  1081. ! misc.o: stdh.h
  1082. ! misc.o: trace.h
  1083. ! strstr.o: stdh.h
  1084. ! strstr.o: strstr.c
  1085. ! syn.o: config.h
  1086. ! syn.o: expand.h
  1087. ! syn.o: lex.h
  1088. ! syn.o: sh.h
  1089. ! syn.o: stdh.h
  1090. ! syn.o: syn.c
  1091. ! syn.o: table.h
  1092. ! syn.o: trace.h
  1093. ! syn.o: tree.h
  1094. ! table.o: config.h
  1095. ! table.o: sh.h
  1096. ! table.o: stdh.h
  1097. ! table.o: table.c
  1098. ! table.o: table.h
  1099. ! table.o: trace.h
  1100. ! times.o: times.c
  1101. ! trace.o: trace.c
  1102. ! trap.o: config.h
  1103. ! trap.o: sh.h
  1104. ! trap.o: stdh.h
  1105. ! trap.o: trace.h
  1106. ! trap.o: trap.c
  1107. ! tree.o: config.h
  1108. ! tree.o: sh.h
  1109. ! tree.o: stdh.h
  1110. ! tree.o: trace.h
  1111. ! tree.o: tree.c
  1112. ! tree.o: tree.h
  1113. ! ulimit.o: config.h
  1114. ! ulimit.o: sh.h
  1115. ! ulimit.o: stdh.h
  1116. ! ulimit.o: trace.h
  1117. ! ulimit.o: ulimit.c
  1118. ! var.o: config.h
  1119. ! var.o: expand.h
  1120. ! var.o: sh.h
  1121. ! var.o: stdh.h
  1122. ! var.o: table.h
  1123. ! var.o: trace.h
  1124. ! var.o: var.c
  1125. ! version.o: config.h
  1126. ! version.o: sh.h
  1127. ! version.o: stdh.h
  1128. ! version.o: trace.h
  1129. ! version.o: version.c
  1130. ! vi.o: config.h
  1131. ! vi.o: edit.h
  1132. ! vi.o: expand.h
  1133. ! vi.o: lex.h
  1134. ! vi.o: sh.h
  1135. ! vi.o: stdh.h
  1136. ! vi.o: table.h
  1137. ! vi.o: trace.h
  1138. ! vi.o: tree.h
  1139. ! vi.o: vi.c
  1140. ! # WARNING: Put nothing here or make depend will gobble it up!
  1141. *** sh/alloc.c.old    Mon Nov 25 13:38:52 1991
  1142. --- sh/alloc.c    Fri Nov 22 22:54:13 1991
  1143. ***************
  1144. *** 2,11 ****
  1145.    * area-based allocation built on malloc/free
  1146.    */
  1147.   
  1148.   static char *RCSid = "$Id";
  1149.   
  1150. ! #include <stddef.h>
  1151. ! #include <stdlib.h>
  1152.   #include <setjmp.h>
  1153.   #include "sh.h"
  1154.   
  1155. --- 2,13 ----
  1156.    * area-based allocation built on malloc/free
  1157.    */
  1158.   
  1159. + #ifndef lint
  1160.   static char *RCSid = "$Id";
  1161. + static char *sccs_id = "@(#)alloc.c    1.2 91/11/22 22:53:32 (sjg)";
  1162. + #endif
  1163.   
  1164. ! #include "stdh.h"
  1165.   #include <setjmp.h>
  1166.   #include "sh.h"
  1167.   
  1168. *** sh/c_ksh.c.old    Mon Nov 25 13:38:32 1991
  1169. --- sh/c_ksh.c    Fri Nov 22 22:54:13 1991
  1170. ***************
  1171. *** 2,12 ****
  1172.    * built-in Korn commands: c_*
  1173.    */
  1174.   
  1175.   static char *RCSid = "$Id: c_ksh.c,v 3.4 89/03/27 15:47:16 egisin Exp $";
  1176.   
  1177. ! #include <stddef.h>
  1178. ! #include <stdio.h>
  1179. ! #include <string.h>
  1180.   #include <errno.h>
  1181.   #include <setjmp.h>
  1182.   #include "sh.h"
  1183. --- 2,13 ----
  1184.    * built-in Korn commands: c_*
  1185.    */
  1186.   
  1187. + #ifndef lint
  1188.   static char *RCSid = "$Id: c_ksh.c,v 3.4 89/03/27 15:47:16 egisin Exp $";
  1189. + static char *sccs_id = "@(#)c_ksh.c    1.2 91/11/22 22:53:34 (sjg)";
  1190. + #endif
  1191.   
  1192. ! #include "stdh.h"
  1193.   #include <errno.h>
  1194.   #include <setjmp.h>
  1195.   #include "sh.h"
  1196. *** sh/c_sh.c.old    Mon Nov 25 13:38:39 1991
  1197. --- sh/c_sh.c    Fri Nov 22 22:54:11 1991
  1198. ***************
  1199. *** 4,20 ****
  1200.   
  1201.   #ifndef lint
  1202.   static char *RCSid = "Id: /u/egisin/sh/src/RCS/c_sh.c,v 3.1 88/11/03 09:14:31 egisin Exp $";
  1203. ! static char *sccs_id = "@(#)c_sh.c    1.3 91/11/09 15:35:24 (sjg)";
  1204.   #endif
  1205.   
  1206. ! #include <stddef.h>
  1207. ! #include <stdio.h>
  1208. ! #include <string.h>
  1209.   #include <errno.h>
  1210.   #include <signal.h>
  1211.   #include <setjmp.h>
  1212. - #include <sys/times.h>
  1213.   #include <unistd.h>        /* getcwd */
  1214.   #include "sh.h"
  1215.   #include "lex.h"
  1216.   #include "tree.h"
  1217. --- 4,18 ----
  1218.   
  1219.   #ifndef lint
  1220.   static char *RCSid = "Id: /u/egisin/sh/src/RCS/c_sh.c,v 3.1 88/11/03 09:14:31 egisin Exp $";
  1221. ! static char *sccs_id = "@(#)c_sh.c    1.4 91/11/22 22:53:24 (sjg)";
  1222.   #endif
  1223.   
  1224. ! #include "stdh.h"
  1225.   #include <errno.h>
  1226.   #include <signal.h>
  1227.   #include <setjmp.h>
  1228.   #include <unistd.h>        /* getcwd */
  1229. + #include <sys/times.h>
  1230.   #include "sh.h"
  1231.   #include "lex.h"
  1232.   #include "tree.h"
  1233. ***************
  1234. *** 21,26 ****
  1235. --- 19,27 ----
  1236.   #include "table.h"
  1237.   
  1238.   static    char *clocktos();
  1239. + #ifndef CLK_TCK
  1240. + #define CLK_TCK 60            /* 60HZ */
  1241. + #endif
  1242.   
  1243.   int
  1244.   c_label(wp)
  1245. *** sh/c_test.c.old    Mon Nov 25 13:38:40 1991
  1246. --- sh/c_test.c    Fri Nov 22 22:54:14 1991
  1247. ***************
  1248. *** 5,18 ****
  1249.    * (-x -c -b -p -u -g -k) plus Korn's -L -nt -ot -ef and new -S (socket).
  1250.    */
  1251.   
  1252.   static char *RCSid = "$Id: c_test.c,v 3.3 89/03/27 15:47:25 egisin Exp $";
  1253.   
  1254. ! #include <stddef.h>
  1255. ! #include <string.h>
  1256.   #include <signal.h>
  1257.   #include <errno.h>
  1258.   #include <setjmp.h>
  1259. - #include <sys/types.h>
  1260.   #include <sys/stat.h>
  1261.   #include "sh.h"
  1262.   
  1263. --- 5,19 ----
  1264.    * (-x -c -b -p -u -g -k) plus Korn's -L -nt -ot -ef and new -S (socket).
  1265.    */
  1266.   
  1267. + #ifndef lint
  1268.   static char *RCSid = "$Id: c_test.c,v 3.3 89/03/27 15:47:25 egisin Exp $";
  1269. + static char *sccs_id = "@(#)c_test.c    1.2 91/11/22 22:53:37 (sjg)";
  1270. + #endif
  1271.   
  1272. ! #include "stdh.h"
  1273.   #include <signal.h>
  1274.   #include <errno.h>
  1275.   #include <setjmp.h>
  1276.   #include <sys/stat.h>
  1277.   #include "sh.h"
  1278.   
  1279. *** sh/config.h.old    Mon Nov 25 13:39:24 1991
  1280. --- sh/config.h    Fri Nov 22 22:54:12 1991
  1281. ***************
  1282. *** 1,5 ****
  1283. --- 1,7 ----
  1284.   /*
  1285.    * Configuration file for the PD ksh
  1286. +  *
  1287. +  * SCCSID: @(#)config.h 1.2 91/11/22 22:53:31
  1288.    */
  1289.   
  1290.   #ifndef    _CONFIG_H
  1291. ***************
  1292. *** 11,24 ****
  1293.   
  1294.   #define    EMACS                /* EMACS-like mode */
  1295.   #define    VI                /* vi-like mode */
  1296.   
  1297. ! /*
  1298. !  * Various compilation options.  They are defined to 1 because
  1299. !  * the original code uses #if a lot, and some versions of cpp
  1300. !  * seem to choke on #if NOTDEF
  1301. !  */
  1302.   
  1303. ! #define    JOBS            /* job control */
  1304.   /* #define    FASCIST            /* Fascist getopts */
  1305.   #define    SHARPBANG            /* Hack to handle #! */
  1306.   /* #define    SILLY            /* Game of life in EMACS mode */
  1307. --- 13,28 ----
  1308.   
  1309.   #define    EMACS                /* EMACS-like mode */
  1310.   #define    VI                /* vi-like mode */
  1311. + #define    JOBS                /* job control */
  1312.   
  1313. ! #ifndef SIGINT
  1314. ! #include <signal.h>
  1315. ! #endif
  1316.   
  1317. ! #if defined(JOBS) && !defined(SIGCONT)
  1318. ! #undef JOBS
  1319. ! #endif
  1320.   /* #define    FASCIST            /* Fascist getopts */
  1321.   #define    SHARPBANG            /* Hack to handle #! */
  1322.   /* #define    SILLY            /* Game of life in EMACS mode */
  1323. *** sh/edit.c.old    Mon Nov 25 13:38:42 1991
  1324. --- sh/edit.c    Fri Nov 22 22:54:06 1991
  1325. ***************
  1326. *** 1,5 ****
  1327. --- 1,6 ----
  1328.   /*
  1329.    * Command line editing - common code
  1330. +  *
  1331.    */
  1332.   
  1333.   #include "config.h"
  1334. ***************
  1335. *** 7,19 ****
  1336.   
  1337.   #ifndef lint
  1338.   static char *RCSid = "$Id: edit.c,v 3.2 89/03/27 15:47:34 egisin Exp $";
  1339. ! static char *sccs_id = "@(#)edit.c    1.4 91/11/09 15:35:07 (sjg)";
  1340.   #endif
  1341.   
  1342. ! #include <stddef.h>
  1343. ! #include <stdlib.h>
  1344. ! #include <string.h>
  1345. ! #include <stdio.h>
  1346.   #include <unistd.h>
  1347.   #include <signal.h>
  1348.   #include <fcntl.h>
  1349. --- 8,17 ----
  1350.   
  1351.   #ifndef lint
  1352.   static char *RCSid = "$Id: edit.c,v 3.2 89/03/27 15:47:34 egisin Exp $";
  1353. ! static char *sccs_id = "@(#)edit.c    1.5 91/11/22 22:52:59 (sjg)";
  1354.   #endif
  1355.   
  1356. ! #include "stdh.h"
  1357.   #include <unistd.h>
  1358.   #include <signal.h>
  1359.   #include <fcntl.h>
  1360.  
  1361. exit 0 # Just in case...
  1362. -- 
  1363. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  1364. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  1365. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  1366. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  1367.