home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume16 / lc / patch2 / lc.patch2
Encoding:
Text File  |  1991-02-06  |  7.0 KB  |  276 lines

  1. diff -c ../lc.old/README ./README
  2. *** ../lc.old/README    Sun Feb  3 22:20:06 1991
  3. --- ./README    Sun Feb  3 22:25:46 1991
  4. ***************
  5. *** 1,7 ****
  6.   
  7.               LC
  8.   
  9. !         "@(#)README    1.4 1/8/91 Kent Landfield"
  10.   
  11.   This directory contains the source to lc. lc is much like the ls 
  12.   command except it separates the types of files into groups and then
  13. --- 1,7 ----
  14.   
  15.               LC
  16.   
  17. !         "@(#)README    1.5 2/3/91 Kent Landfield"
  18.   
  19.   This directory contains the source to lc. lc is much like the ls 
  20.   command except it separates the types of files into groups and then
  21. ***************
  22. *** 113,118 ****
  23. --- 113,127 ----
  24.   INTERNET: kent@sparky.IMD.Sterling.COM or UUCP: uunet!sparky!kent
  25.   
  26.   so that I can continue to improve the functionality and portability of lc.
  27. + Just a note for historical interest: David Tanguay of Software Development 
  28. + Group, University of Waterloo informs me that LC stands for "list catalog".
  29. + GCOS TSS on the Honeywell used the term "catalog", meaning (roughly) the
  30. + same thing as a Unix directory. The GCOS file system maintenance program
  31. + was called ACCE (short for access), a Swiss Army knife type program, and
  32. + one of its sub-functions was LC, which gave the usual baroque display.
  33. + A separate LC program was written to give the more commonly wanted structure
  34. + info, and CLIS (for catalog listing) to give a more "ls -l" type of display.
  35.   
  36.               -Kent+
  37.   
  38. diff -c ../lc.old/lc.c ./lc.c
  39. *** ../lc.old/lc.c    Sun Feb  3 22:20:07 1991
  40. --- ./lc.c    Sun Feb  3 22:25:53 1991
  41. ***************
  42. *** 1,7 ****
  43.   /*
  44.   ** This software is 
  45.   **
  46. ! ** Copyright (c) 1984, 1985, 1986, 1987, 1988, 1989, 1990 by Kent Landfield.
  47.   **
  48.   ** Permission is hereby granted to copy, distribute or otherwise 
  49.   ** use any part of this package as long as you do not try to make 
  50. --- 1,8 ----
  51.   /*
  52.   ** This software is 
  53.   **
  54. ! ** Copyright (c) 1984, 1985, 1986, 1987, 1988, 1989, 1990,
  55. ! **               1991 by Kent Landfield.
  56.   **
  57.   ** Permission is hereby granted to copy, distribute or otherwise 
  58.   ** use any part of this package as long as you do not try to make 
  59. ***************
  60. *** 54,60 ****
  61.   ** on your system ? Options -s, -L or -l won't be available..)
  62.   **
  63.   **  History:
  64. ! **      Initially designed on an IBM-XT running Coherent in 1984.
  65.   **      Ported to XENIX on an IBM-AT in 1984.
  66.   **      Ported to System V on AT&T 3Bs in 1985.
  67.   **      Ported to DEC Vax 11/750 running System V in 1986.
  68. --- 55,62 ----
  69.   ** on your system ? Options -s, -L or -l won't be available..)
  70.   **
  71.   **  History:
  72. ! **      This implementation initially designed on an 
  73. ! **           IBM-XT running Coherent in 1984.
  74.   **      Ported to XENIX on an IBM-AT in 1984.
  75.   **      Ported to System V on AT&T 3Bs in 1985.
  76.   **      Ported to DEC Vax 11/750 running System V in 1986.
  77. ***************
  78. *** 70,80 ****
  79.   **      Tested with AmigaDOS 1.3 on an Amiga 1000 in 1989.
  80.   **      Tested with SunOS 4.0.3 on a Sparkstation 1 in 1989.
  81.   **      Tested with AIX 3.+ on a Risc System/6000 in 1990. 
  82. ! **      Ivan Fris added the ability to combine "only" options.
  83.   **                                                               
  84.   */
  85.   #ifndef lint
  86. ! static char *sccsid = "@(#)lc.c    1.25 1/2/91  Kent Landfield";
  87.   #endif
  88.   
  89.   #include <stdio.h>
  90. --- 72,83 ----
  91.   **      Tested with AmigaDOS 1.3 on an Amiga 1000 in 1989.
  92.   **      Tested with SunOS 4.0.3 on a Sparkstation 1 in 1989.
  93.   **      Tested with AIX 3.+ on a Risc System/6000 in 1990. 
  94. ! **      Ivan Fris added the ability to combine "only" options in 1990.
  95. ! **      Mike Peterson ported it to the Apollo Domain/OS SR10.2 in 1990.
  96.   **                                                               
  97.   */
  98.   #ifndef lint
  99. ! static char *sccsid = "@(#)lc.c    1.26 2/3/91  Kent Landfield";
  100.   #endif
  101.   
  102.   #include <stdio.h>
  103. ***************
  104. *** 152,159 ****
  105.   #ifdef S_IFBLK
  106.   #  define BLOCK_ONLY    1<<4
  107.   #endif
  108. ! #ifdef S_IFIFO
  109.   #  define FIFO_ONLY     1<<5
  110.   #endif
  111.   #ifdef S_IFLNK
  112.   #  define LNK_ONLY      1<<6
  113. --- 155,164 ----
  114.   #ifdef S_IFBLK
  115.   #  define BLOCK_ONLY    1<<4
  116.   #endif
  117. ! #ifndef apollo
  118. ! # ifdef S_IFIFO
  119.   #  define FIFO_ONLY     1<<5
  120. + # endif
  121.   #endif
  122.   #ifdef S_IFLNK
  123.   #  define LNK_ONLY      1<<6
  124. ***************
  125. *** 194,202 ****
  126. --- 199,209 ----
  127.   struct list Dirs = { 0, 0, (char **) NULL, 0 };
  128.   struct list Fls = { 0, 0, (char **) NULL, 0 };
  129.   
  130. + #ifndef apollo
  131.   #ifdef S_IFIFO
  132.   struct list Fifos = { 0, 0, (char **) NULL, 0 };
  133.   #endif
  134. + #endif
  135.   
  136.   #ifdef S_IFLNK
  137.   struct list Lnks = { 0, 0, (char **) NULL, 0 };
  138. ***************
  139. *** 225,233 ****
  140. --- 232,242 ----
  141.   struct list Dirs = { 0, 0, (char **) NULL };
  142.   struct list Fls = { 0, 0, (char **) NULL };
  143.   
  144. + #ifndef apollo
  145.   #ifdef S_IFIFO
  146.   struct list Fifos = { 0, 0, (char **) NULL };
  147.   #endif
  148. + #endif
  149.   
  150.   #ifdef S_IFLNK
  151.   struct list Lnks = { 0, 0, (char **) NULL };
  152. ***************
  153. *** 602,610 ****
  154.           flag = pr_info("Shared Data Files: ", &Sds, flag, Sort_wanted);
  155.   #endif
  156.   
  157. ! #ifdef S_IFIFO
  158.       if (Fifos.num > 0 && (Only == 0 || Only & FIFO_ONLY))
  159.           flag = pr_info("Fifo Files: ", &Fifos, flag, Sort_wanted);
  160.   #endif
  161.   
  162.   #ifdef S_IFCHR
  163. --- 611,621 ----
  164.           flag = pr_info("Shared Data Files: ", &Sds, flag, Sort_wanted);
  165.   #endif
  166.   
  167. ! #ifndef apollo
  168. ! # ifdef S_IFIFO
  169.       if (Fifos.num > 0 && (Only == 0 || Only & FIFO_ONLY))
  170.           flag = pr_info("Fifo Files: ", &Fifos, flag, Sort_wanted);
  171. + # endif
  172.   #endif
  173.   
  174.   #ifdef S_IFCHR
  175. ***************
  176. *** 795,800 ****
  177. --- 806,812 ----
  178.           break;
  179.   #endif
  180.   
  181. + #ifndef apollo
  182.   #ifdef S_IFIFO
  183.       case S_IFIFO:
  184.           if (!Allfiles && sav_str[0] == '.')
  185. ***************
  186. *** 806,811 ****
  187. --- 818,824 ----
  188.   #endif
  189.           break;
  190.   #endif
  191. + #endif
  192.   
  193.   #ifdef S_IFLNK
  194.       case S_IFLNK:
  195. ***************
  196. *** 890,895 ****
  197. --- 903,909 ----
  198.                   break;
  199.   #endif
  200.   
  201. + #ifndef apollo
  202.   #ifdef S_IFIFO
  203.               case S_IFIFO:
  204.                   add_to_list(&Fifos, sav_str);
  205. ***************
  206. *** 899,904 ****
  207. --- 913,919 ----
  208.   #endif
  209.                   break;
  210.   #endif
  211. + #endif
  212.   
  213.   #ifdef S_IFSOCK
  214.               case S_IFSOCK :
  215. ***************
  216. *** 1007,1016 ****
  217.           Sort_wanted = FALSE;
  218.           break;
  219.   
  220. ! #ifdef S_IFIFO
  221.       case 'F':
  222.           Only |= FIFO_ONLY;
  223.           break;
  224.   #endif
  225.   
  226.       case '1':
  227. --- 1022,1033 ----
  228.           Sort_wanted = FALSE;
  229.           break;
  230.   
  231. ! #ifndef apollo
  232. ! # ifdef S_IFIFO
  233.       case 'F':
  234.           Only |= FIFO_ONLY;
  235.           break;
  236. + # endif
  237.   #endif
  238.   
  239.       case '1':
  240. ***************
  241. *** 1407,1412 ****
  242. --- 1424,1430 ----
  243.                   break;
  244.   #endif
  245.   
  246. + #ifndef apollo
  247.   #ifdef S_IFIFO
  248.               case S_IFIFO:
  249.                   if (Display_single)
  250. ***************
  251. *** 1413,1418 ****
  252. --- 1431,1437 ----
  253.                      (void) printf("%s: fifo file\n", buf);
  254.                   break;
  255.   #endif
  256. + #endif
  257.   
  258.   #ifdef S_IFSOCK
  259.               case S_IFSOCK:
  260. ***************
  261. *** 1468,1477 ****
  262. --- 1487,1498 ----
  263.                   Dirs.maxlen = Fls.maxlen = 0;
  264.   #endif
  265.   
  266. + #ifndef apollo
  267.   #ifdef S_IFIFO
  268.                   Fifos.num = 0;
  269.   #ifdef LENS
  270.                   Fifos.maxlen = 0;
  271. + #endif
  272.   #endif
  273.   #endif
  274.   
  275.