home *** CD-ROM | disk | FTP | other *** search
/ Current Shareware 1994 January / SHAR194.ISO / networks / tcpv21cc.zip / TCPCSD.BAT < prev    next >
DOS Batch File  |  1993-08-30  |  6KB  |  237 lines

  1. @ECHO OFF
  2. SET CSDTYPE=NETBIOS
  3. SET CSDNO=NETBIOS 2.1.0.2
  4. rem
  5. rem  Licensed Materials - Property of IBM
  6. rem
  7. rem  (C) Copyright IBM Corp. 1991,1993. All rights reserved.
  8. rem  US Government Users Restricted Rights - Use, duplication or
  9. rem  disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  10. rem
  11. rem
  12. rem  Written by:  William T. Nelson
  13. rem               IBM Corporation
  14. rem               March 23, 1991
  15. rem
  16. rem  Updated by:  Lee Cole
  17. rem               IBM Corporation
  18. rem               Feb. 15, 1993
  19. rem
  20.  
  21. set DSK=%1
  22. if %1.==. SET DSK=A:\
  23. if not exist %DSK%lpt1 goto slash
  24. goto noslash
  25. :slash
  26. SET DSK=%DSK%\
  27. if not exist %DSK%lpt1 goto help
  28. :MOUNT
  29. if not exist %DSK%READ.ME goto REQUEST
  30. goto CONTINUE
  31. :REQUEST
  32. echo Please INSERT %CSDTYPE% CSD DISKETTE 1
  33. pause
  34. goto MOUNT
  35. :noslash
  36. if not exist %DSK%%CSDTYPE%CSD.DOC goto REQUEST
  37. if exist %DSK%ASK.EXE goto CONTINUE
  38. :help
  39.  
  40. cls
  41. echo.
  42. echo IBM TCP/IP for DOS Version 2.1
  43. echo Corrective Service Diskette
  44. echo Feburary 15, 1993
  45. echo.
  46. echo.
  47. echo If you are running this program from anything other than diskette
  48. echo drive A, you must enter:
  49. echo.
  50. echo           %0 [drive letter][\path]
  51. echo.
  52. echo to override diskette drive A (i.e. %0 B).
  53. echo.
  54. echo.
  55. echo The drive:\path %DSK% is invalid.  Correct and try again.
  56. goto QUIT
  57.  
  58. SET D=B
  59. if "%D%"=="" goto QUIT
  60. if EXIST %DSK%ASK.EXE SET D=
  61. if "%D%"=="B" goto QUIT
  62.  
  63. :CONTINUE
  64. %DSK%TCPCHKV %CSDNO%
  65. if errorlevel 1 goto  CHKBASE
  66.  
  67. echo.
  68. echo.
  69. echo.
  70. echo.
  71. echo This CSD has already been installed.  If you install it again
  72. echo you may backlevel your system.
  73. echo Do you want the Corrective Service to be applied again? (Y, N or Q):
  74. %DSK%ask Yy Nn Qq
  75. if ERRORLEVEL 3 goto QUIT
  76. if ERRORLEVEL 2 goto QUIT
  77.  
  78. :CHKBASE
  79. if %tcpbase%.==. set tcpbase=%ETC%\..
  80.  
  81. echo.
  82. echo.
  83. echo.
  84. echo.
  85. echo Your TCPBASE environment variable is set to:  %TCPBASE%
  86. echo.
  87. echo Do you want the Corrective Service to be applied to the TCP/IP for DOS
  88. echo installed at %TCPBASE% (Y, N or Q):
  89. %DSK%ask Yy Nn Qq
  90. if ERRORLEVEL 3 goto QUIT
  91. if ERRORLEVEL 2 goto BADBASE
  92. if ERRORLEVEL 1 goto CHKDECOMP
  93. echo.
  94. echo.
  95. echo ERROR:  Your entry must be Y(es), N(o) or Q(uit)
  96. echo.
  97. goto CHKBASE
  98.  
  99.  
  100. :BADBASE
  101.  
  102. echo.
  103. echo.
  104. echo The environment variable TCPBASE must be set inorder for this CSD to
  105. echo install correctly.  TCPBASE points to the base directory for the
  106. echo TCP/IP for DOS product.  Please set this variable by entering:
  107. echo.
  108. echo        SET TCPBASE=[base directory]
  109. echo.
  110. echo For example:
  111. echo.
  112. echo        SET TCPBASE=C:\TCPDOS
  113. echo.
  114. goto QUIT
  115.  
  116.  
  117. :CHKDECOMP
  118.  
  119. IF EXIST %TCPBASE%\BIN\DECOMP.EXE goto DOCSDSECT
  120. echo.
  121. echo.
  122. echo ERROR:
  123. echo.
  124. echo You must have installed the IBM TCP/IP for DOS Product in the directory
  125. echo indicated by the environment variable TCPBASE.  This BIN subdirectory
  126. echo should contain the file DECOMP.EXE.  If you have deleted this file, you
  127. echo must reinstall the TCP/IP for DOS before this CSD can be applied.
  128. echo.
  129. goto QUIT
  130.  
  131. :DOCSDSECT
  132. cls
  133.  
  134. :DOCSD
  135.  
  136. echo.
  137. echo.
  138. echo This CSD replaces several files within the %TCPBASE%\BIN and
  139. echo %TCPBASE%\ETC directories.  If you wish, a backup copy of each
  140. echo original file will be saved under under a different name.  The backup
  141. echo file will be created by changing the last character in each file type
  142. echo to an "@" (i.e. TELNET.EXE will be saved as TELNET.EX@).
  143. echo.
  144. echo Please note that only one backup of each file will be saved and if
  145. echo you have any backup copies that you wish to retain, you must back these
  146. echo files up by hand.
  147. echo.
  148. echo WARNING:  To perform this backup, you must have at lease 1.7MB free
  149. echo           (1,700,000 bytes) on the disk drive that contains %TCPBASE%.
  150. echo           There is no error checking to verify if you have enough free
  151. echo           disk space so, YOU MUST ASSURE THAT YOU HAVE ENOUGH ROOM TO
  152. echo           BACKUP THE FILES.
  153. echo.
  154. echo Do you want the previous versions to be saved (Y, N or Q):
  155. %DSK%PUSHD %TCPBASE%
  156. if errorlevel 1 goto QUIT
  157.  
  158. %DSK%ask Yy Nn Qq
  159. if ERRORLEVEL 3 goto QUIT
  160. if ERRORLEVEL 2 goto REALLYDOCSD
  161. if ERRORLEVEL 1 goto COPYFILES
  162. echo.
  163. echo.
  164. echo ERROR:  Your entry must be Y(es), N(o) or Q(uit)
  165. echo.
  166. goto DOCSD
  167.  
  168. :COPYFILES
  169.  
  170. cls
  171.  
  172. echo.
  173. echo.
  174. echo PLEASE WAIT WHILE THE ORIGINAL FILES ARE BEING BACKED UP....
  175. echo.
  176. echo.
  177.  
  178. COPY %ETC%\..\BIN\COMPRESS.EXE CP$.EXE>nul
  179.  
  180. echo .... NBTCP.EXE     -- NBTCP.EX@
  181. if exist BIN\NBTCP.EXE CP$ BIN\NBTCP.EXE BIN\NBTCP.EX@ >nul
  182. echo .... NBDOWN.EXE    -- NBDOWN.EX@
  183. if exist BIN\NBDOWN.EXE CP$ BIN\NBDOWN.EXE BIN\NBDOWN.EX@ >nul
  184. echo .... MAPNAME.EXE   -- MAPNAME.EX@
  185. if exist BIN\MAPNAME.EXE CP$ BIN\MAPNAME.EXE BIN\MAPNAME.EX@ >nul
  186.  
  187. if exist DOC\READ.ME CP$ DOC\READ.ME DOC\READ.ME@ >nul
  188. ERASE CP$.EXE>nul
  189. :REALLYDOCSD
  190.  
  191. cls
  192.  
  193. echo.
  194. echo.
  195. echo PLEASE WAIT WHILE THE CSD IS BEING APPLIED....
  196. echo.
  197. echo.
  198.  
  199. @echo off
  200. COPY %ETC%\..\BIN\DECOMP.EXE DC$.EXE>nul
  201. echo ....%CSDTYPE%CSD.DOC
  202. COPY %DSK%%CSDTYPE%CSD.DOC DOC\%CSDTYPE%CSD.DOC >nul
  203.  
  204. echo .... NBTCP.EX#     -- NBTCP.EXE
  205. DC$ %DSK%NBTCP.EX#      BIN\NBTCP.EXE >nul
  206. echo .... NBDOWN.EX#    -- NBDOWN.EXE
  207. DC$ %DSK%NBDOWN.EX#     BIN\NBDOWN.EXE >nul
  208. echo .... MAPNAME.EX#   -- MAPNAME.EXE
  209. DC$ %DSK%MAPNAME.EX#    BIN\MAPNAME.EXE >nul
  210.  
  211. ERASE DC$.EXE>nul
  212.  
  213. echo.
  214. echo.
  215. cls
  216. echo.
  217. echo The Corrective Service has been installed correctly...
  218. echo.
  219. if not exist DOC\%CSDTYPE%CSD.DOC goto nocsddoc
  220. echo Please look at the file DOC\%CSDTYPE%CSD.DOC to see what has been
  221. echo fixed in this CSD.
  222. echo You should also examine DOC\SLIP.DOC, DOC\TFTP.DOC, and DOC\FTP.DOC
  223. echo for changes since the manuals were printed.
  224. :nocsddoc
  225. echo.
  226. echo.
  227.  
  228. :installed
  229. %DSK%TCPSETV %CSDNO%
  230. call POPD$
  231. ERASE %TCPBASE%\POPD$.BAT>nul
  232. echo CSD %CSDNO% is installed.
  233.  
  234. :QUIT
  235. SET DSK=
  236. SET D=
  237.