]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/openssl/openssl-0.9.7d/debian.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / openssl / openssl-0.9.7d / debian.patch
1 --- openssl-0.9.7d.orig/apps/der_chop
2 +++ openssl-0.9.7d/apps/der_chop
3 @@ -1,4 +1,4 @@
4 -#!/usr/local/bin/perl
5 +#!/usr/bin/perl
6  #
7  # der_chop ... this is one total hack that Eric is really not proud of
8  #              so don't look at it and don't ask for support
9 --- openssl-0.9.7d.orig/apps/der_chop.in
10 +++ openssl-0.9.7d/apps/der_chop.in
11 @@ -1,4 +1,4 @@
12 -#!/usr/local/bin/perl
13 +#!/usr/bin/perl
14  #
15  # der_chop ... this is one total hack that Eric is really not proud of
16  #              so don't look at it and don't ask for support
17 --- openssl-0.9.7d.orig/apps/Makefile.ssl
18 +++ openssl-0.9.7d/apps/Makefile.ssl
19 @@ -3,7 +3,7 @@
20  #
21  
22  DIR=           apps
23 -TOP=           ..
24 +TOP=           $(shell pwd)/..
25  CC=            cc
26  INCLUDES=      -I$(TOP) -I../include $(KRB5_INCLUDES)
27  CFLAG=         -g -static
28 @@ -30,9 +30,14 @@
29  
30  GENERAL=Makefile makeapps.com install.com
31  
32 +TOP=$(shell pwd)/..
33 +#DLIBCRYPTO=../crypto/.libs/libcrypto.a
34  DLIBCRYPTO=../libcrypto.a
35 +#DLIBSSL=../ssl/.libs/libssl.a
36  DLIBSSL=../libssl.a
37 +#LIBCRYPTO=-L$(TOP)/crypto/.libs -lcrypto
38  LIBCRYPTO=-L.. -lcrypto
39 +#LIBSSL=-L$(TOP)/ssl/.libs -lssl
40  LIBSSL=-L.. -lssl
41  
42  PROGRAM= openssl
43 @@ -136,6 +141,8 @@
44  clean:
45         rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff $(EXE)
46         rm -f req
47 +       rm -f *.lo
48 +       rm -fr .libs
49  
50  $(DLIBSSL):
51         (cd ..; $(MAKE) DIRS=ssl all)
52 --- openssl-0.9.7d.orig/apps/progs.h
53 +++ openssl-0.9.7d/apps/progs.h
54 @@ -35,9 +35,7 @@
55  extern int spkac_main(int argc,char *argv[]);
56  extern int smime_main(int argc,char *argv[]);
57  extern int rand_main(int argc,char *argv[]);
58 -#ifndef OPENSSL_NO_ENGINE
59  extern int engine_main(int argc,char *argv[]);
60 -#endif
61  extern int ocsp_main(int argc,char *argv[]);
62  
63  #define FUNC_TYPE_GENERAL      1
64 @@ -94,9 +92,7 @@
65  #if !defined(OPENSSL_NO_SOCK) && !(defined(OPENSSL_NO_SSL2) && defined(OPENSSL_NO_SSL3))
66         {FUNC_TYPE_GENERAL,"s_client",s_client_main},
67  #endif
68 -#ifndef OPENSSL_NO_SPEED
69         {FUNC_TYPE_GENERAL,"speed",speed_main},
70 -#endif
71  #if !defined(OPENSSL_NO_SOCK) && !(defined(OPENSSL_NO_SSL2) && defined(OPENSSL_NO_SSL3))
72         {FUNC_TYPE_GENERAL,"s_time",s_time_main},
73  #endif
74 @@ -115,9 +111,7 @@
75         {FUNC_TYPE_GENERAL,"spkac",spkac_main},
76         {FUNC_TYPE_GENERAL,"smime",smime_main},
77         {FUNC_TYPE_GENERAL,"rand",rand_main},
78 -#ifndef OPENSSL_NO_ENGINE
79         {FUNC_TYPE_GENERAL,"engine",engine_main},
80 -#endif
81         {FUNC_TYPE_GENERAL,"ocsp",ocsp_main},
82  #ifndef OPENSSL_NO_MD2
83         {FUNC_TYPE_MD,"md2",dgst_main},
84 --- openssl-0.9.7d.orig/config
85 +++ openssl-0.9.7d/config
86 @@ -162,8 +162,8 @@
87         echo "${MACHINE}-whatever-linux1"; exit 0
88         ;;
89  
90 -    GNU*)
91 -       echo "hurd-x86"; exit 0;
92 +    GNU:*|GNU/*:*)
93 +       echo "${MACHINE}-gnuish"; exit 0;
94         ;;
95  
96      LynxOS:*)
97 --- openssl-0.9.7d.orig/Configure
98 +++ openssl-0.9.7d/Configure
99 @@ -1,4 +1,4 @@
100 -:
101 +#!/usr/local/bin/perl
102  eval 'exec perl -S $0 ${1+"$@"}'
103      if $running_under_some_shell;
104  ##
105 @@ -373,6 +373,42 @@
106  # assembler versions -- currently defunct:
107  ##"OpenBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer:::(unknown):SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:${alpha_asm}",
108  
109 +# Debian GNU/* (various architectures)
110 +"debian-alpha","gcc:-DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
111 +"debian-alpha-ev4","gcc:-DTERMIO -O3 -mcpu=ev4 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
112 +"debian-alpha-ev5","gcc:-DTERMIO -O3 -mcpu=ev5 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
113 +"debian-arm","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG DES_RISC1::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
114 +#"debian-amd64","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
115 +"debian-amd64", "gcc:-m64 -DL_ENDIAN -DTERMIO -O3 -Wall -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR BF_PTR2 DES_INT DES_UNROLL:asm/x86_64-gcc.o:::::::::dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
116 +#"debian-freebsd-alpha","gcc:-DTERMIOS -O -fomit-frame-pointer::(unknown):::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC2::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
117 +#"debian-freebsd-i386",  "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::-pthread -D_REENTRANT -D_THREAD_SAFE -D_THREADSAFE:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
118 +"debian-freebsd-i386","gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
119 +"debian-hppa","gcc:-DB_ENDIAN -DTERMIO -O2 -Wall::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
120 +"debian-hurd-i386","gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
121 +"debian-ia64","gcc:-DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR:asm/ia64.o:::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
122 +#"debian-i386","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC",
123 +"debian-i386","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
124 +"debian-i386-i486","gcc:-DL_ENDIAN -DTERMIO -O3 -march=i486 -mcpu=i486 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
125 +"debian-i386-i586","gcc:-DL_ENDIAN -DTERMIO -O3 -march=i586 -mcpu=i586 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
126 +"debian-i386-i686/cmov","gcc:-DL_ENDIAN -DTERMIO -O3 -march=i686 -mcpu=i686 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
127 +"debian-m68k","gcc:-DB_ENDIAN -DTERMIO -O2 -Wall::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
128 +"debian-mips",   "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
129 +"debian-mipsel",   "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
130 +"debian-netbsd-i386",  "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486 -Wall::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
131 +"debian-netbsd-m68k",  "gcc:-DB_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -Wall::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
132 +"debian-netbsd-sparc", "gcc:-DB_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -mv8 -Wall::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
133 +"debian-openbsd-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown):::SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
134 +"debian-openbsd-i386",  "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
135 +"debian-openbsd-mips","gcc:-O2 -DL_ENDIAN::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC2 DES_PTR BF_PTR:::::::::::dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
136 +"debian-powerpc","gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG DES_UNROLL DES_RISC2 DES_PTR MD2_CHAR RC4_INDEX::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
137 +"debian-s390","gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)", 
138 +"debian-sh3",   "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
139 +"debian-sh4",   "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
140 +"debian-sh3eb",   "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
141 +"debian-sh4eb",   "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
142 +"debian-sparc","gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
143 +"debian-sparc-v8","gcc:-DB_ENDIAN -DTERMIO -O3 -mcpu=v8 -fomit-frame-pointer -Wall -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
144 +"debian-sparc-v9","gcc:-DB_ENDIAN -DTERMIO -O3 -mcpu=v9 -Wa,-Av8plus -fomit-frame-pointer -Wall -DULTRASPARC -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
145  # The intel boxes :-), It would be worth seeing if bsdi-gcc can use the
146  # bn86-elf.o file file since it is hand tweaked assembler.
147  "linux-elf",   "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
148 @@ -1260,7 +1296,8 @@
149         elsif ($shared_extension ne "" && $shared_extension =~ /^\.s([ol])\.[^\.]*\.[^\.]*$/)
150                 {
151                 my $sotmp = $1;
152 -               s/^SHARED_LIBS_LINK_EXTS=.*/SHARED_LIBS_LINK_EXTS=.s$sotmp.\$(SHLIB_MAJOR) .s$sotmp/;
153 +#              s/^SHARED_LIBS_LINK_EXTS=.*/SHARED_LIBS_LINK_EXTS=.s$sotmp.\$(SHLIB_MAJOR) .s$sotmp/;
154 +               s/^SHARED_LIBS_LINK_EXTS=.*/SHARED_LIBS_LINK_EXTS=.s$sotmp/;
155                 }
156         elsif ($shared_extension ne "" && $shared_extension =~ /^\.[^\.]*\.[^\.]*\.dylib$/)
157                 {
158 --- openssl-0.9.7d.orig/crypto/asn1/charmap.pl
159 +++ openssl-0.9.7d/crypto/asn1/charmap.pl
160 @@ -1,4 +1,4 @@
161 -#!/usr/local/bin/perl -w
162 +#!/usr/local/bin/perl
163  
164  use strict;
165  
166 --- openssl-0.9.7d.orig/crypto/Makefile.ssl
167 +++ openssl-0.9.7d/crypto/Makefile.ssl
168 @@ -34,6 +34,7 @@
169  
170  GENERAL=Makefile README crypto-lib.com install.com
171  
172 +#LIB= libcrypto.la
173  LIB= $(TOP)/libcrypto.a
174  SHARED_LIB= libcrypto$(SHLIB_EXT)
175  LIBSRC=        cryptlib.c mem.c mem_clr.c mem_dbg.c cversion.c ex_data.c tmdiff.c cpt_err.c ebcdic.c uid.c o_time.c
176 @@ -69,8 +70,9 @@
177         @for i in $(SDIRS) ;\
178         do \
179         (cd $$i && echo "making all in crypto/$$i..." && \
180 -       $(MAKE) CC='$(CC)' INCLUDES='${INCLUDES}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' all ) || exit 1; \
181 +       $(MAKE) CC='$(CC)' INCLUDES='${INCLUDES}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='true' all ) || exit 1; \
182         done;
183 +#      $(AR) $(LIB) *.lo */*.lo
184  
185  files:
186         $(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
187 @@ -145,7 +147,9 @@
188         done;
189  
190  clean:
191 -       rm -f buildinf.h *.o */*.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
192 +       rm -f buildinf.h *.o */*.o *.obj lib tags core .pure .nfs* *.old *.bak fluff date.h
193 +       $(RM) -f *.lo */*.lo *.la
194 +       $(RM) -rf .libs
195         @for i in $(SDIRS) ;\
196         do \
197         (cd $$i && echo "making clean in crypto/$$i..." && \
198 --- openssl-0.9.7d.orig/crypto/md5/asm/md5-sparcv9.S
199 +++ openssl-0.9.7d/crypto/md5/asm/md5-sparcv9.S
200 @@ -74,14 +74,14 @@
201  #define Dval   R8
202  
203  #if defined(MD5_BLOCK_DATA_ORDER)
204 -# if defined(OPENSSL_SYSNAME_ULTRASPARC)
205 +/*# if defined(OPENSSL_SYSNAME_ULTRASPARC)*/
206  #  define      LOAD                    lda
207  #  define      X(i)                    [%i1+i*4]%asi
208  #  define      md5_block               md5_block_asm_data_order_aligned
209  #  define      ASI_PRIMARY_LITTLE      0x88
210 -# else
211 +/*# else
212  #  error "MD5_BLOCK_DATA_ORDER is supported only on UltraSPARC!"
213 -# endif
214 +# endif*/
215  #else
216  # define       LOAD                    ld
217  # define       X(i)                    [%i1+i*4]
218 --- openssl-0.9.7d.orig/crypto/opensslconf.h
219 +++ openssl-0.9.7d/crypto/opensslconf.h
220 @@ -4,17 +4,38 @@
221  /* OpenSSL was configured with the following options: */
222  #ifndef OPENSSL_DOING_MAKEDEPEND
223  
224 +#ifndef OPENSSL_NO_IDEA
225 +# define OPENSSL_NO_IDEA
226 +#endif
227 +#ifndef OPENSSL_NO_MDC2
228 +# define OPENSSL_NO_MDC2
229 +#endif
230 +#ifndef OPENSSL_NO_RC5
231 +# define OPENSSL_NO_RC5
232 +#endif
233  #ifndef OPENSSL_NO_KRB5
234  # define OPENSSL_NO_KRB5
235  #endif
236  
237  #endif /* OPENSSL_DOING_MAKEDEPEND */
238 +#ifndef OPENSSL_THREADS
239 +# define OPENSSL_THREADS
240 +#endif
241  
242  /* The OPENSSL_NO_* macros are also defined as NO_* if the application
243     asks for it.  This is a transient feature that is provided for those
244     who haven't had the time to do the appropriate changes in their
245     applications.  */
246  #ifdef OPENSSL_ALGORITHM_DEFINES
247 +# if defined(OPENSSL_NO_IDEA) && !defined(NO_IDEA)
248 +#  define NO_IDEA
249 +# endif
250 +# if defined(OPENSSL_NO_MDC2) && !defined(NO_MDC2)
251 +#  define NO_MDC2
252 +# endif
253 +# if defined(OPENSSL_NO_RC5) && !defined(NO_RC5)
254 +#  define NO_RC5
255 +# endif
256  # if defined(OPENSSL_NO_KRB5) && !defined(NO_KRB5)
257  #  define NO_KRB5
258  # endif
259 @@ -27,7 +48,7 @@
260  
261  #if !(defined(VMS) || defined(__VMS)) /* VMS uses logical names instead */
262  #if defined(HEADER_CRYPTLIB_H) && !defined(OPENSSLDIR)
263 -#define OPENSSLDIR "/usr/local/ssl"
264 +#define OPENSSLDIR "/usr/lib/ssl"
265  #endif
266  #endif
267  
268 @@ -79,7 +100,7 @@
269  
270  #if defined(HEADER_BN_H) && !defined(CONFIG_HEADER_BN_H)
271  #define CONFIG_HEADER_BN_H
272 -#undef BN_LLONG
273 +#define BN_LLONG
274  
275  /* Should we define BN_DIV2W here? */
276  
277 @@ -98,7 +119,7 @@
278  #define CONFIG_HEADER_RC4_LOCL_H
279  /* if this is defined data[i] is used instead of *data, this is a %20
280   * speedup on x86 */
281 -#undef RC4_INDEX
282 +#define RC4_INDEX
283  #endif
284  
285  #if defined(HEADER_BF_LOCL_H) && !defined(CONFIG_HEADER_BF_LOCL_H)
286 @@ -112,14 +133,14 @@
287  /* the following is tweaked from a config script, that is why it is a
288   * protected undef/define */
289  #ifndef DES_PTR
290 -#undef DES_PTR
291 +#define DES_PTR
292  #endif
293  
294  /* This helps C compiler generate the correct code for multiple functional
295   * units.  It reduces register dependancies at the expense of 2 more
296   * registers */
297  #ifndef DES_RISC1
298 -#undef DES_RISC1
299 +#define DES_RISC1
300  #endif
301  
302  #ifndef DES_RISC2
303 @@ -133,7 +154,7 @@
304  /* Unroll the inner loop, this sometimes helps, sometimes hinders.
305   * Very mucy CPU dependant */
306  #ifndef DES_UNROLL
307 -#undef DES_UNROLL
308 +#define DES_UNROLL
309  #endif
310  
311  /* These default values were supplied by
312 --- openssl-0.9.7d.orig/demos/tunala/configure.in
313 +++ openssl-0.9.7d/demos/tunala/configure.in
314 @@ -1,4 +1,4 @@
315 -dnl Process this file with autoconf to produce a configure script.
316 +#!/usr/local/bin/perl
317  AC_INIT(tunala.c)
318  AM_CONFIG_HEADER(config.h)
319  AM_INIT_AUTOMAKE(tunala, 0.0.1-dev)
320 --- openssl-0.9.7d.orig/doc/crypto/pem.pod
321 +++ openssl-0.9.7d/doc/crypto/pem.pod
322 @@ -471,6 +471,6 @@
323  =head1 RETURN CODES
324  
325  The read routines return either a pointer to the structure read or NULL
326 -is an error occurred.
327 +if an error occurred.
328  
329  The write routines return 1 for success or 0 for failure.
330 --- openssl-0.9.7d.orig/doc/Makefile.ssl
331 +++ openssl-0.9.7d/doc/Makefile.ssl
332 @@ -0,0 +1,40 @@
333 +VERSION =
334 +
335 +#PODS = $(wildcard *.pod)
336 +#MANS = $(addsuffix .man, $(basename $(PODS)))
337 +
338 +MANS = openssl.1 ssl.3 crypto.3
339 +
340 +P2M = pod2man --center='OpenSSL Documentation' --release="OpenSSL $(VERSION)"
341 +
342 +all: manpages
343 +
344 +.PHONY: manpages 
345 +
346 +manpages: openssl.1 crypto.3 ssl.3
347 +
348 +openssl.1:
349 +       $(P2M) --section=1 openssl.pod > openssl.1
350 +
351 +crypto.3:
352 +       $(P2M) --section=3 crypto.pod > crypto.3
353 +
354 +ssl.3:
355 +       $(P2M) --section=3 ssl.pod > ssl.3
356 +
357 +.PHONY: install
358 +install:
359 +       mkdir -p $(INSTALL_PREFIX)$(INSTALLTOP)/share/man/man1
360 +       mkdir -p $(INSTALL_PREFIX)$(INSTALLTOP)/share/man/man3
361 +       install -m 644 -p openssl.1 $(INSTALL_PREFIX)$(INSTALLTOP)/share/man/man1
362 +       install -m 644 -p crypto.3 $(INSTALL_PREFIX)$(INSTALLTOP)/share/man/man3
363 +       install -m 644 -p ssl.3 $(INSTALL_PREFIX)$(INSTALLTOP)/share/man/man3
364 +       rm -f $(MANS)
365 +
366 +.PHONY: clean
367 +clean:
368 +       rm -f $(MANS)
369 +
370 +.PHONY: realclean
371 +realclean:
372 +       -$(MAKE) clean
373 --- openssl-0.9.7d.orig/Makefile.org
374 +++ openssl-0.9.7d/Makefile.org
375 @@ -57,6 +57,7 @@
376  # equal 4.
377  # PKCS1_CHECK - pkcs1 tests.
378  
379 +#TOP=$(shell pwd)
380  CC= gcc
381  #CFLAG= -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall -Wuninitialized -DSHA1_ASM -DMD5_ASM -DRMD160_ASM
382  CFLAG= -DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall -DSHA1_ASM -DMD5_ASM -DRMD160_ASM
383 @@ -173,7 +174,7 @@
384  # we might set SHLIB_MARK to '$(SHARED_LIBS)'.
385  SHLIB_MARK=
386  
387 -DIRS=   crypto ssl $(SHLIB_MARK) apps test tools
388 +DIRS=   crypto ssl $(SHLIB_MARK) apps doc tools
389  SHLIBDIRS= crypto ssl
390  
391  # dirs in crypto to build
392 @@ -191,10 +192,10 @@
393  MAKEFILE= Makefile.ssl
394  MAKE=     make -f Makefile.ssl
395  
396 -MANDIR=$(OPENSSLDIR)/man
397 +MANDIR=/usr/share/man
398  MAN1=1
399  MAN3=3
400 -MANSUFFIX=
401 +MANSUFFIX=ssl
402  SHELL=/bin/sh
403  
404  TOP=    .
405 @@ -795,7 +796,7 @@
406         do \
407                 if [ -f "$$i" ]; then \
408                 (       echo installing $$i; \
409 -                       cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
410 +                       cp -d $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
411                         $(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
412                         chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
413                         mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
414 --- openssl-0.9.7d.orig/Makefile.ssl
415 +++ openssl-0.9.7d/Makefile.ssl
416 @@ -11,11 +11,11 @@
417  SHLIB_VERSION_HISTORY=
418  SHLIB_MAJOR=0
419  SHLIB_MINOR=9.7
420 -SHLIB_EXT=
421 -PLATFORM=dist
422 -OPTIONS= no-krb5
423 -CONFIGURE_ARGS=dist
424 -SHLIB_TARGET=
425 +SHLIB_EXT=.so.$(SHLIB_MAJOR).$(SHLIB_MINOR)
426 +PLATFORM=debian-i386
427 +OPTIONS=--prefix=/usr --openssldir=/usr/lib/ssl no-idea no-mdc2 no-rc5 no-krb5
428 +CONFIGURE_ARGS=--prefix=/usr --openssldir=/usr/lib/ssl no-idea no-mdc2 no-rc5 debian-i386
429 +SHLIB_TARGET=linux-shared
430  
431  # HERE indicates where this Makefile lives.  This can be used to indicate
432  # where sub-Makefiles are expected to be.  Currently has very limited usage,
433 @@ -26,10 +26,10 @@
434  # for, say, /usr/ and yet have everything installed to /tmp/somedir/usr/.
435  # Normally it is left empty.
436  INSTALL_PREFIX=
437 -INSTALLTOP=/usr/local/ssl
438 +INSTALLTOP=/usr
439  
440  # Do not edit this manually. Use Configure --openssldir=DIR do change this!
441 -OPENSSLDIR=/usr/local/ssl
442 +OPENSSLDIR=/usr/lib/ssl
443  
444  # NO_IDEA - Define to build without the IDEA algorithm
445  # NO_RC4  - Define to build without the RC4 algorithm
446 @@ -59,20 +59,21 @@
447  # equal 4.
448  # PKCS1_CHECK - pkcs1 tests.
449  
450 -CC= cc
451 +#TOP=$(shell pwd)
452 +CC= gcc
453  #CFLAG= -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall -Wuninitialized -DSHA1_ASM -DMD5_ASM -DRMD160_ASM
454 -CFLAG= -DOPENSSL_NO_KRB5 -O
455 -DEPFLAG= 
456 +CFLAG= -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -DOPENSSL_NO_KRB5 -DOPENSSL_NO_IDEA -DOPENSSL_NO_MDC2 -DOPENSSL_NO_RC5 -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall
457 +DEPFLAG= -DOPENSSL_NO_IDEA -DOPENSSL_NO_MDC2 -DOPENSSL_NO_RC5 
458  PEX_LIBS= 
459 -EX_LIBS= 
460 +EX_LIBS= -ldl
461  EXE_EXT= 
462  ARFLAGS= 
463  AR=ar $(ARFLAGS) r
464  RANLIB= /usr/bin/ranlib
465 -PERL= /usr/local/bin/perl
466 +PERL= /usr/bin/perl
467  TAR= tar
468  TARFLAGS= --no-recursion
469 -MAKEDEPPROG=makedepend
470 +MAKEDEPPROG= gcc
471  
472  # We let the C compiler driver to take care of .s files. This is done in
473  # order to be excused from maintaining a separate set of architecture
474 @@ -175,13 +176,13 @@
475  # we might set SHLIB_MARK to '$(SHARED_LIBS)'.
476  SHLIB_MARK=
477  
478 -DIRS=   crypto ssl $(SHLIB_MARK) apps test tools
479 +DIRS=   crypto ssl $(SHLIB_MARK) apps doc tools
480  SHLIBDIRS= crypto ssl
481  
482  # dirs in crypto to build
483  SDIRS=  \
484 -       md2 md4 md5 sha mdc2 hmac ripemd \
485 -       des rc2 rc4 rc5 idea bf cast \
486 +       md2 md4 md5 sha hmac ripemd \
487 +       des rc2 rc4 bf cast \
488         bn ec rsa dsa dh dso engine aes \
489         buffer bio stack lhash rand err objects \
490         evp asn1 pem x509 x509v3 conf txt_db pkcs7 pkcs12 comp ocsp ui krb5
491 @@ -193,10 +194,10 @@
492  MAKEFILE= Makefile.ssl
493  MAKE=     make -f Makefile.ssl
494  
495 -MANDIR=$(OPENSSLDIR)/man
496 +MANDIR=/usr/share/man
497  MAN1=1
498  MAN3=3
499 -MANSUFFIX=
500 +MANSUFFIX=ssl
501  SHELL=/bin/sh
502  
503  TOP=    .
504 @@ -207,7 +208,7 @@
505  SHARED_CRYPTO=libcrypto$(SHLIB_EXT)
506  SHARED_SSL=libssl$(SHLIB_EXT)
507  SHARED_LIBS=
508 -SHARED_LIBS_LINK_EXTS=
509 +SHARED_LIBS_LINK_EXTS=.so
510  SHARED_LDFLAGS=
511  
512  GENERAL=        Makefile
513 @@ -797,7 +798,7 @@
514         do \
515                 if [ -f "$$i" ]; then \
516                 (       echo installing $$i; \
517 -                       cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
518 +                       cp -d $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
519                         $(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
520                         chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
521                         mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
522 --- openssl-0.9.7d.orig/os2/backwardify.pl
523 +++ openssl-0.9.7d/os2/backwardify.pl
524 @@ -1,4 +1,4 @@
525 -#!/usr/bin/perl -w
526 +#!/usr/local/bin/perl
527  use strict;
528  
529  # Use as $0
530 --- openssl-0.9.7d.orig/ssl/Makefile.ssl
531 +++ openssl-0.9.7d/ssl/Makefile.ssl
532 @@ -24,6 +24,7 @@
533  TEST=ssltest.c
534  APPS=
535  
536 +#LIB=libssl.la
537  LIB=$(TOP)/libssl.a
538  SHARED_LIB= libssl$(SHLIB_EXT)
539  LIBSRC=        \
540 @@ -58,6 +59,7 @@
541  all:   shared
542  
543  lib:   $(LIBOBJ)
544 +#      $(AR) $(LIB) *.lo
545         $(AR) $(LIB) $(LIBOBJ)
546         $(RANLIB) $(LIB) || echo Never mind.
547         @touch lib
548 @@ -100,6 +102,8 @@
549  
550  clean:
551         rm -f *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
552 +       rm -f *.lo *.la
553 +       rm -rf .libs
554  
555  # DO NOT DELETE THIS LINE -- make depend depends on it.
556  
557 --- openssl-0.9.7d.orig/ssl/ssl_algs.c
558 +++ openssl-0.9.7d/ssl/ssl_algs.c
559 @@ -109,3 +109,8 @@
560         return(1);
561         }
562  
563 +#undef SSLeay_add_ssl_algorithms
564 +int SSLeay_add_ssl_algorithms(void)
565 +    {
566 +         return SSL_library_init();
567 +    }
568 --- openssl-0.9.7d.orig/test/Makefile.ssl
569 +++ openssl-0.9.7d/test/Makefile.ssl
570 @@ -3,7 +3,7 @@
571  #
572  
573  DIR=           test
574 -TOP=           ..
575 +TOP=           $(shell pwd)/..
576  CC=            cc
577  INCLUDES=      -I$(TOP) -I../include $(KRB5_INCLUDES)
578  CFLAG=         -g
579 @@ -29,6 +29,10 @@
580         tpkcs7.com tpkcs7d.com tverify.com testgen.com testss.com testssl.com \
581         testca.com VMSca-response.1 VMSca-response.2
582  
583 +#DLIBCRYPTO= ../crypto/.libs/libcrypto.a
584 +#DLIBSSL= ../ssl/.libs/libssl.a
585 +#LIBCRYPTO= -L$(TOP)/crypto/.libs -lcrypto
586 +#LIBSSL= -L$(TOP)/ssl/.libs -lssl
587  DLIBCRYPTO= ../libcrypto.a
588  DLIBSSL= ../libssl.a
589  LIBCRYPTO= -L.. -lcrypto
590 --- openssl-0.9.7d.orig/tools/c_issuer
591 +++ openssl-0.9.7d/tools/c_issuer
592 @@ -6,5 +6,5 @@
593  for i in $*
594  do
595         n=`openssl x509 -issuer -noout -in $i`
596 -       echo "$i\t$n"
597 +       echo -e "$i\t$n"
598  done
599 --- openssl-0.9.7d.orig/tools/c_rehash
600 +++ openssl-0.9.7d/tools/c_rehash
601 @@ -1,4 +1,4 @@
602 -#!/usr/local/bin/perl
603 +#!/usr/bin/perl
604  
605  
606  # Perl c_rehash script, scan all files in a directory
607 --- openssl-0.9.7d.orig/tools/c_rehash.in
608 +++ openssl-0.9.7d/tools/c_rehash.in
609 @@ -1,4 +1,4 @@
610 -#!/usr/local/bin/perl
611 +#!/usr/bin/perl
612  
613  
614  # Perl c_rehash script, scan all files in a directory
615 --- openssl-0.9.7d.orig/util/clean-depend.pl
616 +++ openssl-0.9.7d/util/clean-depend.pl
617 @@ -1,4 +1,4 @@
618 -#!/usr/local/bin/perl -w
619 +#!/usr/local/bin/perl
620  # Clean the dependency list in a makefile of standard includes...
621  # Written by Ben Laurie <ben@algroup.co.uk> 19 Jan 1999
622  
623 --- openssl-0.9.7d.orig/util/extract-names.pl
624 +++ openssl-0.9.7d/util/extract-names.pl
625 @@ -1,4 +1,4 @@
626 -#!/usr/bin/perl
627 +#!/usr/local/bin/perl
628  
629  $/ = "";                       # Eat a paragraph at once.
630  while(<STDIN>) {
631 --- openssl-0.9.7d.orig/util/mkdef.pl
632 +++ openssl-0.9.7d/util/mkdef.pl
633 @@ -1,4 +1,4 @@
634 -#!/usr/local/bin/perl -w
635 +#!/usr/local/bin/perl
636  #
637  # generate a .def file
638  #
639 --- openssl-0.9.7d.orig/util/mkerr.pl
640 +++ openssl-0.9.7d/util/mkerr.pl
641 @@ -1,4 +1,4 @@
642 -#!/usr/local/bin/perl -w
643 +#!/usr/local/bin/perl
644  
645  my $config = "crypto/err/openssl.ec";
646  my $debug = 0;
647 --- openssl-0.9.7d.orig/util/mkstack.pl
648 +++ openssl-0.9.7d/util/mkstack.pl
649 @@ -1,4 +1,4 @@
650 -#!/usr/local/bin/perl -w
651 +#!/usr/local/bin/perl
652  
653  # This is a utility that searches out "DECLARE_STACK_OF()"
654  # declarations in .h and .c files, and updates/creates/replaces
655 --- openssl-0.9.7d.orig/util/pod2man.pl
656 +++ openssl-0.9.7d/util/pod2man.pl
657 @@ -1,4 +1,4 @@
658 -: #!/usr/bin/perl-5.005
659 +#!/usr/local/bin/perl
660      eval 'exec /usr/bin/perl -S $0 ${1+"$@"}'
661         if $running_under_some_shell;
662  
663 --- openssl-0.9.7d.orig/util/selftest.pl
664 +++ openssl-0.9.7d/util/selftest.pl
665 @@ -1,4 +1,4 @@
666 -#!/usr/local/bin/perl -w
667 +#!/usr/local/bin/perl
668  #
669  # Run the test suite and generate a report
670  #