diff options
Diffstat (limited to 'src/lib/libcrypto/comp')
-rw-r--r-- | src/lib/libcrypto/comp/Makefile | 108 | ||||
-rw-r--r-- | src/lib/libcrypto/comp/Makefile.ssl | 114 | ||||
-rw-r--r-- | src/lib/libcrypto/comp/c_zlib.c | 4 |
3 files changed, 224 insertions, 2 deletions
diff --git a/src/lib/libcrypto/comp/Makefile b/src/lib/libcrypto/comp/Makefile new file mode 100644 index 0000000000..5d364b8513 --- /dev/null +++ b/src/lib/libcrypto/comp/Makefile | |||
@@ -0,0 +1,108 @@ | |||
1 | # | ||
2 | # OpenSSL/crypto/comp/Makefile | ||
3 | # | ||
4 | |||
5 | DIR= comp | ||
6 | TOP= ../.. | ||
7 | CC= cc | ||
8 | INCLUDES= -I.. -I$(TOP) -I../../include | ||
9 | CFLAG=-g | ||
10 | MAKEFILE= Makefile | ||
11 | AR= ar r | ||
12 | |||
13 | CFLAGS= $(INCLUDES) $(CFLAG) | ||
14 | |||
15 | GENERAL=Makefile | ||
16 | TEST= | ||
17 | APPS= | ||
18 | |||
19 | LIB=$(TOP)/libcrypto.a | ||
20 | LIBSRC= comp_lib.c comp_err.c \ | ||
21 | c_rle.c c_zlib.c | ||
22 | |||
23 | LIBOBJ= comp_lib.o comp_err.o \ | ||
24 | c_rle.o c_zlib.o | ||
25 | |||
26 | SRC= $(LIBSRC) | ||
27 | |||
28 | EXHEADER= comp.h | ||
29 | HEADER= $(EXHEADER) | ||
30 | |||
31 | ALL= $(GENERAL) $(SRC) $(HEADER) | ||
32 | |||
33 | top: | ||
34 | (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all) | ||
35 | |||
36 | all: lib | ||
37 | |||
38 | lib: $(LIBOBJ) | ||
39 | $(ARX) $(LIB) $(LIBOBJ) | ||
40 | $(RANLIB) $(LIB) || echo Never mind. | ||
41 | @touch lib | ||
42 | |||
43 | files: | ||
44 | $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO | ||
45 | |||
46 | links: | ||
47 | @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER) | ||
48 | @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST) | ||
49 | @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS) | ||
50 | |||
51 | install: | ||
52 | @[ -n "$(INSTALLTOP)" ] # should be set by top Makefile... | ||
53 | @headerlist="$(EXHEADER)"; for i in $$headerlist ; \ | ||
54 | do \ | ||
55 | (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ | ||
56 | chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ | ||
57 | done; | ||
58 | |||
59 | tags: | ||
60 | ctags $(SRC) | ||
61 | |||
62 | tests: | ||
63 | |||
64 | lint: | ||
65 | lint -DLINT $(INCLUDES) $(SRC)>fluff | ||
66 | |||
67 | depend: | ||
68 | @[ -n "$(MAKEDEPEND)" ] # should be set by upper Makefile... | ||
69 | $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(LIBSRC) | ||
70 | |||
71 | dclean: | ||
72 | $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new | ||
73 | mv -f Makefile.new $(MAKEFILE) | ||
74 | |||
75 | clean: | ||
76 | rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff | ||
77 | |||
78 | # DO NOT DELETE THIS LINE -- make depend depends on it. | ||
79 | |||
80 | c_rle.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
81 | c_rle.o: ../../include/openssl/comp.h ../../include/openssl/crypto.h | ||
82 | c_rle.o: ../../include/openssl/e_os2.h ../../include/openssl/obj_mac.h | ||
83 | c_rle.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h | ||
84 | c_rle.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h | ||
85 | c_rle.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h | ||
86 | c_rle.o: ../../include/openssl/symhacks.h c_rle.c | ||
87 | c_zlib.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
88 | c_zlib.o: ../../include/openssl/comp.h ../../include/openssl/crypto.h | ||
89 | c_zlib.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h | ||
90 | c_zlib.o: ../../include/openssl/lhash.h ../../include/openssl/obj_mac.h | ||
91 | c_zlib.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h | ||
92 | c_zlib.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h | ||
93 | c_zlib.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h | ||
94 | c_zlib.o: ../../include/openssl/symhacks.h c_zlib.c | ||
95 | comp_err.o: ../../include/openssl/bio.h ../../include/openssl/comp.h | ||
96 | comp_err.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h | ||
97 | comp_err.o: ../../include/openssl/err.h ../../include/openssl/lhash.h | ||
98 | comp_err.o: ../../include/openssl/opensslconf.h | ||
99 | comp_err.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h | ||
100 | comp_err.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h | ||
101 | comp_err.o: ../../include/openssl/symhacks.h comp_err.c | ||
102 | comp_lib.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
103 | comp_lib.o: ../../include/openssl/comp.h ../../include/openssl/crypto.h | ||
104 | comp_lib.o: ../../include/openssl/e_os2.h ../../include/openssl/obj_mac.h | ||
105 | comp_lib.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h | ||
106 | comp_lib.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h | ||
107 | comp_lib.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h | ||
108 | comp_lib.o: ../../include/openssl/symhacks.h comp_lib.c | ||
diff --git a/src/lib/libcrypto/comp/Makefile.ssl b/src/lib/libcrypto/comp/Makefile.ssl new file mode 100644 index 0000000000..f70ba1b285 --- /dev/null +++ b/src/lib/libcrypto/comp/Makefile.ssl | |||
@@ -0,0 +1,114 @@ | |||
1 | # | ||
2 | # SSLeay/crypto/comp/Makefile | ||
3 | # | ||
4 | |||
5 | DIR= comp | ||
6 | TOP= ../.. | ||
7 | CC= cc | ||
8 | INCLUDES= -I.. -I$(TOP) -I../../include | ||
9 | CFLAG=-g | ||
10 | INSTALL_PREFIX= | ||
11 | OPENSSLDIR= /usr/local/ssl | ||
12 | INSTALLTOP=/usr/local/ssl | ||
13 | MAKE= make -f Makefile.ssl | ||
14 | MAKEDEPPROG= makedepend | ||
15 | MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG) | ||
16 | MAKEFILE= Makefile.ssl | ||
17 | AR= ar r | ||
18 | |||
19 | CFLAGS= $(INCLUDES) $(CFLAG) | ||
20 | |||
21 | GENERAL=Makefile | ||
22 | TEST= | ||
23 | APPS= | ||
24 | |||
25 | LIB=$(TOP)/libcrypto.a | ||
26 | LIBSRC= comp_lib.c comp_err.c \ | ||
27 | c_rle.c c_zlib.c | ||
28 | |||
29 | LIBOBJ= comp_lib.o comp_err.o \ | ||
30 | c_rle.o c_zlib.o | ||
31 | |||
32 | SRC= $(LIBSRC) | ||
33 | |||
34 | EXHEADER= comp.h | ||
35 | HEADER= $(EXHEADER) | ||
36 | |||
37 | ALL= $(GENERAL) $(SRC) $(HEADER) | ||
38 | |||
39 | top: | ||
40 | (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all) | ||
41 | |||
42 | all: lib | ||
43 | |||
44 | lib: $(LIBOBJ) | ||
45 | $(AR) $(LIB) $(LIBOBJ) | ||
46 | $(RANLIB) $(LIB) || echo Never mind. | ||
47 | @touch lib | ||
48 | |||
49 | files: | ||
50 | $(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO | ||
51 | |||
52 | links: | ||
53 | @sh $(TOP)/util/point.sh Makefile.ssl Makefile | ||
54 | @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER) | ||
55 | @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST) | ||
56 | @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS) | ||
57 | |||
58 | install: | ||
59 | @for i in $(EXHEADER) ; \ | ||
60 | do \ | ||
61 | (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ | ||
62 | chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ | ||
63 | done; | ||
64 | |||
65 | tags: | ||
66 | ctags $(SRC) | ||
67 | |||
68 | tests: | ||
69 | |||
70 | lint: | ||
71 | lint -DLINT $(INCLUDES) $(SRC)>fluff | ||
72 | |||
73 | depend: | ||
74 | $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(LIBSRC) | ||
75 | |||
76 | dclean: | ||
77 | $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new | ||
78 | mv -f Makefile.new $(MAKEFILE) | ||
79 | |||
80 | clean: | ||
81 | rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff | ||
82 | |||
83 | # DO NOT DELETE THIS LINE -- make depend depends on it. | ||
84 | |||
85 | c_rle.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
86 | c_rle.o: ../../include/openssl/bn.h ../../include/openssl/comp.h | ||
87 | c_rle.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h | ||
88 | c_rle.o: ../../include/openssl/obj_mac.h ../../include/openssl/objects.h | ||
89 | c_rle.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h | ||
90 | c_rle.o: ../../include/openssl/ossl_typ.h ../../include/openssl/safestack.h | ||
91 | c_rle.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h c_rle.c | ||
92 | c_zlib.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
93 | c_zlib.o: ../../include/openssl/bn.h ../../include/openssl/comp.h | ||
94 | c_zlib.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h | ||
95 | c_zlib.o: ../../include/openssl/obj_mac.h ../../include/openssl/objects.h | ||
96 | c_zlib.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h | ||
97 | c_zlib.o: ../../include/openssl/ossl_typ.h ../../include/openssl/safestack.h | ||
98 | c_zlib.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h | ||
99 | c_zlib.o: c_zlib.c | ||
100 | comp_err.o: ../../include/openssl/bio.h ../../include/openssl/comp.h | ||
101 | comp_err.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h | ||
102 | comp_err.o: ../../include/openssl/err.h ../../include/openssl/lhash.h | ||
103 | comp_err.o: ../../include/openssl/opensslconf.h | ||
104 | comp_err.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h | ||
105 | comp_err.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h | ||
106 | comp_err.o: comp_err.c | ||
107 | comp_lib.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h | ||
108 | comp_lib.o: ../../include/openssl/bn.h ../../include/openssl/comp.h | ||
109 | comp_lib.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h | ||
110 | comp_lib.o: ../../include/openssl/obj_mac.h ../../include/openssl/objects.h | ||
111 | comp_lib.o: ../../include/openssl/opensslconf.h | ||
112 | comp_lib.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h | ||
113 | comp_lib.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h | ||
114 | comp_lib.o: ../../include/openssl/symhacks.h comp_lib.c | ||
diff --git a/src/lib/libcrypto/comp/c_zlib.c b/src/lib/libcrypto/comp/c_zlib.c index eccfd09137..0f34597e70 100644 --- a/src/lib/libcrypto/comp/c_zlib.c +++ b/src/lib/libcrypto/comp/c_zlib.c | |||
@@ -727,7 +727,6 @@ static long bio_zlib_ctrl(BIO *b, int cmd, long num, void *ptr) | |||
727 | case BIO_CTRL_RESET: | 727 | case BIO_CTRL_RESET: |
728 | ctx->ocount = 0; | 728 | ctx->ocount = 0; |
729 | ctx->odone = 0; | 729 | ctx->odone = 0; |
730 | ret = 1; | ||
731 | break; | 730 | break; |
732 | 731 | ||
733 | case BIO_CTRL_FLUSH: | 732 | case BIO_CTRL_FLUSH: |
@@ -772,7 +771,7 @@ static long bio_zlib_ctrl(BIO *b, int cmd, long num, void *ptr) | |||
772 | } | 771 | } |
773 | ctx->obufsize = obs; | 772 | ctx->obufsize = obs; |
774 | } | 773 | } |
775 | ret = 1; | 774 | |
776 | break; | 775 | break; |
777 | 776 | ||
778 | case BIO_C_DO_STATE_MACHINE: | 777 | case BIO_C_DO_STATE_MACHINE: |
@@ -784,6 +783,7 @@ static long bio_zlib_ctrl(BIO *b, int cmd, long num, void *ptr) | |||
784 | default: | 783 | default: |
785 | ret = BIO_ctrl(b->next_bio, cmd, num, ptr); | 784 | ret = BIO_ctrl(b->next_bio, cmd, num, ptr); |
786 | break; | 785 | break; |
786 | |||
787 | } | 787 | } |
788 | 788 | ||
789 | return ret; | 789 | return ret; |