Thanks Linda for the reply.

I later came to know that I was using the fips opensslconf.h instead of one
from openssl sources.

With correct include file, I could build and execute my project properly.

Thanks again for the help.

Regards,
Mrunal



On Mon, Aug 25, 2014 at 5:09 PM, Linda Zhang <[email protected]> wrote:

> Hi Mrunal,
> It's due to the bad codes in the source file. Please edit
> crypto/evp/m_md2.c and add type conversions shown as below and retry
> building.
> ===
>  static int init(EVP_MD_CTX *ctx)
> -{ return MD2_Init(ctx->md_data); }
> +{ return MD2_Init((MD2_CTX *)ctx->md_data); }
>  static int update(EVP_MD_CTX *ctx,const void *data,size_t count)
> -{ return MD2_Update(ctx->md_data,data,count); }
> +{ return MD2_Update((MD2_CTX *)ctx->md_data, data, count); }
>  static int final(EVP_MD_CTX *ctx,unsigned char *md)
> -{ return MD2_Final(md,ctx->md_data); }
> +{ return MD2_Final(md, (MD2_CTX *)ctx->md_data); }
> ===
>
> Linda Zhang
>
> >Hi All,
> >
> >
> >I am trying building fips capable openssl and getting following error:
> >gcc -I.. -I../.. -I../modes -I../asn1 -I../evp -I../../include  -fPIC
> -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H
> -DOPENSSL_DOING_MAKEDEPEND >-DOPENSSL_NO_EC_NISTP_64_GCC_128
> -DOPENSSL_NO_SCTP -DOPENSSL_NO_JPAKE -DL_ENDIAN -DTERMIO -O3
> -fomit-frame-pointer -Wall
> -I/unixhome/mrnpawar/openssl/linux_x86/fips//include   >-c -o m_md2.o
> m_md2.c
> >m_md2.c: In function `init':
> >m_md2.c:74: error: void value not ignored as it ought to be
> >m_md2.c: In function `update':
> >m_md2.c:77: error: void value not ignored as it ought to be
> >m_md2.c: In function `final':
> >m_md2.c:80: error: void value not ignored as it ought to be
> >make[2]: *** [m_md2.o] Error 1
> >make[2]: Leaving directory
> `/unixhome/mrnpawar/openssl/linux_x86/openssl-1.0.1h/crypto/evp'
> >make[1]: *** [subdirs] Error 1
> >make[1]: Leaving directory
> `/unixhome/mrnpawar/openssl/linux_x86/openssl-1.0.1h/crypto'
> >make: *** [build_crypto] Error 1
> >
> >
> >Here is the sequence of build that i followed with options provided:
> >1) Copy  and Extract sources
> >
> >2) cd openssl-fips-ecp-2.0.5
> >
> >3) run :
> >./config
> >make
> >make install INSTALLTOP=/linux_x86/fips
> >
> >4) cd openssl-1.0.1h
> >5) run :
> > ./config fips shared no-idea no-mdc2 no-ec2m  no-asm no-sctp no-jpake
> md2 -DOPENSSL_DOING_MAKEDEPEND -DOPENSSL_NO_EC_NISTP_64_GCC_128
> -DOPENSSL_NO_SCTP -DOPENSSL_NO_JPAKE
> >--with-fipslibdir=/unixhome/mrnpawar/openssl/linux_x86/fips/lib/
> --with-fipsdir=/unixhome/mrnpawar/openssl/linux_x86/fips/
> >
> >make depend
> >
> >make
> >
> >
> >The errors are seen in the last make run.
> >
> >I checked definition of init, update and final functions in md2.h which
> return int value. not sure what is causing this error. Need urgent help on
> this.
> >
> >
> >Also, in the config option,i have added -DOPENSSL_DOING_MAKEDEPEND
> -DOPENSSL_NO_EC_NISTP_64_GCC_128 -DOPENSSL_NO_SCTP -DOPENSSL_NO_JPAKE to
> avoid many other errors.
> >
> >Any suggestions to achieve the same with other options?
> >
> >
> >
> >
> >Thanks & Regards,
> >Mrunal
>
>
>
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> Development Mailing List                       [email protected]
> Automated List Manager                           [email protected]
>

Reply via email to