zlib 1.2.0.7
This commit is contained in:
parent
f81ba93d4a
commit
b97ec631c6
17
ChangeLog
17
ChangeLog
@ -1,17 +1,28 @@
|
|||||||
|
|
||||||
ChangeLog file for zlib
|
ChangeLog file for zlib
|
||||||
|
|
||||||
|
Changes in 1.2.0.7 (21 September 2003)
|
||||||
|
- Correct some debug formats in contrib/infback9
|
||||||
|
- Cast a type in a debug statement in trees.c
|
||||||
|
- Change search and replace delimiter in configure from % to # [Beebe]
|
||||||
|
- Update contrib/untgz to 0.2 with various fixes [Truta]
|
||||||
|
- Add build support for Amiga [Nikl]
|
||||||
|
- Remove some directories in old that have been updated to 1.2
|
||||||
|
- Add dylib building for Mac OS X in configure and Makefile.in
|
||||||
|
- Remove old distribution stuff from Makefile
|
||||||
|
- Update README to point for DLL_FAQ.txt, and add comment on Mac OS X
|
||||||
|
- Update links in README
|
||||||
|
|
||||||
Changes in 1.2.0.6 (13 September 2003)
|
Changes in 1.2.0.6 (13 September 2003)
|
||||||
- Minor FAQ updates
|
- Minor FAQ updates
|
||||||
- Update contrib/minizip to 1.00 [Vollant]
|
- Update contrib/minizip to 1.00 [Vollant]
|
||||||
- Remove test of gz functions in example.c when GZ_COMPRESS defined [Truta]
|
- Remove test of gz functions in example.c when GZ_COMPRESS defined [Truta]
|
||||||
- Updated POSTINC comment for 68060 [Nikl]
|
- Update POSTINC comment for 68060 [Nikl]
|
||||||
- Added contrib/infback9 with deflate64 decoding (unsupported)
|
- Add contrib/infback9 with deflate64 decoding (unsupported)
|
||||||
- For MVS define NO_vsnprintf and undefine FAR [van Burik]
|
- For MVS define NO_vsnprintf and undefine FAR [van Burik]
|
||||||
- Add pragma for fdopen on MVS [van Burik]
|
- Add pragma for fdopen on MVS [van Burik]
|
||||||
|
|
||||||
Changes in 1.2.0.5 (8 September 2003)
|
Changes in 1.2.0.5 (8 September 2003)
|
||||||
- Add infback9 diffs to contrib
|
|
||||||
- Add OF to inflateBackEnd() declaration in zlib.h
|
- Add OF to inflateBackEnd() declaration in zlib.h
|
||||||
- Remember start when using gzdopen in the middle of a file
|
- Remember start when using gzdopen in the middle of a file
|
||||||
- Use internal off_t counters in gz* functions to properly handle seeks
|
- Use internal off_t counters in gz* functions to properly handle seeks
|
||||||
|
63
Makefile
63
Makefile
@ -28,9 +28,10 @@ LDFLAGS=libz.a
|
|||||||
LDSHARED=$(CC)
|
LDSHARED=$(CC)
|
||||||
CPP=$(CC) -E
|
CPP=$(CC) -E
|
||||||
|
|
||||||
VER=1.2.0.6
|
|
||||||
LIBS=libz.a
|
LIBS=libz.a
|
||||||
SHAREDLIB=libz.so
|
SHAREDLIB=libz.so
|
||||||
|
SHAREDLIBV=libz.so.1.2.0.7
|
||||||
|
SHAREDLIBM=libz.so.1
|
||||||
|
|
||||||
AR=ar rc
|
AR=ar rc
|
||||||
RANLIB=ranlib
|
RANLIB=ranlib
|
||||||
@ -52,19 +53,6 @@ OBJA =
|
|||||||
|
|
||||||
TEST_OBJS = example.o minigzip.o
|
TEST_OBJS = example.o minigzip.o
|
||||||
|
|
||||||
# Note: this has not been updated for zlib 1.2.0
|
|
||||||
DISTFILES = README FAQ INDEX ChangeLog configure Make*[a-z0-9] *.[ch] *.mms \
|
|
||||||
algorithm.txt zlib.3 zlib.html \
|
|
||||||
msdos/Make*[a-z0-9] msdos/zlib.def msdos/zlib.rc \
|
|
||||||
nt/Make*[a-z0-9] nt/zlib.dnt amiga/Make*.??? os2/M*.os2 os2/zlib.def \
|
|
||||||
contrib/RE*.contrib contrib/*.txt contrib/asm386/*.asm contrib/asm386/*.c \
|
|
||||||
contrib/asm386/*.bat contrib/asm386/zlibvc.d?? contrib/asm[56]86/*.?86 \
|
|
||||||
contrib/asm[56]86/*.S contrib/iostream/*.cpp \
|
|
||||||
contrib/iostream/*.h contrib/iostream2/*.h contrib/iostream2/*.cpp \
|
|
||||||
contrib/untgz/Makefile contrib/untgz/*.c contrib/untgz/*.w32 \
|
|
||||||
contrib/minizip/[CM]*[pe] contrib/minizip/*.[ch] contrib/minizip/*.[td]?? \
|
|
||||||
contrib/delphi*/*.???
|
|
||||||
|
|
||||||
all: example minigzip
|
all: example minigzip
|
||||||
|
|
||||||
check: test
|
check: test
|
||||||
@ -88,11 +76,11 @@ match.o: match.S
|
|||||||
mv _match.o match.o
|
mv _match.o match.o
|
||||||
rm -f _match.s
|
rm -f _match.s
|
||||||
|
|
||||||
$(SHAREDLIB).$(VER): $(OBJS)
|
$(SHAREDLIBV): $(OBJS)
|
||||||
$(LDSHARED) -o $@ $(OBJS)
|
$(LDSHARED) -o $@ $(OBJS)
|
||||||
rm -f $(SHAREDLIB) $(SHAREDLIB).1
|
rm -f $(SHAREDLIB) $(SHAREDLIBM)
|
||||||
ln -s $@ $(SHAREDLIB)
|
ln -s $@ $(SHAREDLIB)
|
||||||
ln -s $@ $(SHAREDLIB).1
|
ln -s $@ $(SHAREDLIBM)
|
||||||
|
|
||||||
example: example.o $(LIBS)
|
example: example.o $(LIBS)
|
||||||
$(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
|
$(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
|
||||||
@ -110,10 +98,10 @@ install: $(LIBS)
|
|||||||
cp $(LIBS) $(libdir)
|
cp $(LIBS) $(libdir)
|
||||||
cd $(libdir); chmod 755 $(LIBS)
|
cd $(libdir); chmod 755 $(LIBS)
|
||||||
-@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
|
-@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
|
||||||
cd $(libdir); if test -f $(SHAREDLIB).$(VER); then \
|
cd $(libdir); if test -f $(SHAREDLIBV); then \
|
||||||
rm -f $(SHAREDLIB) $(SHAREDLIB).1; \
|
rm -f $(SHAREDLIB) $(SHAREDLIBM); \
|
||||||
ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB); \
|
ln -s $(SHAREDLIBV) $(SHAREDLIB); \
|
||||||
ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB).1; \
|
ln -s $(SHAREDLIBV) $(SHAREDLIBM); \
|
||||||
(ldconfig || true) >/dev/null 2>&1; \
|
(ldconfig || true) >/dev/null 2>&1; \
|
||||||
fi
|
fi
|
||||||
cp zlib.3 $(man3dir)
|
cp zlib.3 $(man3dir)
|
||||||
@ -123,20 +111,15 @@ install: $(LIBS)
|
|||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
cd $(includedir); \
|
cd $(includedir); \
|
||||||
v=$(VER); \
|
|
||||||
if test -f zlib.h; then \
|
|
||||||
v=`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`; \
|
|
||||||
rm -f zlib.h zconf.h; \
|
|
||||||
fi; \
|
|
||||||
cd $(libdir); rm -f libz.a; \
|
cd $(libdir); rm -f libz.a; \
|
||||||
if test -f $(SHAREDLIB).$$v; then \
|
if test -f $(SHAREDLIBV); then \
|
||||||
rm -f $(SHAREDLIB).$$v $(SHAREDLIB) $(SHAREDLIB).1; \
|
rm -f $(SHAREDLIBV) $(SHAREDLIB) $(SHAREDLIBM); \
|
||||||
fi
|
fi
|
||||||
cd $(man3dir); rm -f zlib.3
|
cd $(man3dir); rm -f zlib.3
|
||||||
|
|
||||||
mostlyclean: clean
|
mostlyclean: clean
|
||||||
clean:
|
clean:
|
||||||
rm -f *.o *~ example minigzip libz.a libz.so* foo.gz so_locations \
|
rm -f *.o *~ example minigzip libz.* foo.gz so_locations \
|
||||||
_match.s maketree contrib/infback9/*.o
|
_match.s maketree contrib/infback9/*.o
|
||||||
|
|
||||||
maintainer-clean: distclean
|
maintainer-clean: distclean
|
||||||
@ -145,28 +128,6 @@ distclean: clean
|
|||||||
cp -p zconf.in.h zconf.h
|
cp -p zconf.in.h zconf.h
|
||||||
rm -f .DS_Store
|
rm -f .DS_Store
|
||||||
|
|
||||||
zip:
|
|
||||||
echo Warning: this has not been updated for zlib 1.2.0 -- do not use
|
|
||||||
mv Makefile Makefile~; cp -p Makefile.in Makefile
|
|
||||||
rm -f test.c ztest*.c contrib/minizip/test.zip
|
|
||||||
v=`sed -n -e 's/\.//g' -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\
|
|
||||||
zip -ul9 zlib$$v $(DISTFILES)
|
|
||||||
mv Makefile~ Makefile
|
|
||||||
|
|
||||||
dist:
|
|
||||||
echo Warning: this has not been updated for zlib 1.2.0 -- do not use
|
|
||||||
mv Makefile Makefile~; cp -p Makefile.in Makefile
|
|
||||||
rm -f test.c ztest*.c contrib/minizip/test.zip
|
|
||||||
d=zlib-`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\
|
|
||||||
rm -f $$d.tar.gz; \
|
|
||||||
if test ! -d ../$$d; then rm -f ../$$d; ln -s `pwd` ../$$d; fi; \
|
|
||||||
files=""; \
|
|
||||||
for f in $(DISTFILES); do files="$$files $$d/$$f"; done; \
|
|
||||||
cd ..; \
|
|
||||||
GZIP=-9 $(TAR) chofz $$d/$$d.tar.gz $$files; \
|
|
||||||
if test ! -d $$d; then rm -f $$d; fi
|
|
||||||
mv Makefile~ Makefile
|
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
etags *.[ch]
|
etags *.[ch]
|
||||||
|
|
||||||
|
63
Makefile.in
63
Makefile.in
@ -28,9 +28,10 @@ LDFLAGS=libz.a
|
|||||||
LDSHARED=$(CC)
|
LDSHARED=$(CC)
|
||||||
CPP=$(CC) -E
|
CPP=$(CC) -E
|
||||||
|
|
||||||
VER=1.2.0.6
|
|
||||||
LIBS=libz.a
|
LIBS=libz.a
|
||||||
SHAREDLIB=libz.so
|
SHAREDLIB=libz.so
|
||||||
|
SHAREDLIBV=libz.so.1.2.0.7
|
||||||
|
SHAREDLIBM=libz.so.1
|
||||||
|
|
||||||
AR=ar rc
|
AR=ar rc
|
||||||
RANLIB=ranlib
|
RANLIB=ranlib
|
||||||
@ -52,19 +53,6 @@ OBJA =
|
|||||||
|
|
||||||
TEST_OBJS = example.o minigzip.o
|
TEST_OBJS = example.o minigzip.o
|
||||||
|
|
||||||
# Note: this has not been updated for zlib 1.2.0
|
|
||||||
DISTFILES = README FAQ INDEX ChangeLog configure Make*[a-z0-9] *.[ch] *.mms \
|
|
||||||
algorithm.txt zlib.3 zlib.html \
|
|
||||||
msdos/Make*[a-z0-9] msdos/zlib.def msdos/zlib.rc \
|
|
||||||
nt/Make*[a-z0-9] nt/zlib.dnt amiga/Make*.??? os2/M*.os2 os2/zlib.def \
|
|
||||||
contrib/RE*.contrib contrib/*.txt contrib/asm386/*.asm contrib/asm386/*.c \
|
|
||||||
contrib/asm386/*.bat contrib/asm386/zlibvc.d?? contrib/asm[56]86/*.?86 \
|
|
||||||
contrib/asm[56]86/*.S contrib/iostream/*.cpp \
|
|
||||||
contrib/iostream/*.h contrib/iostream2/*.h contrib/iostream2/*.cpp \
|
|
||||||
contrib/untgz/Makefile contrib/untgz/*.c contrib/untgz/*.w32 \
|
|
||||||
contrib/minizip/[CM]*[pe] contrib/minizip/*.[ch] contrib/minizip/*.[td]?? \
|
|
||||||
contrib/delphi*/*.???
|
|
||||||
|
|
||||||
all: example minigzip
|
all: example minigzip
|
||||||
|
|
||||||
check: test
|
check: test
|
||||||
@ -88,11 +76,11 @@ match.o: match.S
|
|||||||
mv _match.o match.o
|
mv _match.o match.o
|
||||||
rm -f _match.s
|
rm -f _match.s
|
||||||
|
|
||||||
$(SHAREDLIB).$(VER): $(OBJS)
|
$(SHAREDLIBV): $(OBJS)
|
||||||
$(LDSHARED) -o $@ $(OBJS)
|
$(LDSHARED) -o $@ $(OBJS)
|
||||||
rm -f $(SHAREDLIB) $(SHAREDLIB).1
|
rm -f $(SHAREDLIB) $(SHAREDLIBM)
|
||||||
ln -s $@ $(SHAREDLIB)
|
ln -s $@ $(SHAREDLIB)
|
||||||
ln -s $@ $(SHAREDLIB).1
|
ln -s $@ $(SHAREDLIBM)
|
||||||
|
|
||||||
example: example.o $(LIBS)
|
example: example.o $(LIBS)
|
||||||
$(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
|
$(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
|
||||||
@ -110,10 +98,10 @@ install: $(LIBS)
|
|||||||
cp $(LIBS) $(libdir)
|
cp $(LIBS) $(libdir)
|
||||||
cd $(libdir); chmod 755 $(LIBS)
|
cd $(libdir); chmod 755 $(LIBS)
|
||||||
-@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
|
-@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
|
||||||
cd $(libdir); if test -f $(SHAREDLIB).$(VER); then \
|
cd $(libdir); if test -f $(SHAREDLIBV); then \
|
||||||
rm -f $(SHAREDLIB) $(SHAREDLIB).1; \
|
rm -f $(SHAREDLIB) $(SHAREDLIBM); \
|
||||||
ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB); \
|
ln -s $(SHAREDLIBV) $(SHAREDLIB); \
|
||||||
ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB).1; \
|
ln -s $(SHAREDLIBV) $(SHAREDLIBM); \
|
||||||
(ldconfig || true) >/dev/null 2>&1; \
|
(ldconfig || true) >/dev/null 2>&1; \
|
||||||
fi
|
fi
|
||||||
cp zlib.3 $(man3dir)
|
cp zlib.3 $(man3dir)
|
||||||
@ -123,20 +111,15 @@ install: $(LIBS)
|
|||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
cd $(includedir); \
|
cd $(includedir); \
|
||||||
v=$(VER); \
|
|
||||||
if test -f zlib.h; then \
|
|
||||||
v=`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`; \
|
|
||||||
rm -f zlib.h zconf.h; \
|
|
||||||
fi; \
|
|
||||||
cd $(libdir); rm -f libz.a; \
|
cd $(libdir); rm -f libz.a; \
|
||||||
if test -f $(SHAREDLIB).$$v; then \
|
if test -f $(SHAREDLIBV); then \
|
||||||
rm -f $(SHAREDLIB).$$v $(SHAREDLIB) $(SHAREDLIB).1; \
|
rm -f $(SHAREDLIBV) $(SHAREDLIB) $(SHAREDLIBM); \
|
||||||
fi
|
fi
|
||||||
cd $(man3dir); rm -f zlib.3
|
cd $(man3dir); rm -f zlib.3
|
||||||
|
|
||||||
mostlyclean: clean
|
mostlyclean: clean
|
||||||
clean:
|
clean:
|
||||||
rm -f *.o *~ example minigzip libz.a libz.so* foo.gz so_locations \
|
rm -f *.o *~ example minigzip libz.* foo.gz so_locations \
|
||||||
_match.s maketree contrib/infback9/*.o
|
_match.s maketree contrib/infback9/*.o
|
||||||
|
|
||||||
maintainer-clean: distclean
|
maintainer-clean: distclean
|
||||||
@ -145,28 +128,6 @@ distclean: clean
|
|||||||
cp -p zconf.in.h zconf.h
|
cp -p zconf.in.h zconf.h
|
||||||
rm -f .DS_Store
|
rm -f .DS_Store
|
||||||
|
|
||||||
zip:
|
|
||||||
echo Warning: this has not been updated for zlib 1.2.0 -- do not use
|
|
||||||
mv Makefile Makefile~; cp -p Makefile.in Makefile
|
|
||||||
rm -f test.c ztest*.c contrib/minizip/test.zip
|
|
||||||
v=`sed -n -e 's/\.//g' -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\
|
|
||||||
zip -ul9 zlib$$v $(DISTFILES)
|
|
||||||
mv Makefile~ Makefile
|
|
||||||
|
|
||||||
dist:
|
|
||||||
echo Warning: this has not been updated for zlib 1.2.0 -- do not use
|
|
||||||
mv Makefile Makefile~; cp -p Makefile.in Makefile
|
|
||||||
rm -f test.c ztest*.c contrib/minizip/test.zip
|
|
||||||
d=zlib-`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\
|
|
||||||
rm -f $$d.tar.gz; \
|
|
||||||
if test ! -d ../$$d; then rm -f ../$$d; ln -s `pwd` ../$$d; fi; \
|
|
||||||
files=""; \
|
|
||||||
for f in $(DISTFILES); do files="$$files $$d/$$f"; done; \
|
|
||||||
cd ..; \
|
|
||||||
GZIP=-9 $(TAR) chofz $$d/$$d.tar.gz $$files; \
|
|
||||||
if test ! -d $$d; then rm -f $$d; fi
|
|
||||||
mv Makefile~ Makefile
|
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
etags *.[ch]
|
etags *.[ch]
|
||||||
|
|
||||||
|
33
README
33
README
@ -1,6 +1,6 @@
|
|||||||
ZLIB DATA COMPRESSION LIBRARY
|
ZLIB DATA COMPRESSION LIBRARY
|
||||||
|
|
||||||
zlib 1.2.0.6 is a general purpose data compression library. All the code is
|
zlib 1.2.0.7 is a general purpose data compression library. All the code is
|
||||||
thread safe. The data format used by the zlib library is described by RFCs
|
thread safe. The data format used by the zlib library is described by RFCs
|
||||||
(Request for Comments) 1950 to 1952 in the files
|
(Request for Comments) 1950 to 1952 in the files
|
||||||
http://www.ietf.org/rfc/rfc1950.txt (zlib format), rfc1951.txt (deflate format)
|
http://www.ietf.org/rfc/rfc1950.txt (zlib format), rfc1951.txt (deflate format)
|
||||||
@ -8,7 +8,7 @@ and rfc1952.txt (gzip format). These documents are also available in other
|
|||||||
formats from ftp://ftp.uu.net/graphics/png/documents/zlib/zdoc-index.html
|
formats from ftp://ftp.uu.net/graphics/png/documents/zlib/zdoc-index.html
|
||||||
|
|
||||||
All functions of the compression library are documented in the file zlib.h
|
All functions of the compression library are documented in the file zlib.h
|
||||||
(volunteer to write man pages welcome, contact jloup@gzip.org). A usage example
|
(volunteer to write man pages welcome, contact zlib@gzip.org). A usage example
|
||||||
of the library is given in the file example.c which also tests that the library
|
of the library is given in the file example.c which also tests that the library
|
||||||
is working correctly. Another example is given in the file minigzip.c. The
|
is working correctly. Another example is given in the file minigzip.c. The
|
||||||
compression library itself is composed of all source files except example.c and
|
compression library itself is composed of all source files except example.c and
|
||||||
@ -34,12 +34,12 @@ Mark Nelson <markn@ieee.org> wrote an article about zlib for the Jan. 1997
|
|||||||
issue of Dr. Dobb's Journal; a copy of the article is available in
|
issue of Dr. Dobb's Journal; a copy of the article is available in
|
||||||
http://dogma.net/markn/articles/zlibtool/zlibtool.htm
|
http://dogma.net/markn/articles/zlibtool/zlibtool.htm
|
||||||
|
|
||||||
The changes made in version 1.2.0.6 are documented in the file ChangeLog.
|
The changes made in version 1.2.0.7 are documented in the file ChangeLog.
|
||||||
|
|
||||||
Unsupported third party contributions are provided in directory "contrib".
|
Unsupported third party contributions are provided in directory "contrib".
|
||||||
|
|
||||||
A Java implementation of zlib is available in the Java Development Kit
|
A Java implementation of zlib is available in the Java Development Kit
|
||||||
http://www.javasoft.com/products/JDK/1.1/docs/api/Package-java.util.zip.html
|
http://java.sun.com/j2se/1.4.2/docs/api/java/util/zip/package-summary.html
|
||||||
See the zlib home page http://www.zlib.org for details.
|
See the zlib home page http://www.zlib.org for details.
|
||||||
|
|
||||||
A Perl interface to zlib written by Paul Marquess <pmqs@cpan.org> is in the
|
A Perl interface to zlib written by Paul Marquess <pmqs@cpan.org> is in the
|
||||||
@ -51,26 +51,16 @@ available in Python 1.5 and later versions, see
|
|||||||
http://www.python.org/doc/lib/module-zlib.html
|
http://www.python.org/doc/lib/module-zlib.html
|
||||||
|
|
||||||
A zlib binding for TCL written by Andreas Kupries <a.kupries@westend.com> is
|
A zlib binding for TCL written by Andreas Kupries <a.kupries@westend.com> is
|
||||||
availlable at http://www.westend.com/~kupries/doc/trf/man/man.html
|
availlable at http://www.oche.de/~akupries/soft/trf/trf_zip.html
|
||||||
|
|
||||||
An experimental package to read and write files in .zip format, written on top
|
An experimental package to read and write files in .zip format, written on top
|
||||||
of zlib by Gilles Vollant <info@winimage.com>, is available at
|
of zlib by Gilles Vollant <info@winimage.com>, is available in the
|
||||||
http://www.winimage.com/zLibDll/unzip.html and also in the contrib/minizip
|
contrib/minizip directory of zlib.
|
||||||
directory of zlib.
|
|
||||||
|
|
||||||
|
|
||||||
Notes for some targets:
|
Notes for some targets:
|
||||||
|
|
||||||
- To build a Windows DLL version, include in a DLL project zlib.def, zlib.rc
|
- For Windows DLL versions, please see win32/DLL_FAQ.txt
|
||||||
and all .c files except example.c and minigzip.c; compile with -DZLIB_DLL The
|
|
||||||
zlib DLL support was initially done by Alessandro Iacopetti and is now
|
|
||||||
maintained by Gilles Vollant <info@winimage.com>. Check the zlib DLL home
|
|
||||||
page at http://www.winimage.com/zLibDll
|
|
||||||
|
|
||||||
From Visual Basic, you can call the DLL functions which do not take a
|
|
||||||
structure as argument: compress, uncompress and all gz* functions. See
|
|
||||||
contrib/visual-basic.txt for more information, or get
|
|
||||||
http://www.tcfb.com/dowseware/cmp-z-it.zip
|
|
||||||
|
|
||||||
- For 64-bit Irix, deflate.c must be compiled without any optimization. With
|
- For 64-bit Irix, deflate.c must be compiled without any optimization. With
|
||||||
-O, one libpng test fails. The test works in 32 bit mode (with the -n32
|
-O, one libpng test fails. The test works in 32 bit mode (with the -n32
|
||||||
@ -90,8 +80,11 @@ Notes for some targets:
|
|||||||
- For Turbo C the small model is supported only with reduced performance to
|
- For Turbo C the small model is supported only with reduced performance to
|
||||||
avoid any far allocation; it was tested with -DMAX_WBITS=11 -DMAX_MEM_LEVEL=3
|
avoid any far allocation; it was tested with -DMAX_WBITS=11 -DMAX_MEM_LEVEL=3
|
||||||
|
|
||||||
- For PalmOs, see http://www.cs.uit.no/~perm/PASTA/pilot/software.html Per
|
- For PalmOs, see http://palmzlib.sourceforge.net/
|
||||||
Harald Myrvang <perm@stud.cs.uit.no>
|
|
||||||
|
- When building a shared, i.e. dynamic library on Mac OS X, the library must be
|
||||||
|
installed before testing (do "make install" before "make test"), since the
|
||||||
|
library location is specified in the library.
|
||||||
|
|
||||||
|
|
||||||
Acknowledgments:
|
Acknowledgments:
|
||||||
|
66
amiga/Makefile.pup
Normal file
66
amiga/Makefile.pup
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
# Amiga powerUP (TM) Makefile
|
||||||
|
# makefile for libpng and SAS C V6.58/7.00 PPC compiler
|
||||||
|
# Copyright (C) 1998 by Andreas R. Kleinert
|
||||||
|
|
||||||
|
LIBNAME = libzip.a
|
||||||
|
|
||||||
|
CC = scppc
|
||||||
|
CFLAGS = NOSTKCHK NOSINT OPTIMIZE OPTGO OPTPEEP OPTINLOCAL OPTINL \
|
||||||
|
OPTLOOP OPTRDEP=8 OPTDEP=8 OPTCOMP=8 NOVER
|
||||||
|
AR = ppc-amigaos-ar cr
|
||||||
|
RANLIB = ppc-amigaos-ranlib
|
||||||
|
LD = ppc-amigaos-ld -r
|
||||||
|
LDFLAGS = -o
|
||||||
|
LDLIBS = LIB:scppc.a LIB:end.o
|
||||||
|
RM = delete quiet
|
||||||
|
|
||||||
|
OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
|
||||||
|
zutil.o inflate.o infback.o inftrees.o inffast.o
|
||||||
|
|
||||||
|
TEST_OBJS = example.o minigzip.o
|
||||||
|
|
||||||
|
all: example minigzip
|
||||||
|
|
||||||
|
check: test
|
||||||
|
test: all
|
||||||
|
example
|
||||||
|
echo hello world | minigzip | minigzip -d
|
||||||
|
|
||||||
|
$(LIBNAME): $(OBJS)
|
||||||
|
$(AR) $@ $(OBJS)
|
||||||
|
-$(RANLIB) $@
|
||||||
|
|
||||||
|
example: example.o $(LIBNAME)
|
||||||
|
$(LD) $(LDFLAGS) $@ LIB:c_ppc.o $@.o $(LIBNAME) $(LDLIBS)
|
||||||
|
|
||||||
|
minigzip: minigzip.o $(LIBNAME)
|
||||||
|
$(LD) $(LDFLAGS) $@ LIB:c_ppc.o $@.o $(LIBNAME) $(LDLIBS)
|
||||||
|
|
||||||
|
mostlyclean: clean
|
||||||
|
clean:
|
||||||
|
$(RM) *.o example minigzip $(LIBNAME) foo.gz
|
||||||
|
|
||||||
|
zip:
|
||||||
|
zip -ul9 zlib README ChangeLog Makefile Make????.??? Makefile.?? \
|
||||||
|
descrip.mms *.[ch]
|
||||||
|
|
||||||
|
tgz:
|
||||||
|
cd ..; tar cfz zlib/zlib.tgz zlib/README zlib/ChangeLog zlib/Makefile \
|
||||||
|
zlib/Make????.??? zlib/Makefile.?? zlib/descrip.mms zlib/*.[ch]
|
||||||
|
|
||||||
|
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
||||||
|
|
||||||
|
adler32.o: zlib.h zconf.h
|
||||||
|
compress.o: zlib.h zconf.h
|
||||||
|
crc32.o: crc32.h zlib.h zconf.h
|
||||||
|
deflate.o: deflate.h zutil.h zlib.h zconf.h
|
||||||
|
example.o: zlib.h zconf.h
|
||||||
|
gzio.o: zutil.h zlib.h zconf.h
|
||||||
|
inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
|
inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
|
infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
|
inftrees.o: zutil.h zlib.h zconf.h inftrees.h
|
||||||
|
minigzip.o: zlib.h zconf.h
|
||||||
|
trees.o: deflate.h zutil.h zlib.h zconf.h trees.h
|
||||||
|
uncompr.o: zlib.h zconf.h
|
||||||
|
zutil.o: zutil.h zlib.h zconf.h
|
@ -10,22 +10,24 @@ CFLAGS=OPT
|
|||||||
LDFLAGS=LIB z.lib
|
LDFLAGS=LIB z.lib
|
||||||
|
|
||||||
SCOPTIONS=OPTSCHED OPTINLINE OPTALIAS OPTTIME OPTINLOCAL STRMERGE \
|
SCOPTIONS=OPTSCHED OPTINLINE OPTALIAS OPTTIME OPTINLOCAL STRMERGE \
|
||||||
NOICONS PARMS=BOTH NOSTACKCHECK UTILLIB NOVERSION ERRORREXX
|
NOICONS PARMS=BOTH NOSTACKCHECK UTILLIB NOVERSION ERRORREXX \
|
||||||
|
DEF=POSTINC
|
||||||
|
|
||||||
OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
|
OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
|
||||||
zutil.o inflate.o infblock.o inftrees.o infcodes.o infutil.o inffast.o
|
zutil.o inflate.o infback.o inftrees.o inffast.o
|
||||||
|
|
||||||
TEST_OBJS = example.o minigzip.o
|
TEST_OBJS = example.o minigzip.o
|
||||||
|
|
||||||
all: SCOPTIONS example minigzip
|
all: SCOPTIONS example minigzip
|
||||||
|
|
||||||
|
check: test
|
||||||
test: all
|
test: all
|
||||||
`cd`/example
|
example
|
||||||
echo hello world | minigzip | minigzip -d
|
echo hello world | minigzip | minigzip -d
|
||||||
|
|
||||||
install: z.lib
|
install: z.lib
|
||||||
copy zlib.h zconf.h INCLUDE: clone
|
copy clone zlib.h zconf.h INCLUDE:
|
||||||
copy z.lib LIB: clone
|
copy clone z.lib LIB:
|
||||||
|
|
||||||
z.lib: $(OBJS)
|
z.lib: $(OBJS)
|
||||||
oml z.lib r $(OBJS)
|
oml z.lib r $(OBJS)
|
||||||
@ -36,29 +38,28 @@ example: example.o z.lib
|
|||||||
minigzip: minigzip.o z.lib
|
minigzip: minigzip.o z.lib
|
||||||
$(CC) $(CFLAGS) LINK TO $@ minigzip.o $(LDFLAGS)
|
$(CC) $(CFLAGS) LINK TO $@ minigzip.o $(LDFLAGS)
|
||||||
|
|
||||||
|
mostlyclean: clean
|
||||||
clean:
|
clean:
|
||||||
-delete force quiet *.o example minigzip z.lib foo.gz *.lnk SCOPTIONS
|
-delete force quiet example minigzip *.o z.lib foo.gz *.lnk SCOPTIONS
|
||||||
|
|
||||||
SCOPTIONS: Smakefile
|
SCOPTIONS: Makefile.sas
|
||||||
copy to $@ <from <
|
copy to $@ <from <
|
||||||
$(SCOPTIONS)
|
$(SCOPTIONS)
|
||||||
<
|
<
|
||||||
|
|
||||||
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
||||||
|
|
||||||
adler32.o: zutil.h zlib.h zconf.h
|
adler32.o: zlib.h zconf.h
|
||||||
compress.o: zlib.h zconf.h
|
compress.o: zlib.h zconf.h
|
||||||
crc32.o: zutil.h zlib.h zconf.h
|
crc32.o: crc32.h zlib.h zconf.h
|
||||||
deflate.o: deflate.h zutil.h zlib.h zconf.h
|
deflate.o: deflate.h zutil.h zlib.h zconf.h
|
||||||
example.o: zlib.h zconf.h
|
example.o: zlib.h zconf.h
|
||||||
gzio.o: zutil.h zlib.h zconf.h
|
gzio.o: zutil.h zlib.h zconf.h
|
||||||
infblock.o: zutil.h zlib.h zconf.h infblock.h inftrees.h infcodes.h infutil.h
|
inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
infcodes.o: zutil.h zlib.h zconf.h inftrees.h infutil.h infcodes.h inffast.h
|
inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
inffast.o: zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h
|
infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
|
||||||
inflate.o: zutil.h zlib.h zconf.h infblock.h
|
|
||||||
inftrees.o: zutil.h zlib.h zconf.h inftrees.h
|
inftrees.o: zutil.h zlib.h zconf.h inftrees.h
|
||||||
infutil.o: zutil.h zlib.h zconf.h inftrees.h infutil.h
|
|
||||||
minigzip.o: zlib.h zconf.h
|
minigzip.o: zlib.h zconf.h
|
||||||
trees.o: deflate.h zutil.h zlib.h zconf.h
|
trees.o: deflate.h zutil.h zlib.h zconf.h trees.h
|
||||||
uncompr.o: zlib.h zconf.h
|
uncompr.o: zlib.h zconf.h
|
||||||
zutil.o: zutil.h zlib.h zconf.h
|
zutil.o: zutil.h zlib.h zconf.h
|
57
configure
vendored
57
configure
vendored
@ -20,8 +20,9 @@
|
|||||||
|
|
||||||
LIBS=libz.a
|
LIBS=libz.a
|
||||||
LDFLAGS="-L. ${LIBS}"
|
LDFLAGS="-L. ${LIBS}"
|
||||||
SHAREDLIB=libz.so
|
|
||||||
VER=`sed -n -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`
|
VER=`sed -n -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`
|
||||||
|
VER2=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\)\\..*/\1/p' < zlib.h`
|
||||||
|
VER1=`sed -n -e '/VERSION "/s/.*"\([0-9]*\)\\..*/\1/p' < zlib.h`
|
||||||
AR=${AR-"ar rc"}
|
AR=${AR-"ar rc"}
|
||||||
RANLIB=${RANLIB-"ranlib"}
|
RANLIB=${RANLIB-"ranlib"}
|
||||||
prefix=${prefix-/usr/local}
|
prefix=${prefix-/usr/local}
|
||||||
@ -55,10 +56,6 @@ case "$1" in
|
|||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ $shared -eq 1 ]; then
|
|
||||||
LDFLAGS="-L. ${SHAREDLIB}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
test=ztest$$
|
test=ztest$$
|
||||||
cat > $test.c <<EOF
|
cat > $test.c <<EOF
|
||||||
extern int getchar();
|
extern int getchar();
|
||||||
@ -85,6 +82,13 @@ if test "$gcc" -eq 1 && ($cc -c $cflags $test.c) 2>/dev/null; then
|
|||||||
HP-UX*) LDSHARED=${LDSHARED-"$cc -shared $SFLAGS"}
|
HP-UX*) LDSHARED=${LDSHARED-"$cc -shared $SFLAGS"}
|
||||||
shared_ext='.sl'
|
shared_ext='.sl'
|
||||||
SHAREDLIB='libz.sl';;
|
SHAREDLIB='libz.sl';;
|
||||||
|
Darwin*) shared_ext='.dylib'
|
||||||
|
SHAREDLIB=libz$shared_ext
|
||||||
|
SHAREDLIBV=libz.$VER$shared_ext
|
||||||
|
SHAREDLIBM=libz.$VER1$shared_ext
|
||||||
|
LDSHARED=${LDSHARED-"$cc -dynamiclib -install_name /usr/lib/$SHAREDLIBV -compatibility_version $VER2 -current_version $VER"}
|
||||||
|
libdir='/usr/lib'
|
||||||
|
includedir='/usr/include';;
|
||||||
*) LDSHARED=${LDSHARED-"$cc -shared"};;
|
*) LDSHARED=${LDSHARED-"$cc -shared"};;
|
||||||
esac
|
esac
|
||||||
else
|
else
|
||||||
@ -102,7 +106,7 @@ else
|
|||||||
LDSHARED=${LDSHARED-"cc -shared"};;
|
LDSHARED=${LDSHARED-"cc -shared"};;
|
||||||
OSF1\ V4*) SFLAGS=${CFLAGS-"-O -std1"}
|
OSF1\ V4*) SFLAGS=${CFLAGS-"-O -std1"}
|
||||||
CFLAGS=${CFLAGS-"-O -std1"}
|
CFLAGS=${CFLAGS-"-O -std1"}
|
||||||
LDSHARED=${LDSHARED-"cc -shared -Wl,-soname,$SHAREDLIB -Wl,-msym -Wl,-rpath,$(libdir) -Wl,-set_version,${VER}:1.0"};;
|
LDSHARED=${LDSHARED-"cc -shared -Wl,-soname,libz.so -Wl,-msym -Wl,-rpath,$(libdir) -Wl,-set_version,${VER}:1.0"};;
|
||||||
OSF1*) SFLAGS=${CFLAGS-"-O -std1"}
|
OSF1*) SFLAGS=${CFLAGS-"-O -std1"}
|
||||||
CFLAGS=${CFLAGS-"-O -std1"}
|
CFLAGS=${CFLAGS-"-O -std1"}
|
||||||
LDSHARED=${LDSHARED-"cc -shared"};;
|
LDSHARED=${LDSHARED-"cc -shared"};;
|
||||||
@ -143,14 +147,18 @@ else
|
|||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
SHAREDLIB=${SHAREDLIB-"libz$shared_ext"}
|
||||||
|
SHAREDLIBV=${SHAREDLIBV-"libz$shared_ext.$VER"}
|
||||||
|
SHAREDLIBM=${SHAREDLIBM-"libz$shared_ext.$VER1"}
|
||||||
|
|
||||||
if test $shared -eq 1; then
|
if test $shared -eq 1; then
|
||||||
echo Checking for shared library support...
|
echo Checking for shared library support...
|
||||||
# we must test in two steps (cc then ld), required at least on SunOS 4.x
|
# we must test in two steps (cc then ld), required at least on SunOS 4.x
|
||||||
if test "`($CC -c $SFLAGS $test.c) 2>&1`" = "" &&
|
if test "`($CC -c $SFLAGS $test.c) 2>&1`" = "" &&
|
||||||
test "`($LDSHARED -o $test$shared_ext $test.o) 2>&1`" = ""; then
|
test "`($LDSHARED -o $test$shared_ext $test.o) 2>&1`" = ""; then
|
||||||
CFLAGS="$SFLAGS"
|
CFLAGS="$SFLAGS"
|
||||||
LIBS="$SHAREDLIB.$VER"
|
LIBS="$SHAREDLIBV"
|
||||||
echo Building shared library $SHAREDLIB.$VER with $CC.
|
echo Building shared library $SHAREDLIBV with $CC.
|
||||||
elif test -z "$old_cc" -a -z "$old_cflags"; then
|
elif test -z "$old_cc" -a -z "$old_cflags"; then
|
||||||
echo No shared library support.
|
echo No shared library support.
|
||||||
shared=0;
|
shared=0;
|
||||||
@ -162,6 +170,8 @@ fi
|
|||||||
if test $shared -eq 0; then
|
if test $shared -eq 0; then
|
||||||
LDSHARED="$CC"
|
LDSHARED="$CC"
|
||||||
echo Building static library $LIBS version $VER with $CC.
|
echo Building static library $LIBS version $VER with $CC.
|
||||||
|
else
|
||||||
|
LDFLAGS="-L. ${SHAREDLIBV}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cat > $test.c <<EOF
|
cat > $test.c <<EOF
|
||||||
@ -422,19 +432,20 @@ rm -f $test.[co] $test$shared_ext
|
|||||||
|
|
||||||
# udpate Makefile
|
# udpate Makefile
|
||||||
sed < Makefile.in "
|
sed < Makefile.in "
|
||||||
/^CC *=/s%=.*%=$CC%
|
/^CC *=/s#=.*#=$CC#
|
||||||
/^CFLAGS *=/s%=.*%=$CFLAGS%
|
/^CFLAGS *=/s#=.*#=$CFLAGS#
|
||||||
/^CPP *=/s%=.*%=$CPP%
|
/^CPP *=/s#=.*#=$CPP#
|
||||||
/^LDSHARED *=/s%=.*%=$LDSHARED%
|
/^LDSHARED *=/s#=.*#=$LDSHARED#
|
||||||
/^LIBS *=/s%=.*%=$LIBS%
|
/^LIBS *=/s#=.*#=$LIBS#
|
||||||
/^SHAREDLIB *=/s%=.*%=$SHAREDLIB%
|
/^SHAREDLIB *=/s#=.*#=$SHAREDLIB#
|
||||||
/^AR *=/s%=.*%=$AR%
|
/^SHAREDLIBV *=/s#=.*#=$SHAREDLIBV#
|
||||||
/^RANLIB *=/s%=.*%=$RANLIB%
|
/^SHAREDLIBM *=/s#=.*#=$SHAREDLIBM#
|
||||||
/^VER *=/s%=.*%=$VER%
|
/^AR *=/s#=.*#=$AR#
|
||||||
/^prefix *=/s%=.*%=$prefix%
|
/^RANLIB *=/s#=.*#=$RANLIB#
|
||||||
/^exec_prefix *=/s%=.*%=$exec_prefix%
|
/^prefix *=/s#=.*#=$prefix#
|
||||||
/^libdir *=/s%=.*%=$libdir%
|
/^exec_prefix *=/s#=.*#=$exec_prefix#
|
||||||
/^includedir *=/s%=.*%=$includedir%
|
/^libdir *=/s#=.*#=$libdir#
|
||||||
/^mandir *=/s%=.*%=$mandir%
|
/^includedir *=/s#=.*#=$includedir#
|
||||||
/^LDFLAGS *=/s%=.*%=$LDFLAGS%
|
/^mandir *=/s#=.*#=$mandir#
|
||||||
|
/^LDFLAGS *=/s#=.*#=$LDFLAGS#
|
||||||
" > Makefile
|
" > Makefile
|
||||||
|
@ -321,7 +321,7 @@ void FAR *out_desc;
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
length = (unsigned)hold & 0xffff;
|
length = (unsigned)hold & 0xffff;
|
||||||
Tracev((stderr, "inflate: stored length %u\n",
|
Tracev((stderr, "inflate: stored length %lu\n",
|
||||||
length));
|
length));
|
||||||
INITBITS();
|
INITBITS();
|
||||||
|
|
||||||
@ -507,7 +507,7 @@ void FAR *out_desc;
|
|||||||
length += BITS(extra);
|
length += BITS(extra);
|
||||||
DROPBITS(extra);
|
DROPBITS(extra);
|
||||||
}
|
}
|
||||||
Tracevv((stderr, "inflate: length %u\n", length));
|
Tracevv((stderr, "inflate: length %lu\n", length));
|
||||||
|
|
||||||
/* get distance code */
|
/* get distance code */
|
||||||
for (;;) {
|
for (;;) {
|
||||||
@ -545,7 +545,7 @@ void FAR *out_desc;
|
|||||||
mode = BAD;
|
mode = BAD;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
Tracevv((stderr, "inflate: distance %u\n", offset));
|
Tracevv((stderr, "inflate: distance %lu\n", offset));
|
||||||
|
|
||||||
/* copy match from window to output */
|
/* copy match from window to output */
|
||||||
do {
|
do {
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
#define MAXBITS 15
|
#define MAXBITS 15
|
||||||
|
|
||||||
const char inflate9_copyright[] =
|
const char inflate9_copyright[] =
|
||||||
" inflate9 1.2.0.6 Copyright 1995-2003 Mark Adler ";
|
" inflate9 1.2.0.7 Copyright 1995-2003 Mark Adler ";
|
||||||
/*
|
/*
|
||||||
If you use the zlib library in a product, an acknowledgment is welcome
|
If you use the zlib library in a product, an acknowledgment is welcome
|
||||||
in the documentation of your product. If for some reason you cannot
|
in the documentation of your product. If for some reason you cannot
|
||||||
@ -64,7 +64,7 @@ unsigned short FAR *work;
|
|||||||
static const unsigned short lext[31] = { /* Length codes 257..285 extra */
|
static const unsigned short lext[31] = { /* Length codes 257..285 extra */
|
||||||
128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129,
|
128, 128, 128, 128, 128, 128, 128, 128, 129, 129, 129, 129,
|
||||||
130, 130, 130, 130, 131, 131, 131, 131, 132, 132, 132, 132,
|
130, 130, 130, 130, 131, 131, 131, 131, 132, 132, 132, 132,
|
||||||
133, 133, 133, 133, 144, 65, 77};
|
133, 133, 133, 133, 144, 71, 69};
|
||||||
static const unsigned short dbase[32] = { /* Distance codes 0..31 base */
|
static const unsigned short dbase[32] = { /* Distance codes 0..31 base */
|
||||||
1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49,
|
1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49,
|
||||||
65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073,
|
65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073,
|
||||||
|
@ -1,8 +1,9 @@
|
|||||||
/*
|
/*
|
||||||
* untgz.c -- Display contents and/or extract file from
|
* untgz.c -- Display contents and extract files from a gzip'd TAR file
|
||||||
* a gzip'd TAR file
|
*
|
||||||
* written by "Pedro A. Aranda Guti\irrez" <paag@tid.es>
|
* written by "Pedro A. Aranda Guti\irrez" <paag@tid.es>
|
||||||
* adaptation to Unix by Jean-loup Gailly <jloup@gzip.org>
|
* adaptation to Unix by Jean-loup Gailly <jloup@gzip.org>
|
||||||
|
* various fixes by Cosmin Truta <cosmint@cs.ubbcluj.ro>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
@ -10,7 +11,9 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <fcntl.h>
|
|
||||||
|
#include "zlib.h"
|
||||||
|
|
||||||
#ifdef unix
|
#ifdef unix
|
||||||
# include <unistd.h>
|
# include <unistd.h>
|
||||||
#else
|
#else
|
||||||
@ -18,27 +21,22 @@
|
|||||||
# include <io.h>
|
# include <io.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "zlib.h"
|
|
||||||
|
|
||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
# ifndef F_OK
|
# ifndef F_OK
|
||||||
# define F_OK (0)
|
# define F_OK 0
|
||||||
# endif
|
# endif
|
||||||
|
# define mkdir(dirname,mode) _mkdir(dirname)
|
||||||
# ifdef _MSC_VER
|
# ifdef _MSC_VER
|
||||||
# define mkdir(dirname,mode) _mkdir(dirname)
|
|
||||||
# define strdup(str) _strdup(str)
|
# define strdup(str) _strdup(str)
|
||||||
# define unlink(fn) _unlink(fn)
|
|
||||||
# define access(path,mode) _access(path,mode)
|
# define access(path,mode) _access(path,mode)
|
||||||
# else
|
|
||||||
# define mkdir(dirname,mode) _mkdir(dirname)
|
|
||||||
# endif
|
# endif
|
||||||
#else
|
#else
|
||||||
# include <utime.h>
|
# include <utime.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* Values used in typeflag field. */
|
/* values used in typeflag field */
|
||||||
|
|
||||||
#define REGTYPE '0' /* regular file */
|
#define REGTYPE '0' /* regular file */
|
||||||
#define AREGTYPE '\0' /* regular file */
|
#define AREGTYPE '\0' /* regular file */
|
||||||
@ -78,40 +76,38 @@ union tar_buffer {
|
|||||||
struct tar_header header;
|
struct tar_header header;
|
||||||
};
|
};
|
||||||
|
|
||||||
enum { TGZ_EXTRACT = 0, TGZ_LIST };
|
enum { TGZ_EXTRACT, TGZ_LIST, TGZ_INVALID };
|
||||||
|
|
||||||
static char *TGZfname OF((const char *));
|
char *TGZfname OF((const char *));
|
||||||
void TGZnotfound OF((const char *));
|
void TGZnotfound OF((const char *));
|
||||||
|
|
||||||
int getoct OF((char *, int));
|
int getoct OF((char *, int));
|
||||||
char *strtime OF((time_t *));
|
char *strtime OF((time_t *));
|
||||||
int setftime OF((char *, time_t));
|
int setfiletime OF((char *, time_t));
|
||||||
int ExprMatch OF((char *, char *));
|
int ExprMatch OF((char *, char *));
|
||||||
|
|
||||||
int makedir OF((char *));
|
int makedir OF((char *));
|
||||||
int matchname OF((int, int, char **, char *));
|
int matchname OF((int, int, char **, char *));
|
||||||
|
|
||||||
void error OF((const char *));
|
void error OF((const char *));
|
||||||
int tar OF((gzFile, int, int, int, char **));
|
int tar OF((gzFile, int, int, int, char **));
|
||||||
|
|
||||||
void help OF((int));
|
void help OF((int));
|
||||||
int main OF((int, char **));
|
int main OF((int, char **));
|
||||||
|
|
||||||
char *prog;
|
char *prog;
|
||||||
|
|
||||||
/* This will give a benign warning */
|
const char *TGZsuffix[] = { "\0", ".tar", ".tar.gz", ".taz", ".tgz", NULL };
|
||||||
|
|
||||||
static char *TGZsuffix[] = { "\0", ".tar", ".tar.gz", ".taz", ".tgz", NULL };
|
/* return the file name of the TGZ archive */
|
||||||
|
/* or NULL if it does not exist */
|
||||||
|
|
||||||
/* Return the real name of the TGZ archive */
|
char *TGZfname (const char *arcname)
|
||||||
/* or NULL if it does not exist. */
|
|
||||||
|
|
||||||
static char *TGZfname (const char *fname)
|
|
||||||
{
|
{
|
||||||
static char buffer[1024];
|
static char buffer[1024];
|
||||||
int origlen,i;
|
int origlen,i;
|
||||||
|
|
||||||
strcpy(buffer,fname);
|
strcpy(buffer,arcname);
|
||||||
origlen = strlen(buffer);
|
origlen = strlen(buffer);
|
||||||
|
|
||||||
for (i=0; TGZsuffix[i]; i++)
|
for (i=0; TGZsuffix[i]; i++)
|
||||||
@ -123,55 +119,67 @@ static char *TGZfname (const char *fname)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* error message for the filename */
|
/* error message for the filename */
|
||||||
|
|
||||||
void TGZnotfound (const char *fname)
|
void TGZnotfound (const char *arcname)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
fprintf(stderr,"%s : couldn't find ",prog);
|
fprintf(stderr,"%s: Couldn't find ",prog);
|
||||||
for (i=0;TGZsuffix[i];i++)
|
for (i=0;TGZsuffix[i];i++)
|
||||||
fprintf(stderr,(TGZsuffix[i+1]) ? "%s%s, " : "or %s%s\n",
|
fprintf(stderr,(TGZsuffix[i+1]) ? "%s%s, " : "or %s%s\n",
|
||||||
fname,
|
arcname,
|
||||||
TGZsuffix[i]);
|
TGZsuffix[i]);
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* help functions */
|
/* convert octal digits to int */
|
||||||
|
/* on error return -1 */
|
||||||
|
|
||||||
int getoct (char *p,int width)
|
int getoct (char *p,int width)
|
||||||
{
|
{
|
||||||
int result = 0;
|
int result = 0;
|
||||||
char c;
|
char c;
|
||||||
|
|
||||||
while (width --)
|
while (width--)
|
||||||
{
|
{
|
||||||
c = *p++;
|
c = *p++;
|
||||||
if (c == ' ')
|
|
||||||
continue;
|
|
||||||
if (c == 0)
|
if (c == 0)
|
||||||
break;
|
break;
|
||||||
|
if (c == ' ')
|
||||||
|
continue;
|
||||||
|
if (c < '0' || c > '7')
|
||||||
|
return -1;
|
||||||
result = result * 8 + (c - '0');
|
result = result * 8 + (c - '0');
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* convert time_t to string */
|
||||||
|
/* use the "YYYY/MM/DD hh:mm:ss" format */
|
||||||
|
|
||||||
char *strtime (time_t *t)
|
char *strtime (time_t *t)
|
||||||
{
|
{
|
||||||
struct tm *local;
|
struct tm *local;
|
||||||
static char result[32];
|
static char result[32];
|
||||||
|
|
||||||
local = localtime(t);
|
local = localtime(t);
|
||||||
sprintf(result,"%2d/%02d/%4d %02d:%02d:%02d",
|
sprintf(result,"%4d/%02d/%02d %02d:%02d:%02d",
|
||||||
local->tm_mday, local->tm_mon+1, local->tm_year+1900,
|
local->tm_year+1900, local->tm_mon+1, local->tm_mday,
|
||||||
local->tm_hour, local->tm_min, local->tm_sec);
|
local->tm_hour, local->tm_min, local->tm_sec);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
int setftime (char *fname,time_t ftime)
|
|
||||||
|
/* set file time */
|
||||||
|
|
||||||
|
int setfiletime (char *fname,time_t ftime)
|
||||||
{
|
{
|
||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
|
static int isWinNT = -1;
|
||||||
SYSTEMTIME st;
|
SYSTEMTIME st;
|
||||||
FILETIME locft, modft;
|
FILETIME locft, modft;
|
||||||
struct tm *loctm;
|
struct tm *loctm;
|
||||||
@ -194,8 +202,11 @@ int setftime (char *fname,time_t ftime)
|
|||||||
!LocalFileTimeToFileTime(&locft, &modft))
|
!LocalFileTimeToFileTime(&locft, &modft))
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
hFile = CreateFile(fname, GENERIC_READ | GENERIC_WRITE,
|
if (isWinNT < 0)
|
||||||
0, NULL, OPEN_EXISTING, 0, 0);
|
isWinNT = (GetVersion() < 0x80000000) ? 1 : 0;
|
||||||
|
hFile = CreateFile(fname, GENERIC_WRITE, 0, NULL, OPEN_EXISTING,
|
||||||
|
(isWinNT ? FILE_FLAG_BACKUP_SEMANTICS : 0),
|
||||||
|
NULL);
|
||||||
if (hFile == INVALID_HANDLE_VALUE)
|
if (hFile == INVALID_HANDLE_VALUE)
|
||||||
return -1;
|
return -1;
|
||||||
result = SetFileTime(hFile, NULL, NULL, &modft) ? 0 : -1;
|
result = SetFileTime(hFile, NULL, NULL, &modft) ? 0 : -1;
|
||||||
@ -246,10 +257,9 @@ int ExprMatch (char *string,char *expr)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* recursive make directory */
|
|
||||||
/* abort if you get an ENOENT errno somewhere in the middle */
|
/* recursive mkdir */
|
||||||
/* e.g. ignore error "mkdir on existing directory" */
|
/* abort on ENOENT; ignore other errors like "directory already exists" */
|
||||||
/* */
|
|
||||||
/* return 1 if OK */
|
/* return 1 if OK */
|
||||||
/* 0 on error */
|
/* 0 on error */
|
||||||
|
|
||||||
@ -266,7 +276,7 @@ int makedir (char *newdir)
|
|||||||
if (buffer[len-1] == '/') {
|
if (buffer[len-1] == '/') {
|
||||||
buffer[len-1] = '\0';
|
buffer[len-1] = '\0';
|
||||||
}
|
}
|
||||||
if (mkdir(buffer, 0775) == 0)
|
if (mkdir(buffer, 0755) == 0)
|
||||||
{
|
{
|
||||||
free(buffer);
|
free(buffer);
|
||||||
return 1;
|
return 1;
|
||||||
@ -281,9 +291,9 @@ int makedir (char *newdir)
|
|||||||
p++;
|
p++;
|
||||||
hold = *p;
|
hold = *p;
|
||||||
*p = 0;
|
*p = 0;
|
||||||
if ((mkdir(buffer, 0775) == -1) && (errno == ENOENT))
|
if ((mkdir(buffer, 0755) == -1) && (errno == ENOENT))
|
||||||
{
|
{
|
||||||
fprintf(stderr,"%s: couldn't create directory %s\n",prog,buffer);
|
fprintf(stderr,"%s: Couldn't create directory %s\n",prog,buffer);
|
||||||
free(buffer);
|
free(buffer);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -295,9 +305,10 @@ int makedir (char *newdir)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int matchname (int arg,int argc,char **argv,char *fname)
|
int matchname (int arg,int argc,char **argv,char *fname)
|
||||||
{
|
{
|
||||||
if (arg == argc) /* no arguments given (untgz tgzarchive) */
|
if (arg == argc) /* no arguments given (untgz tgzarchive) */
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
while (arg < argc)
|
while (arg < argc)
|
||||||
@ -308,7 +319,7 @@ int matchname (int arg,int argc,char **argv,char *fname)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Tar file list or extract */
|
/* tar file list or extract */
|
||||||
|
|
||||||
int tar (gzFile in,int action,int arg,int argc,char **argv)
|
int tar (gzFile in,int action,int arg,int argc,char **argv)
|
||||||
{
|
{
|
||||||
@ -319,22 +330,26 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
int remaining = 0;
|
int remaining = 0;
|
||||||
FILE *outfile = NULL;
|
FILE *outfile = NULL;
|
||||||
char fname[BLOCKSIZE];
|
char fname[BLOCKSIZE];
|
||||||
|
int tarmode;
|
||||||
time_t tartime;
|
time_t tartime;
|
||||||
|
|
||||||
if (action == TGZ_LIST)
|
if (action == TGZ_LIST)
|
||||||
printf(" day time size file\n"
|
printf(" date time size file\n"
|
||||||
" ---------- -------- --------- -------------------------------------\n");
|
" ---------- -------- --------- -------------------------------------\n");
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
len = gzread(in, &buffer, BLOCKSIZE);
|
len = gzread(in, &buffer, BLOCKSIZE);
|
||||||
if (len < 0)
|
if (len < 0)
|
||||||
error (gzerror(in, &err));
|
error(gzerror(in, &err));
|
||||||
/*
|
/*
|
||||||
* Always expect complete blocks to process
|
* Always expect complete blocks to process
|
||||||
* the tar information.
|
* the tar information.
|
||||||
*/
|
*/
|
||||||
if (len != BLOCKSIZE)
|
if (len != BLOCKSIZE)
|
||||||
error("gzread: incomplete block read");
|
{
|
||||||
|
action = TGZ_INVALID; /* force error exit */
|
||||||
|
remaining = 0; /* force I/O cleanup */
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If we have to get a tar header
|
* If we have to get a tar header
|
||||||
@ -346,9 +361,16 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
* or the end-of-tar block,
|
* or the end-of-tar block,
|
||||||
* we are done
|
* we are done
|
||||||
*/
|
*/
|
||||||
if ((len == 0) || (buffer.header.name[0]== 0)) break;
|
if ((len == 0) || (buffer.header.name[0] == 0)) break;
|
||||||
|
|
||||||
|
tarmode = getoct(buffer.header.mode,8);
|
||||||
tartime = (time_t)getoct(buffer.header.mtime,12);
|
tartime = (time_t)getoct(buffer.header.mtime,12);
|
||||||
|
if (tarmode == -1 || tartime == (time_t)-1)
|
||||||
|
{
|
||||||
|
buffer.header.name[0] = 0;
|
||||||
|
action = TGZ_INVALID;
|
||||||
|
}
|
||||||
|
|
||||||
strcpy(fname,buffer.header.name);
|
strcpy(fname,buffer.header.name);
|
||||||
|
|
||||||
switch (buffer.header.typeflag)
|
switch (buffer.header.typeflag)
|
||||||
@ -357,16 +379,24 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
if (action == TGZ_LIST)
|
if (action == TGZ_LIST)
|
||||||
printf(" %s <dir> %s\n",strtime(&tartime),fname);
|
printf(" %s <dir> %s\n",strtime(&tartime),fname);
|
||||||
if (action == TGZ_EXTRACT)
|
if (action == TGZ_EXTRACT)
|
||||||
makedir(fname);
|
{
|
||||||
|
makedir(fname);
|
||||||
|
setfiletime(fname,tartime);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case REGTYPE:
|
case REGTYPE:
|
||||||
case AREGTYPE:
|
case AREGTYPE:
|
||||||
remaining = getoct(buffer.header.size,12);
|
remaining = getoct(buffer.header.size,12);
|
||||||
|
if (remaining == -1)
|
||||||
|
{
|
||||||
|
action = TGZ_INVALID;
|
||||||
|
break;
|
||||||
|
}
|
||||||
if (action == TGZ_LIST)
|
if (action == TGZ_LIST)
|
||||||
printf(" %s %9d %s\n",strtime(&tartime),remaining,fname);
|
printf(" %s %9d %s\n",strtime(&tartime),remaining,fname);
|
||||||
if (action == TGZ_EXTRACT)
|
else if (action == TGZ_EXTRACT)
|
||||||
{
|
{
|
||||||
if ((remaining) && (matchname(arg,argc,argv,fname)))
|
if (matchname(arg,argc,argv,fname))
|
||||||
{
|
{
|
||||||
outfile = fopen(fname,"wb");
|
outfile = fopen(fname,"wb");
|
||||||
if (outfile == NULL) {
|
if (outfile == NULL) {
|
||||||
@ -379,18 +409,15 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
outfile = fopen(fname,"wb");
|
outfile = fopen(fname,"wb");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
fprintf(stderr,
|
if (outfile != NULL)
|
||||||
"%s %s\n",
|
printf("Extracting %s\n",fname);
|
||||||
(outfile) ? "Extracting" : "Couldn't create",
|
else
|
||||||
fname);
|
fprintf(stderr, "%s: Couldn't create %s",prog,fname);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
outfile = NULL;
|
outfile = NULL;
|
||||||
}
|
}
|
||||||
/*
|
getheader = 0;
|
||||||
* could have no contents
|
|
||||||
*/
|
|
||||||
getheader = (remaining) ? 0 : 1;
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
if (action == TGZ_LIST)
|
if (action == TGZ_LIST)
|
||||||
@ -402,27 +429,39 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
{
|
{
|
||||||
unsigned int bytes = (remaining > BLOCKSIZE) ? BLOCKSIZE : remaining;
|
unsigned int bytes = (remaining > BLOCKSIZE) ? BLOCKSIZE : remaining;
|
||||||
|
|
||||||
if ((action == TGZ_EXTRACT) && (outfile != NULL))
|
if (outfile != NULL)
|
||||||
{
|
{
|
||||||
if (fwrite(&buffer,sizeof(char),bytes,outfile) != bytes)
|
if (fwrite(&buffer,sizeof(char),bytes,outfile) != bytes)
|
||||||
{
|
{
|
||||||
fprintf(stderr,"%s : error writing %s skipping...\n",prog,fname);
|
fprintf(stderr,"%s: Error writing %s -- skipping\n",prog,fname);
|
||||||
fclose(outfile);
|
fclose(outfile);
|
||||||
unlink(fname);
|
outfile = NULL;
|
||||||
|
remove(fname);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
remaining -= bytes;
|
remaining -= bytes;
|
||||||
if (remaining == 0)
|
}
|
||||||
|
|
||||||
|
if (remaining == 0)
|
||||||
|
{
|
||||||
|
getheader = 1;
|
||||||
|
if (outfile != NULL)
|
||||||
{
|
{
|
||||||
getheader = 1;
|
fclose(outfile);
|
||||||
if ((action == TGZ_EXTRACT) && (outfile != NULL))
|
outfile = NULL;
|
||||||
{
|
if (action != TGZ_INVALID)
|
||||||
fclose(outfile);
|
setfiletime(fname,tartime);
|
||||||
outfile = NULL;
|
|
||||||
setftime(fname,tartime);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Abandon if errors are found
|
||||||
|
*/
|
||||||
|
if (action == TGZ_INVALID)
|
||||||
|
{
|
||||||
|
error("broken archive");
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gzclose(in) != Z_OK)
|
if (gzclose(in) != Z_OK)
|
||||||
@ -432,30 +471,32 @@ int tar (gzFile in,int action,int arg,int argc,char **argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* =========================================================== */
|
/* ============================================================ */
|
||||||
|
|
||||||
void help(int exitval)
|
void help(int exitval)
|
||||||
{
|
{
|
||||||
fprintf(stderr,
|
printf("untgz version 0.2\n"
|
||||||
"untgz version 0.1\n"
|
" using zlib version %s\n\n",
|
||||||
" a sample application of zlib\n\n"
|
zlibVersion());
|
||||||
"Usage : untgz file.tgz to extract all files\n"
|
printf("Usage: untgz file.tgz extract all files\n"
|
||||||
" untgz file.tgz fname ... to extract selected files\n"
|
" untgz file.tgz fname ... extract selected files\n"
|
||||||
" untgz -l file.tgz to list archive contents\n"
|
" untgz -l file.tgz list archive contents\n"
|
||||||
" untgz -h to display this help\n\n");
|
" untgz -h display this help\n");
|
||||||
exit(exitval);
|
exit(exitval);
|
||||||
}
|
}
|
||||||
|
|
||||||
void error(const char *msg)
|
void error(const char *msg)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "%s: %s\n", prog, msg);
|
fprintf(stderr, "%s: %s\n", prog, msg);
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* ====================================================================== */
|
/* ============================================================ */
|
||||||
|
|
||||||
int _CRT_glob = 0; /* disable globbing of the arguments */
|
#if defined(WIN32) && defined(__GNUC__)
|
||||||
|
int _CRT_glob = 0; /* disable argument globbing in MinGW */
|
||||||
|
#endif
|
||||||
|
|
||||||
int main(int argc,char **argv)
|
int main(int argc,char **argv)
|
||||||
{
|
{
|
||||||
@ -464,7 +505,6 @@ int main(int argc,char **argv)
|
|||||||
char *TGZfile;
|
char *TGZfile;
|
||||||
gzFile *f;
|
gzFile *f;
|
||||||
|
|
||||||
|
|
||||||
prog = strrchr(argv[0],'\\');
|
prog = strrchr(argv[0],'\\');
|
||||||
if (prog == NULL)
|
if (prog == NULL)
|
||||||
{
|
{
|
||||||
@ -514,16 +554,14 @@ int main(int argc,char **argv)
|
|||||||
f = gzopen(TGZfile,"rb");
|
f = gzopen(TGZfile,"rb");
|
||||||
if (f == NULL)
|
if (f == NULL)
|
||||||
{
|
{
|
||||||
fprintf(stderr,"%s: Couldn't gzopen %s\n",
|
fprintf(stderr,"%s: Couldn't gzopen %s\n",prog,TGZfile);
|
||||||
prog,
|
|
||||||
TGZfile);
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
exit(tar(f, action, arg, argc, argv));
|
exit(tar(f, action, arg, argc, argv));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
error("Unknown option!");
|
error("Unknown option");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@
|
|||||||
#include "deflate.h"
|
#include "deflate.h"
|
||||||
|
|
||||||
const char deflate_copyright[] =
|
const char deflate_copyright[] =
|
||||||
" deflate 1.2.0.6 Copyright 1995-2003 Jean-loup Gailly ";
|
" deflate 1.2.0.7 Copyright 1995-2003 Jean-loup Gailly ";
|
||||||
/*
|
/*
|
||||||
If you use the zlib library in a product, an acknowledgment is welcome
|
If you use the zlib library in a product, an acknowledgment is welcome
|
||||||
in the documentation of your product. If for some reason you cannot
|
in the documentation of your product. If for some reason you cannot
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
#define MAXBITS 15
|
#define MAXBITS 15
|
||||||
|
|
||||||
const char inflate_copyright[] =
|
const char inflate_copyright[] =
|
||||||
" inflate 1.2.0.6 Copyright 1995-2003 Mark Adler ";
|
" inflate 1.2.0.7 Copyright 1995-2003 Mark Adler ";
|
||||||
/*
|
/*
|
||||||
If you use the zlib library in a product, an acknowledgment is welcome
|
If you use the zlib library in a product, an acknowledgment is welcome
|
||||||
in the documentation of your product. If for some reason you cannot
|
in the documentation of your product. If for some reason you cannot
|
||||||
@ -62,7 +62,7 @@ unsigned short FAR *work;
|
|||||||
35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0};
|
35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0};
|
||||||
static const unsigned short lext[31] = { /* Length codes 257..285 extra */
|
static const unsigned short lext[31] = { /* Length codes 257..285 extra */
|
||||||
16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18,
|
16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18,
|
||||||
19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 65, 77};
|
19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 71, 69};
|
||||||
static const unsigned short dbase[32] = { /* Distance codes 0..29 base */
|
static const unsigned short dbase[32] = { /* Distance codes 0..29 base */
|
||||||
1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193,
|
1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193,
|
||||||
257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145,
|
257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145,
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
This directory contains files that have not been updated for zlib 1.2.0.
|
This directory contains files that have not been updated for zlib 1.2.
|
||||||
|
|
||||||
(Volunteers are encouraged to help clean this up. Thanks.)
|
(Volunteers are encouraged to help clean this up. Thanks.)
|
||||||
|
@ -1,66 +0,0 @@
|
|||||||
# Amiga powerUP (TM) Makefile
|
|
||||||
# makefile for libpng and SAS C V6.58/7.00 PPC compiler
|
|
||||||
# Copyright (C) 1998 by Andreas R. Kleinert
|
|
||||||
|
|
||||||
CC = scppc
|
|
||||||
CFLAGS = NOSTKCHK NOSINT OPTIMIZE OPTGO OPTPEEP OPTINLOCAL OPTINL \
|
|
||||||
OPTLOOP OPTRDEP=8 OPTDEP=8 OPTCOMP=8
|
|
||||||
LIBNAME = libzip.a
|
|
||||||
AR = ppc-amigaos-ar
|
|
||||||
AR_FLAGS = cr
|
|
||||||
RANLIB = ppc-amigaos-ranlib
|
|
||||||
LDFLAGS = -r -o
|
|
||||||
LDLIBS = LIB:scppc.a
|
|
||||||
LN = ppc-amigaos-ld
|
|
||||||
RM = delete quiet
|
|
||||||
|
|
||||||
OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
|
|
||||||
zutil.o inflate.o infblock.o inftrees.o infcodes.o infutil.o inffast.o
|
|
||||||
|
|
||||||
TEST_OBJS = example.o minigzip.o
|
|
||||||
|
|
||||||
all: example minigzip
|
|
||||||
|
|
||||||
test: all
|
|
||||||
example
|
|
||||||
echo hello world | minigzip | minigzip -d
|
|
||||||
|
|
||||||
$(LIBNAME): $(OBJS)
|
|
||||||
$(AR) $(AR_FLAGS) $@ $(OBJS)
|
|
||||||
$(RANLIB) $@
|
|
||||||
|
|
||||||
example: example.o $(LIBNAME)
|
|
||||||
$(LN) $(LDFLAGS) example LIB:c_ppc.o example.o $(LIBNAME) $(LDLIBS) LIB:end.o
|
|
||||||
|
|
||||||
minigzip: minigzip.o $(LIBNAME)
|
|
||||||
$(LN) $(LDFLAGS) minigzip LIB:c_ppc.o minigzip.o $(LIBNAME) $(LDLIBS) LIB:end.o
|
|
||||||
|
|
||||||
clean:
|
|
||||||
$(RM) *.o example minigzip $(LIBNAME) foo.gz
|
|
||||||
|
|
||||||
zip:
|
|
||||||
zip -ul9 zlib README ChangeLog Makefile Make????.??? Makefile.?? \
|
|
||||||
descrip.mms *.[ch]
|
|
||||||
|
|
||||||
tgz:
|
|
||||||
cd ..; tar cfz zlib/zlib.tgz zlib/README zlib/ChangeLog zlib/Makefile \
|
|
||||||
zlib/Make????.??? zlib/Makefile.?? zlib/descrip.mms zlib/*.[ch]
|
|
||||||
|
|
||||||
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
|
||||||
|
|
||||||
adler32.o: zutil.h zlib.h zconf.h
|
|
||||||
compress.o: zlib.h zconf.h
|
|
||||||
crc32.o: zutil.h zlib.h zconf.h
|
|
||||||
deflate.o: deflate.h zutil.h zlib.h zconf.h
|
|
||||||
example.o: zlib.h zconf.h
|
|
||||||
gzio.o: zutil.h zlib.h zconf.h
|
|
||||||
infblock.o: zutil.h zlib.h zconf.h infblock.h inftrees.h infcodes.h infutil.h
|
|
||||||
infcodes.o: zutil.h zlib.h zconf.h inftrees.h infutil.h infcodes.h inffast.h
|
|
||||||
inffast.o: zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h
|
|
||||||
inflate.o: zutil.h zlib.h zconf.h infblock.h
|
|
||||||
inftrees.o: zutil.h zlib.h zconf.h inftrees.h
|
|
||||||
infutil.o: zutil.h zlib.h zconf.h inftrees.h infutil.h
|
|
||||||
minigzip.o: zlib.h zconf.h
|
|
||||||
trees.o: deflate.h zutil.h zlib.h zconf.h
|
|
||||||
uncompr.o: zlib.h zconf.h
|
|
||||||
zutil.o: zutil.h zlib.h zconf.h
|
|
@ -1,104 +0,0 @@
|
|||||||
# Makefile for zlib
|
|
||||||
# Borland C++
|
|
||||||
|
|
||||||
# This version of the zlib makefile was adapted by Chris Young for use
|
|
||||||
# with Borland C 4.5x with the Dos Power Pack for a 32-bit protected mode
|
|
||||||
# flat memory model. It was created for use with POV-Ray ray tracer and
|
|
||||||
# you may choose to edit the CFLAGS to suit your needs but the
|
|
||||||
# switches -WX and -DMSDOS are required.
|
|
||||||
# -- Chris Young 76702.1655@compuserve.com
|
|
||||||
|
|
||||||
# To use, do "make -fmakefile.b32"
|
|
||||||
|
|
||||||
# See zconf.h for details about the memory requirements.
|
|
||||||
|
|
||||||
# ------------- Borland C++ -------------
|
|
||||||
MODEL=-WX
|
|
||||||
CFLAGS= $(MODEL) -P-C -K -N- -k- -d -3 -r- -v- -f -DMSDOS
|
|
||||||
CC=bcc32
|
|
||||||
LD=bcc32
|
|
||||||
LIB=tlib
|
|
||||||
LDFLAGS= $(MODEL)
|
|
||||||
O=.obj
|
|
||||||
|
|
||||||
# variables
|
|
||||||
OBJ1 = adler32$(O) compress$(O) crc32$(O) gzio$(O) uncompr$(O) deflate$(O) \
|
|
||||||
trees$(O)
|
|
||||||
OBJP1 = adler32$(O)+compress$(O)+crc32$(O)+gzio$(O)+uncompr$(O)+deflate$(O)+\
|
|
||||||
trees$(O)
|
|
||||||
OBJ2 = zutil$(O) inflate$(O) infblock$(O) inftrees$(O) infcodes$(O) \
|
|
||||||
infutil$(O) inffast$(O)
|
|
||||||
OBJP2 = zutil$(O)+inflate$(O)+infblock$(O)+inftrees$(O)+infcodes$(O)+\
|
|
||||||
infutil$(O)+inffast$(O)
|
|
||||||
|
|
||||||
all: test
|
|
||||||
|
|
||||||
adler32.obj: adler32.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
compress.obj: compress.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
crc32.obj: crc32.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
deflate.obj: deflate.c deflate.h zutil.h zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
gzio.obj: gzio.c zutil.h zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infblock.obj: infblock.c zutil.h zlib.h zconf.h infblock.h inftrees.h\
|
|
||||||
infcodes.h infutil.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infcodes.obj: infcodes.c zutil.h zlib.h zconf.h inftrees.h infutil.h\
|
|
||||||
infcodes.h inffast.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inflate.obj: inflate.c zutil.h zlib.h zconf.h infblock.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inftrees.obj: inftrees.c zutil.h zlib.h zconf.h inftrees.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infutil.obj: infutil.c zutil.h zlib.h zconf.h inftrees.h infutil.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inffast.obj: inffast.c zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
trees.obj: trees.c deflate.h zutil.h zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
uncompr.obj: uncompr.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
zutil.obj: zutil.c zutil.h zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
example.obj: example.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
minigzip.obj: minigzip.c zlib.h zconf.h
|
|
||||||
$(CC) -c $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
# we must cut the command line to fit in the MS/DOS 128 byte limit:
|
|
||||||
zlib.lib: $(OBJ1) $(OBJ2)
|
|
||||||
del zlib.lib
|
|
||||||
$(LIB) zlib +$(OBJP1)
|
|
||||||
$(LIB) zlib +$(OBJP2)
|
|
||||||
|
|
||||||
example.exe: example.obj zlib.lib
|
|
||||||
$(LD) $(LDFLAGS) example.obj zlib.lib
|
|
||||||
|
|
||||||
minigzip.exe: minigzip.obj zlib.lib
|
|
||||||
$(LD) $(LDFLAGS) minigzip.obj zlib.lib
|
|
||||||
|
|
||||||
test: example.exe minigzip.exe
|
|
||||||
example
|
|
||||||
echo hello world | minigzip | minigzip -d
|
|
||||||
|
|
||||||
#clean:
|
|
||||||
# del *.obj
|
|
||||||
# del *.exe
|
|
@ -1,103 +0,0 @@
|
|||||||
# Makefile for zlib
|
|
||||||
# Watcom 10a
|
|
||||||
|
|
||||||
# This version of the zlib makefile was adapted by Chris Young for use
|
|
||||||
# with Watcom 10a 32-bit protected mode flat memory model. It was created
|
|
||||||
# for use with POV-Ray ray tracer and you may choose to edit the CFLAGS to
|
|
||||||
# suit your needs but the -DMSDOS is required.
|
|
||||||
# -- Chris Young 76702.1655@compuserve.com
|
|
||||||
|
|
||||||
# To use, do "wmake -f makefile.wat"
|
|
||||||
|
|
||||||
# See zconf.h for details about the memory requirements.
|
|
||||||
|
|
||||||
# ------------- Watcom 10a -------------
|
|
||||||
MODEL=-mf
|
|
||||||
CFLAGS= $(MODEL) -fpi87 -fp5 -zp4 -5r -w5 -oneatx -DMSDOS
|
|
||||||
CC=wcc386
|
|
||||||
LD=wcl386
|
|
||||||
LIB=wlib -b -c
|
|
||||||
LDFLAGS=
|
|
||||||
O=.obj
|
|
||||||
|
|
||||||
# variables
|
|
||||||
OBJ1=adler32$(O) compress$(O) crc32$(O) gzio$(O) uncompr$(O) deflate$(O)
|
|
||||||
OBJ2=trees$(O) zutil$(O) inflate$(O) infblock$(O) inftrees$(O) infcodes$(O)
|
|
||||||
OBJ3=infutil$(O) inffast$(O)
|
|
||||||
OBJP1=adler32$(O)+compress$(O)+crc32$(O)+gzio$(O)+uncompr$(O)+deflate$(O)
|
|
||||||
OBJP2=trees$(O)+zutil$(O)+inflate$(O)+infblock$(O)+inftrees$(O)+infcodes$(O)
|
|
||||||
OBJP3=infutil$(O)+inffast$(O)
|
|
||||||
|
|
||||||
all: test
|
|
||||||
|
|
||||||
adler32.obj: adler32.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
compress.obj: compress.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
crc32.obj: crc32.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
deflate.obj: deflate.c deflate.h zutil.h zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
gzio.obj: gzio.c zutil.h zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infblock.obj: infblock.c zutil.h zlib.h zconf.h infblock.h inftrees.h &
|
|
||||||
infcodes.h infutil.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infcodes.obj: infcodes.c zutil.h zlib.h zconf.h inftrees.h infutil.h &
|
|
||||||
infcodes.h inffast.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inflate.obj: inflate.c zutil.h zlib.h zconf.h infblock.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inftrees.obj: inftrees.c zutil.h zlib.h zconf.h inftrees.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
infutil.obj: infutil.c zutil.h zlib.h zconf.h inftrees.h infutil.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
inffast.obj: inffast.c zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
trees.obj: trees.c deflate.h zutil.h zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
uncompr.obj: uncompr.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
zutil.obj: zutil.c zutil.h zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
example.obj: example.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
minigzip.obj: minigzip.c zlib.h zconf.h
|
|
||||||
$(CC) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
# we must cut the command line to fit in the MS/DOS 128 byte limit:
|
|
||||||
zlib.lib: $(OBJ1) $(OBJ2) $(OBJ3)
|
|
||||||
del zlib.lib
|
|
||||||
$(LIB) zlib.lib +$(OBJP1)
|
|
||||||
$(LIB) zlib.lib +$(OBJP2)
|
|
||||||
$(LIB) zlib.lib +$(OBJP3)
|
|
||||||
|
|
||||||
example.exe: example.obj zlib.lib
|
|
||||||
$(LD) $(LDFLAGS) example.obj zlib.lib
|
|
||||||
|
|
||||||
minigzip.exe: minigzip.obj zlib.lib
|
|
||||||
$(LD) $(LDFLAGS) minigzip.obj zlib.lib
|
|
||||||
|
|
||||||
test: minigzip.exe example.exe
|
|
||||||
example
|
|
||||||
echo hello world | minigzip | minigzip -d >test
|
|
||||||
type test
|
|
||||||
|
|
||||||
#clean:
|
|
||||||
# del *.obj
|
|
||||||
# del *.exe
|
|
@ -25,10 +25,10 @@
|
|||||||
<QPG:Files>
|
<QPG:Files>
|
||||||
<QPG:Add file="../zconf.h" install="/opt/include/" user="root:sys" permission="644"/>
|
<QPG:Add file="../zconf.h" install="/opt/include/" user="root:sys" permission="644"/>
|
||||||
<QPG:Add file="../zlib.h" install="/opt/include/" user="root:sys" permission="644"/>
|
<QPG:Add file="../zlib.h" install="/opt/include/" user="root:sys" permission="644"/>
|
||||||
<QPG:Add file="../libz.so.1.2.0.6" install="/opt/lib/" user="root:bin" permission="644"/>
|
<QPG:Add file="../libz.so.1.2.0.7" install="/opt/lib/" user="root:bin" permission="644"/>
|
||||||
<QPG:Add file="libz.so" install="/opt/lib/" component="dev" filetype="symlink" linkto="libz.so.1.2.0.6"/>
|
<QPG:Add file="libz.so" install="/opt/lib/" component="dev" filetype="symlink" linkto="libz.so.1.2.0.7"/>
|
||||||
<QPG:Add file="libz.so.1" install="/opt/lib/" filetype="symlink" linkto="libz.so.1.2.0.6"/>
|
<QPG:Add file="libz.so.1" install="/opt/lib/" filetype="symlink" linkto="libz.so.1.2.0.7"/>
|
||||||
<QPG:Add file="../libz.so.1.2.0.6" install="/opt/lib/" component="slib"/>
|
<QPG:Add file="../libz.so.1.2.0.7" install="/opt/lib/" component="slib"/>
|
||||||
</QPG:Files>
|
</QPG:Files>
|
||||||
|
|
||||||
<QPG:PackageFilter>
|
<QPG:PackageFilter>
|
||||||
@ -63,7 +63,7 @@
|
|||||||
</QPM:ProductDescription>
|
</QPM:ProductDescription>
|
||||||
|
|
||||||
<QPM:ReleaseDescription>
|
<QPM:ReleaseDescription>
|
||||||
<QPM:ReleaseVersion>1.2.0.6</QPM:ReleaseVersion>
|
<QPM:ReleaseVersion>1.2.0.7</QPM:ReleaseVersion>
|
||||||
<QPM:ReleaseUrgency>Medium</QPM:ReleaseUrgency>
|
<QPM:ReleaseUrgency>Medium</QPM:ReleaseUrgency>
|
||||||
<QPM:ReleaseStability>Stable</QPM:ReleaseStability>
|
<QPM:ReleaseStability>Stable</QPM:ReleaseStability>
|
||||||
<QPM:ReleaseNoteMinor></QPM:ReleaseNoteMinor>
|
<QPM:ReleaseNoteMinor></QPM:ReleaseNoteMinor>
|
||||||
|
3
trees.c
3
trees.c
@ -1107,7 +1107,8 @@ local void compress_block(s, ltree, dtree)
|
|||||||
} /* literal or match pair ? */
|
} /* literal or match pair ? */
|
||||||
|
|
||||||
/* Check that the overlay between pending_buf and d_buf+l_buf is ok: */
|
/* Check that the overlay between pending_buf and d_buf+l_buf is ok: */
|
||||||
Assert(s->pending < s->lit_bufsize + 2*lx, "pendingBuf overflow");
|
Assert((uInt)(s->pending) < s->lit_bufsize + 2*lx,
|
||||||
|
"pendingBuf overflow");
|
||||||
|
|
||||||
} while (lx < s->last_lit);
|
} while (lx < s->last_lit);
|
||||||
|
|
||||||
|
@ -5,8 +5,8 @@ VS_VERSION_INFO VERSIONINFO
|
|||||||
#else
|
#else
|
||||||
VS_VERSION_INFO VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE
|
VS_VERSION_INFO VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE
|
||||||
#endif
|
#endif
|
||||||
FILEVERSION 1,2,0,6
|
FILEVERSION 1,2,0,7
|
||||||
PRODUCTVERSION 1,2,0,6
|
PRODUCTVERSION 1,2,0,7
|
||||||
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
|
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
FILEFLAGS 1
|
FILEFLAGS 1
|
||||||
@ -23,12 +23,12 @@ BEGIN
|
|||||||
//language ID = U.S. English, char set = Windows, Multilingual
|
//language ID = U.S. English, char set = Windows, Multilingual
|
||||||
BEGIN
|
BEGIN
|
||||||
VALUE "FileDescription", "zlib data compression library\0"
|
VALUE "FileDescription", "zlib data compression library\0"
|
||||||
VALUE "FileVersion", "1.2.0.6\0"
|
VALUE "FileVersion", "1.2.0.7\0"
|
||||||
VALUE "InternalName", "zlib1.dll\0"
|
VALUE "InternalName", "zlib1.dll\0"
|
||||||
VALUE "LegalCopyright", "(C) 1995-2003 Jean-loup Gailly & Mark Adler\0"
|
VALUE "LegalCopyright", "(C) 1995-2003 Jean-loup Gailly & Mark Adler\0"
|
||||||
VALUE "OriginalFilename", "zlib1.dll\0"
|
VALUE "OriginalFilename", "zlib1.dll\0"
|
||||||
VALUE "ProductName", "zlib\0"
|
VALUE "ProductName", "zlib\0"
|
||||||
VALUE "ProductVersion", "1.2.0.6\0"
|
VALUE "ProductVersion", "1.2.0.7\0"
|
||||||
VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0"
|
VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0"
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
4
zlib.3
4
zlib.3
@ -1,4 +1,4 @@
|
|||||||
.TH ZLIB 3 "13 September 2003"
|
.TH ZLIB 3 "21 September 2003"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
zlib \- compression/decompression library
|
zlib \- compression/decompression library
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
@ -133,7 +133,7 @@ before asking for help.
|
|||||||
Send questions and/or comments to zlib@gzip.org,
|
Send questions and/or comments to zlib@gzip.org,
|
||||||
or (for the Windows DLL version) to Gilles Vollant (info@winimage.com).
|
or (for the Windows DLL version) to Gilles Vollant (info@winimage.com).
|
||||||
.SH AUTHORS
|
.SH AUTHORS
|
||||||
Version 1.2.0.6
|
Version 1.2.0.7
|
||||||
Copyright (C) 1995-2003 Jean-loup Gailly (jloup@gzip.org)
|
Copyright (C) 1995-2003 Jean-loup Gailly (jloup@gzip.org)
|
||||||
and Mark Adler (madler@alumni.caltech.edu).
|
and Mark Adler (madler@alumni.caltech.edu).
|
||||||
.LP
|
.LP
|
||||||
|
6
zlib.h
6
zlib.h
@ -1,5 +1,5 @@
|
|||||||
/* zlib.h -- interface of the 'zlib' general purpose compression library
|
/* zlib.h -- interface of the 'zlib' general purpose compression library
|
||||||
version 1.2.0.6, September 13th, 2003
|
version 1.2.0.7, September 21st, 2003
|
||||||
|
|
||||||
Copyright (C) 1995-2003 Jean-loup Gailly and Mark Adler
|
Copyright (C) 1995-2003 Jean-loup Gailly and Mark Adler
|
||||||
|
|
||||||
@ -37,8 +37,8 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define ZLIB_VERSION "1.2.0.6"
|
#define ZLIB_VERSION "1.2.0.7"
|
||||||
#define ZLIB_VERNUM 0x1206
|
#define ZLIB_VERNUM 0x1207
|
||||||
|
|
||||||
/*
|
/*
|
||||||
The 'zlib' compression library provides in-memory compression and
|
The 'zlib' compression library provides in-memory compression and
|
||||||
|
3
zutil.h
3
zutil.h
@ -181,6 +181,9 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */
|
|||||||
# define vsnprintf _vsnprintf
|
# define vsnprintf _vsnprintf
|
||||||
# endif
|
# endif
|
||||||
# endif
|
# endif
|
||||||
|
# ifdef __SASC
|
||||||
|
# define NO_vsnprintf
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_STRERROR
|
#ifdef HAVE_STRERROR
|
||||||
|
Loading…
Reference in New Issue
Block a user