Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- PKZIP 2.0 Reference Guide - Norton Guide http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]

  PKSFX/ZIP2EXE/PKUNZJR

  The PKZIP utilities offer a self-extraction capability.  This means that
  you can make a .ZIP file into an .EXE file.  This file will in effect be
  able to extract itself.  A PKSFX (PK-Self Extracting) file consists of a
  .ZIP file which has been transformed into a self-extracting file by the
  utility ZIP2EXE.  There is no utility or file called "SFX" or "PKSFX", but
  the self-extracting file will show PKSFX on the banner in the same manner
  as PKUNZIP:

     PKSFX (R)  FAST!  Self Extract Utility  Version 2
     Copr. 1989-1992 PKWARE Inc. All Rights Reserved. PKSFX/h for help
     PKSFX Reg. U.S. Pat. and Tm. Off.

  Creating a Self-Extracting File

  In order to create a self-extracting file, you must first create a .ZIP
  file.  Once this .ZIP file is created, use the ZIP2EXE utility to
  transform this .ZIP file into an .EXE file.

     D:\>zip2exe test.zip

     ZIP2EXE (tm)     Self-Extract Creator     Version 2
     Copr. 1989-1992 PKWARE Inc. All Rights Reserved. ZIP2EXE/h for help

     TEST.ZIP => TEST.EXE

     D:\>

  As you can see, an .EXE file by the same name as the .ZIP file is created.
  The original .ZIP file is not deleted.

  Meet Junior

  Turning a .ZIP file into an .EXE file increases the size because of the
  included extraction program.  The added size is approximately 13.5K bytes.
  If space is at a premium, and you are willing to sacrifice functionality
  for size, try PKSFX Junior(TM).

  The PKSFX Junior is somewhat smaller, and offers very few command line
  options due to this reduced size.  The options which are available with
  the PKSFX Junior are indicated on the PKSFX command summary.

  To create a PKSFX Junior file, add the command line option -j when
  performing the ZIP2EXE step.

     D:\>zip2exe -j test.zip

  PKSFX Junior adds approximately 3K bytes to the .ZIP file.

  PKSFX Junior can handle a maximum of 512 files.  Although PKSFX Junior has
  this limit to the number of files it can handle, there is no limit to the
  file size.

  PKUNZIP Junior

  The PKUNZIP Junior program is an extremely small stand-alone extraction
  program.  It is used in the same manner as PKUNZIP but it has only the
  functionality of the PKSFX Junior self-extractor.

     PKUNZIP(R)  FAST!  Mini Extract Utility  Version 2
     Copr. 1989-1992 PKWARE Inc. All Rights Reserved.
     PKUNZIP Reg. U.S. Pat. and Tm. Off.

     Usage:  pkunzjr [-o] filename[.zip] [output_path]

  PKUNZIP Junior has one option, -o.  This option is the same as that for
  PKUNZIP (Senior).

  PKUNZIP Junior accepts the .ZIP file name on the command line, and may
  optionally accept an output path.  PKUNZIP Junior cannot extract specific
  files, but must extract the entire .ZIP file.

  PKUNZIP Junior cannot extract a file containing more that 512 files, and
  does not support multiple volume .ZIP files.

  PKSFX Command Summary

  Command line syntax and options are the same as PKUNZIP.  The options
  listed below are offered by a self-extracting file.

  Syntax: pksfx [option] [d:\path] [file]* [file]*

  PKSFX indicates the name of the self-extracting file you are executing.
  No options are necessary if you wish to simply extract all files to the
  current directory.  If you wish to extract the contents to another
  directory, indicate the drive and/or path the files should extract to.  To
  extract only particular files, indicate the name(s) at the end of the
  command line.

  Options:

     @listfile.lst            Specify list of files for extraction*

     -c[m]                    Extract to console*

     -d                       Re-create directories stored in .ZIP file*

     -l                       Display software license agreement*

     -n                       Extract only newer files*

     -o                       Overwrite existing files

     -p[a|b][c][#]            Extract to printer*

     -s<password>             Decrypt with password*

     -t                       Test file integrity*

  * Indicates options not available in the PKSFX Junior and PKUNZIP Junior
    programs.

  Options should be placed after the self-extracting files name.  If
  multiple options are used they must be separated by a space and each must
  have its own option indicator (either - or /).

  All options behave in the same manner as they do with PKUNZIP, with one
  exception.  The -s option cannot accept keyboard entry.  A password
  entered with a self-extracting file must be able to be entered from the
  command line.

  Modifying a Self-Extracting File

  A self-extracting file can be operated upon by PKZIP and PKUNZIP in a
  manner identical to normal .ZIP files.  You will need to specify the full
  file name including the EXE extension.

     C:\>pkzip test.exe -f d:\*.*

  There is no difference between operating on a self-extracting file and a
  normal .ZIP file.

  A Note About Self-Extracting Files

  When you create a self-extracting file, you are adding a copy of the
  extraction code to that file.  Since this code duplicates the
  functionality of the PKUNZIP program, it makes sense to use the
  self-extractor only when PKUNZIP will not be present on the machine to
  extract the file.

  If you create many self-extracting files for your own use, you will be
  using more space unnecessarily.  Therefore it is recommended that you only
  use the self-extracting capability when you are sending a file to someone
  that you know does not have a compatible PKUNZIP.

  Stripping the PKSFX Code

  You may have occasion to want to keep the contents of a self-extracting
  file, but wish to turn it back to a normal .ZIP file.

  The ZIP2EXE offers an option to reverse the process.  This is done with
  the command line switch -e:

     F:\>zip2exe -e test.exe

  ZIP2EXE will recognize normal and PKSFX Junior files automatically.

  Sending a Self-Extractor

  If you are sending a PKSFX file to somone who is not familiar with data
  compression and/or PKWARE products, we recommend you tell them to do the
  following:

  With PKSFX Junior:

  1) Create a temporary directory on the hard drive to hold the files
     contained in the self-extracting file.

     C:\>md temp

  2) Change to the directory that was just created.

     C:\>cd temp
     C:\temp>

  3) Place the diskette containing the self-extracting file into the A: or
     B: drive.  4) Type the name of the self-extractor, including the path
     to the floppy drive.

     C:\temp>a:test

  With normal PKSFX:

  1) Place the diskette containing the self-extracting file into the A: or
     B: drive and change to that drive.

     C:\>a:

  2) Type in the following;

     A:\>test -d c:\temp

  You may also wish to create a batch file or text file on the floppy disk
  containing the above steps.  The contents of the self-extractor will be
  placed into this temporary directory.  They can then examine or move the
  files at their leisure.  The -d option ensures that any subdirectory
  information included will be re-created, and causes PKSFX to create the
  temporary directory for the user.

  Site license

  A site license is required by a corporation, company, educational
  institution, or governmental agency for use of PKWARE software on the
  total number of computers that will use the software.

  Use of PKWARE programs for personal use is covered by your purchase of a
  single license for PKZIP.  A Distribution License is required by a
  corporation, company, educational institution or governmental agency to
  use PKWARE programs to facilitate the distribution of software to outside
  parties.

  Please note that if a self-extracting file is used, a Distribution License
  is required, because PKWARE code is distributed in the form of the PKSFX
  program combined with the file(s) being distributed.

  Please contact PKWARE for more information if you intend to distribute
  self- extracting files.

  Confirm before extract

  If a PKSFX file has a .ZIP file comment attached, this comment is
  displayed before the file is extracted.  By imbedding a Control-S
  character (Hex 13, ASCII 19), you can cause PKSFX to pause.  The display
  will look like this:

     Searching EXE: XXXXX.EXE -
     .
     .
     .
     (ZIP file comment text)
     .
     .
     .
     Do you want to extract these files now (y/n)?

  Press 'Y' to extract the files, 'N' o abort.  Note that the Control-S
  character is not displayed.  This control character may be located
  anywhere within the comment.

  If the user aborts by pressing 'N', an exit code of 12 will be returned by
  PKSFX.  PKSFX Junior will return an exit code of 8.

  Memory Requirements

  The memory requirements for PKSFX are similar to those of PKUNZIP.

  PKSFX Junior, and PKUNZIP Junior require a minimum of 50K RAM free, and a
  maximum of 64K RAM free.

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson