home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c031 / 11.ddi / MFC / SAMPLES / TUTORIAL / PHBOOK.$ / phbook
Encoding:
Text File  |  1992-03-08  |  1.7 KB  |  68 lines

  1. # Makefile : Builds the PHONE BOOK application
  2. #
  3. # Usage:     NMAKE PHBOOK (build PHBOOK.EXE)
  4. #    or:     NMAKE -f phbook clean  (erase all compiled files)
  5. #
  6. # option:    DEBUG=[0|1]  (DEBUG not defined is equivalent to DEBUG=0)
  7.  
  8. # This is a part of the Microsoft Foundation Classes C++ library.
  9. # Copyright (C) 1992 Microsoft Corporation
  10. # All rights reserved.
  11. #
  12. # This source code is only intended as a supplement to the
  13. # Microsoft Foundation Classes Reference and Microsoft
  14. # QuickHelp documentation provided with the library.
  15. # See these sources for detailed information regarding the
  16. # Microsoft Foundation Classes product.
  17.  
  18. CPPFLAGS=  /DWINVER=0x0300 /AM /W3 /Zp /GA /GEs /G2
  19. LINKFLAGS=/NOD /ONERROR:NOEXE
  20. DIR=WIN
  21.  
  22. !if "$(DEBUG)"=="1"
  23. CPPFLAGS=/D_DEBUG $(CPPFLAGS) /Od /Zi /f /Fo$*.OBJ
  24. LINKFLAGS=$(LINKFLAGS) /COD
  25. LIBS=mafxcwd libw mlibcew commdlg
  26. !else
  27. CPPFLAGS=$(CPPFLAGS) /Oselg /Gs /Fo$*.OBJ
  28. LINKFLAGS=$(LINKFLAGS)  
  29. LIBS=mafxcw libw mlibcew commdlg
  30. !endif
  31.  
  32. .cpp{$(DIR)}.obj:
  33.     $(CPP) /c $(CPPFLAGS) $<
  34.  
  35. .rc{$(DIR)}.res:
  36.     $(RC) $(RFLAGS) /r /fo $@ $<
  37.  
  38. phbook.exe : $(DIR)\phbook.exe
  39.     copy $** $@
  40.  
  41. $(DIR)\phbook.exe: $(DIR) $(DIR)\person.obj $(DIR)\view.obj \
  42.                    $(DIR)\database.obj phbook.def $(DIR)\phbook.res
  43.     link $(LINKFLAGS) @<<
  44. $(DIR)\person $(DIR)\view $(DIR)\database,
  45. $@,
  46. NUL,
  47. $(LIBS),
  48. phbook.def;
  49. <<
  50.     rc -30 /k /t $(DIR)\phbook.res
  51.  
  52. $(DIR):
  53.     @IF NOT EXIST $(DIR)\*.* MD $(DIR)
  54.  
  55.  
  56. person.obj : person.h
  57. database.h : person.h
  58. database.obj : database.h
  59. view.obj : view.h database.h resource.h
  60. phbook.res : resource.h phbook.ico phbook.rc phbook.dlg
  61.  
  62. clean:
  63.     -del $(DIR)\person.obj
  64.     -del $(DIR)\view.obj
  65.     -del $(DIR)\phbook.res
  66.     -del $(DIR)\database.obj
  67.     -del $(DIR)\phbook.exe
  68.