home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 33 VDrivers / 33-VDrivers.zip / avanc14.zip / INSTALL.CMD < prev    next >
OS/2 REXX Batch file  |  1995-04-06  |  3KB  |  95 lines

  1. /* */
  2.  
  3. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  4. call SysLoadFuncs
  5. call SysCls
  6. PMMPEGPATH = DIRECTORY()
  7. parse upper arg srcdisk dstdisk .
  8.  
  9. parse source . . command .
  10.  
  11. path = FILESPEC( 'path', command )
  12.    path = substr( path, 1, length(path) - 1 )
  13.    path = translate( path )
  14. Drive = FILESPEC( 'drive', command )
  15.  
  16. '@ 'Drive
  17. '@cd 'path
  18.  
  19. bksrc.1 = 'MDOS\VSVGA.SYS'
  20. bksrc.2 = 'MDOS\VVGA.SYS'
  21. bksrc.3 = 'SVGA.EXE'
  22. bksrc.4 = 'SCREEN01.SYS'
  23. bksrc.5 = 'SCREEN02.SYS'
  24. bksrc.6 = 'DLL\IBMGPMI.DLL'
  25. bksrc.7 = 'DLL\IBMDEV32.DLL'
  26. bksrc.8 = 'DLL\IBMVGA32.DLL'
  27. bksrc.9 = 'DLL\BVHVGA.DLL'
  28. bksrc.10 = 'DLL\BVHSVGA.DLL'
  29.  
  30. bksrc.0 = 10
  31.  
  32. bkdst.1 = 'VSVGA.SYS'
  33. bkdst.2 = 'VVGA.SYS'
  34. bkdst.3 = 'SVGA.EXE'
  35. bkdst.4 = 'SCREEN01.SYS'
  36. bkdst.5 = 'SCREEN02.SYS'
  37. bkdst.6 = 'IBMGPMI.DLL'
  38. bkdst.7 = 'IBMDEV32.DLL'
  39. bkdst.8 = 'IBMVGA32.DLL'
  40. bkdst.9 = 'BVHVGA.DLL'
  41. bkdst.10 = 'BVHSVGA.DLL'
  42.  
  43. say d2c(27)'[1;40;32m' 
  44. say '* Avance Logic, Inc.'
  45. say '*'
  46. say '* OS/2 Support Files Installation...'
  47. say '*'
  48. say '* You are about to begin installation of driver support files.'
  49. say '*'d2c(27)'[1;40;36m'
  50. '@pause'
  51. say '*'d2c(27)'[1;40;37m'
  52.  
  53. Call SysFileTree 'C:\OS2\MDOS\AVANCEBK',dirs,'DO'
  54. if dirs.0 = 0 then
  55.   do
  56.       '@MD C:\OS2\MDOS\AVANCEBK >NUL'
  57.       say 'Backup Files'd2c(27)'[1;40;33m'
  58.       do i = 1 to bksrc.0
  59.          say 'C:\OS2\'bksrc.i
  60.          '@COPY C:\OS2\'bksrc.i' C:\OS2\MDOS\AVANCEBK\'bkdst.i' >NUL'
  61.       end
  62.   end
  63. Call SysFileTree 'C:\OS2\MDOS\AVANCEBK\ALIDRV',dirs,'DO'
  64. if dirs.0 = 0 then
  65.   do
  66.       '@MD C:\OS2\MDOS\AVANCEBK\ALIDRV >NUL'
  67.       call CopyDrv Drive, path
  68.   end
  69. Call SysFileTree 'C:\OS2\MDOS\AVANCEBK\ALIDRV\svga.exe',file,'F'
  70. if file.0 = 0 then
  71.       call CopyDrv Drive, path
  72. else
  73.    Do
  74.       '@dir C:\OS2\MDOS\AVANCEBK\ALIDRV\svga.exe | find "4-03-95" >nul'
  75.       if rc <> 0 then call CopyDrv Drive, path
  76.    End
  77. call setup.cmd
  78. Return
  79.  
  80.  
  81. CopyDrv: Procedure
  82.  Parse Arg Drive,path
  83.       say '*'d2c(27)'[1;40;32m'
  84.       Call SysFileTree '.\*.*',files,'F'
  85.       do i = 1 to files.0
  86.          files.i = FILESPEC( 'name', files.i )
  87.          say Drive''path'\'files.i
  88.          '@COPY 'files.i' C:\OS2\MDOS\AVANCEBK\ALIDRV\'files.i' >NUL'
  89.       end
  90.       if SysCreateObject("WPProgram","Avance Display Install","<WP_DESKTOP>",255,
  91.                            "PROGTYPE=PM;EXENAME==C:\OS2\MDOS\AVANCEBK\ALIDRV\SETUP.CMD;STARTUPDIR=C:\OS2\MDOS\AVANCEBK\ALIDRV;ASSOCFILTER=setup.ico")
  92.       then
  93.         say
  94. Return
  95.