Hello Ganesh,

For Vxworks you should include <sys/times.h>.

Vxworks doesn't have a "times" function,
however, Vxworks has a "time" function.
Also, Vxworks has "random" and
"srandom" function.

About "Time_F" function in "apps" directory,
I have not ported this directory. I have
ported only the "ssl" and "crypto" directories.
I don't think "Time_F" function is used in
the crypto directory (looks like it is used
only in speed.c and s_time.c in the apps
directory).

These are the files I have compiled in "des" directory

CLIST = \
cbc_cksm.c cbc_enc.c  cfb64enc.c cfb_enc.c  \
        ecb3_enc.c ecb_enc.c  enc_read.c enc_writ.c \
        fcrypt.c ofb64enc.c ofb_enc.c  pcbc_enc.c \
        qud_cksm.c rand_key.c read_pwd.c rpc_enc.c  set_key.c  \
        des_enc.c fcrypt_b.c read2pwd.c \
        xcbc_enc.c \
        str2key.c  cfb64ede.c ofb64ede.c ede_cbcm_enc.c

Also, I have attached herewith the Vxworks changes
I did in e_os.h.

Hope that this helps.

Regards,
Prashant.



-----Original Message-----
From: ganesh kumar godavari [mailto:[EMAIL PROTECTED]]
Sent: Saturday, January 26, 2002 10:09 PM
To: Kumar, Prashant [BL60:437:EXCH]
Cc: [EMAIL PROTECTED]
Subject: RE: OpenSSL ported to VxWorks?



hello,
 i am trying to port openssl-0.96b onto VxWorks. i found the ftime and alarm
functions missing in VxWorks.

does VxWorks have related function for ftime and alarm?. if so can u tell
me.

have u been successful in porting rand functions? i am facing some problem
as VxWorks doesn't have <sys/un.h> header. can u tell me the how to port
rand functions.

i am also facing some problem with des too. i am getting an error saying
"des_cbc_encrypt" func is declare multiple times. i looked into it but it
was defined only once. can u send me the make file for DES?

sending a copy of Time_f function that is widely used
in most of the crypto library.


double Time_F(int s)
        {
        double ret;
#ifdef TIMES
        static struct tms tstart,tend;

        if (s == START)
                {
                times(&tstart);
                return(0);
                }
        else
                {
                times(&tend);
                ret=((double)(tend.tms_utime-tstart.tms_utime))/HZ;
                return((ret == 0.0)?1e-6:ret);
                }
#else /* !times() */
        static struct timeb tstart,tend;
        long i;

        if (s == START)
                {
                ftime(&tstart);
                return(0);
                }
        else
                {
                ftime(&tend);
                i=(long)tend.millitm-(long)tstart.millitm;
                ret=((double)(tend.time-tstart.time))+((double)i)/1000.0;
                return((ret == 0.0)?1e-6:ret);
                }
#endif
        }



Thanks,
gkgodava


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

Attachment: e_os.h
Description: Binary data

Reply via email to