home *** CD-ROM | disk | FTP | other *** search
/ World of Shareware - Software Farm 2 / wosw_2.zip / wosw_2 / CPROG / CPE601.ZIP / 3PMAKE.DOC next >
Text File  |  1990-04-09  |  6KB  |  173 lines

  1.                                   3PMAKE v1.00
  2.                           Program Maintenance Utility
  3.            Copyright(c) 1990 - 3P Software, Inc. All Rights Reserved.
  4.  
  5.  
  6. 3PMAKE is a cross between the Unix MAKE and Microsoft's NMAKE utilities. While 
  7. it is not as powerful as NMAKE it does support the format of NMAKE files and 
  8. some of the NMAKE command set.
  9.  
  10. 3PMAKE has some advantages over other MAKE utilities in the structure of the 
  11. makefile that it will use. Unlike most other MAKE utilities which require that 
  12. dependencies be listed in a bottom up manner, 3PMAKE will accept dependencies 
  13. anywhere in the makefile.
  14.  
  15. 3PMAKE supports a DOS environment variable called '3PMAKE' of course. This 
  16. environment variable can be used to set your preferred default command line 
  17. switches for 3PMAKE. For example the command 'SET 3PMAKE=-d' will cause 3PMAKE 
  18. to always operate in debug mode. Any command line option, or options, may be 
  19. entered into the environment variable as defaults.
  20.  
  21. The folowing special macros are pre-defined in 3PMAKE:
  22.  
  23.         $*      = base filename of current target file
  24.         $@      = full filename & path of current target file
  25.         $<      = full name of first dependent file.
  26.         $**     = list of all dependent files.
  27.         
  28. The following commands are supported:
  29.  
  30.         .SILENT = do not echo comands as they are processed.
  31.         .IGNORE = ignore errorlevels of executing programs and continue.
  32.         
  33. User defined macros are supported for example:
  34.  
  35.         CC = clipper
  36.         CLFLAGS= -l -m
  37.         
  38.         .prg.obj:
  39.                 $(CC) $< $(CLFLAGS)
  40.  
  41. Command line parameters:
  42.  
  43.         -d      - Debug mode, shows dates & times of files as it works
  44.         -n      - No-Execute, shows steps without actual execution.
  45.         -i      - Ignore program return codes. Same as '.IGNORE'
  46.         -f      - next argument is make file name, '-' means use stdin.
  47.         -s      - silent mode, same as '.SILENT'
  48.         any other command will display a help screen
  49.         
  50. 3PMAKE also allows variables to be defined on the command line, for example:
  51.     3PMAKE CC=Clipper    would define a macro $(CC) = to 'Clipper'
  52.     
  53.  
  54.   If you're unfamiliar with Make utilities, the job of this program is to
  55. maintain multi-module programs. You specify (in a 'makefile' - an ordinary
  56. text file) a target file (say, PROG.EXE), its components (e.g. PROG.OBJ,
  57. FUNCS.OBJ), THEIR components (PROG.C, FUNCS.C, PROG.H), and the actions
  58. required to construct a target from its components (called dependents). For
  59. instance, if PROG.OBJ depends on PROG.C and PROG.H, you could include the
  60. lines:
  61.  
  62. prog.obj:     prog.c prog.h
  63.   cc -c $<
  64.  
  65.   Then, if Make finds either prog.c or prog.h to be newer than prog.obj, the
  66. specified action is performed. The '$<' is a macro which is replaced by the
  67. name of the first dependent, in this case prog.c. You can define your own
  68. macros, like this:
  69.  
  70. MNAME = text
  71.  
  72. where 'MNAME' is the name you wish to use for this macro, and 'text' is the
  73. text to replace the macro. You reference a macro my preceding it with a '$'
  74. and enclosing it in parentheses. e.g.:
  75.  
  76. CC = clipper
  77. CLFLAGS = -l
  78.  
  79. fil.obj:    fil.clp
  80.         $(CC) @$< $(CLFLAGS)
  81.  
  82.  
  83.   When invoking 3PMAKE, either specify a target name, or by default the target
  84. will be the 'topmost' in the dependency tree.
  85.  
  86.  
  87. Following is a sample makefile:
  88.  
  89.  
  90. # sample makefile for 3PMAKE
  91. #
  92.  
  93. # define macros
  94. CC = clipper
  95. CF = -l -m
  96. CP = -l
  97.  
  98. # Inference rules
  99. .prg.obj:
  100.         $(CC) $< $(CF)
  101.  
  102. .clp.obj:
  103.         $(CC) @$@ $(CP)
  104.         
  105. # program make defines
  106. prog.exe:       main.obj cust.obj addr.obj errorsys.obj \
  107.                 rprt.obj scan.obj
  108.                 blinker @$*.lnk
  109.                 
  110. # dependencies
  111. main.obj:       main.clp
  112.  
  113. main.clp:       main1.prg main2.prg main3.prg
  114.  
  115. cust.obj:       cust.prg
  116.  
  117. addr.obj:       addr.prg
  118.  
  119. errorsys.obj:   errorsys.prg
  120.  
  121. rprt.obj:       rprt.prg
  122.  
  123. scan.obj:       scan.prg
  124.  
  125. # EOF: makefile
  126.  
  127. Note that 3PMAKE prefers a downward dependency list with the topmost 
  128. dependencies having priority and the first being the primary condition of the 
  129. make.
  130.  
  131. 3PMAKE is now provided with the 3PX library for Clipper and CPE v5.00. 3PMAKE
  132. will be undergoing constant enhancement and improvement. If you are using 
  133. 3PMAKE and do not own 3PX or CPE, then you should register your copy of 3PMAKE
  134. with 3P Software, Inc. by filling out the registration form and sending it with
  135. your registration fee to:
  136.  
  137.         3P Software, Inc
  138.         1827 Kendrick Street
  139.         Philadelphia, PA 19152-1829
  140.         
  141.  
  142. --------------------------------------------------------------------------------
  143. REGISTRATION FORM FOR 3PMAKE v1.00
  144.  
  145.  
  146. Name: ____________________________________________________________
  147.  
  148. Address: ____________________________________________________________
  149.  
  150.          ____________________________________________________________
  151.          
  152.          ____________________________________________________________
  153.          
  154. Phone: ________________________________________ optional
  155.  
  156.  
  157. Where did you receive 3PMAKE?
  158.  
  159. ______________________________________________________________________________
  160.  
  161.  
  162. Comments:
  163.  
  164. ______________________________________________________________________________
  165.  
  166. ______________________________________________________________________________
  167.  
  168.  
  169. Registration Fee:       $10.00            Amount Enclosed: _______________
  170.  
  171. Checks or money orders should be payable to: 3P SOFTWARE, INC.
  172.  
  173.