home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c004 / 2.ddi / TC / MAKEAPP.BAT < prev    next >
Encoding:
DOS Batch File  |  1989-04-18  |  3.2 KB  |  116 lines

  1. echo off
  2.  
  3. rem check syntax
  4. if XX%1==XX goto usage
  5.  
  6. if XX%2==XX goto usage
  7. if  %2==*   goto df_tcd_action
  8. echo ---------- Turbo c directory is -- %2 --
  9. if not exist %2\*.* goto bad_name
  10. echo TCDIR=%2> mct.mac
  11. goto chk_3
  12.  
  13. :df_tcd_action
  14. echo .
  15. echo ++++++++++ You have to specify the Turbo C directory path 
  16. goto usage 
  17.  
  18. :chk_3
  19. if XX%3==XX goto df_rtd_msg
  20. if  %3==*   goto df_rtd_msg
  21. echo ---------- r-tree directory is -- %3 --
  22. if not exist %3\*.* goto bad_name
  23. echo RTREE=%3>> mct.mac
  24. goto chk_4
  25.  
  26. :df_rtd_msg
  27. echo .
  28. echo Default r-tree directory in the 'make' files will be used
  29.  
  30. :chk_4
  31. if XX%4==XX goto tc15msg
  32. echo .
  33. echo ---------------------------------------------------------
  34. echo This installation procedure assumes Turbo C 1.0 is in use
  35. echo ---------------------------------------------------------
  36. echo .
  37. echo TC10=x>> mct.mac
  38. goto install
  39.  
  40. :tc15msg
  41. echo .
  42. echo ---------------------------------------------------------
  43. echo This installation procedure assumes Turbo C 1.5 or later
  44. echo ---------------------------------------------------------
  45. echo .
  46. goto install
  47.  
  48. :bad_name
  49. echo ++++++++++ And I can't find it!!!
  50. echo .
  51. goto usage
  52.  
  53. :install
  54. pause ===== Now go to make the libraries =====
  55.  
  56. if %1==S goto small
  57. if %1==s goto small
  58. if %1==C goto compact
  59. if %1==c goto compact
  60. if %1==M goto medium
  61. if %1==m goto medium
  62. if %1==L goto large
  63. if %1==l goto large
  64.  
  65. echo ************
  66. echo SYNTAX ERROR
  67. echo ************
  68.  
  69. :usage
  70. echo . Program to build c-tree library, utilities, and sample programs
  71. echo .                      +---------+------+-------+--------+-----+  
  72. echo "                      |         | S or | Turbo |        |     |       "
  73. echo "                      | MAKEAPP | C or |   C   | r-tree | [x] |       "
  74. echo "                      |         | M or | path- | path   |     |       "
  75. echo "                      |         | L    | name  |        |     |       "
  76. echo .                      +---------+------+-------+--------+-----+  
  77. echo .              examples:
  78. echo .                        MAKEAPP   L    e:\turboc  e:\rt11d2   x
  79. echo .                        MAKEAPP   L    e:\tc
  80. echo .
  81. echo . where S = small, C = compact, M = medium, L = large  memory model
  82. echo .       Turbo C path - if Turbo C is not in the same drive, add drive name
  83. echo .       r-tree path  - r-tree main directory
  84. echo .       x            - optional.  If x is NOT entered, Turbo C v1.5 or later
  85. echo .                      will be used, otherwise v1.0 setting will be selected.
  86. echo .       *            - ===  signifies default value will be used  ===
  87. echo .
  88. echo .......................................................................
  89. echo          The libary and object files are created in directory nAPP
  90. echo                       (eg. LAPP for large model)
  91. echo .......................................................................
  92. goto done
  93.  
  94. :small
  95. if not exist SAPP\*.* md SAPP
  96. %2\make -DMM=s -fmakeapp.mak
  97. goto done
  98.  
  99. :compact
  100. if not exist CAPP\*.* md CAPP
  101. %2\make -DMM=c -fmakeapp.mak
  102. goto done
  103.  
  104. :medium
  105. if not exist MAPP\*.* md MAPP
  106. %2\make -DMM=m -fmakeapp.mak
  107. goto done
  108.  
  109. :large
  110. if not exist LAPP\*.* md LAPP
  111. %2\make -DMM=l -fmakeapp.mak
  112. goto done
  113.  
  114. :done
  115. REM if exist mct.mac del mct.mac
  116.