home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 18 REXX / 18-REXX.zip / rexxtk12.zip / makedist.cmd < prev    next >
OS/2 REXX Batch file  |  2001-07-14  |  2KB  |  89 lines

  1. /* 
  2.  * Make a distribution of Rexx/Tk
  3.  * Required for those platforms that use GNU make:
  4.  *   DOSDJP
  5.  *   OS2EMX
  6.  *   DOSEMX
  7.  *   WIN32
  8.  */
  9. Trace o
  10. Parse Arg verdot src
  11. If verdot = '' Then Call usage
  12. If Stream(src,'C','QUERY EXISTS') = '' Then Call usage
  13. If Stream('tmp','C','QUERY EXISTS') = '' Then 'mkdir tmp'
  14. platform = hereok()
  15. ver = Changestr( '.', verdot, '' )
  16. Call Chdir('tmp')
  17. 'del /Y *.*'
  18.  
  19. if src = '' then call usage
  20. select
  21.   when platform = 'DOSDJG' then do
  22.        dizfile = src || '\dosgo32.diz'
  23.        suffix = 'djg'
  24.        interpreter = 'Regina'
  25.        'copy c:\djgpp\bin\go32.exe .'
  26.        end
  27.   when platform = 'DOSEMX' then do
  28.        dizfile = src || '\dosvcpi.diz'
  29.        suffix = 'vcp'
  30.        interpreter = 'Regina'
  31.        end
  32.   when platform = 'OS2EMX' then do
  33.        dizfile = src || '\os2.diz'
  34.        suffix = 'os2'
  35.        interpreter = 'OS/2 Rexx'
  36.        end
  37.   when platform = 'WIN32' then do
  38.        dizfile = src || '\win32.diz'
  39.        suffix = 'w32'
  40.        interpreter = 'Rexx/Trans'
  41.        fullpath = 'c:\bin\rexxtrans.dll'
  42.        'copy' fullpath '.'
  43.        end
  44.    otherwise call usage
  45. end
  46. 'copy ..\rexxtk.exe .'
  47. 'copy ..\rexxtk.dll .'
  48. 'copy ..\rexxtktree.dll .'
  49. 'copy ..\rexxtkmclistbox.dll .'
  50. 'copy ..\rexxtknotebook.dll .'
  51. 'copy ..\rexxtkcombobox.dll .'
  52. 'copy' src || '\COPYING-LIB .'
  53. 'copy' src || '\HISTORY .'
  54. 'copy' src || '\INSTALL .'
  55. 'copy' src || '\TODO .'
  56. 'copy' src || '\README .'
  57. If Stream('doc','C','QUERY EXISTS') = '' Then 'mkdir doc'
  58. 'del /Y doc\*.*'
  59. 'copy' src || '\doc\*.html doc'
  60. 'copy' src || '\doc\*.jpg doc'
  61. If Stream('demo','C','QUERY EXISTS') = '' Then 'mkdir demo'
  62. 'del /Y demo\*.*'
  63. 'copy' src || '\demo\aces.rexx demo'
  64. 'copy' src || '\demo\testtk.rexx demo'
  65. /*
  66. Call fixdiz dizfile
  67. */
  68. 'zip -r rexxtk' || ver || '_'suffix '*'
  69. 'cd ..'
  70. Return
  71.  
  72. hereok: Procedure
  73. here = Right(Stream('.','C','QUERY EXISTS'),3)
  74. If here = 'emx' Then Return 'OS2EMX'
  75. If here = 'vcp' Then Return 'DOSEMX'
  76. If here = 'djg' Then Return 'DOSDJG'
  77. here = Right(Stream('.','C','QUERY EXISTS'),2)
  78. If here = 'vc' Then Return 'WIN32'
  79. Say 'not in correct directory. should be running from one of: emx, vcp, djg, vc'
  80. Exit 1
  81. Return
  82.  
  83. usage:
  84. Say 'makedist versiondot src'
  85. Say 'where:'
  86. Say '      versiondot - 2.5'
  87. Say '      src        - source of Rexx/Tk'
  88. Exit 1
  89.