This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Alarm callbacks on Windows with Gnu or MinGW?


Please excuse me if this is the wrong location for this post - I
looked long and hard before I posted, and would be happy to be
redirected!

I am using C++ in Eclipse with CDT and MinGW on a Windows machine.
I'd prefer not to use VC++.

I would like to implement a simple alarm callback, a la 'C', where I
set a timer to go off and use a signal catcher to catch the
interrupt/exception/signal/whatever.

(as, on Unix/Linux, signal(SIG_ALRM, FPTR); alarm(nsec); where FPTR is
a pointer to a function that will asynchronously handle the signal
SIG_ALRM)

I don't find support for SIG_ALRM in MinGW, though other signals are defined.

My Googles have left me fairly convinced that I can't do this without
including the VC++ libraries - is this true?

Thanks,

Dana Good


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]