home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / sdktools / winnt / walker / makefile next >
Encoding:
Makefile  |  1997-10-15  |  2.3 KB  |  95 lines

  1. # Nmake macros for building Windows 32-Bit apps
  2.  
  3. TARGETOS=WINNT
  4. SEHMAP=TRUE
  5.  
  6. !include <ntwin32.mak>
  7.  
  8. !if "$(CPU)" == "i386"
  9. cflags = $(cflags) -D_CRTAPI1=_cdecl -D_CRTAPI2=_cdecl
  10. !else
  11. cflags = $(cflags) -D_CRTAPI1= -D_CRTAPI2=
  12. !endif
  13.  
  14. all: pwalk.exe
  15.  
  16. # object files for pwalk.exe
  17. pstat.obj : pstat.c pwalk.h
  18.     $(cc) $(cflags) $(cvars) $(cdebug) pstat.c
  19.  
  20. pdebug.obj : pdebug.c pwalk.h
  21.     $(cc) $(cflags) $(cvars) $(cdebug) pdebug.c
  22.  
  23. pwalkio.obj : pwalkio.c pwalk.h
  24.     $(cc) $(cflags) $(cvars) $(cdebug) pwalkio.c
  25.  
  26. pwalk.obj : pwalk.c pwalk.h
  27.     $(cc) $(cflags) $(cvars) $(cdebug) pwalk.c
  28.  
  29. pview.obj : pview.c pwalk.h
  30.     $(cc) $(cflags) $(cvars) $(cdebug) pview.c
  31.  
  32.  
  33. # object files for pefile.dll
  34. pefile.obj : pefile.c pefile.h
  35.     $(cc) $(cflags) $(cvars) $(cdebug) pefile.c
  36.  
  37.  
  38. # object files for probe.dll
  39. probe.obj: probe.c pwalk.h
  40.     $(cc) $(cflags) $(cvarsdll) $(cdebug) probe.c
  41.  
  42.  
  43. # resrouces for pwalk.exe
  44. pwalk.res: pwalk.rc pwalk.h pwalk.ico
  45.     rc -r pwalk.rc
  46.  
  47. # resrouces for probe.dll
  48. probe.res: probe.rc pwalk.h
  49.     rc -r probe.rc
  50.  
  51. # resrouces for pefile.dll
  52. pefile.res: pefile.rc pefile.h
  53.     rc -r pefile.rc
  54.  
  55.  
  56. # export library for probe.dll
  57. probe.lib: probe.obj probe.def probe.res
  58.     $(implib) -machine:$(CPU)     \
  59.     -def:probe.def         \
  60.     probe.obj             \
  61.     -out:probe.lib
  62.  
  63.  
  64. # export library for pefile.dll
  65. pefile.lib: pefile.obj pefile.def pefile.res
  66.     $(implib) -machine:$(CPU)     \
  67.     -def:pefile.def         \
  68.     pefile.obj             \
  69.     -out:pefile.lib
  70.  
  71.  
  72. # link probe.dll
  73. probe.dll: probe.obj probe.def probe.lib pefile.lib pefile.dll
  74.     $(link) $(linkdebug) $(dlllflags)     \
  75.     -base:0x1C000000         \
  76.     -out:probe.dll         \
  77.     probe.exp pefile.lib probe.obj probe.res $(guilibsdll)
  78.  
  79.  
  80. # link pefile.dll
  81. pefile.dll: pefile.obj pefile.def pefile.lib
  82.     $(link) $(linkdebug) $(dlllflags)     \
  83.     -base:0x1D000000         \
  84.     -out:pefile.dll         \
  85.     pefile.exp pefile.obj pefile.res $(guilibsdll)
  86.  
  87.  
  88. # link pwalk.exe
  89. pwalk.exe: pwalk.res pwalk.obj probe.lib probe.dll pefile.lib pefile.dll \
  90.        pwalkio.obj pdebug.obj pstat.obj pview.obj
  91.     $(link) $(linkdebug) $(lflags)     \
  92.     $(guiflags)          \
  93.     -out:pwalk.exe         \
  94.     pwalk.obj pdebug.obj probe.lib pefile.lib pstat.obj pwalkio.obj pview.obj pwalk.res $(guilibs)
  95.