Subject: Re: GNU-Win32 : gettimeofday
From: [email-masked] (Chin Chee-Kai)

30 May 1997 02:05:22 -0700
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Original-To: GNU Win32 <[email-masked]>
Original-Cc: Lim Chu Cheow <[email-masked]>
In-Reply-To: <[email-masked]>
Original-Sender: [email-masked]

Just to add to this, I compiled the exact same program
on b17.1 on Win95 and got a smooth compiled binary that
run :

C:\tmp>gcc test.c
test.c: In function `main':
test.c:5: warning: return type of `main' is not `int'

C:\tmp>a
Hello world!!
Current time = 864984734.359000 s

(I had to eventually revert back to b17.1 as gcc ran 
way too slowly on my project and the resulting binary
doesn't even run.)

Chin Chee-Kai
Internet Email: [email-masked]
Sterling Software Asia Pacific Group
Tel: (65)-732-9996	Fax: (65)-733-4358
	
On Thu, 29 May 1997, Lim Chu Cheow wrote:

> Hi,
> I just installed b18, and compiled a simple program 
> (given below).  Compilation went through, but the 
> execution received some exception and died.  Am I 
> missing something?  Thanks in advance for any advice.
> 
> ============
> #include <stdio.h>
> #include <sys/time.h>
> 
> void main(void)
> {
>   struct timeval tp;
> 
>   fprintf(stdout,"Hello world!!\n");
>   gettimeofday(&tp);
>   fprintf(stdout,"Current time = %lf s\n", 
> 	  ((double)tp.tv_sec+tp.tv_usec*1.0e-6));
> }
> 
> ==============
> - Chu-Cheow
> -
> For help on using this list (especially unsubscribing), send a message to
> "[email-masked]" with one line of text: "help".
> 

-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".