Peter Schmiedeskamp wrote :
Hi, during the process of compiling OpenSSL 0.9.7e on
AIX 5.3, I ran into a compile issue whereby
"fips_rand.c" attempted to redefine
_XOPEN_SOURCE_EXTENDED which is already defined in
AIX's system headers.

Here's a patch that worked for me:

--- fips_rand.c.orig 2005-03-10 08:30:39.000000000
-0700
+++ fips_rand.c 2005-03-09 15:27:59.000000000 -0700
@@ -56,7 +56,9 @@
/* If we don't define _XOPEN_SOURCE_EXTENDED, struct
timeval won't
be defined and gettimeofday() won't be declared
with strict compilers
like DEC C in ANSI C mode. */
+#ifndef _XOPEN_SOURCE_EXTENDED
#define _XOPEN_SOURCE_EXTENDED
+#endif
#include <openssl/des.h>
#include <openssl/rand.h>

Hi there,

the above patch also works on AIX 5.2.

However, openssl built in 64bits mode fails SQR test:

# openssl-0.9.7e > make test
[... stuff deleted ...]
starting big number library test, could take a while...
test BN_add
test BN_sub
test BN_lshift1
test BN_lshift (fixed)
test BN_lshift
test BN_rshift1
test BN_rshift
test BN_sqr
Square test failed!
gmake[1]: *** [test_bn] Error 1
gmake[1]: Leaving directory `/openssl-0.9.7e/test'
gmake: *** [tests] Error 2

# openssl-0.9.7e > openssl version -a
OpenSSL 0.9.7e 25 Oct 2004
built on: Tue Mar 22 15:25:44 NFT 2005
platform: aix43-cc
options: bn(64,64) md2(int) rc4(ptr,char) des(idx,cisc,4,long) idea(int) blowfish(idx)
compiler: cc -q64 -qwarn64 -DOPENSSL_THREADS -DDSO_DLFCN -DHAVE_DLFCN_H -DOPENSSL_NO_KRB5 -O -DAIX -DB_ENDIAN -qmaxmem=16384
OPENSSLDIR: "/usr/local/ssl"


# openssl-0.9.7e > file ./apps/openssl
./apps/openssl: 64-bit XCOFF executable or object module not stripped

# openssl-0.9.7e >

The same test fails with OpenSSL 0.9.7d.
In addition to the above '-q64 and -qwarn64' options, I set OBJECT_MODE=64 environment variable to get 64bits binaries upon link.



Both 0.9.7d and 0.9.7e successfully pass the BN_sqr test when built in 32bits mode.


Any hint ?

PS: Is OpenSSL on AIX 5.2 64bits still trustworthy with this failure in BN_sqr ?

--
Mr. Jacques LEBASTARD            mailto:[EMAIL PROTECTED]
EVIDIAN S.A.                     www.evidian.com
Rue Jean Jaurès                  Tel: +33 1 30 80 77 86
F-78340 LES CLAYES SOUS BOIS     Fax: +33 1 30 80 77 99

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to