When I have this problem I normally go into the /usr/include or other include directories on the system and grep for the missing #define, in your case S_IWRITE. It always help to know what what compiler you are using when posting these types of C programming system questions.
BTW, nothing in the /include main dir on my linux box:
Quote:
# cd /usr/include
# grep S_IWRITE *.h
#
Sorry, I'm lazy to check the subdirectories and other directories (since you are on BSD and not linux... I'm just a linux basement here). Perhaps someone with BSD can grep?
[Edited by Neo on 02-27-2001 at 09:14 PM]