本书分为四大篇。第一篇提出学习MFC程序设计之前的必要基础
源代码在线查看: text.mak
# Microsoft Developer Studio Generated NMAKE File, Format Version 4.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Application" 0x0101
!IF "$(CFG)" == ""
CFG=Text - Win32 Debug
!MESSAGE No configuration specified. Defaulting to Text - Win32 Debug.
!ENDIF
!IF "$(CFG)" != "Text - Win32 Release" && "$(CFG)" != "Text - Win32 Debug"
!MESSAGE Invalid configuration "$(CFG)" specified.
!MESSAGE You can specify a configuration when running NMAKE on this makefile
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "Text.mak" CFG="Text - Win32 Debug"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "Text - Win32 Release" (based on "Win32 (x86) Application")
!MESSAGE "Text - Win32 Debug" (based on "Win32 (x86) Application")
!MESSAGE
!ERROR An invalid configuration is specified.
!ENDIF
!IF "$(OS)" == "Windows_NT"
NULL=
!ELSE
NULL=nul
!ENDIF
################################################################################
# Begin Project
MTL=mktyplib.exe
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "Text - Win32 Release"
# PROP BASE Use_MFC 6
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 6
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
# PROP Intermediate_Dir "Release"
# PROP Target_Dir ""
OUTDIR=.\Release
INTDIR=.\Release
ALL : "$(OUTDIR)\Text.exe"
CLEAN :
-@erase ".\Release\Text.exe"
-@erase ".\Release\Text.obj"
-@erase ".\Release\Text.pch"
-@erase ".\Release\StdAfx.obj"
-@erase ".\Release\MainFrm.obj"
-@erase ".\Release\ChildFrm.obj"
-@erase ".\Release\TextDoc.obj"
-@erase ".\Release\TextView.obj"
-@erase ".\Release\Text.res"
-@erase ".\Release\HexView.obj"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_AFXDLL" /D "_MBCS" /Yu"stdafx.h" /c
# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_AFXDLL" /D "_MBCS" /Yu"stdafx.h" /c
CPP_PROJ=/nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D\
"_AFXDLL" /D "_MBCS" /Fp"$(INTDIR)/Text.pch" /Yu"stdafx.h" /Fo"$(INTDIR)/" /c
CPP_OBJS=.\Release/
CPP_SBRS=
# ADD BASE MTL /nologo /D "NDEBUG" /win32
# ADD MTL /nologo /D "NDEBUG" /win32
MTL_PROJ=/nologo /D "NDEBUG" /win32
# ADD BASE RSC /l 0x404 /d "NDEBUG" /d "_AFXDLL"
# ADD RSC /l 0x404 /d "NDEBUG" /d "_AFXDLL"
RSC_PROJ=/l 0x404 /fo"$(INTDIR)/Text.res" /d "NDEBUG" /d "_AFXDLL"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
BSC32_FLAGS=/nologo /o"$(OUTDIR)/Text.bsc"
BSC32_SBRS=
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:windows /machine:I386
# ADD LINK32 /nologo /subsystem:windows /machine:I386
LINK32_FLAGS=/nologo /subsystem:windows /incremental:no\
/pdb:"$(OUTDIR)/Text.pdb" /machine:I386 /out:"$(OUTDIR)/Text.exe"
LINK32_OBJS= \
"$(INTDIR)/Text.obj" \
"$(INTDIR)/StdAfx.obj" \
"$(INTDIR)/MainFrm.obj" \
"$(INTDIR)/ChildFrm.obj" \
"$(INTDIR)/TextDoc.obj" \
"$(INTDIR)/TextView.obj" \
"$(INTDIR)/HexView.obj" \
"$(INTDIR)/Text.res"
"$(OUTDIR)\Text.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @ $(LINK32_FLAGS) $(LINK32_OBJS)
!ELSEIF "$(CFG)" == "Text - Win32 Debug"
# PROP BASE Use_MFC 6
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 6
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "Debug"
# PROP Intermediate_Dir "Debug"
# PROP Target_Dir ""
OUTDIR=.\Debug
INTDIR=.\Debug
ALL : "$(OUTDIR)\Text.exe"
CLEAN :
-@erase ".\Debug\Text.exe"
-@erase ".\Debug\Text.obj"
-@erase ".\Debug\Text.pch"
-@erase ".\Debug\StdAfx.obj"
-@erase ".\Debug\MainFrm.obj"
-@erase ".\Debug\ChildFrm.obj"
-@erase ".\Debug\TextDoc.obj"
-@erase ".\Debug\TextView.obj"
-@erase ".\Debug\Text.res"
-@erase ".\Debug\HexView.obj"
-@erase ".\Debug\Text.ilk"
-@erase ".\Debug\Text.pdb"
-@erase ".\Debug\vc40.pdb"
-@erase ".\Debug\vc40.idb"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_AFXDLL" /D "_MBCS" /Yu"stdafx.h" /c
# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_AFXDLL" /D "_MBCS" /Yu"stdafx.h" /c
CPP_PROJ=/nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS"\
/D "_AFXDLL" /D "_MBCS" /Fp"$(INTDIR)/Text.pch" /Yu"stdafx.h" /Fo"$(INTDIR)/"\
/Fd"$(INTDIR)/" /c
CPP_OBJS=.\Debug/
CPP_SBRS=
# ADD BASE MTL /nologo /D "_DEBUG" /win32
# ADD MTL /nologo /D "_DEBUG" /win32
MTL_PROJ=/nologo /D "_DEBUG" /win32
# ADD BASE RSC /l 0x404 /d "_DEBUG" /d "_AFXDLL"
# ADD RSC /l 0x404 /d "_DEBUG" /d "_AFXDLL"
RSC_PROJ=/l 0x404 /fo"$(INTDIR)/Text.res" /d "_DEBUG" /d "_AFXDLL"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
BSC32_FLAGS=/nologo /o"$(OUTDIR)/Text.bsc"
BSC32_SBRS=
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:windows /debug /machine:I386
# ADD LINK32 /nologo /subsystem:windows /debug /machine:I386
LINK32_FLAGS=/nologo /subsystem:windows /incremental:yes\
/pdb:"$(OUTDIR)/Text.pdb" /debug /machine:I386 /out:"$(OUTDIR)/Text.exe"
LINK32_OBJS= \
"$(INTDIR)/Text.obj" \
"$(INTDIR)/StdAfx.obj" \
"$(INTDIR)/MainFrm.obj" \
"$(INTDIR)/ChildFrm.obj" \
"$(INTDIR)/TextDoc.obj" \
"$(INTDIR)/TextView.obj" \
"$(INTDIR)/HexView.obj" \
"$(INTDIR)/Text.res"
"$(OUTDIR)\Text.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @ $(LINK32_FLAGS) $(LINK32_OBJS)
!ENDIF
.c{$(CPP_OBJS)}.obj:
$(CPP) $(CPP_PROJ) $<
.cpp{$(CPP_OBJS)}.obj:
$(CPP) $(CPP_PROJ) $<
.cxx{$(CPP_OBJS)}.obj:
$(CPP) $(CPP_PROJ) $<
.c{$(CPP_SBRS)}.sbr:
$(CPP) $(CPP_PROJ) $<
.cpp{$(CPP_SBRS)}.sbr:
$(CPP) $(CPP_PROJ) $<
.cxx{$(CPP_SBRS)}.sbr:
$(CPP) $(CPP_PROJ) $<
################################################################################
# Begin Target
# Name "Text - Win32 Release"
# Name "Text - Win32 Debug"
!IF "$(CFG)" == "Text - Win32 Release"
!ELSEIF "$(CFG)" == "Text - Win32 Debug"
!ENDIF
################################################################################
# Begin Source File
SOURCE=.\ReadMe.txt
!IF "$(CFG)" == "Text - Win32 Release"
!ELSEIF "$(CFG)" == "Text - Win32 Debug"
!ENDIF
# End Source File
################################################################################
# Begin Source File
SOURCE=.\Text.cpp
DEP_CPP_TEXT_=\
".\StdAfx.h"\
".\Text.h"\
".\MainFrm.h"\
".\ChildFrm.h"\
".\TextDoc.h"\
".\TextView.h"\
".\HexView.h"\
"$(INTDIR)\Text.obj" : $(SOURCE) $(DEP_CPP_TEXT_) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
################################################################################
# Begin Source File
SOURCE=.\StdAfx.cpp
DEP_CPP_STDAF=\
".\StdAfx.h"\
!IF "$(CFG)" == "Text - Win32 Release"
# ADD CPP /Yc"stdafx.h"
BuildCmds= \
$(CPP) /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D\
"_AFXDLL" /D "_MBCS" /Fp"$(INTDIR)/Text.pch" /Yc"stdafx.h" /Fo"$(INTDIR)/" /c\
$(SOURCE) \
"$(INTDIR)\StdAfx.obj" : $(SOURCE) $(DEP_CPP_STDAF) "$(INTDIR)"
$(BuildCmds)
"$(INTDIR)\Text.pch" : $(SOURCE) $(DEP_CPP_STDAF) "$(INTDIR)"
$(BuildCmds)
!ELSEIF "$(CFG)" == "Text - Win32 Debug"
# ADD CPP /Yc"stdafx.h"
BuildCmds= \
$(CPP) /nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS"\
/D "_AFXDLL" /D "_MBCS" /Fp"$(INTDIR)/Text.pch" /Yc"stdafx.h" /Fo"$(INTDIR)/"\
/Fd"$(INTDIR)/" /c $(SOURCE) \
"$(INTDIR)\StdAfx.obj" : $(SOURCE) $(DEP_CPP_STDAF) "$(INTDIR)"
$(BuildCmds)
"$(INTDIR)\Text.pch" : $(SOURCE) $(DEP_CPP_STDAF) "$(INTDIR)"
$(BuildCmds)
!ENDIF
# End Source File
################################################################################
# Begin Source File
SOURCE=.\MainFrm.cpp
DEP_CPP_MAINF=\
".\StdAfx.h"\
".\Text.h"\
".\MainFrm.h"\
"$(INTDIR)\MainFrm.obj" : $(SOURCE) $(DEP_CPP_MAINF) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
################################################################################
# Begin Source File
SOURCE=.\ChildFrm.cpp
DEP_CPP_CHILD=\
".\StdAfx.h"\
".\Text.h"\
".\ChildFrm.h"\
"$(INTDIR)\ChildFrm.obj" : $(SOURCE) $(DEP_CPP_CHILD) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
################################################################################
# Begin Source File
SOURCE=.\TextDoc.cpp
DEP_CPP_TEXTD=\
".\StdAfx.h"\
".\Text.h"\
".\TextDoc.h"\
"$(INTDIR)\TextDoc.obj" : $(SOURCE) $(DEP_CPP_TEXTD) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
################################################################################
# Begin Source File
SOURCE=.\TextView.cpp
DEP_CPP_TEXTV=\
".\StdAfx.h"\
".\Text.h"\
".\TextDoc.h"\
".\TextView.h"\
"$(INTDIR)\TextView.obj" : $(SOURCE) $(DEP_CPP_TEXTV) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
################################################################################
# Begin Source File
SOURCE=.\Text.rc
DEP_RSC_TEXT_R=\
".\res\Text.ico"\
".\res\TextDoc.ico"\
".\res\Toolbar.bmp"\
".\res\Text.rc2"\
"$(INTDIR)\Text.res" : $(SOURCE) $(DEP_RSC_TEXT_R) "$(INTDIR)"
$(RSC) $(RSC_PROJ) $(SOURCE)
# End Source File
################################################################################
# Begin Source File
SOURCE=.\HexView.cpp
DEP_CPP_HEXVI=\
".\StdAfx.h"\
".\Text.h"\
".\TextDoc.h"\
".\HexView.h"\
"$(INTDIR)\HexView.obj" : $(SOURCE) $(DEP_CPP_HEXVI) "$(INTDIR)"\
"$(INTDIR)\Text.pch"
# End Source File
# End Target
# End Project
################################################################################