File: README

package info (click to toggle)
zlibc 0.9k-4.3
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 624 kB
  • ctags: 461
  • sloc: sh: 3,195; ansic: 3,077; csh: 128; makefile: 60; sed: 4
file content (86 lines) | stat: -rw-r--r-- 3,209 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
	ZLIBC -	Uncompressing C Library (For Linux and SunOs)

				by

	               Alain Knaff 1993-1999


 Zlibc is a preloadable shared object that allows executables to
uncompress the datafiles that they need on the fly. No kernel patch,
no recompilation of these executables and no recompilation of the
libraries is needed.

 This package overrides the "open" function (and other system call
functions) in the shared library.

 This package uses the LD_PRELOAD/LD_LIBRARY_PATH mechanism to
redirect the dynamic linker to use the relevant functions out of
uncompress.o instead of the shared library. Thus, it should work with
every release of the shared library.

 (An older, not recommended way to use zlibc is to have it patch the
jumptable. This is only available for a.out on Linux.)


How it works:
=============

 Usually, programs don't make system calls directly, but instead call
a function which does them. To open a file, first the "open" function
is called, and then this function makes the actual syscall.  This
package patches the "open" function and other related functions.

 With the zlibc, if the "open" system call fails because the file
doesn't exist, the "open" function constructs the filename of a
compressed file by appending .gz to the filename supplied by the user
program. If this compressed file exists, it is opened and piped trough
gunzip(1), and the descriptor of the read end of this pipe is returned
to the caller.
 For certain extensions, the .gz file is first uncompressed into a
temporary file, and a read descriptor for this file is passed to the
caller. This is necessary if the caller wants to call lseek on the
descriptor or mmap it. A description of data files for which this is
necessary can be given in the configuration files /usr/lib/zlibrc and
~/.zlibrc. See zlibrc(5) for a detailed description of the syntax of
these configuration files.


Further Documentation:
======================

 The most up to date documentation is the texinfo documentation.

 * To generate a printable copy, run the following commands:
    ./configure; make dvi; dvips zlibc.dvi
 * To generate a html copy,  run:
     ./configure; make html
   A premade html copy can be found at:
    http://www.tux.org/pub/knaff/zlibc/zlibc_toc.html
 * To generate an info copy (browsable using emacs' info mode), run:
     ./configure; make info


This doc looks most pretty when printed or as html.  Indeed, in the
info version certain examples are difficult to read due to the quoting
conventions in info.

 Manpages are less up to date and probably less readable as well.

 There is also a sample configuration file called zlibrc.sample. The
compiled-in defaults are fairly complete, so normally you don't need
to use the run-time compilation. (The zlibrc.sample file reflects
roughly the compiled-in defaults.)

 The file CAVEATS describes the limitations of this package.

 The file BUGS describes the bugs of this package.

 The file FAQ contains frequently asked questions and answers. It is
regularily updated on http://zlibc.linux.lu/FAQ.html


 Have fun,

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Alain L. Knaff					               alain@knaff.lu