The latest tarball for head failed to compile for DJGPP because an
include file from the WATT32 distribution (tcp.h), required in the DJGPP
build, defines "byte" as "unsigned char". This patch renames "byte" to
"byte_ssl" in ssl/ssl_rsa.c to avoid the problem. Otherwise the DJGPP
compilation went fine and passed all the tests, using my compilation
options (Configure no-threads no-idea 386 DJGPP).
The patch is attached. Here is the output of openssl version -a:
OpenSSL 1.1.0-dev xx XXX xxxx
built on: Sun Nov 25 13:57:47 PST 2012
platform: DJGPP
options: bn(64,32) rc4(4x,int) des(ptr,risc1,16,long) blowfish(idx)
compiler: gcc -I/dev/env/WATT_ROOT/inc -DTERMIOS -DL_ENDIAN
-fomit-frame-pointer -O2 -Wall -DOPENSSL_BN_ASM_PART_WORDS
-DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM
-DSHA512_ASM -DMD5_ASM -DRMD160_ASM -DAES_ASM -DGHASH_ASM
OPENSSLDIR: "/dev/env/DJDIR/ssl"
Doug
--
Doug Kaufman
Internet: [email protected]
--- ssl/ssl_rsa.c.ori 2012-06-07 07:00:06.000000000 -0700
+++ ssl/ssl_rsa.c 2012-11-25 16:45:46.000000000 -0800
@@ -825,7 +825,7 @@
for (;;)
{
- unsigned char type, byte, bit;
+ unsigned char type, byte_ssl, bit;
unsigned short len;
if (!length)
@@ -834,11 +834,11 @@
type = *(authz++);
length--;
- byte = type / 8;
+ byte_ssl = type / 8;
bit = type & 7;
- if (types_seen_bitmap[byte] & (1 << bit))
+ if (types_seen_bitmap[byte_ssl] & (1 << bit))
return 0;
- types_seen_bitmap[byte] |= (1 << bit);
+ types_seen_bitmap[byte_ssl] |= (1 << bit);
if (length < 2)
return 0;