> "clock_id undeclared,
This is a POSIX type which is not available under Win32.
> clock_realtime undeclared......blablabla"
I see no 'clock_realtime' in code you provided. I assume you mean
> and when i went back to check time.h, I found really that this
> parameters were not defined there.
Now what does that tell you ?
> However, I think they should be there.Because the below program
> lines are given by books:(
Those books are presumably written for POISX and/or **IX-like OSes.
MinGW strives to be a replacement for MS VisualC++ under Win32.
Therefor it includes all that is used/defined there and only very
little on top of that.
To put it simple the idea is to be able to compile all code that
compiles with MSVC and vice versa. And to be able to mix compilers,
i.e. have some parts compiled with MSVC and some using MinGW.
Nothing less but also nothing more.
> And I don't know what other else I should install to run the below
> program,to solve this problem....
Under Linux it should compile out-of-the-box.
Under Win32 you'll have to replace the POSIX structures and APIs
by those provided by the Win32 API. Check the Win32 Platform SDK
documentation for details.
Sorry, but e.g. clock_gettime simply isn't available under native
Win32. I'd assume cygwin does provide that but I don't know.
On the other hand neither MSVC nor Borland or any other Win32 C/C++
Compiler I know of does compile your below code (as I wrote I'd
assume cygwin does).
Vote against SPAM - see http://www.politik-digital.de/spam/
Michael Gerdau email: mgd@...
GPG-keys available on request or at public keyserver