home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #6 / amigamamagazinepolishissue1998.iso / coders / proasm / rexx / dopus / asxassemble.dopus < prev    next >
Text File  |  1996-04-29  |  1KB  |  41 lines

  1. /* Assemble selected files         */
  2. /* for Directory Opus 4, using ASX */
  3. /* 16.06.93 by Daniel Weber        */
  4.  
  5.  
  6. OPTIONS RESULTS
  7. dopusPort = ADDRESS()            /* get port name of DOpus    */
  8.  
  9. status 3                /* get #of active window     */
  10. win = result
  11. status 13 win                /* get actual selected drive */
  12. path = result
  13. getselectedfiles '+'
  14. IF RC ~= 0 THEN EXIT(0)
  15. files = result
  16.  
  17. DO WHILE files ~=''
  18.   PARSE VAR files txtfile '+' files
  19.  
  20.   ADDRESS (''||dopusPort)        /* show file name  */
  21.   toptext 'Assembling 'path''txtfile
  22.  
  23.   ADDRESS 'asx_rexx'
  24.   BegOfAssembly                /* allocate a job  */
  25.   port = result
  26.   IF port ~='' THEN DO
  27.     ADDRESS (''||port)            /* ARexx weirdness */
  28.     Assemble path''txtfile        /* assemble selected file */
  29.     PARSE VAR result . errors . warnings . optims optimbytes . codesize . workspace
  30.  
  31.     ADDRESS (''||dopusPort)
  32.     toptext errors' Errors 'warnings' Warnings, assembled to 'codesize' bytes.'
  33.  
  34.     ADDRESS (''||port)            /* ARexx weirdness */
  35.     EndOfAssembly            /* free job        */
  36.   END
  37. END
  38.  
  39. EXIT(0)
  40.  
  41.