home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / xwplascr.zip / XWPL0208.ZIP / tools / repclass / makefile next >
Makefile  |  2002-01-19  |  3KB  |  87 lines

  1. #
  2. # makefile:
  3. #       makefile for TOOLS\RECLASS directory.
  4. #       For use with IBM NMAKE, which comes with the IBM compilers,
  5. #       the Developer's Toolkit, and the DDK.
  6. #
  7. #       All the makefiles have been restructured with V0.9.0.
  8. #
  9. #       Called from:    main makefile
  10. #
  11. #       Input:          files in this directory
  12. #
  13. #       Output:         repclass.exe, copied to modules directory.
  14. #
  15. #       Edit "setup.in" to set up the make process.
  16. #
  17.  
  18. # Say hello to yourself.
  19. !if [@echo +++++ Entering $(MAKEDIR)]
  20. !endif
  21.  
  22. # include setup (compiler options etc.)
  23. !include ..\..\setup.in
  24.  
  25. # FIXED MACROS
  26. # ------------
  27. #
  28. # You probably need not change the following.
  29. #
  30.  
  31. # Define the suffixes for files which NMAKE will work on.
  32. # .SUFFIXES is a reserved NMAKE keyword ("pseudotarget") for
  33. # defining file extensions that NMAKE will recognize.
  34. .SUFFIXES: .c .obj .dll .idl .h .ih .rc .res
  35.  
  36. # OUTPUTDIR specifies the directory where all the output .OBJ
  37. # files will be created in.
  38. OUTPUTDIR = $(XWP_OUTPUT_ROOT)\exe_st
  39. !if [@echo       OUTPUTDIR is $(OUTPUTDIR)]
  40. !endif
  41. MODULESDIR = $(XWP_OUTPUT_ROOT)\modules
  42.  
  43. # create output directory
  44. !if [@md ..\..\bin 2> NUL]
  45. !endif
  46. !if [@md $(OUTPUTDIR) 2> NUL]
  47. !endif
  48. !if [@md $(MODULESDIR) 2> NUL]
  49. !endif
  50.  
  51. # The main target:
  52. # If we're called from the main makefile, MAINMAKERUNNING is defined,
  53. # and we'll set $(OBJS) as our targets (which will go on).
  54. # Otherwise, we call the main makefile, which will again call ourselves later.
  55. all: $(MODULESDIR)\repclass.exe
  56.     @echo ----- Leaving $(MAKEDIR)
  57.  
  58. # main include path
  59. INC = ..\..\include
  60. # helpers include path
  61. HLPINC = $(HELPERS_BASE)\include\helpers
  62. # our own corresponding include path
  63. MYOWNINC = $(INC)\hook
  64.  
  65. # 1) files in this directory
  66. .c.{$(OUTPUTDIR)}.obj:
  67.         @ echo Compiling $(@B).c:
  68. !ifndef PRECH
  69. # precompiled headers disabled:
  70.         $(CC_EXE_ST) /Fo$(OUTPUTDIR)\$(@B).obj $(@B).c
  71. !else
  72.         $(CC_EXE_ST) /fi"$(PRECH)\$(@B).pch" /si"$(PRECH)\$(@B).pch" -I$(INC) /Fo$(OUTPUTDIR)\$(@B).obj $(@B).c
  73. !endif
  74.  
  75. #
  76. # Now define dependencies for all our .obj files by telling NMAKE
  77. # which .OBJ file depends on what. For each .obj we define what files
  78. # will enforce a recompilation when they've been changed.
  79. #
  80.  
  81. # .OBJs for executables in this directory
  82. $(OUTPUTDIR)\repclass.obj: $(@B).c
  83.  
  84. # "repclass" executable
  85. $(MODULESDIR)\repclass.exe: $(OUTPUTDIR)\$(@B).obj makefile
  86.           $(LINK) /OUT:$(MODULESDIR)\$(@B).exe /PMTYPE:VIO $(OUTPUTDIR)\$(@B).obj
  87.