Chris@43: ZLIB version 1.2.8 for AS400 installation instructions Chris@43: Chris@43: I) From an AS400 *SAVF file: Chris@43: Chris@43: 1) Unpacking archive to an AS400 save file Chris@43: Chris@43: On the AS400: Chris@43: Chris@43: _ Create the ZLIB AS400 library: Chris@43: Chris@43: CRTLIB LIB(ZLIB) TYPE(*PROD) TEXT('ZLIB compression API library') Chris@43: Chris@43: _ Create a work save file, for example: Chris@43: Chris@43: CRTSAVF FILE(ZLIB/ZLIBSAVF) Chris@43: Chris@43: On a PC connected to the target AS400: Chris@43: Chris@43: _ Unpack the save file image to a PC file "ZLIBSAVF" Chris@43: _ Upload this file into the save file on the AS400, for example Chris@43: using ftp in BINARY mode. Chris@43: Chris@43: Chris@43: 2) Populating the ZLIB AS400 source library Chris@43: Chris@43: On the AS400: Chris@43: Chris@43: _ Extract the saved objects into the ZLIB AS400 library using: Chris@43: Chris@43: RSTOBJ OBJ(*ALL) SAVLIB(ZLIB) DEV(*SAVF) SAVF(ZLIB/ZLIBSAVF) RSTLIB(ZLIB) Chris@43: Chris@43: Chris@43: 3) Customize installation: Chris@43: Chris@43: _ Edit CL member ZLIB/TOOLS(COMPILE) and change parameters if needed, Chris@43: according to the comments. Chris@43: Chris@43: _ Compile this member with: Chris@43: Chris@43: CRTCLPGM PGM(ZLIB/COMPILE) SRCFILE(ZLIB/TOOLS) SRCMBR(COMPILE) Chris@43: Chris@43: Chris@43: 4) Compile and generate the service program: Chris@43: Chris@43: _ This can now be done by executing: Chris@43: Chris@43: CALL PGM(ZLIB/COMPILE) Chris@43: Chris@43: Chris@43: Chris@43: II) From the original source distribution: Chris@43: Chris@43: 1) On the AS400, create the source library: Chris@43: Chris@43: CRTLIB LIB(ZLIB) TYPE(*PROD) TEXT('ZLIB compression API library') Chris@43: Chris@43: 2) Create the source files: Chris@43: Chris@43: CRTSRCPF FILE(ZLIB/SOURCES) RCDLEN(112) TEXT('ZLIB library modules') Chris@43: CRTSRCPF FILE(ZLIB/H) RCDLEN(112) TEXT('ZLIB library includes') Chris@43: CRTSRCPF FILE(ZLIB/TOOLS) RCDLEN(112) TEXT('ZLIB library control utilities') Chris@43: Chris@43: 3) From the machine hosting the distribution files, upload them (with Chris@43: FTP in text mode, for example) according to the following table: Chris@43: Chris@43: Original AS400 AS400 AS400 AS400 Chris@43: file file member type description Chris@43: SOURCES Original ZLIB C subprogram sources Chris@43: adler32.c ADLER32 C ZLIB - Compute the Adler-32 checksum of a dta strm Chris@43: compress.c COMPRESS C ZLIB - Compress a memory buffer Chris@43: crc32.c CRC32 C ZLIB - Compute the CRC-32 of a data stream Chris@43: deflate.c DEFLATE C ZLIB - Compress data using the deflation algorithm Chris@43: gzclose.c GZCLOSE C ZLIB - Close .gz files Chris@43: gzlib.c GZLIB C ZLIB - Miscellaneous .gz files IO support Chris@43: gzread.c GZREAD C ZLIB - Read .gz files Chris@43: gzwrite.c GZWRITE C ZLIB - Write .gz files Chris@43: infback.c INFBACK C ZLIB - Inflate using a callback interface Chris@43: inffast.c INFFAST C ZLIB - Fast proc. literals & length/distance pairs Chris@43: inflate.c INFLATE C ZLIB - Interface to inflate modules Chris@43: inftrees.c INFTREES C ZLIB - Generate Huffman trees for efficient decode Chris@43: trees.c TREES C ZLIB - Output deflated data using Huffman coding Chris@43: uncompr.c UNCOMPR C ZLIB - Decompress a memory buffer Chris@43: zutil.c ZUTIL C ZLIB - Target dependent utility functions Chris@43: H Original ZLIB C and ILE/RPG include files Chris@43: crc32.h CRC32 C ZLIB - CRC32 tables Chris@43: deflate.h DEFLATE C ZLIB - Internal compression state Chris@43: gzguts.h GZGUTS C ZLIB - Definitions for the gzclose module Chris@43: inffast.h INFFAST C ZLIB - Header to use inffast.c Chris@43: inffixed.h INFFIXED C ZLIB - Table for decoding fixed codes Chris@43: inflate.h INFLATE C ZLIB - Internal inflate state definitions Chris@43: inftrees.h INFTREES C ZLIB - Header to use inftrees.c Chris@43: trees.h TREES C ZLIB - Created automatically with -DGEN_TREES_H Chris@43: zconf.h ZCONF C ZLIB - Compression library configuration Chris@43: zlib.h ZLIB C ZLIB - Compression library C user interface Chris@43: as400/zlib.inc ZLIB.INC RPGLE ZLIB - Compression library ILE RPG user interface Chris@43: zutil.h ZUTIL C ZLIB - Internal interface and configuration Chris@43: TOOLS Building source software & AS/400 README Chris@43: as400/bndsrc BNDSRC Entry point exportation list Chris@43: as400/compile.clp COMPILE CLP Compile sources & generate service program Chris@43: as400/readme.txt README TXT Installation instructions Chris@43: Chris@43: 4) Continue as in I)3). Chris@43: Chris@43: Chris@43: Chris@43: Chris@43: Notes: For AS400 ILE RPG programmers, a /copy member defining the ZLIB Chris@43: API prototypes for ILE RPG can be found in ZLIB/H(ZLIB.INC). Chris@43: Please read comments in this member for more information. Chris@43: Chris@43: Remember that most foreign textual data are ASCII coded: this Chris@43: implementation does not handle conversion from/to ASCII, so Chris@43: text data code conversions must be done explicitely. Chris@43: Chris@43: Mainly for the reason above, always open zipped files in binary mode.