Hi,
 
I am trying to compile some source code picked up from the net, because i will have to adapt it to fit my own needs. My goal is to obtain a dll as small as possible.
 
The problem is this program is using the nanosleep function, and this function is definitly needed for the algorithm in itsef ( i cannot afford to take sleep for example, because i need to sleep just for a nanosecond).
 
When I try to compile it using mingw, i got the "undefined reference" to nanosleep, even though the time.h is in the include of the file. I guess this function is not implemented yet.
 
Thus i tried cygwin, and I succeded ( i'm not THAT bad ;) ) but the problem is now that as i will have to distribute this program as a DLL, i will have to distribute with it CYGWIN's dll, which is quite huge ( 888Ko...) and that definitly doesn't suits my needs.
 
Thus, here are my questions :
-Is it possible not to have to distribute the cygwin's dll along with program builded with cygwin or programs using dll made with cygwin ?
-Is there any way to get the nanosleep function work with mingw ?
-Is there any other gcc compiler for windows out there that can meet both these requirements ?
 
The source code i'm trying to compiled is supposed to be compatible with "both linux and windows gcc".
 
Thanks for your help !
 
Adrien