README.MVS 6.1 KB

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