[Haskell-cafe] Unix gurus, help me please

Bulat Ziganshin bulat.ziganshin at gmail.com
Mon Jul 17 11:58:23 EDT 2006

Hello Eugene,

Monday, July 17, 2006, 6:41:26 PM, you wrote:
>> - I include file io.h, but this particular system has "sys/io.h"
>> instead.

> Just out of the blue: could it be that you rather need <fcntl.h>?
> It's the place where open() and friends are defined.  Maybe(?) windows
> have them in <io.h>...

the only thing i import at this moment is fsync

>> - mingw supports _commit operation which (as i guess) saves to disk
>> buffers of given file. Is that true that regular unixes has fsync
>> function to perform the same action? (and what the hell MS don't
>> use the same name??)

> Not all unixes (unii?) have fsync() syscall, but most of them do.  And
> all modern ones, I guess.  If your platform does not have fsync(), it is
> recommended to fallback to sync().

i need only compatibility with platforms supported by Haskell
compilers - ghc, hugs and so on

Best regards,
 Bulat                            mailto:Bulat.Ziganshin at gmail.com

More information about the Haskell-Cafe mailing list