home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / LMUTIL.ZIP / MAKEFILE < prev    next >
Text File  |  1991-03-19  |  1KB  |  87 lines

  1. #
  2. #** Template makefile for <X> application
  3.  
  4.  
  5. .SUFFIXES:
  6. .SUFFIXES:  .c .asm .obj .lst .def .lnk .lrf .exe .com
  7.  
  8. #   Definitions for assembler
  9.  
  10. ASM=masm
  11. AFLAGS=-Mx -t
  12. AINC=
  13.  
  14. #   Definitions for linker
  15.  
  16. LINK=link
  17. LFLAGS= /MAP
  18. LIBS=netapps.lib doslan.lib lan.lib
  19.  
  20. #   Definitions for C compiler
  21. #
  22.  
  23. CC=cl
  24. CADIT=
  25. CFLAGS= -Zi -AL -Lr -W3 -Od -Zep -nologo $(CADIT)
  26. CINC=
  27.  
  28. #   Rules for generating object and linker response and definition files
  29.  
  30. .asm.obj:
  31.     $(ASM) $(AFLAGS) $(AINC) -p $*.asm;
  32.  
  33. .asm.lst:
  34.     $(ASM) -l -n $(AFLAGS) $(AINC) $*.asm;
  35.  
  36. .c.obj:
  37.     $(CC) $(CFLAGS) -Fo$*.obj -dos $(CINC) -c $*.c
  38.  
  39. .c.exe:
  40.     $(CC) $(CFLAGS) -Fo$*.obj -dos $(CINC) $*.c -link $(LIBS)
  41.  
  42. .c.lst:
  43.     $(CC) $(CFLAGS) -Fc$*.cod -Fo$*.obj -dos $(CINC) -c $*.c
  44.  
  45. .lnk.lrf:
  46.     tresp $*.lnk $*.lrf
  47.  
  48. .exe.com:
  49.     reloc $*.exe $*.com
  50.  
  51. APPLIB=netapps.lib
  52. APPMODS=getsrv.obj
  53.  
  54. #
  55. #   Definitions for Librarian
  56.  
  57. LIB=lib
  58. LIBFLAGS=/NOLOGO
  59. #
  60. #   Delete Command
  61. DEL=del
  62.  
  63.  
  64. #   List of object files required
  65. OBJ=
  66.  
  67.  
  68. #   Rules for building executable go here
  69.  
  70. all: username.exe wksta.exe machname.exe ismember.exe rights.exe $(APPMODS)
  71.  
  72. username.exe: username.c $(APPMODS)
  73.  
  74. wksta.exe: wksta.c
  75.  
  76. machname.exe: machname.c
  77.  
  78. ismember.exe: ismember.c $(APPMODS)
  79.  
  80. rights.exe: rights.c $(APPMODS)
  81.  
  82. getsrv.obj: getsrv.c getsrv.h
  83.     $(CC) $(CFLAGS) -Fo$*.obj -dos $(CINC) -c $*.c
  84.         $(LIB) $(LIBFLAGS) $(APPLIB) -+ $*.obj;
  85.         $(DEL) *.bak
  86.         
  87.