home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / Modula / Utilities / Makefiles / MakeForest.DEF < prev    next >
Encoding:
Modula Definition  |  1988-01-24  |  2.0 KB  |  66 lines  |  [TEXT/????]

  1. DEFINITION MODULE MakeForest;
  2.   (*
  3.    * MAKEMAKE.  Create a MAKEFILE for a MODULA-2 program.
  4.    *
  5.    * Written by Steve Tynor, 30 September 1986.
  6.    *            UUCP  : tynor@gitpyr
  7.    *            USNAIL: 2550 Akers Mill Rd. T-2, Atlanta GA. 30339
  8.    *
  9.    * Permission is granted to distribute, copy and change this program as long
  10.    * as this notice remains...
  11.    ---
  12.    *
  13.    * Make.
  14.    * Modified and extended for MacMETH by :
  15.    * J?rgen N?rgaard, 23 october 1987.
  16.    *            UUCP  : jnp@daimi.dk
  17.    *            MAIL  : Dybb?lvej 29, v?r. 2+3, 8240 Risskov, DENMARK
  18.    *
  19.    * Essentially only the parser remains from the original.
  20.    * Extensions are a dependency-tree and a make-like facility.
  21.    *
  22.    *)
  23.   
  24. IMPORT System;
  25. IMPORT FileSystem;
  26.  
  27. TYPE
  28.   NameString = ARRAY[0..60] OF CHAR;  (* Total filename length is 64 - '.EXT' *)
  29.   DepList = POINTER TO DepListEntity;
  30.   DepTree = DepList;
  31.   EntityPtr = POINTER TO DepEntity;
  32.   DepEntity = RECORD
  33.                 moduleName : NameString;
  34.                 defName,
  35.                 impName    : System.Path;
  36.                 seen,
  37.                 checked,
  38.                 library    : BOOLEAN;
  39.                 date       : LONGINT;
  40.                 DEFDepends,
  41.                 MODDepends : DepTree;
  42.               END;
  43.               
  44.   DepListEntity = RECORD
  45.                     next   : DepList;
  46.                     actual : EntityPtr;
  47.                   END;
  48.  
  49. VAR
  50.   root : DepTree;
  51.                   
  52.   (*----------------------------------------------------------------------*)
  53.   PROCEDURE AddModule (VAR name : NameString;
  54.                        VAR dp : DepTree;
  55.                        VAR de : EntityPtr) : BOOLEAN;
  56.     (* returns TRUE if file added, FALSE if the file was already there, and a
  57.        POINTER to a new entity *)
  58.     (*----------------------------------------------------------------------*)
  59.   
  60.   PROCEDURE RemoveTree(VAR dp : DepTree);
  61.   
  62.     (*----------------------------------------------------------------------*)
  63.   PROCEDURE Make(dp : DepTree; VAR fd : FileSystem.File);
  64.   
  65. END MakeForest.
  66.