cannam@89: cannam@89: This directory contains a Pascal (Delphi, Kylix) interface to the cannam@89: zlib data compression library. cannam@89: cannam@89: cannam@89: Directory listing cannam@89: ================= cannam@89: cannam@89: zlibd32.mak makefile for Borland C++ cannam@89: example.pas usage example of zlib cannam@89: zlibpas.pas the Pascal interface to zlib cannam@89: readme.txt this file cannam@89: cannam@89: cannam@89: Compatibility notes cannam@89: =================== cannam@89: cannam@89: - Although the name "zlib" would have been more normal for the cannam@89: zlibpas unit, this name is already taken by Borland's ZLib unit. cannam@89: This is somehow unfortunate, because that unit is not a genuine cannam@89: interface to the full-fledged zlib functionality, but a suite of cannam@89: class wrappers around zlib streams. Other essential features, cannam@89: such as checksums, are missing. cannam@89: It would have been more appropriate for that unit to have a name cannam@89: like "ZStreams", or something similar. cannam@89: cannam@89: - The C and zlib-supplied types int, uInt, long, uLong, etc. are cannam@89: translated directly into Pascal types of similar sizes (Integer, cannam@89: LongInt, etc.), to avoid namespace pollution. In particular, cannam@89: there is no conversion of unsigned int into a Pascal unsigned cannam@89: integer. The Word type is non-portable and has the same size cannam@89: (16 bits) both in a 16-bit and in a 32-bit environment, unlike cannam@89: Integer. Even if there is a 32-bit Cardinal type, there is no cannam@89: real need for unsigned int in zlib under a 32-bit environment. cannam@89: cannam@89: - Except for the callbacks, the zlib function interfaces are cannam@89: assuming the calling convention normally used in Pascal cannam@89: (__pascal for DOS and Windows16, __fastcall for Windows32). cannam@89: Since the cdecl keyword is used, the old Turbo Pascal does cannam@89: not work with this interface. cannam@89: cannam@89: - The gz* function interfaces are not translated, to avoid cannam@89: interfacing problems with the C runtime library. Besides, cannam@89: gzprintf(gzFile file, const char *format, ...) cannam@89: cannot be translated into Pascal. cannam@89: cannam@89: cannam@89: Legal issues cannam@89: ============ cannam@89: cannam@89: The zlibpas interface is: cannam@89: Copyright (C) 1995-2003 Jean-loup Gailly and Mark Adler. cannam@89: Copyright (C) 1998 by Bob Dellaca. cannam@89: Copyright (C) 2003 by Cosmin Truta. cannam@89: cannam@89: The example program is: cannam@89: Copyright (C) 1995-2003 by Jean-loup Gailly. cannam@89: Copyright (C) 1998,1999,2000 by Jacques Nomssi Nzali. cannam@89: Copyright (C) 2003 by Cosmin Truta. cannam@89: cannam@89: This software is provided 'as-is', without any express or implied cannam@89: warranty. In no event will the author be held liable for any damages cannam@89: arising from the use of this software. cannam@89: cannam@89: Permission is granted to anyone to use this software for any purpose, cannam@89: including commercial applications, and to alter it and redistribute it cannam@89: freely, subject to the following restrictions: cannam@89: cannam@89: 1. The origin of this software must not be misrepresented; you must not cannam@89: claim that you wrote the original software. If you use this software cannam@89: in a product, an acknowledgment in the product documentation would be cannam@89: appreciated but is not required. cannam@89: 2. Altered source versions must be plainly marked as such, and must not be cannam@89: misrepresented as being the original software. cannam@89: 3. This notice may not be removed or altered from any source distribution. cannam@89: