Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | Download | RSS feed

  1. Thank you for trying this port of UNZIP for VM/CMS and MVS!
  2.  
  3.                         Using under MVS:
  4.                     -------------------------
  5.  
  6. 1. To use the Info-ZIP's UNZIP under MVS you need:
  7.  
  8.    - C/370 ver 2.1 compiler or another compatible compiler supporting
  9.      long names for function/variable names.
  10.  
  11. 2. To compile the program under MVS do :
  12.  
  13.    - unzip all the files from unz54vm.zip file. They are stored as
  14.      ASCII format so you have to unzip them first on PC or other
  15.      system that already have UNZIP, and then upload them to the
  16.      mainframe with ASCII to EBCDIC conversion.
  17.  
  18.    - Copy all the .C files in the PDS called USERID.UNZIP.C
  19.  
  20.    - Copy all the .H files in the PDS called USERID.UNZIP.H
  21.  
  22.    - adjust the job UNZMVSC.JOB to work on your site. Change USERID
  23.      to your userid.  You might need to change the CEE dataset names
  24.      to match your OS/390 system.
  25.  
  26.    - Preallocate PDS datasets named: USERID.UNZIP.OBJ and
  27.      USERID.UNZIP.LOAD
  28.  
  29.    - execute the job UNZMVSC to compile and link all the sources.
  30.  
  31.    - if everything is ok you will get an UNZIP MODULE
  32.  
  33. 3. Using UNZIP
  34.  
  35.    - Just read the UNZIP.TXT
  36.  
  37.    - A few exceptions concerning MVS
  38.  
  39.      3.0. There are different ways to invoke UNZIP.
  40.  
  41.         - allocating UNZIP.LOAD dataset to your ISPLLIB if you
  42.           want to invoke UNZIP under ISPF.
  43.           Then just type UNZIP ...parms... to get it work
  44.  
  45.         - You can also call it directly with :
  46.              TSO CALL 'userid.UNZIP.LOAD(UNZIP)' '...parms...'
  47.              (notice to quotes!)
  48.  
  49.         - You can even call it from a batch job like:
  50.  
  51.           //MYZIP    JOB  (account)
  52.           //STEP1    EXEC PGM=UNZIP,PARM='-l mytestz.zip *.c'
  53.           //STEPLIB  DD DSN=userid.UNZIP.LOAD,DISP=SHR
  54.           //SYSPRINT DD SYSOUT=*
  55.  
  56.           This will list all the .c files from the zip file mytestz.zip
  57.  
  58.      3.1. If the ZIP file has been zipped on an ASCII based system
  59.           it will be automatically translated to EBCDIC
  60.           ( I hope I got all those translation tables OK :-).
  61.           You can force ASCII to EBCDIC conversion with the -a flag.
  62.  
  63.      3.2. The date/time of the output files is set to the
  64.           current system date/time - not according the date/time in
  65.           the zip file.
  66.  
  67.      3.3. You can even unzip using TSO/E PIPELINES
  68.           so unzip can be used as pipeline filter:
  69.  
  70.           'pipe cms unzip -p test.zip george.test | count lines | cons'
  71.           ( we do also a lot of pipethinking here ;-)
  72.  
  73.      3.4. If you got also the ZIP program (see ZIP21VM.ZIP) you can
  74.           do zipping and unzipping without translating to ASCII
  75.           the ZIP also preserves the file informations (LRECL,BLKSIZE..)
  76.           So when you UNZIP a file zipped with ZIP under MVS it
  77.           restores the file info.
  78.  
  79.           There currently some problems with file with RECFM=V*
  80.           I don't save the length of each record yet :-)
  81.  
  82.      3.5. No wildcards are supported in the input zip name you have
  83.           to give the real name (.zip is not necessary)
  84.  
  85.           So you CAN'T use things like: unzip -t *.zip
  86.  
  87.      3.6. But you CAN use wildcards as filename selection like:
  88.           unzip -t myzip *.c  - OK or even
  89.           unzip -t myzip *.c -x z*.c  - to exclude all files matching
  90.                                         z*.c
  91.  
  92.      3.7. You can unzip to a PDS using the -d parameter,
  93.           for example:
  94.  
  95.            unzip -dmyzip myzip *.c
  96.  
  97.           This will unzip all .c files that are in the zip file in a
  98.           PDS directory called MYZIP.C
  99.  
  100.           BE AWARE that the extension of every files is being placed as
  101.           last identifier on the PDS name, so if you have a file in the
  102.           zipfile called 'testp.doc' and you use '-d mypds' the PDS
  103.           name will become 'mypds.doc(testp)'
  104.  
  105.           Depending on which options IBM chose for C this week, unzip
  106.           may or may not prefix output files with your userid and/or
  107.           TSO prefix.  To prevent this, quote the filename to -d, for
  108.           example
  109.  
  110.                 //UNZIP   EXEC PGM=UNZIP,
  111.                 // PARM='/-a -o ''userid.zip'' -d ''hlq.test'' *'
  112.                 //STEPLIB  DD  DSN=USERID.UNZIP.LOAD,DISP=SHR
  113.                 //SYSPRINT DD  SYSOUT=*
  114.                 //SYSOUT   DD  SYSOUT=*
  115.  
  116.           The above JCL converts from ASCII to EBCDIC (-a), always
  117.           overwrites existing members (-o), extracts from 'userid.zip',
  118.           writes to files starting with 'hlq.test', all members (*).
  119.           Note the double quotes because PARM= requires single quotes.
  120.  
  121.      3.8. The rules for output DCBs are a little messy.  If the output
  122.           file already exists (remember the -d option) then unzip uses
  123.           the existing DCB and space values.
  124.  
  125.           If the output file does not exist and the input zip came from
  126.           MVS then unzip makes its best attempt at preserving the
  127.           original DCB.  However there is not enough information stored
  128.           in the zip file to do this correctly for all file types, some
  129.           file types may be corrupted.
  130.  
  131.           If the output file does not exist and the input zip does not
  132.           contain MVS DCB information then unzip uses RECFM=U,
  133.           LRECL=32760 for binary data, RECFM=V, LRECL=133 for text.
  134.           Text includes ASCII to EBCDIC conversion.  As soon as the
  135.           output file is created, unzip uses the same output DCB for
  136.           all following members, even if the input is a mixture of text
  137.           and binary.
  138.  
  139.           In all cases, unzip has no built in parameters for space.
  140.           For a preallocated file this is not a problem.  If unzip
  141.           creates an output file you get a default space allocation
  142.           which is site dependent.
  143.  
  144.           It is far better to preallocate the output files with the
  145.           correct space and DCB values then use the -d option to point
  146.           to those files.
  147.  
  148.      3.9. All '+','_' or '-' signs are skipped from the filenames
  149.  
  150.  
  151. Please repport all bugs and problems to :
  152.      Zip-Bugs@lists.wku.edu
  153.  
  154. That's all for now.
  155.  
  156. Have fun!
  157.  
  158.  
  159. George Petrov
  160. e-mail: c888090@nlevdpsb.snads.philips.nl
  161. tel: +31-40-781155
  162.  
  163. Philips C&P
  164. Eindhoven
  165. The Netherlands
  166.  
  167. Updated by:
  168.  
  169. Keith Owens <kaos@ocs.com.au>
  170.