home *** CD-ROM | disk | FTP | other *** search
/ The UNIX CD Bookshelf / OREILLY_TUCB_UNIX_CD.iso / upt / examples / SOURCES / DELETE / I386 / DELETE. < prev    next >
Encoding:
Text File  |  1998-07-24  |  3.1 KB  |  133 lines

  1. --- Makefile.rtr    Tue Feb  4 14:41:15 1997
  2. +++ Makefile    Tue Feb  4 14:43:49 1997
  3. @@ -28,8 +28,8 @@
  4.  DEPEND=        /usr/bin/X11/makedepend
  5.  COMPILE_ET=     ../com_err/compile_et
  6.  LINT=         lint
  7. -MALLOC=
  8. -DEFINES=    $(MALLOC)
  9. +MALLOC=    -DMALLOC_0_RETURNS_NULL
  10. +DEFINES=    -DSYSV -DMAXPATHLEN=PATHSIZE $(MALLOC) -DPOSIX
  11.  
  12.  
  13.  # These variables apply only if you want this program to recognize
  14. --- delete.c.rtr    Tue Feb  4 14:41:13 1997
  15. +++ delete.c    Tue Feb  4 14:41:16 1997
  16. @@ -14,13 +14,15 @@
  17.       static char rcsid_delete_c[] = "$Header: /afs/athena.mit.edu/astaff/project/delete/src/RCS/delete.c,v 1.26 91/06/04 22:06:55 jik Exp $";
  18.  #endif
  19.  
  20. +#define MAXPATHLEN PATHSIZE
  21.  #include <sys/types.h>
  22. +#include <sys/unistd.h>
  23.  #include <stdio.h>
  24.  #ifdef POSIX
  25.  #include <dirent.h>
  26.  #define direct dirent
  27.  #else
  28. -#include <sys/dir.h>
  29. +#include <sys/ndir.h>
  30.  #endif
  31.  #ifdef SYSV
  32.  #include <string.h>
  33. --- directories.c.rtr    Tue Feb  4 14:41:13 1997
  34. +++ directories.c    Tue Feb  4 14:41:17 1997
  35. @@ -21,7 +21,7 @@
  36.  #include <dirent.h>
  37.  #define direct dirent
  38.  #else
  39. -#include <sys/dir.h>
  40. +/* #include <sys/ndir.h> */
  41.  #endif
  42.  #ifdef SYSV
  43.  #include <string.h>
  44. --- directories.h.rtr    Tue Feb  4 14:41:17 1997
  45. +++ directories.h    Tue Feb  4 14:41:18 1997
  46. @@ -12,7 +12,7 @@
  47.   */
  48.  
  49.  #include "mit-copying.h"
  50. -#include <sys/ndir.h>
  51. +/* #include <sys/ndir.h> */
  52.  
  53.  typedef short Boolean;
  54.  #define True            (Boolean) 1
  55. --- expunge.c.rtr    Tue Feb  4 14:41:14 1997
  56. +++ expunge.c    Tue Feb  4 14:41:17 1997
  57. @@ -21,7 +21,7 @@
  58.  #include <dirent.h>
  59.  #define direct dirent
  60.  #else
  61. -#include <sys/dir.h>
  62. +/* #include <sys/dir.h> */
  63.  #endif
  64.  #include <sys/param.h>
  65.  #ifdef SYSV
  66. --- lsdel.c.rtr    Tue Feb  4 14:41:14 1997
  67. +++ lsdel.c    Tue Feb  4 14:41:17 1997
  68. @@ -20,7 +20,7 @@
  69.  #include <dirent.h>
  70.  #define direct dirent
  71.  #else
  72. -#include <sys/dir.h>
  73. +/* #include <sys/dir.h> */
  74.  #endif
  75.  #include <sys/param.h>
  76.  #ifdef SYSV
  77. --- pattern.c.rtr    Tue Feb  4 14:41:14 1997
  78. +++ pattern.c    Tue Feb  4 14:41:17 1997
  79. @@ -20,7 +20,7 @@
  80.  #include <dirent.h>
  81.  #define direct dirent
  82.  #else
  83. -#include <sys/dir.h>
  84. +/* #include <sys/dir.h> */
  85.  #endif
  86.  #include <sys/param.h>
  87.  #ifdef SYSV
  88. @@ -774,6 +774,7 @@
  89.       }
  90.       
  91.       if (is_link(base, &statbuf)) {
  92. +#ifndef M_UNIX /* SCO doesn't get symbolic links until 3.2.4 */
  93.        /* Never follow deleted symlinks */
  94.        if (is_deleted(lastpart(base))) {
  95.             return 0;
  96. @@ -808,6 +809,7 @@
  97.              return error_code;
  98.             }
  99.        }
  100. +#endif
  101.       }
  102.  
  103.       if ((statbuf.st_mode & S_IFMT) != S_IFDIR)
  104. --- undelete.c.rtr    Tue Feb  4 14:41:13 1997
  105. +++ undelete.c    Tue Feb  4 14:41:18 1997
  106. @@ -20,7 +20,7 @@
  107.  #include <dirent.h>
  108.  #define direct dirent
  109.  #else
  110. -#include <sys/dir.h>
  111. +/* #include <sys/dir.h> */
  112.  #endif
  113.  #include <sys/param.h>
  114.  #ifdef SYSV
  115. --- util.c.rtr    Tue Feb  4 14:41:14 1997
  116. +++ util.c    Tue Feb  4 14:41:18 1997
  117. @@ -18,13 +18,13 @@
  118.  #include <sys/param.h>
  119.  #include <sys/types.h>
  120.  #ifdef SYSV /* SYSV doesn't define uid_t */
  121. -typedef unsigned short uid_t;
  122. +/*typedef unsigned short uid_t;*/ /* causes redef probs under SCO */
  123.  #endif
  124.  #ifdef POSIX
  125.  #include <dirent.h>
  126.  #define direct dirent
  127.  #else
  128. -#include <sys/dir.h>
  129. +/* #include <sys/ndir.h> */
  130.  #endif
  131.  #ifdef SYSV
  132.  #include <string.h>
  133.