home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / BC_502 / 32QUERY.PAK / MAKEFILE < prev    next >
Encoding:
Text File  |  1997-05-06  |  2.3 KB  |  113 lines

  1. .autodepend
  2. .swap
  3.  
  4. # (C) Copyright 1996 by Borland International
  5. #
  6. # Query32 MAKEFILE for Borland C++ v5.x.
  7. #
  8. #     Use 'make -DBCROOT=<compiler root directory>' to specify
  9. #       where the compiler resides if it is not in the default
  10. #       c:\bc5 directory.
  11. #
  12. #     Set -DINCLUDE and -DLIB to specify the compiler include
  13. #       and lib directories.
  14. #
  15. #     Set -DIDAPIINC and -DIDAPILIB to the IDAPI INCLUDE and
  16. #       IDAPI LIB directories if you did not install to the
  17. #       default directory structure.
  18. #
  19.  
  20. # Set the IDAPI INCLUDE and LIB directory
  21. !ifndef IDAPIINC
  22. IDAPIINC = ..\..\include
  23. !endif
  24.  
  25. !ifndef IDAPILIB
  26. IDAPILIB = ..\..\lib
  27. !endif
  28.  
  29. # BCROOT is only used if either the INCLUDE or LIB
  30. # environment variable is not used.
  31. !ifndef BCROOT
  32. BCROOT = \bc5
  33. !endif
  34.  
  35. # Check if the INCLUDE environment variable exists
  36. # If not, set it
  37. !ifndef INCLUDE
  38. INCLUDE = $(BCROOT)\include
  39. !endif
  40.  
  41. # Check if the LIB environment variable exists
  42. # If not, set it
  43. !ifndef LIB
  44. LIB = $(BCROOT)\lib
  45. !endif
  46.  
  47. # Set the compiler, linker, and Resource Compiler, and libraries
  48. CC       = bcc32
  49. TLINK    = tlink32
  50. BRC      = brc32
  51. C0OBJ    = c0w32.obj
  52. LIBS     = idapi32.lib import32.lib ctl3d32.lib cw32.lib
  53.  
  54. # Set the full INCLUDE and LIB search paths
  55. INCLUDE = $(IDAPIINC);$(INCLUDE)
  56. LIB     = $(IDAPILIB);$(LIB)
  57.  
  58. # Set the Compiler, Linker, and Resource Compiler Options
  59. BCCOPT   = -w -d -c -WE -R -v -vi -X- -H=query32.csm -D_RTLDLL;STRICT;
  60. BCCWARNS = -w-eff -w-aus -w-stu -w-par -w-sig
  61. TLINKOPT = -L$(LIB) -Tpe -aa -c -s
  62. RCOPT    = -I$(INCLUDE) -31 -w32 -r
  63. RSPFILE  = BCC32.RSP
  64.  
  65. # Dependency List
  66. DEPEND32 = \
  67.    engine.obj\
  68.    query.obj\
  69.    display.obj\
  70.    macro.obj\
  71.    qry_data.obj\
  72.    query.res
  73.  
  74. # Implicit Rules
  75. .c.obj:
  76.     $(CC) @$(RSPFILE) @&&|
  77. | -I$(INCLUDE) $<
  78.  
  79. {.}.rc.res:
  80.     $(BRC) $(RCOPT) -FO$@ $.
  81.  
  82. # Explicit rules
  83.  
  84. all: bcc32.rsp query32.exe
  85.  
  86. bcc32.rsp: makefile
  87.     echo $(BCCOPT) >bcc32.rsp
  88.     echo $(BCCWARNS) >>bcc32.rsp
  89.  
  90. query32.exe: bcc32.rsp $(DEPEND32)
  91.   $(TLINK)   @&&|
  92.  /v $(TLINKOPT) +
  93. $(C0OBJ)+
  94. engine.obj+
  95. query.obj+
  96. display.obj+
  97. macro.obj+
  98. qry_data.obj
  99. $<,$*
  100. $(LIBS)
  101. query.def
  102. query.res
  103. |
  104.     $(BRC) query.res $<
  105.  
  106. clean:
  107.     del *.obj
  108.     del *.res
  109.     del *.csm
  110.     del *.exe
  111.     del *.map
  112.     del *.rsp
  113.